diff --git a/generation_config.yaml b/generation_config.yaml index a2f41f0e02a4..3a9aa5852f4b 100644 --- a/generation_config.yaml +++ b/generation_config.yaml @@ -1,5 +1,5 @@ gapic_generator_version: 2.62.1 -googleapis_commitish: 6d1dca2b8e3d50914609414e219df2778b2b20ba +googleapis_commitish: 9978d435df71bb16ecadd1e4421640748d0bf533 libraries_bom_version: 26.67.0 # the libraries are ordered with respect to library name, which is diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClient.java new file mode 100644 index 000000000000..2f663f7a59db --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClient.java @@ -0,0 +1,3144 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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.dataplex.v1.stub.BusinessGlossaryServiceStub; +import com.google.cloud.dataplex.v1.stub.BusinessGlossaryServiceStubSettings; +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 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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: BusinessGlossaryService provides APIs for managing business glossary + * resources for enterprise customers. The resources currently supported in Business Glossary are: + * 1. Glossary 2. GlossaryCategory 3. GlossaryTerm + * + *

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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+ *     BusinessGlossaryServiceClient.create()) {
+ *   GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+ *   Glossary response = businessGlossaryServiceClient.getGlossary(name);
+ * }
+ * }
+ * + *

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

CreateGlossary

Creates a new Glossary resource.

+ *

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

+ *
    + *
  • createGlossaryAsync(CreateGlossaryRequest request) + *

+ *

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

+ *
    + *
  • createGlossaryAsync(LocationName parent, Glossary glossary, String glossaryId) + *

  • createGlossaryAsync(String parent, Glossary glossary, String glossaryId) + *

+ *

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

+ *
    + *
  • createGlossaryOperationCallable() + *

  • createGlossaryCallable() + *

+ *

UpdateGlossary

Updates a Glossary resource.

+ *

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

+ *
    + *
  • updateGlossaryAsync(UpdateGlossaryRequest request) + *

+ *

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

+ *
    + *
  • updateGlossaryAsync(Glossary glossary, 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.

+ *
    + *
  • updateGlossaryOperationCallable() + *

  • updateGlossaryCallable() + *

+ *

DeleteGlossary

Deletes a Glossary resource. All the categories and terms within the Glossary must be deleted before the Glossary can be deleted.

+ *

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

+ *
    + *
  • deleteGlossaryAsync(DeleteGlossaryRequest request) + *

+ *

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

+ *
    + *
  • deleteGlossaryAsync(GlossaryName name) + *

  • deleteGlossaryAsync(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.

+ *
    + *
  • deleteGlossaryOperationCallable() + *

  • deleteGlossaryCallable() + *

+ *

GetGlossary

Gets a Glossary resource.

+ *

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

+ *
    + *
  • getGlossary(GetGlossaryRequest request) + *

+ *

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

+ *
    + *
  • getGlossary(GlossaryName name) + *

  • getGlossary(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.

+ *
    + *
  • getGlossaryCallable() + *

+ *

ListGlossaries

Lists Glossary resources in a project and location.

+ *

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

+ *
    + *
  • listGlossaries(ListGlossariesRequest request) + *

+ *

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

+ *
    + *
  • listGlossaries(LocationName parent) + *

  • listGlossaries(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.

+ *
    + *
  • listGlossariesPagedCallable() + *

  • listGlossariesCallable() + *

+ *

CreateGlossaryCategory

Creates a new GlossaryCategory resource.

+ *

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

+ *
    + *
  • createGlossaryCategory(CreateGlossaryCategoryRequest request) + *

+ *

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

+ *
    + *
  • createGlossaryCategory(GlossaryName parent, GlossaryCategory category, String categoryId) + *

  • createGlossaryCategory(String parent, GlossaryCategory category, String categoryId) + *

+ *

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

+ *
    + *
  • createGlossaryCategoryCallable() + *

+ *

UpdateGlossaryCategory

Updates a GlossaryCategory resource.

+ *

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

+ *
    + *
  • updateGlossaryCategory(UpdateGlossaryCategoryRequest request) + *

+ *

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

+ *
    + *
  • updateGlossaryCategory(GlossaryCategory category, 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.

+ *
    + *
  • updateGlossaryCategoryCallable() + *

+ *

DeleteGlossaryCategory

Deletes a GlossaryCategory resource. All the GlossaryCategories and GlossaryTerms nested directly under the specified GlossaryCategory will be moved one level up to the parent in the hierarchy.

+ *

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

+ *
    + *
  • deleteGlossaryCategory(DeleteGlossaryCategoryRequest request) + *

+ *

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

+ *
    + *
  • deleteGlossaryCategory(GlossaryCategoryName name) + *

  • deleteGlossaryCategory(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.

+ *
    + *
  • deleteGlossaryCategoryCallable() + *

+ *

GetGlossaryCategory

Gets a GlossaryCategory resource.

+ *

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

+ *
    + *
  • getGlossaryCategory(GetGlossaryCategoryRequest request) + *

+ *

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

+ *
    + *
  • getGlossaryCategory(GlossaryCategoryName name) + *

  • getGlossaryCategory(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.

+ *
    + *
  • getGlossaryCategoryCallable() + *

+ *

ListGlossaryCategories

Lists GlossaryCategory resources in a Glossary.

+ *

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

+ *
    + *
  • listGlossaryCategories(ListGlossaryCategoriesRequest request) + *

+ *

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

+ *
    + *
  • listGlossaryCategories(GlossaryName parent) + *

  • listGlossaryCategories(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.

+ *
    + *
  • listGlossaryCategoriesPagedCallable() + *

  • listGlossaryCategoriesCallable() + *

+ *

CreateGlossaryTerm

Creates a new GlossaryTerm resource.

+ *

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

+ *
    + *
  • createGlossaryTerm(CreateGlossaryTermRequest request) + *

+ *

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

+ *
    + *
  • createGlossaryTerm(GlossaryName parent, GlossaryTerm term, String termId) + *

  • createGlossaryTerm(String parent, GlossaryTerm term, String termId) + *

+ *

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

+ *
    + *
  • createGlossaryTermCallable() + *

+ *

UpdateGlossaryTerm

Updates a GlossaryTerm resource.

+ *

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

+ *
    + *
  • updateGlossaryTerm(UpdateGlossaryTermRequest request) + *

+ *

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

+ *
    + *
  • updateGlossaryTerm(GlossaryTerm term, 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.

+ *
    + *
  • updateGlossaryTermCallable() + *

+ *

DeleteGlossaryTerm

Deletes a GlossaryTerm resource.

+ *

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

+ *
    + *
  • deleteGlossaryTerm(DeleteGlossaryTermRequest request) + *

+ *

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

+ *
    + *
  • deleteGlossaryTerm(GlossaryTermName name) + *

  • deleteGlossaryTerm(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.

+ *
    + *
  • deleteGlossaryTermCallable() + *

+ *

GetGlossaryTerm

Gets a GlossaryTerm resource.

+ *

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

+ *
    + *
  • getGlossaryTerm(GetGlossaryTermRequest request) + *

+ *

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

+ *
    + *
  • getGlossaryTerm(GlossaryTermName name) + *

  • getGlossaryTerm(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.

+ *
    + *
  • getGlossaryTermCallable() + *

+ *

ListGlossaryTerms

Lists GlossaryTerm resources in a Glossary.

+ *

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

+ *
    + *
  • listGlossaryTerms(ListGlossaryTermsRequest request) + *

+ *

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

+ *
    + *
  • listGlossaryTerms(GlossaryName parent) + *

  • listGlossaryTerms(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.

+ *
    + *
  • listGlossaryTermsPagedCallable() + *

  • listGlossaryTermsCallable() + *

+ *

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() + *

+ *
+ * + *

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 + * BusinessGlossaryServiceSettings 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
+ * BusinessGlossaryServiceSettings businessGlossaryServiceSettings =
+ *     BusinessGlossaryServiceSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * BusinessGlossaryServiceClient businessGlossaryServiceClient =
+ *     BusinessGlossaryServiceClient.create(businessGlossaryServiceSettings);
+ * }
+ * + *

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
+ * BusinessGlossaryServiceSettings businessGlossaryServiceSettings =
+ *     BusinessGlossaryServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * BusinessGlossaryServiceClient businessGlossaryServiceClient =
+ *     BusinessGlossaryServiceClient.create(businessGlossaryServiceSettings);
+ * }
+ * + *

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
+ * BusinessGlossaryServiceSettings businessGlossaryServiceSettings =
+ *     BusinessGlossaryServiceSettings.newHttpJsonBuilder().build();
+ * BusinessGlossaryServiceClient businessGlossaryServiceClient =
+ *     BusinessGlossaryServiceClient.create(businessGlossaryServiceSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@Generated("by gapic-generator-java") +public class BusinessGlossaryServiceClient implements BackgroundResource { + private final BusinessGlossaryServiceSettings settings; + private final BusinessGlossaryServiceStub stub; + private final OperationsClient httpJsonOperationsClient; + private final com.google.longrunning.OperationsClient operationsClient; + + /** Constructs an instance of BusinessGlossaryServiceClient with default settings. */ + public static final BusinessGlossaryServiceClient create() throws IOException { + return create(BusinessGlossaryServiceSettings.newBuilder().build()); + } + + /** + * Constructs an instance of BusinessGlossaryServiceClient, 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 BusinessGlossaryServiceClient create(BusinessGlossaryServiceSettings settings) + throws IOException { + return new BusinessGlossaryServiceClient(settings); + } + + /** + * Constructs an instance of BusinessGlossaryServiceClient, using the given stub for making calls. + * This is for advanced usage - prefer using create(BusinessGlossaryServiceSettings). + */ + public static final BusinessGlossaryServiceClient create(BusinessGlossaryServiceStub stub) { + return new BusinessGlossaryServiceClient(stub); + } + + /** + * Constructs an instance of BusinessGlossaryServiceClient, 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 BusinessGlossaryServiceClient(BusinessGlossaryServiceSettings settings) + throws IOException { + this.settings = settings; + this.stub = ((BusinessGlossaryServiceStubSettings) settings.getStubSettings()).createStub(); + this.operationsClient = + com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); + this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); + } + + protected BusinessGlossaryServiceClient(BusinessGlossaryServiceStub 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 BusinessGlossaryServiceSettings getSettings() { + return settings; + } + + public BusinessGlossaryServiceStub 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. + /** + * Creates a new Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   Glossary glossary = Glossary.newBuilder().build();
+   *   String glossaryId = "glossaryId1849967577";
+   *   Glossary response =
+   *       businessGlossaryServiceClient.createGlossaryAsync(parent, glossary, glossaryId).get();
+   * }
+   * }
+ * + * @param parent Required. The parent resource where this Glossary will be created. Format: + * projects/{project_id_or_number}/locations/{location_id} where `location_id` refers to a + * Google Cloud region. + * @param glossary Required. The Glossary to create. + * @param glossaryId Required. Glossary ID: Glossary identifier. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createGlossaryAsync( + LocationName parent, Glossary glossary, String glossaryId) { + CreateGlossaryRequest request = + CreateGlossaryRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setGlossary(glossary) + .setGlossaryId(glossaryId) + .build(); + return createGlossaryAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   Glossary glossary = Glossary.newBuilder().build();
+   *   String glossaryId = "glossaryId1849967577";
+   *   Glossary response =
+   *       businessGlossaryServiceClient.createGlossaryAsync(parent, glossary, glossaryId).get();
+   * }
+   * }
+ * + * @param parent Required. The parent resource where this Glossary will be created. Format: + * projects/{project_id_or_number}/locations/{location_id} where `location_id` refers to a + * Google Cloud region. + * @param glossary Required. The Glossary to create. + * @param glossaryId Required. Glossary ID: Glossary identifier. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture createGlossaryAsync( + String parent, Glossary glossary, String glossaryId) { + CreateGlossaryRequest request = + CreateGlossaryRequest.newBuilder() + .setParent(parent) + .setGlossary(glossary) + .setGlossaryId(glossaryId) + .build(); + return createGlossaryAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   CreateGlossaryRequest request =
+   *       CreateGlossaryRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setGlossaryId("glossaryId1849967577")
+   *           .setGlossary(Glossary.newBuilder().build())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Glossary response = businessGlossaryServiceClient.createGlossaryAsync(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 createGlossaryAsync( + CreateGlossaryRequest request) { + return createGlossaryOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new Glossary resource. + * + *

Sample code: + * + *

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

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   Glossary glossary = Glossary.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   Glossary response =
+   *       businessGlossaryServiceClient.updateGlossaryAsync(glossary, updateMask).get();
+   * }
+   * }
+ * + * @param glossary Required. The Glossary to update. The Glossary's `name` field is used to + * identify the Glossary to update. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * @param updateMask Required. The list of fields to update. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture updateGlossaryAsync( + Glossary glossary, FieldMask updateMask) { + UpdateGlossaryRequest request = + UpdateGlossaryRequest.newBuilder().setGlossary(glossary).setUpdateMask(updateMask).build(); + return updateGlossaryAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   UpdateGlossaryRequest request =
+   *       UpdateGlossaryRequest.newBuilder()
+   *           .setGlossary(Glossary.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   Glossary response = businessGlossaryServiceClient.updateGlossaryAsync(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 updateGlossaryAsync( + UpdateGlossaryRequest request) { + return updateGlossaryOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a Glossary resource. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   UpdateGlossaryRequest request =
+   *       UpdateGlossaryRequest.newBuilder()
+   *           .setGlossary(Glossary.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .setValidateOnly(true)
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.updateGlossaryCallable().futureCall(request);
+   *   // Do something.
+   *   Operation response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable updateGlossaryCallable() { + return stub.updateGlossaryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Glossary resource. All the categories and terms within the Glossary must be deleted + * before the Glossary can be deleted. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+   *   businessGlossaryServiceClient.deleteGlossaryAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the Glossary to delete. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteGlossaryAsync(GlossaryName name) { + DeleteGlossaryRequest request = + DeleteGlossaryRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteGlossaryAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Glossary resource. All the categories and terms within the Glossary must be deleted + * before the Glossary can be deleted. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString();
+   *   businessGlossaryServiceClient.deleteGlossaryAsync(name).get();
+   * }
+   * }
+ * + * @param name Required. The name of the Glossary to delete. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final OperationFuture deleteGlossaryAsync(String name) { + DeleteGlossaryRequest request = DeleteGlossaryRequest.newBuilder().setName(name).build(); + return deleteGlossaryAsync(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Glossary resource. All the categories and terms within the Glossary must be deleted + * before the Glossary can be deleted. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   DeleteGlossaryRequest request =
+   *       DeleteGlossaryRequest.newBuilder()
+   *           .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setEtag("etag3123477")
+   *           .build();
+   *   businessGlossaryServiceClient.deleteGlossaryAsync(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 deleteGlossaryAsync( + DeleteGlossaryRequest request) { + return deleteGlossaryOperationCallable().futureCall(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Glossary resource. All the categories and terms within the Glossary must be deleted + * before the Glossary can be deleted. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   DeleteGlossaryRequest request =
+   *       DeleteGlossaryRequest.newBuilder()
+   *           .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setEtag("etag3123477")
+   *           .build();
+   *   OperationFuture future =
+   *       businessGlossaryServiceClient.deleteGlossaryOperationCallable().futureCall(request);
+   *   // Do something.
+   *   future.get();
+   * }
+   * }
+ */ + public final OperationCallable + deleteGlossaryOperationCallable() { + return stub.deleteGlossaryOperationCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a Glossary resource. All the categories and terms within the Glossary must be deleted + * before the Glossary can be deleted. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+   *   Glossary response = businessGlossaryServiceClient.getGlossary(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Glossary to retrieve. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Glossary getGlossary(GlossaryName name) { + GetGlossaryRequest request = + GetGlossaryRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getGlossary(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString();
+   *   Glossary response = businessGlossaryServiceClient.getGlossary(name);
+   * }
+   * }
+ * + * @param name Required. The name of the Glossary to retrieve. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Glossary getGlossary(String name) { + GetGlossaryRequest request = GetGlossaryRequest.newBuilder().setName(name).build(); + return getGlossary(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GetGlossaryRequest request =
+   *       GetGlossaryRequest.newBuilder()
+   *           .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .build();
+   *   Glossary response = businessGlossaryServiceClient.getGlossary(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 Glossary getGlossary(GetGlossaryRequest request) { + return getGlossaryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a Glossary resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GetGlossaryRequest request =
+   *       GetGlossaryRequest.newBuilder()
+   *           .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.getGlossaryCallable().futureCall(request);
+   *   // Do something.
+   *   Glossary response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable getGlossaryCallable() { + return stub.getGlossaryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Glossary resources in a 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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
+   *   for (Glossary element : businessGlossaryServiceClient.listGlossaries(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, which has this collection of Glossaries. Format: + * projects/{project_id_or_number}/locations/{location_id} where `location_id` refers to a + * Google Cloud region. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGlossariesPagedResponse listGlossaries(LocationName parent) { + ListGlossariesRequest request = + ListGlossariesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listGlossaries(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Glossary resources in a 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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
+   *   for (Glossary element : businessGlossaryServiceClient.listGlossaries(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, which has this collection of Glossaries. Format: + * projects/{project_id_or_number}/locations/{location_id} where `location_id` refers to a + * Google Cloud region. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGlossariesPagedResponse listGlossaries(String parent) { + ListGlossariesRequest request = ListGlossariesRequest.newBuilder().setParent(parent).build(); + return listGlossaries(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Glossary resources in a 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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListGlossariesRequest request =
+   *       ListGlossariesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (Glossary element : businessGlossaryServiceClient.listGlossaries(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 ListGlossariesPagedResponse listGlossaries(ListGlossariesRequest request) { + return listGlossariesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Glossary resources in a 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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListGlossariesRequest request =
+   *       ListGlossariesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.listGlossariesPagedCallable().futureCall(request);
+   *   // Do something.
+   *   for (Glossary element : future.get().iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listGlossariesPagedCallable() { + return stub.listGlossariesPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists Glossary resources in a 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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListGlossariesRequest request =
+   *       ListGlossariesRequest.newBuilder()
+   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListGlossariesResponse response =
+   *         businessGlossaryServiceClient.listGlossariesCallable().call(request);
+   *     for (Glossary element : response.getGlossariesList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listGlossariesCallable() { + return stub.listGlossariesCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+   *   GlossaryCategory category = GlossaryCategory.newBuilder().build();
+   *   String categoryId = "categoryId1296531129";
+   *   GlossaryCategory response =
+   *       businessGlossaryServiceClient.createGlossaryCategory(parent, category, categoryId);
+   * }
+   * }
+ * + * @param parent Required. The parent resource where this GlossaryCategory will be created. + * Format: projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * where `locationId` refers to a Google Cloud region. + * @param category Required. The GlossaryCategory to create. + * @param categoryId Required. GlossaryCategory identifier. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryCategory createGlossaryCategory( + GlossaryName parent, GlossaryCategory category, String categoryId) { + CreateGlossaryCategoryRequest request = + CreateGlossaryCategoryRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setCategory(category) + .setCategoryId(categoryId) + .build(); + return createGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString();
+   *   GlossaryCategory category = GlossaryCategory.newBuilder().build();
+   *   String categoryId = "categoryId1296531129";
+   *   GlossaryCategory response =
+   *       businessGlossaryServiceClient.createGlossaryCategory(parent, category, categoryId);
+   * }
+   * }
+ * + * @param parent Required. The parent resource where this GlossaryCategory will be created. + * Format: projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + * where `locationId` refers to a Google Cloud region. + * @param category Required. The GlossaryCategory to create. + * @param categoryId Required. GlossaryCategory identifier. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryCategory createGlossaryCategory( + String parent, GlossaryCategory category, String categoryId) { + CreateGlossaryCategoryRequest request = + CreateGlossaryCategoryRequest.newBuilder() + .setParent(parent) + .setCategory(category) + .setCategoryId(categoryId) + .build(); + return createGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   CreateGlossaryCategoryRequest request =
+   *       CreateGlossaryCategoryRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setCategoryId("categoryId1296531129")
+   *           .setCategory(GlossaryCategory.newBuilder().build())
+   *           .build();
+   *   GlossaryCategory response = businessGlossaryServiceClient.createGlossaryCategory(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 GlossaryCategory createGlossaryCategory(CreateGlossaryCategoryRequest request) { + return createGlossaryCategoryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   CreateGlossaryCategoryRequest request =
+   *       CreateGlossaryCategoryRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setCategoryId("categoryId1296531129")
+   *           .setCategory(GlossaryCategory.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.createGlossaryCategoryCallable().futureCall(request);
+   *   // Do something.
+   *   GlossaryCategory response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + createGlossaryCategoryCallable() { + return stub.createGlossaryCategoryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryCategory category = GlossaryCategory.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   GlossaryCategory response =
+   *       businessGlossaryServiceClient.updateGlossaryCategory(category, updateMask);
+   * }
+   * }
+ * + * @param category Required. The GlossaryCategory to update. The GlossaryCategory's `name` field + * is used to identify the GlossaryCategory to update. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + * @param updateMask Required. The list of fields to update. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryCategory updateGlossaryCategory( + GlossaryCategory category, FieldMask updateMask) { + UpdateGlossaryCategoryRequest request = + UpdateGlossaryCategoryRequest.newBuilder() + .setCategory(category) + .setUpdateMask(updateMask) + .build(); + return updateGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   UpdateGlossaryCategoryRequest request =
+   *       UpdateGlossaryCategoryRequest.newBuilder()
+   *           .setCategory(GlossaryCategory.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   GlossaryCategory response = businessGlossaryServiceClient.updateGlossaryCategory(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 GlossaryCategory updateGlossaryCategory(UpdateGlossaryCategoryRequest request) { + return updateGlossaryCategoryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   UpdateGlossaryCategoryRequest request =
+   *       UpdateGlossaryCategoryRequest.newBuilder()
+   *           .setCategory(GlossaryCategory.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.updateGlossaryCategoryCallable().futureCall(request);
+   *   // Do something.
+   *   GlossaryCategory response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable + updateGlossaryCategoryCallable() { + return stub.updateGlossaryCategoryCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryCategory resource. All the GlossaryCategories and GlossaryTerms nested + * directly under the specified GlossaryCategory will be moved one level up to the parent in the + * hierarchy. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryCategoryName name =
+   *       GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]");
+   *   businessGlossaryServiceClient.deleteGlossaryCategory(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryCategory to delete. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteGlossaryCategory(GlossaryCategoryName name) { + DeleteGlossaryCategoryRequest request = + DeleteGlossaryCategoryRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + deleteGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryCategory resource. All the GlossaryCategories and GlossaryTerms nested + * directly under the specified GlossaryCategory will be moved one level up to the parent in the + * hierarchy. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String name =
+   *       GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]")
+   *           .toString();
+   *   businessGlossaryServiceClient.deleteGlossaryCategory(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryCategory to delete. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteGlossaryCategory(String name) { + DeleteGlossaryCategoryRequest request = + DeleteGlossaryCategoryRequest.newBuilder().setName(name).build(); + deleteGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryCategory resource. All the GlossaryCategories and GlossaryTerms nested + * directly under the specified GlossaryCategory will be moved one level up to the parent in the + * hierarchy. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   DeleteGlossaryCategoryRequest request =
+   *       DeleteGlossaryCategoryRequest.newBuilder()
+   *           .setName(
+   *               GlossaryCategoryName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]")
+   *                   .toString())
+   *           .build();
+   *   businessGlossaryServiceClient.deleteGlossaryCategory(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 void deleteGlossaryCategory(DeleteGlossaryCategoryRequest request) { + deleteGlossaryCategoryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryCategory resource. All the GlossaryCategories and GlossaryTerms nested + * directly under the specified GlossaryCategory will be moved one level up to the parent in the + * hierarchy. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryCategoryName name =
+   *       GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]");
+   *   GlossaryCategory response = businessGlossaryServiceClient.getGlossaryCategory(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryCategory to retrieve. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryCategory getGlossaryCategory(GlossaryCategoryName name) { + GetGlossaryCategoryRequest request = + GetGlossaryCategoryRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String name =
+   *       GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]")
+   *           .toString();
+   *   GlossaryCategory response = businessGlossaryServiceClient.getGlossaryCategory(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryCategory to retrieve. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryCategory getGlossaryCategory(String name) { + GetGlossaryCategoryRequest request = + GetGlossaryCategoryRequest.newBuilder().setName(name).build(); + return getGlossaryCategory(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a GlossaryCategory resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GetGlossaryCategoryRequest request =
+   *       GetGlossaryCategoryRequest.newBuilder()
+   *           .setName(
+   *               GlossaryCategoryName.of(
+   *                       "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]")
+   *                   .toString())
+   *           .build();
+   *   GlossaryCategory response = businessGlossaryServiceClient.getGlossaryCategory(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 GlossaryCategory getGlossaryCategory(GetGlossaryCategoryRequest request) { + return getGlossaryCategoryCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a GlossaryCategory resource. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+   *   for (GlossaryCategory element :
+   *       businessGlossaryServiceClient.listGlossaryCategories(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, which has this collection of GlossaryCategories. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} Location + * is the Google Cloud region. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGlossaryCategoriesPagedResponse listGlossaryCategories(GlossaryName parent) { + ListGlossaryCategoriesRequest request = + ListGlossaryCategoriesRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listGlossaryCategories(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists GlossaryCategory resources in a Glossary. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString();
+   *   for (GlossaryCategory element :
+   *       businessGlossaryServiceClient.listGlossaryCategories(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, which has this collection of GlossaryCategories. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} Location + * is the Google Cloud region. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGlossaryCategoriesPagedResponse listGlossaryCategories(String parent) { + ListGlossaryCategoriesRequest request = + ListGlossaryCategoriesRequest.newBuilder().setParent(parent).build(); + return listGlossaryCategories(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists GlossaryCategory resources in a Glossary. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListGlossaryCategoriesRequest request =
+   *       ListGlossaryCategoriesRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (GlossaryCategory element :
+   *       businessGlossaryServiceClient.listGlossaryCategories(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 ListGlossaryCategoriesPagedResponse listGlossaryCategories( + ListGlossaryCategoriesRequest request) { + return listGlossaryCategoriesPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists GlossaryCategory resources in a Glossary. + * + *

Sample code: + * + *

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

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+   *   GlossaryTerm term = GlossaryTerm.newBuilder().build();
+   *   String termId = "termId-877206873";
+   *   GlossaryTerm response =
+   *       businessGlossaryServiceClient.createGlossaryTerm(parent, term, termId);
+   * }
+   * }
+ * + * @param parent Required. The parent resource where the GlossaryTerm will be created. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} where + * `location_id` refers to a Google Cloud region. + * @param term Required. The GlossaryTerm to create. + * @param termId Required. GlossaryTerm identifier. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryTerm createGlossaryTerm( + GlossaryName parent, GlossaryTerm term, String termId) { + CreateGlossaryTermRequest request = + CreateGlossaryTermRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setTerm(term) + .setTermId(termId) + .build(); + return createGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString();
+   *   GlossaryTerm term = GlossaryTerm.newBuilder().build();
+   *   String termId = "termId-877206873";
+   *   GlossaryTerm response =
+   *       businessGlossaryServiceClient.createGlossaryTerm(parent, term, termId);
+   * }
+   * }
+ * + * @param parent Required. The parent resource where the GlossaryTerm will be created. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} where + * `location_id` refers to a Google Cloud region. + * @param term Required. The GlossaryTerm to create. + * @param termId Required. GlossaryTerm identifier. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryTerm createGlossaryTerm(String parent, GlossaryTerm term, String termId) { + CreateGlossaryTermRequest request = + CreateGlossaryTermRequest.newBuilder() + .setParent(parent) + .setTerm(term) + .setTermId(termId) + .build(); + return createGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   CreateGlossaryTermRequest request =
+   *       CreateGlossaryTermRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setTermId("termId-877206873")
+   *           .setTerm(GlossaryTerm.newBuilder().build())
+   *           .build();
+   *   GlossaryTerm response = businessGlossaryServiceClient.createGlossaryTerm(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 GlossaryTerm createGlossaryTerm(CreateGlossaryTermRequest request) { + return createGlossaryTermCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates a new GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   CreateGlossaryTermRequest request =
+   *       CreateGlossaryTermRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setTermId("termId-877206873")
+   *           .setTerm(GlossaryTerm.newBuilder().build())
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.createGlossaryTermCallable().futureCall(request);
+   *   // Do something.
+   *   GlossaryTerm response = future.get();
+   * }
+   * }
+ */ + public final UnaryCallable createGlossaryTermCallable() { + return stub.createGlossaryTermCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryTerm term = GlossaryTerm.newBuilder().build();
+   *   FieldMask updateMask = FieldMask.newBuilder().build();
+   *   GlossaryTerm response = businessGlossaryServiceClient.updateGlossaryTerm(term, updateMask);
+   * }
+   * }
+ * + * @param term Required. The GlossaryTerm to update. The GlossaryTerm's `name` field is used to + * identify the GlossaryTerm to update. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + * @param updateMask Required. The list of fields to update. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryTerm updateGlossaryTerm(GlossaryTerm term, FieldMask updateMask) { + UpdateGlossaryTermRequest request = + UpdateGlossaryTermRequest.newBuilder().setTerm(term).setUpdateMask(updateMask).build(); + return updateGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   UpdateGlossaryTermRequest request =
+   *       UpdateGlossaryTermRequest.newBuilder()
+   *           .setTerm(GlossaryTerm.newBuilder().build())
+   *           .setUpdateMask(FieldMask.newBuilder().build())
+   *           .build();
+   *   GlossaryTerm response = businessGlossaryServiceClient.updateGlossaryTerm(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 GlossaryTerm updateGlossaryTerm(UpdateGlossaryTermRequest request) { + return updateGlossaryTermCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates a GlossaryTerm resource. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryTermName name =
+   *       GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]");
+   *   businessGlossaryServiceClient.deleteGlossaryTerm(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryTerm to delete. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteGlossaryTerm(GlossaryTermName name) { + DeleteGlossaryTermRequest request = + DeleteGlossaryTermRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + deleteGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String name =
+   *       GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]")
+   *           .toString();
+   *   businessGlossaryServiceClient.deleteGlossaryTerm(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryTerm to delete. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteGlossaryTerm(String name) { + DeleteGlossaryTermRequest request = + DeleteGlossaryTermRequest.newBuilder().setName(name).build(); + deleteGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   DeleteGlossaryTermRequest request =
+   *       DeleteGlossaryTermRequest.newBuilder()
+   *           .setName(
+   *               GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]")
+   *                   .toString())
+   *           .build();
+   *   businessGlossaryServiceClient.deleteGlossaryTerm(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 void deleteGlossaryTerm(DeleteGlossaryTermRequest request) { + deleteGlossaryTermCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes a GlossaryTerm resource. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryTermName name =
+   *       GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]");
+   *   GlossaryTerm response = businessGlossaryServiceClient.getGlossaryTerm(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryTerm to retrieve. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryTerm getGlossaryTerm(GlossaryTermName name) { + GetGlossaryTermRequest request = + GetGlossaryTermRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String name =
+   *       GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]")
+   *           .toString();
+   *   GlossaryTerm response = businessGlossaryServiceClient.getGlossaryTerm(name);
+   * }
+   * }
+ * + * @param name Required. The name of the GlossaryTerm to retrieve. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final GlossaryTerm getGlossaryTerm(String name) { + GetGlossaryTermRequest request = GetGlossaryTermRequest.newBuilder().setName(name).build(); + return getGlossaryTerm(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a GlossaryTerm resource. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GetGlossaryTermRequest request =
+   *       GetGlossaryTermRequest.newBuilder()
+   *           .setName(
+   *               GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]")
+   *                   .toString())
+   *           .build();
+   *   GlossaryTerm response = businessGlossaryServiceClient.getGlossaryTerm(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 GlossaryTerm getGlossaryTerm(GetGlossaryTermRequest request) { + return getGlossaryTermCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets a GlossaryTerm resource. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]");
+   *   for (GlossaryTerm element :
+   *       businessGlossaryServiceClient.listGlossaryTerms(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, which has this collection of GlossaryTerms. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} where + * `location_id` refers to a Google Cloud region. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGlossaryTermsPagedResponse listGlossaryTerms(GlossaryName parent) { + ListGlossaryTermsRequest request = + ListGlossaryTermsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listGlossaryTerms(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists GlossaryTerm resources in a Glossary. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString();
+   *   for (GlossaryTerm element :
+   *       businessGlossaryServiceClient.listGlossaryTerms(parent).iterateAll()) {
+   *     // doThingsWith(element);
+   *   }
+   * }
+   * }
+ * + * @param parent Required. The parent, which has this collection of GlossaryTerms. Format: + * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} where + * `location_id` refers to a Google Cloud region. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListGlossaryTermsPagedResponse listGlossaryTerms(String parent) { + ListGlossaryTermsRequest request = + ListGlossaryTermsRequest.newBuilder().setParent(parent).build(); + return listGlossaryTerms(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists GlossaryTerm resources in a Glossary. + * + *

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListGlossaryTermsRequest request =
+   *       ListGlossaryTermsRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   for (GlossaryTerm element :
+   *       businessGlossaryServiceClient.listGlossaryTerms(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 ListGlossaryTermsPagedResponse listGlossaryTerms(ListGlossaryTermsRequest request) { + return listGlossaryTermsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Lists GlossaryTerm resources in a Glossary. + * + *

Sample code: + * + *

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

Sample code: + * + *

{@code
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+   * try (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListGlossaryTermsRequest request =
+   *       ListGlossaryTermsRequest.newBuilder()
+   *           .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString())
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .setFilter("filter-1274492040")
+   *           .setOrderBy("orderBy-1207110587")
+   *           .build();
+   *   while (true) {
+   *     ListGlossaryTermsResponse response =
+   *         businessGlossaryServiceClient.listGlossaryTermsCallable().call(request);
+   *     for (GlossaryTerm element : response.getTermsList()) {
+   *       // doThingsWith(element);
+   *     }
+   *     String nextPageToken = response.getNextPageToken();
+   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
+   *       request = request.toBuilder().setPageToken(nextPageToken).build();
+   *     } else {
+   *       break;
+   *     }
+   *   }
+   * }
+   * }
+ */ + public final UnaryCallable + listGlossaryTermsCallable() { + return stub.listGlossaryTermsCallable(); + } + + // 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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   for (Location element : businessGlossaryServiceClient.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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   ListLocationsRequest request =
+   *       ListLocationsRequest.newBuilder()
+   *           .setName("name3373707")
+   *           .setFilter("filter-1274492040")
+   *           .setPageSize(883849137)
+   *           .setPageToken("pageToken873572522")
+   *           .build();
+   *   while (true) {
+   *     ListLocationsResponse response =
+   *         businessGlossaryServiceClient.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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   Location response = businessGlossaryServiceClient.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 (BusinessGlossaryServiceClient businessGlossaryServiceClient =
+   *     BusinessGlossaryServiceClient.create()) {
+   *   GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build();
+   *   ApiFuture future =
+   *       businessGlossaryServiceClient.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 ListGlossariesPagedResponse + extends AbstractPagedListResponse< + ListGlossariesRequest, + ListGlossariesResponse, + Glossary, + ListGlossariesPage, + ListGlossariesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListGlossariesPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListGlossariesPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListGlossariesPagedResponse(ListGlossariesPage page) { + super(page, ListGlossariesFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListGlossariesPage + extends AbstractPage< + ListGlossariesRequest, ListGlossariesResponse, Glossary, ListGlossariesPage> { + + private ListGlossariesPage( + PageContext context, + ListGlossariesResponse response) { + super(context, response); + } + + private static ListGlossariesPage createEmptyPage() { + return new ListGlossariesPage(null, null); + } + + @Override + protected ListGlossariesPage createPage( + PageContext context, + ListGlossariesResponse response) { + return new ListGlossariesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListGlossariesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListGlossariesRequest, + ListGlossariesResponse, + Glossary, + ListGlossariesPage, + ListGlossariesFixedSizeCollection> { + + private ListGlossariesFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListGlossariesFixedSizeCollection createEmptyCollection() { + return new ListGlossariesFixedSizeCollection(null, 0); + } + + @Override + protected ListGlossariesFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListGlossariesFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListGlossaryCategoriesPagedResponse + extends AbstractPagedListResponse< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + GlossaryCategory, + ListGlossaryCategoriesPage, + ListGlossaryCategoriesFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListGlossaryCategoriesPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListGlossaryCategoriesPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListGlossaryCategoriesPagedResponse(ListGlossaryCategoriesPage page) { + super(page, ListGlossaryCategoriesFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListGlossaryCategoriesPage + extends AbstractPage< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + GlossaryCategory, + ListGlossaryCategoriesPage> { + + private ListGlossaryCategoriesPage( + PageContext + context, + ListGlossaryCategoriesResponse response) { + super(context, response); + } + + private static ListGlossaryCategoriesPage createEmptyPage() { + return new ListGlossaryCategoriesPage(null, null); + } + + @Override + protected ListGlossaryCategoriesPage createPage( + PageContext + context, + ListGlossaryCategoriesResponse response) { + return new ListGlossaryCategoriesPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListGlossaryCategoriesFixedSizeCollection + extends AbstractFixedSizeCollection< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + GlossaryCategory, + ListGlossaryCategoriesPage, + ListGlossaryCategoriesFixedSizeCollection> { + + private ListGlossaryCategoriesFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListGlossaryCategoriesFixedSizeCollection createEmptyCollection() { + return new ListGlossaryCategoriesFixedSizeCollection(null, 0); + } + + @Override + protected ListGlossaryCategoriesFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListGlossaryCategoriesFixedSizeCollection(pages, collectionSize); + } + } + + public static class ListGlossaryTermsPagedResponse + extends AbstractPagedListResponse< + ListGlossaryTermsRequest, + ListGlossaryTermsResponse, + GlossaryTerm, + ListGlossaryTermsPage, + ListGlossaryTermsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListGlossaryTermsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + input -> new ListGlossaryTermsPagedResponse(input), + MoreExecutors.directExecutor()); + } + + private ListGlossaryTermsPagedResponse(ListGlossaryTermsPage page) { + super(page, ListGlossaryTermsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListGlossaryTermsPage + extends AbstractPage< + ListGlossaryTermsRequest, + ListGlossaryTermsResponse, + GlossaryTerm, + ListGlossaryTermsPage> { + + private ListGlossaryTermsPage( + PageContext context, + ListGlossaryTermsResponse response) { + super(context, response); + } + + private static ListGlossaryTermsPage createEmptyPage() { + return new ListGlossaryTermsPage(null, null); + } + + @Override + protected ListGlossaryTermsPage createPage( + PageContext context, + ListGlossaryTermsResponse response) { + return new ListGlossaryTermsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListGlossaryTermsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListGlossaryTermsRequest, + ListGlossaryTermsResponse, + GlossaryTerm, + ListGlossaryTermsPage, + ListGlossaryTermsFixedSizeCollection> { + + private ListGlossaryTermsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListGlossaryTermsFixedSizeCollection createEmptyCollection() { + return new ListGlossaryTermsFixedSizeCollection(null, 0); + } + + @Override + protected ListGlossaryTermsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListGlossaryTermsFixedSizeCollection(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( + PageContext context, + ListLocationsResponse response) { + super(context, response); + } + + private static ListLocationsPage createEmptyPage() { + return new ListLocationsPage(null, null); + } + + @Override + protected ListLocationsPage createPage( + PageContext context, + ListLocationsResponse response) { + return new ListLocationsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListLocationsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListLocationsRequest, + ListLocationsResponse, + Location, + ListLocationsPage, + ListLocationsFixedSizeCollection> { + + private ListLocationsFixedSizeCollection(List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListLocationsFixedSizeCollection createEmptyCollection() { + return new ListLocationsFixedSizeCollection(null, 0); + } + + @Override + protected ListLocationsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListLocationsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceSettings.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceSettings.java new file mode 100644 index 000000000000..ea47e8c307a9 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceSettings.java @@ -0,0 +1,490 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListLocationsPagedResponse; + +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.dataplex.v1.stub.BusinessGlossaryServiceStubSettings; +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 com.google.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link BusinessGlossaryServiceClient}. + * + *

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

    + *
  • The default service address (dataplex.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 getGlossary: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * BusinessGlossaryServiceSettings.Builder businessGlossaryServiceSettingsBuilder =
+ *     BusinessGlossaryServiceSettings.newBuilder();
+ * businessGlossaryServiceSettingsBuilder
+ *     .getGlossarySettings()
+ *     .setRetrySettings(
+ *         businessGlossaryServiceSettingsBuilder
+ *             .getGlossarySettings()
+ *             .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());
+ * BusinessGlossaryServiceSettings businessGlossaryServiceSettings =
+ *     businessGlossaryServiceSettingsBuilder.build();
+ * }
+ * + * Please refer to the [Client Side Retry + * Guide](https://github.com/googleapis/google-cloud-java/blob/main/docs/client_retries.md) 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 createGlossary: + * + *

{@code
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
+ * BusinessGlossaryServiceSettings.Builder businessGlossaryServiceSettingsBuilder =
+ *     BusinessGlossaryServiceSettings.newBuilder();
+ * TimedRetryAlgorithm timedRetryAlgorithm =
+ *     OperationalTimedPollAlgorithm.create(
+ *         RetrySettings.newBuilder()
+ *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
+ *             .setRetryDelayMultiplier(1.5)
+ *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
+ *             .setTotalTimeoutDuration(Duration.ofHours(24))
+ *             .build());
+ * businessGlossaryServiceSettingsBuilder
+ *     .createClusterOperationSettings()
+ *     .setPollingAlgorithm(timedRetryAlgorithm)
+ *     .build();
+ * }
+ */ +@Generated("by gapic-generator-java") +public class BusinessGlossaryServiceSettings + extends ClientSettings { + + /** Returns the object with the settings used for calls to createGlossary. */ + public UnaryCallSettings createGlossarySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).createGlossarySettings(); + } + + /** Returns the object with the settings used for calls to createGlossary. */ + public OperationCallSettings + createGlossaryOperationSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .createGlossaryOperationSettings(); + } + + /** Returns the object with the settings used for calls to updateGlossary. */ + public UnaryCallSettings updateGlossarySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).updateGlossarySettings(); + } + + /** Returns the object with the settings used for calls to updateGlossary. */ + public OperationCallSettings + updateGlossaryOperationSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .updateGlossaryOperationSettings(); + } + + /** Returns the object with the settings used for calls to deleteGlossary. */ + public UnaryCallSettings deleteGlossarySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).deleteGlossarySettings(); + } + + /** Returns the object with the settings used for calls to deleteGlossary. */ + public OperationCallSettings + deleteGlossaryOperationSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .deleteGlossaryOperationSettings(); + } + + /** Returns the object with the settings used for calls to getGlossary. */ + public UnaryCallSettings getGlossarySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).getGlossarySettings(); + } + + /** Returns the object with the settings used for calls to listGlossaries. */ + public PagedCallSettings< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + listGlossariesSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).listGlossariesSettings(); + } + + /** Returns the object with the settings used for calls to createGlossaryCategory. */ + public UnaryCallSettings + createGlossaryCategorySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .createGlossaryCategorySettings(); + } + + /** Returns the object with the settings used for calls to updateGlossaryCategory. */ + public UnaryCallSettings + updateGlossaryCategorySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .updateGlossaryCategorySettings(); + } + + /** Returns the object with the settings used for calls to deleteGlossaryCategory. */ + public UnaryCallSettings deleteGlossaryCategorySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .deleteGlossaryCategorySettings(); + } + + /** Returns the object with the settings used for calls to getGlossaryCategory. */ + public UnaryCallSettings + getGlossaryCategorySettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).getGlossaryCategorySettings(); + } + + /** Returns the object with the settings used for calls to listGlossaryCategories. */ + public PagedCallSettings< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + listGlossaryCategoriesSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()) + .listGlossaryCategoriesSettings(); + } + + /** Returns the object with the settings used for calls to createGlossaryTerm. */ + public UnaryCallSettings createGlossaryTermSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).createGlossaryTermSettings(); + } + + /** Returns the object with the settings used for calls to updateGlossaryTerm. */ + public UnaryCallSettings updateGlossaryTermSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).updateGlossaryTermSettings(); + } + + /** Returns the object with the settings used for calls to deleteGlossaryTerm. */ + public UnaryCallSettings deleteGlossaryTermSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).deleteGlossaryTermSettings(); + } + + /** Returns the object with the settings used for calls to getGlossaryTerm. */ + public UnaryCallSettings getGlossaryTermSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).getGlossaryTermSettings(); + } + + /** Returns the object with the settings used for calls to listGlossaryTerms. */ + public PagedCallSettings< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + listGlossaryTermsSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).listGlossaryTermsSettings(); + } + + /** Returns the object with the settings used for calls to listLocations. */ + public PagedCallSettings + listLocationsSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).listLocationsSettings(); + } + + /** Returns the object with the settings used for calls to getLocation. */ + public UnaryCallSettings getLocationSettings() { + return ((BusinessGlossaryServiceStubSettings) getStubSettings()).getLocationSettings(); + } + + public static final BusinessGlossaryServiceSettings create( + BusinessGlossaryServiceStubSettings stub) throws IOException { + return new BusinessGlossaryServiceSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return BusinessGlossaryServiceStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return BusinessGlossaryServiceStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return BusinessGlossaryServiceStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return BusinessGlossaryServiceStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default gRPC ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return BusinessGlossaryServiceStubSettings.defaultGrpcTransportProviderBuilder(); + } + + /** Returns a builder for the default REST ChannelProvider for this service. */ + @BetaApi + public static InstantiatingHttpJsonChannelProvider.Builder + defaultHttpJsonTransportProviderBuilder() { + return BusinessGlossaryServiceStubSettings.defaultHttpJsonTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return BusinessGlossaryServiceStubSettings.defaultTransportChannelProvider(); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return BusinessGlossaryServiceStubSettings.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(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 BusinessGlossaryServiceSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for BusinessGlossaryServiceSettings. */ + public static class Builder + extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(BusinessGlossaryServiceStubSettings.newBuilder(clientContext)); + } + + protected Builder(BusinessGlossaryServiceSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(BusinessGlossaryServiceStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(BusinessGlossaryServiceStubSettings.newBuilder()); + } + + private static Builder createHttpJsonDefault() { + return new Builder(BusinessGlossaryServiceStubSettings.newHttpJsonBuilder()); + } + + public BusinessGlossaryServiceStubSettings.Builder getStubSettingsBuilder() { + return ((BusinessGlossaryServiceStubSettings.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 createGlossary. */ + public UnaryCallSettings.Builder createGlossarySettings() { + return getStubSettingsBuilder().createGlossarySettings(); + } + + /** Returns the builder for the settings used for calls to createGlossary. */ + public OperationCallSettings.Builder + createGlossaryOperationSettings() { + return getStubSettingsBuilder().createGlossaryOperationSettings(); + } + + /** Returns the builder for the settings used for calls to updateGlossary. */ + public UnaryCallSettings.Builder updateGlossarySettings() { + return getStubSettingsBuilder().updateGlossarySettings(); + } + + /** Returns the builder for the settings used for calls to updateGlossary. */ + public OperationCallSettings.Builder + updateGlossaryOperationSettings() { + return getStubSettingsBuilder().updateGlossaryOperationSettings(); + } + + /** Returns the builder for the settings used for calls to deleteGlossary. */ + public UnaryCallSettings.Builder deleteGlossarySettings() { + return getStubSettingsBuilder().deleteGlossarySettings(); + } + + /** Returns the builder for the settings used for calls to deleteGlossary. */ + public OperationCallSettings.Builder + deleteGlossaryOperationSettings() { + return getStubSettingsBuilder().deleteGlossaryOperationSettings(); + } + + /** Returns the builder for the settings used for calls to getGlossary. */ + public UnaryCallSettings.Builder getGlossarySettings() { + return getStubSettingsBuilder().getGlossarySettings(); + } + + /** Returns the builder for the settings used for calls to listGlossaries. */ + public PagedCallSettings.Builder< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + listGlossariesSettings() { + return getStubSettingsBuilder().listGlossariesSettings(); + } + + /** Returns the builder for the settings used for calls to createGlossaryCategory. */ + public UnaryCallSettings.Builder + createGlossaryCategorySettings() { + return getStubSettingsBuilder().createGlossaryCategorySettings(); + } + + /** Returns the builder for the settings used for calls to updateGlossaryCategory. */ + public UnaryCallSettings.Builder + updateGlossaryCategorySettings() { + return getStubSettingsBuilder().updateGlossaryCategorySettings(); + } + + /** Returns the builder for the settings used for calls to deleteGlossaryCategory. */ + public UnaryCallSettings.Builder + deleteGlossaryCategorySettings() { + return getStubSettingsBuilder().deleteGlossaryCategorySettings(); + } + + /** Returns the builder for the settings used for calls to getGlossaryCategory. */ + public UnaryCallSettings.Builder + getGlossaryCategorySettings() { + return getStubSettingsBuilder().getGlossaryCategorySettings(); + } + + /** Returns the builder for the settings used for calls to listGlossaryCategories. */ + public PagedCallSettings.Builder< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + listGlossaryCategoriesSettings() { + return getStubSettingsBuilder().listGlossaryCategoriesSettings(); + } + + /** Returns the builder for the settings used for calls to createGlossaryTerm. */ + public UnaryCallSettings.Builder + createGlossaryTermSettings() { + return getStubSettingsBuilder().createGlossaryTermSettings(); + } + + /** Returns the builder for the settings used for calls to updateGlossaryTerm. */ + public UnaryCallSettings.Builder + updateGlossaryTermSettings() { + return getStubSettingsBuilder().updateGlossaryTermSettings(); + } + + /** Returns the builder for the settings used for calls to deleteGlossaryTerm. */ + public UnaryCallSettings.Builder + deleteGlossaryTermSettings() { + return getStubSettingsBuilder().deleteGlossaryTermSettings(); + } + + /** Returns the builder for the settings used for calls to getGlossaryTerm. */ + public UnaryCallSettings.Builder + getGlossaryTermSettings() { + return getStubSettingsBuilder().getGlossaryTermSettings(); + } + + /** Returns the builder for the settings used for calls to listGlossaryTerms. */ + public PagedCallSettings.Builder< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + listGlossaryTermsSettings() { + return getStubSettingsBuilder().listGlossaryTermsSettings(); + } + + /** 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 BusinessGlossaryServiceSettings build() throws IOException { + return new BusinessGlossaryServiceSettings(this); + } + } +} diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceClient.java index 6210d6922972..08a21edf3906 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceClient.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceClient.java @@ -46,9 +46,9 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS. /** * Service Description: The primary resources offered by this service are EntryGroups, EntryTypes, - * AspectTypes, and Entries. They collectively let data administrators organize, manage, secure, and - * catalog data located across cloud projects in their organization in a variety of storage systems, - * including Cloud Storage and BigQuery. + * AspectTypes, Entries and EntryLinks. They collectively let data administrators organize, manage, + * secure, and catalog data located across cloud projects in their organization in a variety of + * storage systems, including Cloud Storage and BigQuery. * *

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: @@ -500,7 +500,7 @@ * * *

CreateMetadataJob - *

Creates a metadata job. For example, use a metadata job to import Dataplex Catalog entries and aspects from a third-party system into Dataplex. + *

Creates a metadata job. For example, use a metadata job to import metadata from a third-party system into Dataplex Universal Catalog. * *

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

*
    @@ -578,6 +578,63 @@ * * * + *

    CreateEntryLink + *

    Creates an Entry Link. + * + *

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

    + *
      + *
    • createEntryLink(CreateEntryLinkRequest request) + *

    + *

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

    + *
      + *
    • createEntryLink(EntryGroupName parent, EntryLink entryLink, String entryLinkId) + *

    • createEntryLink(String parent, EntryLink entryLink, String entryLinkId) + *

    + *

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

    + *
      + *
    • createEntryLinkCallable() + *

    + * + * + * + *

    DeleteEntryLink + *

    Deletes an Entry Link. + * + *

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

    + *
      + *
    • deleteEntryLink(DeleteEntryLinkRequest request) + *

    + *

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

    + *
      + *
    • deleteEntryLink(EntryLinkName name) + *

    • deleteEntryLink(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.

    + *
      + *
    • deleteEntryLinkCallable() + *

    + * + * + * + *

    GetEntryLink + *

    Gets an Entry Link. + * + *

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

    + *
      + *
    • getEntryLink(GetEntryLinkRequest request) + *

    + *

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

    + *
      + *
    • getEntryLink(EntryLinkName name) + *

    • getEntryLink(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.

    + *
      + *
    • getEntryLinkCallable() + *

    + * + * + * *

    ListLocations *

    Lists information about the supported locations for this service. * @@ -2213,8 +2270,8 @@ public final UnaryCallable getAspectTypeCallab * } * * @param parent Required. The resource name of the entryGroup, of the form: - * projects/{project_number}/locations/{location_id} where `location_id` refers to a GCP - * region. + * projects/{project_number}/locations/{location_id} where `location_id` refers to a Google + * Cloud region. * @param entryGroup Required. EntryGroup Resource. * @param entryGroupId Required. EntryGroup identifier. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -2252,8 +2309,8 @@ public final OperationFuture createEntryGroupAsyn * } * * @param parent Required. The resource name of the entryGroup, of the form: - * projects/{project_number}/locations/{location_id} where `location_id` refers to a GCP - * region. + * projects/{project_number}/locations/{location_id} where `location_id` refers to a Google + * Cloud region. * @param entryGroup Required. EntryGroup Resource. * @param entryGroupId Required. EntryGroup identifier. * @throws com.google.api.gax.rpc.ApiException if the remote call fails @@ -3652,9 +3709,9 @@ public final UnaryCallable lookupEntryCallable() { * } * * @param name Required. The project to which the request should be attributed in the following - * form: `projects/{project}/locations/{location}`. + * form: `projects/{project}/locations/global`. * @param query Required. The query against which entries in scope should be matched. The query - * syntax is defined in [Search syntax for Dataplex + * syntax is defined in [Search syntax for Dataplex Universal * Catalog](https://cloud.google.com/dataplex/docs/search-syntax). * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -3690,9 +3747,9 @@ public final SearchEntriesPagedResponse searchEntries(LocationName name, String * } * * @param name Required. The project to which the request should be attributed in the following - * form: `projects/{project}/locations/{location}`. + * form: `projects/{project}/locations/global`. * @param query Required. The query against which entries in scope should be matched. The query - * syntax is defined in [Search syntax for Dataplex + * syntax is defined in [Search syntax for Dataplex Universal * Catalog](https://cloud.google.com/dataplex/docs/search-syntax). * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -3819,8 +3876,8 @@ public final UnaryCallable searchEn // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a metadata job. For example, use a metadata job to import Dataplex Catalog entries and - * aspects from a third-party system into Dataplex. + * Creates a metadata job. For example, use a metadata job to import metadata from a third-party + * system into Dataplex Universal Catalog. * *

    Sample code: * @@ -3859,8 +3916,8 @@ public final OperationFuture createMetadataJobAs // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a metadata job. For example, use a metadata job to import Dataplex Catalog entries and - * aspects from a third-party system into Dataplex. + * Creates a metadata job. For example, use a metadata job to import metadata from a third-party + * system into Dataplex Universal Catalog. * *

    Sample code: * @@ -3899,8 +3956,8 @@ public final OperationFuture createMetadataJobAs // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a metadata job. For example, use a metadata job to import Dataplex Catalog entries and - * aspects from a third-party system into Dataplex. + * Creates a metadata job. For example, use a metadata job to import metadata from a third-party + * system into Dataplex Universal Catalog. * *

    Sample code: * @@ -3932,8 +3989,8 @@ public final OperationFuture createMetadataJobAs // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a metadata job. For example, use a metadata job to import Dataplex Catalog entries and - * aspects from a third-party system into Dataplex. + * Creates a metadata job. For example, use a metadata job to import metadata from a third-party + * system into Dataplex Universal Catalog. * *

    Sample code: * @@ -3965,8 +4022,8 @@ public final OperationFuture createMetadataJobAs // AUTO-GENERATED DOCUMENTATION AND METHOD. /** - * Creates a metadata job. For example, use a metadata job to import Dataplex Catalog entries and - * aspects from a third-party system into Dataplex. + * Creates a metadata job. For example, use a metadata job to import metadata from a third-party + * system into Dataplex Universal Catalog. * *

    Sample code: * @@ -4408,6 +4465,388 @@ public final UnaryCallable cancelMetadataJobCal return stub.cancelMetadataJobCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   EntryGroupName parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]");
    +   *   EntryLink entryLink = EntryLink.newBuilder().build();
    +   *   String entryLinkId = "entryLinkId-1349584441";
    +   *   EntryLink response = catalogServiceClient.createEntryLink(parent, entryLink, entryLinkId);
    +   * }
    +   * }
    + * + * @param parent Required. The resource name of the parent Entry Group: + * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`. + * @param entryLink Required. Entry Link resource. + * @param entryLinkId Required. Entry Link identifier + *
      + *
    • Must contain only lowercase letters, numbers and hyphens. + *
    • Must start with a letter. + *
    • Must be between 1-63 characters. + *
    • Must end with a number or a letter. + *
    • Must be unique within the EntryGroup. + *
    + * + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final EntryLink createEntryLink( + EntryGroupName parent, EntryLink entryLink, String entryLinkId) { + CreateEntryLinkRequest request = + CreateEntryLinkRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setEntryLink(entryLink) + .setEntryLinkId(entryLinkId) + .build(); + return createEntryLink(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   String parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]").toString();
    +   *   EntryLink entryLink = EntryLink.newBuilder().build();
    +   *   String entryLinkId = "entryLinkId-1349584441";
    +   *   EntryLink response = catalogServiceClient.createEntryLink(parent, entryLink, entryLinkId);
    +   * }
    +   * }
    + * + * @param parent Required. The resource name of the parent Entry Group: + * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`. + * @param entryLink Required. Entry Link resource. + * @param entryLinkId Required. Entry Link identifier + *
      + *
    • Must contain only lowercase letters, numbers and hyphens. + *
    • Must start with a letter. + *
    • Must be between 1-63 characters. + *
    • Must end with a number or a letter. + *
    • Must be unique within the EntryGroup. + *
    + * + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final EntryLink createEntryLink(String parent, EntryLink entryLink, String entryLinkId) { + CreateEntryLinkRequest request = + CreateEntryLinkRequest.newBuilder() + .setParent(parent) + .setEntryLink(entryLink) + .setEntryLinkId(entryLinkId) + .build(); + return createEntryLink(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   CreateEntryLinkRequest request =
    +   *       CreateEntryLinkRequest.newBuilder()
    +   *           .setParent(EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]").toString())
    +   *           .setEntryLinkId("entryLinkId-1349584441")
    +   *           .setEntryLink(EntryLink.newBuilder().build())
    +   *           .build();
    +   *   EntryLink response = catalogServiceClient.createEntryLink(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 EntryLink createEntryLink(CreateEntryLinkRequest request) { + return createEntryLinkCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   CreateEntryLinkRequest request =
    +   *       CreateEntryLinkRequest.newBuilder()
    +   *           .setParent(EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]").toString())
    +   *           .setEntryLinkId("entryLinkId-1349584441")
    +   *           .setEntryLink(EntryLink.newBuilder().build())
    +   *           .build();
    +   *   ApiFuture future =
    +   *       catalogServiceClient.createEntryLinkCallable().futureCall(request);
    +   *   // Do something.
    +   *   EntryLink response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable createEntryLinkCallable() { + return stub.createEntryLinkCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   EntryLinkName name =
    +   *       EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]");
    +   *   EntryLink response = catalogServiceClient.deleteEntryLink(name);
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the Entry Link: + * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final EntryLink deleteEntryLink(EntryLinkName name) { + DeleteEntryLinkRequest request = + DeleteEntryLinkRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return deleteEntryLink(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   String name =
    +   *       EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]").toString();
    +   *   EntryLink response = catalogServiceClient.deleteEntryLink(name);
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the Entry Link: + * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final EntryLink deleteEntryLink(String name) { + DeleteEntryLinkRequest request = DeleteEntryLinkRequest.newBuilder().setName(name).build(); + return deleteEntryLink(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   DeleteEntryLinkRequest request =
    +   *       DeleteEntryLinkRequest.newBuilder()
    +   *           .setName(
    +   *               EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]")
    +   *                   .toString())
    +   *           .build();
    +   *   EntryLink response = catalogServiceClient.deleteEntryLink(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 EntryLink deleteEntryLink(DeleteEntryLinkRequest request) { + return deleteEntryLinkCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes an Entry Link. + * + *

    Sample code: + * + *

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

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   EntryLinkName name =
    +   *       EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]");
    +   *   EntryLink response = catalogServiceClient.getEntryLink(name);
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the Entry Link: + * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final EntryLink getEntryLink(EntryLinkName name) { + GetEntryLinkRequest request = + GetEntryLinkRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getEntryLink(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   String name =
    +   *       EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]").toString();
    +   *   EntryLink response = catalogServiceClient.getEntryLink(name);
    +   * }
    +   * }
    + * + * @param name Required. The resource name of the Entry Link: + * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final EntryLink getEntryLink(String name) { + GetEntryLinkRequest request = GetEntryLinkRequest.newBuilder().setName(name).build(); + return getEntryLink(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   GetEntryLinkRequest request =
    +   *       GetEntryLinkRequest.newBuilder()
    +   *           .setName(
    +   *               EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]")
    +   *                   .toString())
    +   *           .build();
    +   *   EntryLink response = catalogServiceClient.getEntryLink(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 EntryLink getEntryLink(GetEntryLinkRequest request) { + return getEntryLinkCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Gets an Entry Link. + * + *

    Sample code: + * + *

    {@code
    +   * // This snippet has been automatically generated and should be regarded as a code template only.
    +   * // It will require modifications to work:
    +   * // - It may require correct/in-range values for request initialization.
    +   * // - It may require specifying regional endpoints when creating the service client as shown in
    +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    +   * try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) {
    +   *   GetEntryLinkRequest request =
    +   *       GetEntryLinkRequest.newBuilder()
    +   *           .setName(
    +   *               EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]")
    +   *                   .toString())
    +   *           .build();
    +   *   ApiFuture future = catalogServiceClient.getEntryLinkCallable().futureCall(request);
    +   *   // Do something.
    +   *   EntryLink response = future.get();
    +   * }
    +   * }
    + */ + public final UnaryCallable getEntryLinkCallable() { + return stub.getEntryLinkCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Lists information about the supported locations for this service. diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceSettings.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceSettings.java index 762e4bc3141b..2a8c7c56c380 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceSettings.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceSettings.java @@ -327,6 +327,21 @@ public UnaryCallSettings cancelMetadataJobSetti return ((CatalogServiceStubSettings) getStubSettings()).cancelMetadataJobSettings(); } + /** Returns the object with the settings used for calls to createEntryLink. */ + public UnaryCallSettings createEntryLinkSettings() { + return ((CatalogServiceStubSettings) getStubSettings()).createEntryLinkSettings(); + } + + /** Returns the object with the settings used for calls to deleteEntryLink. */ + public UnaryCallSettings deleteEntryLinkSettings() { + return ((CatalogServiceStubSettings) getStubSettings()).deleteEntryLinkSettings(); + } + + /** Returns the object with the settings used for calls to getEntryLink. */ + public UnaryCallSettings getEntryLinkSettings() { + return ((CatalogServiceStubSettings) getStubSettings()).getEntryLinkSettings(); + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -659,6 +674,21 @@ public UnaryCallSettings.Builder cancelMetadata return getStubSettingsBuilder().cancelMetadataJobSettings(); } + /** Returns the builder for the settings used for calls to createEntryLink. */ + public UnaryCallSettings.Builder createEntryLinkSettings() { + return getStubSettingsBuilder().createEntryLinkSettings(); + } + + /** Returns the builder for the settings used for calls to deleteEntryLink. */ + public UnaryCallSettings.Builder deleteEntryLinkSettings() { + return getStubSettingsBuilder().deleteEntryLinkSettings(); + } + + /** Returns the builder for the settings used for calls to getEntryLink. */ + public UnaryCallSettings.Builder getEntryLinkSettings() { + return getStubSettingsBuilder().getEntryLinkSettings(); + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CmekServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CmekServiceClient.java index 16a990e5c695..1b86c55fb789 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CmekServiceClient.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/CmekServiceClient.java @@ -45,7 +45,7 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS. /** - * Service Description: Dataplex Cmek Service + * Service Description: Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service * *

    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: diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/ContentServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/ContentServiceClient.java index 66b4b7114519..64d3f900c254 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/ContentServiceClient.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/ContentServiceClient.java @@ -46,7 +46,8 @@ // AUTO-GENERATED DOCUMENTATION AND CLASS. /** - * Service Description: ContentService manages Notebook and SQL Scripts for Dataplex. + * Service Description: ContentService manages Notebook and SQL Scripts for Dataplex Universal + * Catalog. * *

    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: diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataScanServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataScanServiceClient.java index e97a30cbca84..079cb9e0ce55 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataScanServiceClient.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataScanServiceClient.java @@ -435,7 +435,8 @@ public final OperationsClient getHttpJsonOperationsClient() { * * @param parent Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` where `project` refers to a - * *project_id* or *project_number* and `location_id` refers to a GCP region. + * *project_id* or *project_number* and `location_id` refers to a Google Cloud + * region. * @param dataScan Required. DataScan resource. * @param dataScanId Required. DataScan identifier. *

      @@ -482,7 +483,8 @@ public final OperationFuture createDataScanAsync( * * @param parent Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` where `project` refers to a - * *project_id* or *project_number* and `location_id` refers to a GCP region. + * *project_id* or *project_number* and `location_id` refers to a Google Cloud + * region. * @param dataScan Required. DataScan resource. * @param dataScanId Required. DataScan identifier. *
        @@ -745,7 +747,7 @@ public final UnaryCallable updateDataScanCalla * @param name Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final OperationFuture deleteDataScanAsync(DataScanName name) { @@ -775,7 +777,7 @@ public final OperationFuture deleteDataScanAsync(DataS * @param name Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final OperationFuture deleteDataScanAsync(String name) { @@ -893,7 +895,7 @@ public final UnaryCallable deleteDataScanCalla * @param name Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final DataScan getDataScan(DataScanName name) { @@ -923,7 +925,7 @@ public final DataScan getDataScan(DataScanName name) { * @param name Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final DataScan getDataScan(String name) { @@ -1008,7 +1010,8 @@ public final UnaryCallable getDataScanCallable() { * * @param parent Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` where `project` refers to a - * *project_id* or *project_number* and `location_id` refers to a GCP region. + * *project_id* or *project_number* and `location_id` refers to a Google Cloud + * region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListDataScansPagedResponse listDataScans(LocationName parent) { @@ -1041,7 +1044,8 @@ public final ListDataScansPagedResponse listDataScans(LocationName parent) { * * @param parent Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` where `project` refers to a - * *project_id* or *project_number* and `location_id` refers to a GCP region. + * *project_id* or *project_number* and `location_id` refers to a Google Cloud + * region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListDataScansPagedResponse listDataScans(String parent) { @@ -1180,7 +1184,7 @@ public final UnaryCallable listData * @param name Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. *

        Only **OnDemand** data scans are allowed. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -1211,7 +1215,7 @@ public final RunDataScanResponse runDataScan(DataScanName name) { * @param name Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. *

        Only **OnDemand** data scans are allowed. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ @@ -1297,7 +1301,7 @@ public final UnaryCallable runDataScanC * @param name Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final DataScanJob getDataScanJob(DataScanJobName name) { @@ -1327,7 +1331,7 @@ public final DataScanJob getDataScanJob(DataScanJobName name) { * @param name Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final DataScanJob getDataScanJob(String name) { @@ -1416,7 +1420,7 @@ public final UnaryCallable getDataScanJobCal * @param parent Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListDataScanJobsPagedResponse listDataScanJobs(DataScanName parent) { @@ -1450,7 +1454,7 @@ public final ListDataScanJobsPagedResponse listDataScanJobs(DataScanName parent) * @param parent Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` where `project` * refers to a *project_id* or *project_number* and `location_id` refers to a - * GCP region. + * Google Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListDataScanJobsPagedResponse listDataScanJobs(String parent) { diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataTaxonomyServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataTaxonomyServiceClient.java index 26391329a51a..a0504f2c04f6 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataTaxonomyServiceClient.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataTaxonomyServiceClient.java @@ -1060,8 +1060,8 @@ public final UnaryCallable deleteDataTaxon * } * * @param parent Required. The resource name of the DataTaxonomy location, of the form: - * projects/{project_number}/locations/{location_id} where `location_id` refers to a GCP - * region. + * projects/{project_number}/locations/{location_id} where `location_id` refers to a Google + * Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails * @deprecated This method is deprecated and will be removed in the next major version update. */ @@ -1096,8 +1096,8 @@ public final ListDataTaxonomiesPagedResponse listDataTaxonomies(LocationName par * } * * @param parent Required. The resource name of the DataTaxonomy location, of the form: - * projects/{project_number}/locations/{location_id} where `location_id` refers to a GCP - * region. + * projects/{project_number}/locations/{location_id} where `location_id` refers to a Google + * Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails * @deprecated This method is deprecated and will be removed in the next major version update. */ diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataplexServiceClient.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataplexServiceClient.java index fbad6f2de486..93e2b1dacc17 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataplexServiceClient.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/DataplexServiceClient.java @@ -906,8 +906,8 @@ public final OperationsClient getHttpJsonOperationsClient() { * } * * @param parent Required. The resource name of the lake location, of the form: - * projects/{project_number}/locations/{location_id} where `location_id` refers to a GCP - * region. + * projects/{project_number}/locations/{location_id} where `location_id` refers to a Google + * Cloud region. * @param lake Required. Lake resource * @param lakeId Required. Lake identifier. This ID will be used to generate names such as * database and dataset names when publishing metadata to Hive Metastore and BigQuery. @@ -953,8 +953,8 @@ public final OperationFuture createLakeAsync( * } * * @param parent Required. The resource name of the lake location, of the form: - * projects/{project_number}/locations/{location_id} where `location_id` refers to a GCP - * region. + * projects/{project_number}/locations/{location_id} where `location_id` refers to a Google + * Cloud region. * @param lake Required. Lake resource * @param lakeId Required. Lake identifier. This ID will be used to generate names such as * database and dataset names when publishing metadata to Hive Metastore and BigQuery. @@ -1354,8 +1354,8 @@ public final UnaryCallable deleteLakeCallable() { * } * * @param parent Required. The resource name of the lake location, of the form: - * `projects/{project_number}/locations/{location_id}` where `location_id` refers to a GCP - * region. + * `projects/{project_number}/locations/{location_id}` where `location_id` refers to a Google + * Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListLakesPagedResponse listLakes(LocationName parent) { @@ -1385,8 +1385,8 @@ public final ListLakesPagedResponse listLakes(LocationName parent) { * } * * @param parent Required. The resource name of the lake location, of the form: - * `projects/{project_number}/locations/{location_id}` where `location_id` refers to a GCP - * region. + * `projects/{project_number}/locations/{location_id}` where `location_id` refers to a Google + * Cloud region. * @throws com.google.api.gax.rpc.ApiException if the remote call fails */ public final ListLakesPagedResponse listLakes(String parent) { diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/gapic_metadata.json b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/gapic_metadata.json index d92810057871..50f7beb25a4c 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/gapic_metadata.json +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/gapic_metadata.json @@ -5,6 +5,66 @@ "protoPackage": "google.cloud.dataplex.v1", "libraryPackage": "com.google.cloud.dataplex.v1", "services": { + "BusinessGlossaryService": { + "clients": { + "grpc": { + "libraryClient": "BusinessGlossaryServiceClient", + "rpcs": { + "CreateGlossary": { + "methods": ["createGlossaryAsync", "createGlossaryAsync", "createGlossaryAsync", "createGlossaryOperationCallable", "createGlossaryCallable"] + }, + "CreateGlossaryCategory": { + "methods": ["createGlossaryCategory", "createGlossaryCategory", "createGlossaryCategory", "createGlossaryCategoryCallable"] + }, + "CreateGlossaryTerm": { + "methods": ["createGlossaryTerm", "createGlossaryTerm", "createGlossaryTerm", "createGlossaryTermCallable"] + }, + "DeleteGlossary": { + "methods": ["deleteGlossaryAsync", "deleteGlossaryAsync", "deleteGlossaryAsync", "deleteGlossaryOperationCallable", "deleteGlossaryCallable"] + }, + "DeleteGlossaryCategory": { + "methods": ["deleteGlossaryCategory", "deleteGlossaryCategory", "deleteGlossaryCategory", "deleteGlossaryCategoryCallable"] + }, + "DeleteGlossaryTerm": { + "methods": ["deleteGlossaryTerm", "deleteGlossaryTerm", "deleteGlossaryTerm", "deleteGlossaryTermCallable"] + }, + "GetGlossary": { + "methods": ["getGlossary", "getGlossary", "getGlossary", "getGlossaryCallable"] + }, + "GetGlossaryCategory": { + "methods": ["getGlossaryCategory", "getGlossaryCategory", "getGlossaryCategory", "getGlossaryCategoryCallable"] + }, + "GetGlossaryTerm": { + "methods": ["getGlossaryTerm", "getGlossaryTerm", "getGlossaryTerm", "getGlossaryTermCallable"] + }, + "GetLocation": { + "methods": ["getLocation", "getLocationCallable"] + }, + "ListGlossaries": { + "methods": ["listGlossaries", "listGlossaries", "listGlossaries", "listGlossariesPagedCallable", "listGlossariesCallable"] + }, + "ListGlossaryCategories": { + "methods": ["listGlossaryCategories", "listGlossaryCategories", "listGlossaryCategories", "listGlossaryCategoriesPagedCallable", "listGlossaryCategoriesCallable"] + }, + "ListGlossaryTerms": { + "methods": ["listGlossaryTerms", "listGlossaryTerms", "listGlossaryTerms", "listGlossaryTermsPagedCallable", "listGlossaryTermsCallable"] + }, + "ListLocations": { + "methods": ["listLocations", "listLocationsPagedCallable", "listLocationsCallable"] + }, + "UpdateGlossary": { + "methods": ["updateGlossaryAsync", "updateGlossaryAsync", "updateGlossaryOperationCallable", "updateGlossaryCallable"] + }, + "UpdateGlossaryCategory": { + "methods": ["updateGlossaryCategory", "updateGlossaryCategory", "updateGlossaryCategoryCallable"] + }, + "UpdateGlossaryTerm": { + "methods": ["updateGlossaryTerm", "updateGlossaryTerm", "updateGlossaryTermCallable"] + } + } + } + } + }, "CatalogService": { "clients": { "grpc": { @@ -22,6 +82,9 @@ "CreateEntryGroup": { "methods": ["createEntryGroupAsync", "createEntryGroupAsync", "createEntryGroupAsync", "createEntryGroupOperationCallable", "createEntryGroupCallable"] }, + "CreateEntryLink": { + "methods": ["createEntryLink", "createEntryLink", "createEntryLink", "createEntryLinkCallable"] + }, "CreateEntryType": { "methods": ["createEntryTypeAsync", "createEntryTypeAsync", "createEntryTypeAsync", "createEntryTypeOperationCallable", "createEntryTypeCallable"] }, @@ -37,6 +100,9 @@ "DeleteEntryGroup": { "methods": ["deleteEntryGroupAsync", "deleteEntryGroupAsync", "deleteEntryGroupAsync", "deleteEntryGroupOperationCallable", "deleteEntryGroupCallable"] }, + "DeleteEntryLink": { + "methods": ["deleteEntryLink", "deleteEntryLink", "deleteEntryLink", "deleteEntryLinkCallable"] + }, "DeleteEntryType": { "methods": ["deleteEntryTypeAsync", "deleteEntryTypeAsync", "deleteEntryTypeAsync", "deleteEntryTypeOperationCallable", "deleteEntryTypeCallable"] }, @@ -49,6 +115,9 @@ "GetEntryGroup": { "methods": ["getEntryGroup", "getEntryGroup", "getEntryGroup", "getEntryGroupCallable"] }, + "GetEntryLink": { + "methods": ["getEntryLink", "getEntryLink", "getEntryLink", "getEntryLinkCallable"] + }, "GetEntryType": { "methods": ["getEntryType", "getEntryType", "getEntryType", "getEntryTypeCallable"] }, diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/package-info.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/package-info.java index 15a575edffcd..c94cb0f9471e 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/package-info.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/package-info.java @@ -19,12 +19,33 @@ * *

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

        ======================= BusinessGlossaryServiceClient ======================= + * + *

        Service Description: BusinessGlossaryService provides APIs for managing business glossary + * resources for enterprise customers. The resources currently supported in Business Glossary are: + * 1. Glossary 2. GlossaryCategory 3. GlossaryTerm + * + *

        Sample for BusinessGlossaryServiceClient: + * + *

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

        ======================= CatalogServiceClient ======================= * *

        Service Description: The primary resources offered by this service are EntryGroups, - * EntryTypes, AspectTypes, and Entries. They collectively let data administrators organize, manage, - * secure, and catalog data located across cloud projects in their organization in a variety of - * storage systems, including Cloud Storage and BigQuery. + * EntryTypes, AspectTypes, Entries and EntryLinks. They collectively let data administrators + * organize, manage, secure, and catalog data located across cloud projects in their organization in + * a variety of storage systems, including Cloud Storage and BigQuery. * *

        Sample for CatalogServiceClient: * @@ -42,7 +63,8 @@ * *

        ======================= CmekServiceClient ======================= * - *

        Service Description: Dataplex Cmek Service + *

        Service Description: Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) + * Service * *

        Sample for CmekServiceClient: * @@ -61,7 +83,8 @@ * *

        ======================= ContentServiceClient ======================= * - *

        Service Description: ContentService manages Notebook and SQL Scripts for Dataplex. + *

        Service Description: ContentService manages Notebook and SQL Scripts for Dataplex Universal + * Catalog. * *

        Sample for ContentServiceClient: * diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/BusinessGlossaryServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/BusinessGlossaryServiceStub.java new file mode 100644 index 000000000000..debf802702d3 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/BusinessGlossaryServiceStub.java @@ -0,0 +1,185 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.stub; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListLocationsPagedResponse; + +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.dataplex.v1.CreateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryTermRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryTermRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.ListGlossariesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; +import com.google.cloud.dataplex.v1.ListGlossaryTermsResponse; +import com.google.cloud.dataplex.v1.OperationMetadata; +import com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest; +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 com.google.longrunning.stub.OperationsStub; +import com.google.protobuf.Empty; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the BusinessGlossaryService service API. + * + *

        This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public abstract class BusinessGlossaryServiceStub implements BackgroundResource { + + public OperationsStub getOperationsStub() { + return null; + } + + public com.google.api.gax.httpjson.longrunning.stub.OperationsStub getHttpJsonOperationsStub() { + return null; + } + + public OperationCallable + createGlossaryOperationCallable() { + throw new UnsupportedOperationException("Not implemented: createGlossaryOperationCallable()"); + } + + public UnaryCallable createGlossaryCallable() { + throw new UnsupportedOperationException("Not implemented: createGlossaryCallable()"); + } + + public OperationCallable + updateGlossaryOperationCallable() { + throw new UnsupportedOperationException("Not implemented: updateGlossaryOperationCallable()"); + } + + public UnaryCallable updateGlossaryCallable() { + throw new UnsupportedOperationException("Not implemented: updateGlossaryCallable()"); + } + + public OperationCallable + deleteGlossaryOperationCallable() { + throw new UnsupportedOperationException("Not implemented: deleteGlossaryOperationCallable()"); + } + + public UnaryCallable deleteGlossaryCallable() { + throw new UnsupportedOperationException("Not implemented: deleteGlossaryCallable()"); + } + + public UnaryCallable getGlossaryCallable() { + throw new UnsupportedOperationException("Not implemented: getGlossaryCallable()"); + } + + public UnaryCallable + listGlossariesPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listGlossariesPagedCallable()"); + } + + public UnaryCallable listGlossariesCallable() { + throw new UnsupportedOperationException("Not implemented: listGlossariesCallable()"); + } + + public UnaryCallable + createGlossaryCategoryCallable() { + throw new UnsupportedOperationException("Not implemented: createGlossaryCategoryCallable()"); + } + + public UnaryCallable + updateGlossaryCategoryCallable() { + throw new UnsupportedOperationException("Not implemented: updateGlossaryCategoryCallable()"); + } + + public UnaryCallable deleteGlossaryCategoryCallable() { + throw new UnsupportedOperationException("Not implemented: deleteGlossaryCategoryCallable()"); + } + + public UnaryCallable getGlossaryCategoryCallable() { + throw new UnsupportedOperationException("Not implemented: getGlossaryCategoryCallable()"); + } + + public UnaryCallable + listGlossaryCategoriesPagedCallable() { + throw new UnsupportedOperationException( + "Not implemented: listGlossaryCategoriesPagedCallable()"); + } + + public UnaryCallable + listGlossaryCategoriesCallable() { + throw new UnsupportedOperationException("Not implemented: listGlossaryCategoriesCallable()"); + } + + public UnaryCallable createGlossaryTermCallable() { + throw new UnsupportedOperationException("Not implemented: createGlossaryTermCallable()"); + } + + public UnaryCallable updateGlossaryTermCallable() { + throw new UnsupportedOperationException("Not implemented: updateGlossaryTermCallable()"); + } + + public UnaryCallable deleteGlossaryTermCallable() { + throw new UnsupportedOperationException("Not implemented: deleteGlossaryTermCallable()"); + } + + public UnaryCallable getGlossaryTermCallable() { + throw new UnsupportedOperationException("Not implemented: getGlossaryTermCallable()"); + } + + public UnaryCallable + listGlossaryTermsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listGlossaryTermsPagedCallable()"); + } + + public UnaryCallable + listGlossaryTermsCallable() { + throw new UnsupportedOperationException("Not implemented: listGlossaryTermsCallable()"); + } + + 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-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/BusinessGlossaryServiceStubSettings.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/BusinessGlossaryServiceStubSettings.java new file mode 100644 index 000000000000..9bd5b7451f82 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/BusinessGlossaryServiceStubSettings.java @@ -0,0 +1,1183 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.stub; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListLocationsPagedResponse; + +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.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.dataplex.v1.CreateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryTermRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryTermRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.ListGlossariesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; +import com.google.cloud.dataplex.v1.ListGlossaryTermsResponse; +import com.google.cloud.dataplex.v1.OperationMetadata; +import com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest; +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 com.google.protobuf.Empty; +import java.io.IOException; +import java.time.Duration; +import java.util.List; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link BusinessGlossaryServiceStub}. + * + *

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

          + *
        • The default service address (dataplex.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 getGlossary: + * + *

        {@code
        + * // This snippet has been automatically generated and should be regarded as a code template only.
        + * // It will require modifications to work:
        + * // - It may require correct/in-range values for request initialization.
        + * // - It may require specifying regional endpoints when creating the service client as shown in
        + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
        + * BusinessGlossaryServiceStubSettings.Builder businessGlossaryServiceSettingsBuilder =
        + *     BusinessGlossaryServiceStubSettings.newBuilder();
        + * businessGlossaryServiceSettingsBuilder
        + *     .getGlossarySettings()
        + *     .setRetrySettings(
        + *         businessGlossaryServiceSettingsBuilder
        + *             .getGlossarySettings()
        + *             .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());
        + * BusinessGlossaryServiceStubSettings businessGlossaryServiceSettings =
        + *     businessGlossaryServiceSettingsBuilder.build();
        + * }
        + * + * Please refer to the [Client Side Retry + * Guide](https://github.com/googleapis/google-cloud-java/blob/main/docs/client_retries.md) 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 createGlossary: + * + *

        {@code
        + * // This snippet has been automatically generated and should be regarded as a code template only.
        + * // It will require modifications to work:
        + * // - It may require correct/in-range values for request initialization.
        + * // - It may require specifying regional endpoints when creating the service client as shown in
        + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
        + * BusinessGlossaryServiceStubSettings.Builder businessGlossaryServiceSettingsBuilder =
        + *     BusinessGlossaryServiceStubSettings.newBuilder();
        + * TimedRetryAlgorithm timedRetryAlgorithm =
        + *     OperationalTimedPollAlgorithm.create(
        + *         RetrySettings.newBuilder()
        + *             .setInitialRetryDelayDuration(Duration.ofMillis(500))
        + *             .setRetryDelayMultiplier(1.5)
        + *             .setMaxRetryDelayDuration(Duration.ofMillis(5000))
        + *             .setTotalTimeoutDuration(Duration.ofHours(24))
        + *             .build());
        + * businessGlossaryServiceSettingsBuilder
        + *     .createClusterOperationSettings()
        + *     .setPollingAlgorithm(timedRetryAlgorithm)
        + *     .build();
        + * }
        + */ +@Generated("by gapic-generator-java") +public class BusinessGlossaryServiceStubSettings + 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 createGlossarySettings; + private final OperationCallSettings + createGlossaryOperationSettings; + private final UnaryCallSettings updateGlossarySettings; + private final OperationCallSettings + updateGlossaryOperationSettings; + private final UnaryCallSettings deleteGlossarySettings; + private final OperationCallSettings + deleteGlossaryOperationSettings; + private final UnaryCallSettings getGlossarySettings; + private final PagedCallSettings< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + listGlossariesSettings; + private final UnaryCallSettings + createGlossaryCategorySettings; + private final UnaryCallSettings + updateGlossaryCategorySettings; + private final UnaryCallSettings + deleteGlossaryCategorySettings; + private final UnaryCallSettings + getGlossaryCategorySettings; + private final PagedCallSettings< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + listGlossaryCategoriesSettings; + private final UnaryCallSettings + createGlossaryTermSettings; + private final UnaryCallSettings + updateGlossaryTermSettings; + private final UnaryCallSettings deleteGlossaryTermSettings; + private final UnaryCallSettings getGlossaryTermSettings; + private final PagedCallSettings< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + listGlossaryTermsSettings; + private final PagedCallSettings< + ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> + listLocationsSettings; + private final UnaryCallSettings getLocationSettings; + + private static final PagedListDescriptor + LIST_GLOSSARIES_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListGlossariesRequest injectToken(ListGlossariesRequest payload, String token) { + return ListGlossariesRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListGlossariesRequest injectPageSize( + ListGlossariesRequest payload, int pageSize) { + return ListGlossariesRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListGlossariesRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListGlossariesResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListGlossariesResponse payload) { + return payload.getGlossariesList(); + } + }; + + private static final PagedListDescriptor< + ListGlossaryCategoriesRequest, ListGlossaryCategoriesResponse, GlossaryCategory> + LIST_GLOSSARY_CATEGORIES_PAGE_STR_DESC = + new PagedListDescriptor< + ListGlossaryCategoriesRequest, ListGlossaryCategoriesResponse, GlossaryCategory>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListGlossaryCategoriesRequest injectToken( + ListGlossaryCategoriesRequest payload, String token) { + return ListGlossaryCategoriesRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListGlossaryCategoriesRequest injectPageSize( + ListGlossaryCategoriesRequest payload, int pageSize) { + return ListGlossaryCategoriesRequest.newBuilder(payload) + .setPageSize(pageSize) + .build(); + } + + @Override + public Integer extractPageSize(ListGlossaryCategoriesRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListGlossaryCategoriesResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListGlossaryCategoriesResponse payload) { + return payload.getCategoriesList(); + } + }; + + private static final PagedListDescriptor< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, GlossaryTerm> + LIST_GLOSSARY_TERMS_PAGE_STR_DESC = + new PagedListDescriptor< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, GlossaryTerm>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListGlossaryTermsRequest injectToken( + ListGlossaryTermsRequest payload, String token) { + return ListGlossaryTermsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListGlossaryTermsRequest injectPageSize( + ListGlossaryTermsRequest payload, int pageSize) { + return ListGlossaryTermsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListGlossaryTermsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListGlossaryTermsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListGlossaryTermsResponse payload) { + return payload.getTermsList(); + } + }; + + 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< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + LIST_GLOSSARIES_PAGE_STR_FACT = + new PagedListResponseFactory< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListGlossariesRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_GLOSSARIES_PAGE_STR_DESC, request, context); + return ListGlossariesPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + LIST_GLOSSARY_CATEGORIES_PAGE_STR_FACT = + new PagedListResponseFactory< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable + callable, + ListGlossaryCategoriesRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + GlossaryCategory> + pageContext = + PageContext.create( + callable, LIST_GLOSSARY_CATEGORIES_PAGE_STR_DESC, request, context); + return ListGlossaryCategoriesPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + private static final PagedListResponseFactory< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + LIST_GLOSSARY_TERMS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListGlossaryTermsRequest, + ListGlossaryTermsResponse, + ListGlossaryTermsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListGlossaryTermsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext + pageContext = + PageContext.create( + callable, LIST_GLOSSARY_TERMS_PAGE_STR_DESC, request, context); + return ListGlossaryTermsPagedResponse.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 createGlossary. */ + public UnaryCallSettings createGlossarySettings() { + return createGlossarySettings; + } + + /** Returns the object with the settings used for calls to createGlossary. */ + public OperationCallSettings + createGlossaryOperationSettings() { + return createGlossaryOperationSettings; + } + + /** Returns the object with the settings used for calls to updateGlossary. */ + public UnaryCallSettings updateGlossarySettings() { + return updateGlossarySettings; + } + + /** Returns the object with the settings used for calls to updateGlossary. */ + public OperationCallSettings + updateGlossaryOperationSettings() { + return updateGlossaryOperationSettings; + } + + /** Returns the object with the settings used for calls to deleteGlossary. */ + public UnaryCallSettings deleteGlossarySettings() { + return deleteGlossarySettings; + } + + /** Returns the object with the settings used for calls to deleteGlossary. */ + public OperationCallSettings + deleteGlossaryOperationSettings() { + return deleteGlossaryOperationSettings; + } + + /** Returns the object with the settings used for calls to getGlossary. */ + public UnaryCallSettings getGlossarySettings() { + return getGlossarySettings; + } + + /** Returns the object with the settings used for calls to listGlossaries. */ + public PagedCallSettings< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + listGlossariesSettings() { + return listGlossariesSettings; + } + + /** Returns the object with the settings used for calls to createGlossaryCategory. */ + public UnaryCallSettings + createGlossaryCategorySettings() { + return createGlossaryCategorySettings; + } + + /** Returns the object with the settings used for calls to updateGlossaryCategory. */ + public UnaryCallSettings + updateGlossaryCategorySettings() { + return updateGlossaryCategorySettings; + } + + /** Returns the object with the settings used for calls to deleteGlossaryCategory. */ + public UnaryCallSettings deleteGlossaryCategorySettings() { + return deleteGlossaryCategorySettings; + } + + /** Returns the object with the settings used for calls to getGlossaryCategory. */ + public UnaryCallSettings + getGlossaryCategorySettings() { + return getGlossaryCategorySettings; + } + + /** Returns the object with the settings used for calls to listGlossaryCategories. */ + public PagedCallSettings< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + listGlossaryCategoriesSettings() { + return listGlossaryCategoriesSettings; + } + + /** Returns the object with the settings used for calls to createGlossaryTerm. */ + public UnaryCallSettings createGlossaryTermSettings() { + return createGlossaryTermSettings; + } + + /** Returns the object with the settings used for calls to updateGlossaryTerm. */ + public UnaryCallSettings updateGlossaryTermSettings() { + return updateGlossaryTermSettings; + } + + /** Returns the object with the settings used for calls to deleteGlossaryTerm. */ + public UnaryCallSettings deleteGlossaryTermSettings() { + return deleteGlossaryTermSettings; + } + + /** Returns the object with the settings used for calls to getGlossaryTerm. */ + public UnaryCallSettings getGlossaryTermSettings() { + return getGlossaryTermSettings; + } + + /** Returns the object with the settings used for calls to listGlossaryTerms. */ + public PagedCallSettings< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + listGlossaryTermsSettings() { + return listGlossaryTermsSettings; + } + + /** 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 BusinessGlossaryServiceStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcBusinessGlossaryServiceStub.create(this); + } + if (getTransportChannelProvider() + .getTransportName() + .equals(HttpJsonTransportChannel.getHttpJsonTransportName())) { + return HttpJsonBusinessGlossaryServiceStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns the default service name. */ + @Override + public String getServiceName() { + return "dataplex"; + } + + /** 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 "dataplex.googleapis.com:443"; + } + + /** Returns the default mTLS service endpoint. */ + public static String getDefaultMtlsEndpoint() { + return "dataplex.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(BusinessGlossaryServiceStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + public static ApiClientHeaderProvider.Builder defaultHttpJsonApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(BusinessGlossaryServiceStubSettings.class)) + .setTransportToken( + GaxHttpJsonProperties.getHttpJsonTokenName(), + GaxHttpJsonProperties.getHttpJsonVersion()); + } + + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return BusinessGlossaryServiceStubSettings.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(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 BusinessGlossaryServiceStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + createGlossarySettings = settingsBuilder.createGlossarySettings().build(); + createGlossaryOperationSettings = settingsBuilder.createGlossaryOperationSettings().build(); + updateGlossarySettings = settingsBuilder.updateGlossarySettings().build(); + updateGlossaryOperationSettings = settingsBuilder.updateGlossaryOperationSettings().build(); + deleteGlossarySettings = settingsBuilder.deleteGlossarySettings().build(); + deleteGlossaryOperationSettings = settingsBuilder.deleteGlossaryOperationSettings().build(); + getGlossarySettings = settingsBuilder.getGlossarySettings().build(); + listGlossariesSettings = settingsBuilder.listGlossariesSettings().build(); + createGlossaryCategorySettings = settingsBuilder.createGlossaryCategorySettings().build(); + updateGlossaryCategorySettings = settingsBuilder.updateGlossaryCategorySettings().build(); + deleteGlossaryCategorySettings = settingsBuilder.deleteGlossaryCategorySettings().build(); + getGlossaryCategorySettings = settingsBuilder.getGlossaryCategorySettings().build(); + listGlossaryCategoriesSettings = settingsBuilder.listGlossaryCategoriesSettings().build(); + createGlossaryTermSettings = settingsBuilder.createGlossaryTermSettings().build(); + updateGlossaryTermSettings = settingsBuilder.updateGlossaryTermSettings().build(); + deleteGlossaryTermSettings = settingsBuilder.deleteGlossaryTermSettings().build(); + getGlossaryTermSettings = settingsBuilder.getGlossaryTermSettings().build(); + listGlossaryTermsSettings = settingsBuilder.listGlossaryTermsSettings().build(); + listLocationsSettings = settingsBuilder.listLocationsSettings().build(); + getLocationSettings = settingsBuilder.getLocationSettings().build(); + } + + /** Builder for BusinessGlossaryServiceStubSettings. */ + public static class Builder + extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final UnaryCallSettings.Builder + createGlossarySettings; + private final OperationCallSettings.Builder + createGlossaryOperationSettings; + private final UnaryCallSettings.Builder + updateGlossarySettings; + private final OperationCallSettings.Builder + updateGlossaryOperationSettings; + private final UnaryCallSettings.Builder + deleteGlossarySettings; + private final OperationCallSettings.Builder + deleteGlossaryOperationSettings; + private final UnaryCallSettings.Builder getGlossarySettings; + private final PagedCallSettings.Builder< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + listGlossariesSettings; + private final UnaryCallSettings.Builder + createGlossaryCategorySettings; + private final UnaryCallSettings.Builder + updateGlossaryCategorySettings; + private final UnaryCallSettings.Builder + deleteGlossaryCategorySettings; + private final UnaryCallSettings.Builder + getGlossaryCategorySettings; + private final PagedCallSettings.Builder< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + listGlossaryCategoriesSettings; + private final UnaryCallSettings.Builder + createGlossaryTermSettings; + private final UnaryCallSettings.Builder + updateGlossaryTermSettings; + private final UnaryCallSettings.Builder + deleteGlossaryTermSettings; + private final UnaryCallSettings.Builder + getGlossaryTermSettings; + private final PagedCallSettings.Builder< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + listGlossaryTermsSettings; + 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("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(ClientContext clientContext) { + super(clientContext); + + createGlossarySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createGlossaryOperationSettings = OperationCallSettings.newBuilder(); + updateGlossarySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateGlossaryOperationSettings = OperationCallSettings.newBuilder(); + deleteGlossarySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteGlossaryOperationSettings = OperationCallSettings.newBuilder(); + getGlossarySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listGlossariesSettings = PagedCallSettings.newBuilder(LIST_GLOSSARIES_PAGE_STR_FACT); + createGlossaryCategorySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateGlossaryCategorySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteGlossaryCategorySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getGlossaryCategorySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listGlossaryCategoriesSettings = + PagedCallSettings.newBuilder(LIST_GLOSSARY_CATEGORIES_PAGE_STR_FACT); + createGlossaryTermSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateGlossaryTermSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteGlossaryTermSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getGlossaryTermSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listGlossaryTermsSettings = PagedCallSettings.newBuilder(LIST_GLOSSARY_TERMS_PAGE_STR_FACT); + listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); + getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createGlossarySettings, + updateGlossarySettings, + deleteGlossarySettings, + getGlossarySettings, + listGlossariesSettings, + createGlossaryCategorySettings, + updateGlossaryCategorySettings, + deleteGlossaryCategorySettings, + getGlossaryCategorySettings, + listGlossaryCategoriesSettings, + createGlossaryTermSettings, + updateGlossaryTermSettings, + deleteGlossaryTermSettings, + getGlossaryTermSettings, + listGlossaryTermsSettings, + listLocationsSettings, + getLocationSettings); + initDefaults(this); + } + + protected Builder(BusinessGlossaryServiceStubSettings settings) { + super(settings); + + createGlossarySettings = settings.createGlossarySettings.toBuilder(); + createGlossaryOperationSettings = settings.createGlossaryOperationSettings.toBuilder(); + updateGlossarySettings = settings.updateGlossarySettings.toBuilder(); + updateGlossaryOperationSettings = settings.updateGlossaryOperationSettings.toBuilder(); + deleteGlossarySettings = settings.deleteGlossarySettings.toBuilder(); + deleteGlossaryOperationSettings = settings.deleteGlossaryOperationSettings.toBuilder(); + getGlossarySettings = settings.getGlossarySettings.toBuilder(); + listGlossariesSettings = settings.listGlossariesSettings.toBuilder(); + createGlossaryCategorySettings = settings.createGlossaryCategorySettings.toBuilder(); + updateGlossaryCategorySettings = settings.updateGlossaryCategorySettings.toBuilder(); + deleteGlossaryCategorySettings = settings.deleteGlossaryCategorySettings.toBuilder(); + getGlossaryCategorySettings = settings.getGlossaryCategorySettings.toBuilder(); + listGlossaryCategoriesSettings = settings.listGlossaryCategoriesSettings.toBuilder(); + createGlossaryTermSettings = settings.createGlossaryTermSettings.toBuilder(); + updateGlossaryTermSettings = settings.updateGlossaryTermSettings.toBuilder(); + deleteGlossaryTermSettings = settings.deleteGlossaryTermSettings.toBuilder(); + getGlossaryTermSettings = settings.getGlossaryTermSettings.toBuilder(); + listGlossaryTermsSettings = settings.listGlossaryTermsSettings.toBuilder(); + listLocationsSettings = settings.listLocationsSettings.toBuilder(); + getLocationSettings = settings.getLocationSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createGlossarySettings, + updateGlossarySettings, + deleteGlossarySettings, + getGlossarySettings, + listGlossariesSettings, + createGlossaryCategorySettings, + updateGlossaryCategorySettings, + deleteGlossaryCategorySettings, + getGlossaryCategorySettings, + listGlossaryCategoriesSettings, + createGlossaryTermSettings, + updateGlossaryTermSettings, + deleteGlossaryTermSettings, + getGlossaryTermSettings, + listGlossaryTermsSettings, + 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 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 + .createGlossarySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .updateGlossarySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteGlossarySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getGlossarySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listGlossariesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createGlossaryCategorySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .updateGlossaryCategorySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteGlossaryCategorySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getGlossaryCategorySettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listGlossaryCategoriesSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .createGlossaryTermSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .updateGlossaryTermSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteGlossaryTermSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getGlossaryTermSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .listGlossaryTermsSettings() + .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 + .createGlossaryOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Glossary.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 + .updateGlossaryOperationSettings() + .setInitialCallSettings( + UnaryCallSettings + .newUnaryCallSettingsBuilder() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) + .build()) + .setResponseTransformer( + ProtoOperationTransformers.ResponseTransformer.create(Glossary.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 + .deleteGlossaryOperationSettings() + .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(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 createGlossary. */ + public UnaryCallSettings.Builder createGlossarySettings() { + return createGlossarySettings; + } + + /** Returns the builder for the settings used for calls to createGlossary. */ + public OperationCallSettings.Builder + createGlossaryOperationSettings() { + return createGlossaryOperationSettings; + } + + /** Returns the builder for the settings used for calls to updateGlossary. */ + public UnaryCallSettings.Builder updateGlossarySettings() { + return updateGlossarySettings; + } + + /** Returns the builder for the settings used for calls to updateGlossary. */ + public OperationCallSettings.Builder + updateGlossaryOperationSettings() { + return updateGlossaryOperationSettings; + } + + /** Returns the builder for the settings used for calls to deleteGlossary. */ + public UnaryCallSettings.Builder deleteGlossarySettings() { + return deleteGlossarySettings; + } + + /** Returns the builder for the settings used for calls to deleteGlossary. */ + public OperationCallSettings.Builder + deleteGlossaryOperationSettings() { + return deleteGlossaryOperationSettings; + } + + /** Returns the builder for the settings used for calls to getGlossary. */ + public UnaryCallSettings.Builder getGlossarySettings() { + return getGlossarySettings; + } + + /** Returns the builder for the settings used for calls to listGlossaries. */ + public PagedCallSettings.Builder< + ListGlossariesRequest, ListGlossariesResponse, ListGlossariesPagedResponse> + listGlossariesSettings() { + return listGlossariesSettings; + } + + /** Returns the builder for the settings used for calls to createGlossaryCategory. */ + public UnaryCallSettings.Builder + createGlossaryCategorySettings() { + return createGlossaryCategorySettings; + } + + /** Returns the builder for the settings used for calls to updateGlossaryCategory. */ + public UnaryCallSettings.Builder + updateGlossaryCategorySettings() { + return updateGlossaryCategorySettings; + } + + /** Returns the builder for the settings used for calls to deleteGlossaryCategory. */ + public UnaryCallSettings.Builder + deleteGlossaryCategorySettings() { + return deleteGlossaryCategorySettings; + } + + /** Returns the builder for the settings used for calls to getGlossaryCategory. */ + public UnaryCallSettings.Builder + getGlossaryCategorySettings() { + return getGlossaryCategorySettings; + } + + /** Returns the builder for the settings used for calls to listGlossaryCategories. */ + public PagedCallSettings.Builder< + ListGlossaryCategoriesRequest, + ListGlossaryCategoriesResponse, + ListGlossaryCategoriesPagedResponse> + listGlossaryCategoriesSettings() { + return listGlossaryCategoriesSettings; + } + + /** Returns the builder for the settings used for calls to createGlossaryTerm. */ + public UnaryCallSettings.Builder + createGlossaryTermSettings() { + return createGlossaryTermSettings; + } + + /** Returns the builder for the settings used for calls to updateGlossaryTerm. */ + public UnaryCallSettings.Builder + updateGlossaryTermSettings() { + return updateGlossaryTermSettings; + } + + /** Returns the builder for the settings used for calls to deleteGlossaryTerm. */ + public UnaryCallSettings.Builder + deleteGlossaryTermSettings() { + return deleteGlossaryTermSettings; + } + + /** Returns the builder for the settings used for calls to getGlossaryTerm. */ + public UnaryCallSettings.Builder + getGlossaryTermSettings() { + return getGlossaryTermSettings; + } + + /** Returns the builder for the settings used for calls to listGlossaryTerms. */ + public PagedCallSettings.Builder< + ListGlossaryTermsRequest, ListGlossaryTermsResponse, ListGlossaryTermsPagedResponse> + listGlossaryTermsSettings() { + return listGlossaryTermsSettings; + } + + /** 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 BusinessGlossaryServiceStubSettings build() throws IOException { + return new BusinessGlossaryServiceStubSettings(this); + } + } +} diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStub.java index 048e57cfc651..ca1b691ce870 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStub.java @@ -31,18 +31,22 @@ import com.google.cloud.dataplex.v1.CancelMetadataJobRequest; import com.google.cloud.dataplex.v1.CreateAspectTypeRequest; import com.google.cloud.dataplex.v1.CreateEntryGroupRequest; +import com.google.cloud.dataplex.v1.CreateEntryLinkRequest; import com.google.cloud.dataplex.v1.CreateEntryRequest; import com.google.cloud.dataplex.v1.CreateEntryTypeRequest; import com.google.cloud.dataplex.v1.CreateMetadataJobRequest; import com.google.cloud.dataplex.v1.DeleteAspectTypeRequest; import com.google.cloud.dataplex.v1.DeleteEntryGroupRequest; +import com.google.cloud.dataplex.v1.DeleteEntryLinkRequest; import com.google.cloud.dataplex.v1.DeleteEntryRequest; import com.google.cloud.dataplex.v1.DeleteEntryTypeRequest; import com.google.cloud.dataplex.v1.Entry; import com.google.cloud.dataplex.v1.EntryGroup; +import com.google.cloud.dataplex.v1.EntryLink; import com.google.cloud.dataplex.v1.EntryType; import com.google.cloud.dataplex.v1.GetAspectTypeRequest; import com.google.cloud.dataplex.v1.GetEntryGroupRequest; +import com.google.cloud.dataplex.v1.GetEntryLinkRequest; import com.google.cloud.dataplex.v1.GetEntryRequest; import com.google.cloud.dataplex.v1.GetEntryTypeRequest; import com.google.cloud.dataplex.v1.GetMetadataJobRequest; @@ -276,6 +280,18 @@ public UnaryCallable cancelMetadataJobCallable( throw new UnsupportedOperationException("Not implemented: cancelMetadataJobCallable()"); } + public UnaryCallable createEntryLinkCallable() { + throw new UnsupportedOperationException("Not implemented: createEntryLinkCallable()"); + } + + public UnaryCallable deleteEntryLinkCallable() { + throw new UnsupportedOperationException("Not implemented: deleteEntryLinkCallable()"); + } + + public UnaryCallable getEntryLinkCallable() { + throw new UnsupportedOperationException("Not implemented: getEntryLinkCallable()"); + } + public UnaryCallable listLocationsPagedCallable() { throw new UnsupportedOperationException("Not implemented: listLocationsPagedCallable()"); diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStubSettings.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStubSettings.java index 751dd65d2f08..33492676d377 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStubSettings.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/CatalogServiceStubSettings.java @@ -58,18 +58,22 @@ import com.google.cloud.dataplex.v1.CancelMetadataJobRequest; import com.google.cloud.dataplex.v1.CreateAspectTypeRequest; import com.google.cloud.dataplex.v1.CreateEntryGroupRequest; +import com.google.cloud.dataplex.v1.CreateEntryLinkRequest; import com.google.cloud.dataplex.v1.CreateEntryRequest; import com.google.cloud.dataplex.v1.CreateEntryTypeRequest; import com.google.cloud.dataplex.v1.CreateMetadataJobRequest; import com.google.cloud.dataplex.v1.DeleteAspectTypeRequest; import com.google.cloud.dataplex.v1.DeleteEntryGroupRequest; +import com.google.cloud.dataplex.v1.DeleteEntryLinkRequest; import com.google.cloud.dataplex.v1.DeleteEntryRequest; import com.google.cloud.dataplex.v1.DeleteEntryTypeRequest; import com.google.cloud.dataplex.v1.Entry; import com.google.cloud.dataplex.v1.EntryGroup; +import com.google.cloud.dataplex.v1.EntryLink; import com.google.cloud.dataplex.v1.EntryType; import com.google.cloud.dataplex.v1.GetAspectTypeRequest; import com.google.cloud.dataplex.v1.GetEntryGroupRequest; +import com.google.cloud.dataplex.v1.GetEntryLinkRequest; import com.google.cloud.dataplex.v1.GetEntryRequest; import com.google.cloud.dataplex.v1.GetEntryTypeRequest; import com.google.cloud.dataplex.v1.GetMetadataJobRequest; @@ -247,6 +251,9 @@ public class CatalogServiceStubSettings extends StubSettings listMetadataJobsSettings; private final UnaryCallSettings cancelMetadataJobSettings; + private final UnaryCallSettings createEntryLinkSettings; + private final UnaryCallSettings deleteEntryLinkSettings; + private final UnaryCallSettings getEntryLinkSettings; private final PagedCallSettings< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -825,6 +832,21 @@ public UnaryCallSettings cancelMetadataJobSetti return cancelMetadataJobSettings; } + /** Returns the object with the settings used for calls to createEntryLink. */ + public UnaryCallSettings createEntryLinkSettings() { + return createEntryLinkSettings; + } + + /** Returns the object with the settings used for calls to deleteEntryLink. */ + public UnaryCallSettings deleteEntryLinkSettings() { + return deleteEntryLinkSettings; + } + + /** Returns the object with the settings used for calls to getEntryLink. */ + public UnaryCallSettings getEntryLinkSettings() { + return getEntryLinkSettings; + } + /** Returns the object with the settings used for calls to listLocations. */ public PagedCallSettings listLocationsSettings() { @@ -984,6 +1006,9 @@ protected CatalogServiceStubSettings(Builder settingsBuilder) throws IOException getMetadataJobSettings = settingsBuilder.getMetadataJobSettings().build(); listMetadataJobsSettings = settingsBuilder.listMetadataJobsSettings().build(); cancelMetadataJobSettings = settingsBuilder.cancelMetadataJobSettings().build(); + createEntryLinkSettings = settingsBuilder.createEntryLinkSettings().build(); + deleteEntryLinkSettings = settingsBuilder.deleteEntryLinkSettings().build(); + getEntryLinkSettings = settingsBuilder.getEntryLinkSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); } @@ -1068,6 +1093,11 @@ public static class Builder extends StubSettings.Builder cancelMetadataJobSettings; + private final UnaryCallSettings.Builder + createEntryLinkSettings; + private final UnaryCallSettings.Builder + deleteEntryLinkSettings; + private final UnaryCallSettings.Builder getEntryLinkSettings; private final PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> listLocationsSettings; @@ -1203,6 +1233,9 @@ protected Builder(ClientContext clientContext) { getMetadataJobSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listMetadataJobsSettings = PagedCallSettings.newBuilder(LIST_METADATA_JOBS_PAGE_STR_FACT); cancelMetadataJobSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createEntryLinkSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteEntryLinkSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getEntryLinkSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1234,6 +1267,9 @@ protected Builder(ClientContext clientContext) { getMetadataJobSettings, listMetadataJobsSettings, cancelMetadataJobSettings, + createEntryLinkSettings, + deleteEntryLinkSettings, + getEntryLinkSettings, listLocationsSettings, getLocationSettings); initDefaults(this); @@ -1278,6 +1314,9 @@ protected Builder(CatalogServiceStubSettings settings) { getMetadataJobSettings = settings.getMetadataJobSettings.toBuilder(); listMetadataJobsSettings = settings.listMetadataJobsSettings.toBuilder(); cancelMetadataJobSettings = settings.cancelMetadataJobSettings.toBuilder(); + createEntryLinkSettings = settings.createEntryLinkSettings.toBuilder(); + deleteEntryLinkSettings = settings.deleteEntryLinkSettings.toBuilder(); + getEntryLinkSettings = settings.getEntryLinkSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); @@ -1309,6 +1348,9 @@ protected Builder(CatalogServiceStubSettings settings) { getMetadataJobSettings, listMetadataJobsSettings, cancelMetadataJobSettings, + createEntryLinkSettings, + deleteEntryLinkSettings, + getEntryLinkSettings, listLocationsSettings, getLocationSettings); } @@ -1468,6 +1510,21 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder + .createEntryLinkSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .deleteEntryLinkSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + + builder + .getEntryLinkSettings() + .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")) @@ -1945,6 +2002,21 @@ public UnaryCallSettings.Builder cancelMetadata return cancelMetadataJobSettings; } + /** Returns the builder for the settings used for calls to createEntryLink. */ + public UnaryCallSettings.Builder createEntryLinkSettings() { + return createEntryLinkSettings; + } + + /** Returns the builder for the settings used for calls to deleteEntryLink. */ + public UnaryCallSettings.Builder deleteEntryLinkSettings() { + return deleteEntryLinkSettings; + } + + /** Returns the builder for the settings used for calls to getEntryLink. */ + public UnaryCallSettings.Builder getEntryLinkSettings() { + return getEntryLinkSettings; + } + /** Returns the builder for the settings used for calls to listLocations. */ public PagedCallSettings.Builder< ListLocationsRequest, ListLocationsResponse, ListLocationsPagedResponse> diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcBusinessGlossaryServiceCallableFactory.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcBusinessGlossaryServiceCallableFactory.java new file mode 100644 index 000000000000..51bcaf0144ec --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcBusinessGlossaryServiceCallableFactory.java @@ -0,0 +1,113 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC callable factory implementation for the BusinessGlossaryService service API. + * + *

        This class is for advanced usage. + */ +@Generated("by gapic-generator-java") +public class GrpcBusinessGlossaryServiceCallableFactory 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-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcBusinessGlossaryServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcBusinessGlossaryServiceStub.java new file mode 100644 index 000000000000..8a5e3b81fb00 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcBusinessGlossaryServiceStub.java @@ -0,0 +1,811 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.stub; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListLocationsPagedResponse; + +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.dataplex.v1.CreateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryTermRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryTermRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.ListGlossariesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; +import com.google.cloud.dataplex.v1.ListGlossaryTermsResponse; +import com.google.cloud.dataplex.v1.OperationMetadata; +import com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest; +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 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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the BusinessGlossaryService service API. + * + *

        This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public class GrpcBusinessGlossaryServiceStub extends BusinessGlossaryServiceStub { + private static final MethodDescriptor + createGlossaryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/CreateGlossary") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateGlossaryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateGlossaryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/UpdateGlossary") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateGlossaryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteGlossaryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/DeleteGlossary") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteGlossaryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor getGlossaryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/GetGlossary") + .setRequestMarshaller(ProtoUtils.marshaller(GetGlossaryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Glossary.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listGlossariesMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/ListGlossaries") + .setRequestMarshaller( + ProtoUtils.marshaller(ListGlossariesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListGlossariesResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + createGlossaryCategoryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/CreateGlossaryCategory") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateGlossaryCategoryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(GlossaryCategory.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateGlossaryCategoryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/UpdateGlossaryCategory") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateGlossaryCategoryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(GlossaryCategory.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteGlossaryCategoryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/DeleteGlossaryCategory") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteGlossaryCategoryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getGlossaryCategoryMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/GetGlossaryCategory") + .setRequestMarshaller( + ProtoUtils.marshaller(GetGlossaryCategoryRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(GlossaryCategory.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor< + ListGlossaryCategoriesRequest, ListGlossaryCategoriesResponse> + listGlossaryCategoriesMethodDescriptor = + MethodDescriptor + .newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/ListGlossaryCategories") + .setRequestMarshaller( + ProtoUtils.marshaller(ListGlossaryCategoriesRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListGlossaryCategoriesResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + createGlossaryTermMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/CreateGlossaryTerm") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateGlossaryTermRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(GlossaryTerm.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + updateGlossaryTermMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/UpdateGlossaryTerm") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateGlossaryTermRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(GlossaryTerm.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteGlossaryTermMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/DeleteGlossaryTerm") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteGlossaryTermRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getGlossaryTermMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/GetGlossaryTerm") + .setRequestMarshaller( + ProtoUtils.marshaller(GetGlossaryTermRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(GlossaryTerm.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + listGlossaryTermsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/ListGlossaryTerms") + .setRequestMarshaller( + ProtoUtils.marshaller(ListGlossaryTermsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListGlossaryTermsResponse.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 final UnaryCallable createGlossaryCallable; + private final OperationCallable + createGlossaryOperationCallable; + private final UnaryCallable updateGlossaryCallable; + private final OperationCallable + updateGlossaryOperationCallable; + private final UnaryCallable deleteGlossaryCallable; + private final OperationCallable + deleteGlossaryOperationCallable; + private final UnaryCallable getGlossaryCallable; + private final UnaryCallable listGlossariesCallable; + private final UnaryCallable + listGlossariesPagedCallable; + private final UnaryCallable + createGlossaryCategoryCallable; + private final UnaryCallable + updateGlossaryCategoryCallable; + private final UnaryCallable deleteGlossaryCategoryCallable; + private final UnaryCallable + getGlossaryCategoryCallable; + private final UnaryCallable + listGlossaryCategoriesCallable; + private final UnaryCallable + listGlossaryCategoriesPagedCallable; + private final UnaryCallable createGlossaryTermCallable; + private final UnaryCallable updateGlossaryTermCallable; + private final UnaryCallable deleteGlossaryTermCallable; + private final UnaryCallable getGlossaryTermCallable; + private final UnaryCallable + listGlossaryTermsCallable; + private final UnaryCallable + listGlossaryTermsPagedCallable; + private final UnaryCallable listLocationsCallable; + private final UnaryCallable + listLocationsPagedCallable; + private final UnaryCallable getLocationCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcBusinessGlossaryServiceStub create( + BusinessGlossaryServiceStubSettings settings) throws IOException { + return new GrpcBusinessGlossaryServiceStub(settings, ClientContext.create(settings)); + } + + public static final GrpcBusinessGlossaryServiceStub create(ClientContext clientContext) + throws IOException { + return new GrpcBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcBusinessGlossaryServiceStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcBusinessGlossaryServiceStub, 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 GrpcBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcBusinessGlossaryServiceCallableFactory()); + } + + /** + * Constructs an instance of GrpcBusinessGlossaryServiceStub, 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 GrpcBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings createGlossaryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createGlossaryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + GrpcCallSettings updateGlossaryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateGlossaryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("glossary.name", String.valueOf(request.getGlossary().getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings deleteGlossaryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteGlossaryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings getGlossaryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getGlossaryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings + listGlossariesTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listGlossariesMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + GrpcCallSettings + createGlossaryCategoryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createGlossaryCategoryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + GrpcCallSettings + updateGlossaryCategoryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateGlossaryCategoryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("category.name", String.valueOf(request.getCategory().getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings deleteGlossaryCategoryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteGlossaryCategoryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings + getGlossaryCategoryTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getGlossaryCategoryMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings + listGlossaryCategoriesTransportSettings = + GrpcCallSettings + .newBuilder() + .setMethodDescriptor(listGlossaryCategoriesMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + GrpcCallSettings createGlossaryTermTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createGlossaryTermMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + GrpcCallSettings updateGlossaryTermTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateGlossaryTermMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("term.name", String.valueOf(request.getTerm().getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings deleteGlossaryTermTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteGlossaryTermMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings getGlossaryTermTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getGlossaryTermMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings + listGlossaryTermsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listGlossaryTermsMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .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(); + + this.createGlossaryCallable = + callableFactory.createUnaryCallable( + createGlossaryTransportSettings, settings.createGlossarySettings(), clientContext); + this.createGlossaryOperationCallable = + callableFactory.createOperationCallable( + createGlossaryTransportSettings, + settings.createGlossaryOperationSettings(), + clientContext, + operationsStub); + this.updateGlossaryCallable = + callableFactory.createUnaryCallable( + updateGlossaryTransportSettings, settings.updateGlossarySettings(), clientContext); + this.updateGlossaryOperationCallable = + callableFactory.createOperationCallable( + updateGlossaryTransportSettings, + settings.updateGlossaryOperationSettings(), + clientContext, + operationsStub); + this.deleteGlossaryCallable = + callableFactory.createUnaryCallable( + deleteGlossaryTransportSettings, settings.deleteGlossarySettings(), clientContext); + this.deleteGlossaryOperationCallable = + callableFactory.createOperationCallable( + deleteGlossaryTransportSettings, + settings.deleteGlossaryOperationSettings(), + clientContext, + operationsStub); + this.getGlossaryCallable = + callableFactory.createUnaryCallable( + getGlossaryTransportSettings, settings.getGlossarySettings(), clientContext); + this.listGlossariesCallable = + callableFactory.createUnaryCallable( + listGlossariesTransportSettings, settings.listGlossariesSettings(), clientContext); + this.listGlossariesPagedCallable = + callableFactory.createPagedCallable( + listGlossariesTransportSettings, settings.listGlossariesSettings(), clientContext); + this.createGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + createGlossaryCategoryTransportSettings, + settings.createGlossaryCategorySettings(), + clientContext); + this.updateGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + updateGlossaryCategoryTransportSettings, + settings.updateGlossaryCategorySettings(), + clientContext); + this.deleteGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + deleteGlossaryCategoryTransportSettings, + settings.deleteGlossaryCategorySettings(), + clientContext); + this.getGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + getGlossaryCategoryTransportSettings, + settings.getGlossaryCategorySettings(), + clientContext); + this.listGlossaryCategoriesCallable = + callableFactory.createUnaryCallable( + listGlossaryCategoriesTransportSettings, + settings.listGlossaryCategoriesSettings(), + clientContext); + this.listGlossaryCategoriesPagedCallable = + callableFactory.createPagedCallable( + listGlossaryCategoriesTransportSettings, + settings.listGlossaryCategoriesSettings(), + clientContext); + this.createGlossaryTermCallable = + callableFactory.createUnaryCallable( + createGlossaryTermTransportSettings, + settings.createGlossaryTermSettings(), + clientContext); + this.updateGlossaryTermCallable = + callableFactory.createUnaryCallable( + updateGlossaryTermTransportSettings, + settings.updateGlossaryTermSettings(), + clientContext); + this.deleteGlossaryTermCallable = + callableFactory.createUnaryCallable( + deleteGlossaryTermTransportSettings, + settings.deleteGlossaryTermSettings(), + clientContext); + this.getGlossaryTermCallable = + callableFactory.createUnaryCallable( + getGlossaryTermTransportSettings, settings.getGlossaryTermSettings(), clientContext); + this.listGlossaryTermsCallable = + callableFactory.createUnaryCallable( + listGlossaryTermsTransportSettings, + settings.listGlossaryTermsSettings(), + clientContext); + this.listGlossaryTermsPagedCallable = + callableFactory.createPagedCallable( + listGlossaryTermsTransportSettings, + settings.listGlossaryTermsSettings(), + 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()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + @Override + public UnaryCallable createGlossaryCallable() { + return createGlossaryCallable; + } + + @Override + public OperationCallable + createGlossaryOperationCallable() { + return createGlossaryOperationCallable; + } + + @Override + public UnaryCallable updateGlossaryCallable() { + return updateGlossaryCallable; + } + + @Override + public OperationCallable + updateGlossaryOperationCallable() { + return updateGlossaryOperationCallable; + } + + @Override + public UnaryCallable deleteGlossaryCallable() { + return deleteGlossaryCallable; + } + + @Override + public OperationCallable + deleteGlossaryOperationCallable() { + return deleteGlossaryOperationCallable; + } + + @Override + public UnaryCallable getGlossaryCallable() { + return getGlossaryCallable; + } + + @Override + public UnaryCallable listGlossariesCallable() { + return listGlossariesCallable; + } + + @Override + public UnaryCallable + listGlossariesPagedCallable() { + return listGlossariesPagedCallable; + } + + @Override + public UnaryCallable + createGlossaryCategoryCallable() { + return createGlossaryCategoryCallable; + } + + @Override + public UnaryCallable + updateGlossaryCategoryCallable() { + return updateGlossaryCategoryCallable; + } + + @Override + public UnaryCallable deleteGlossaryCategoryCallable() { + return deleteGlossaryCategoryCallable; + } + + @Override + public UnaryCallable getGlossaryCategoryCallable() { + return getGlossaryCategoryCallable; + } + + @Override + public UnaryCallable + listGlossaryCategoriesCallable() { + return listGlossaryCategoriesCallable; + } + + @Override + public UnaryCallable + listGlossaryCategoriesPagedCallable() { + return listGlossaryCategoriesPagedCallable; + } + + @Override + public UnaryCallable createGlossaryTermCallable() { + return createGlossaryTermCallable; + } + + @Override + public UnaryCallable updateGlossaryTermCallable() { + return updateGlossaryTermCallable; + } + + @Override + public UnaryCallable deleteGlossaryTermCallable() { + return deleteGlossaryTermCallable; + } + + @Override + public UnaryCallable getGlossaryTermCallable() { + return getGlossaryTermCallable; + } + + @Override + public UnaryCallable + listGlossaryTermsCallable() { + return listGlossaryTermsCallable; + } + + @Override + public UnaryCallable + listGlossaryTermsPagedCallable() { + return listGlossaryTermsPagedCallable; + } + + @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-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcCatalogServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcCatalogServiceStub.java index e5563390cb24..f07c8d175da8 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcCatalogServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/GrpcCatalogServiceStub.java @@ -36,18 +36,22 @@ import com.google.cloud.dataplex.v1.CancelMetadataJobRequest; import com.google.cloud.dataplex.v1.CreateAspectTypeRequest; import com.google.cloud.dataplex.v1.CreateEntryGroupRequest; +import com.google.cloud.dataplex.v1.CreateEntryLinkRequest; import com.google.cloud.dataplex.v1.CreateEntryRequest; import com.google.cloud.dataplex.v1.CreateEntryTypeRequest; import com.google.cloud.dataplex.v1.CreateMetadataJobRequest; import com.google.cloud.dataplex.v1.DeleteAspectTypeRequest; import com.google.cloud.dataplex.v1.DeleteEntryGroupRequest; +import com.google.cloud.dataplex.v1.DeleteEntryLinkRequest; import com.google.cloud.dataplex.v1.DeleteEntryRequest; import com.google.cloud.dataplex.v1.DeleteEntryTypeRequest; import com.google.cloud.dataplex.v1.Entry; import com.google.cloud.dataplex.v1.EntryGroup; +import com.google.cloud.dataplex.v1.EntryLink; import com.google.cloud.dataplex.v1.EntryType; import com.google.cloud.dataplex.v1.GetAspectTypeRequest; import com.google.cloud.dataplex.v1.GetEntryGroupRequest; +import com.google.cloud.dataplex.v1.GetEntryLinkRequest; import com.google.cloud.dataplex.v1.GetEntryRequest; import com.google.cloud.dataplex.v1.GetEntryTypeRequest; import com.google.cloud.dataplex.v1.GetMetadataJobRequest; @@ -371,6 +375,38 @@ public class GrpcCatalogServiceStub extends CatalogServiceStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + createEntryLinkMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.CatalogService/CreateEntryLink") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateEntryLinkRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(EntryLink.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + deleteEntryLinkMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.CatalogService/DeleteEntryLink") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteEntryLinkRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(EntryLink.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + + private static final MethodDescriptor + getEntryLinkMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dataplex.v1.CatalogService/GetEntryLink") + .setRequestMarshaller(ProtoUtils.marshaller(GetEntryLinkRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(EntryLink.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor listLocationsMethodDescriptor = MethodDescriptor.newBuilder() @@ -453,6 +489,9 @@ public class GrpcCatalogServiceStub extends CatalogServiceStub { private final UnaryCallable listMetadataJobsPagedCallable; private final UnaryCallable cancelMetadataJobCallable; + private final UnaryCallable createEntryLinkCallable; + private final UnaryCallable deleteEntryLinkCallable; + private final UnaryCallable getEntryLinkCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; @@ -768,6 +807,36 @@ protected GrpcCatalogServiceStub( return builder.build(); }) .build(); + GrpcCallSettings createEntryLinkTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createEntryLinkMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + GrpcCallSettings deleteEntryLinkTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteEntryLinkMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + GrpcCallSettings getEntryLinkTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getEntryLinkMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); GrpcCallSettings listLocationsTransportSettings = GrpcCallSettings.newBuilder() .setMethodDescriptor(listLocationsMethodDescriptor) @@ -949,6 +1018,15 @@ protected GrpcCatalogServiceStub( cancelMetadataJobTransportSettings, settings.cancelMetadataJobSettings(), clientContext); + this.createEntryLinkCallable = + callableFactory.createUnaryCallable( + createEntryLinkTransportSettings, settings.createEntryLinkSettings(), clientContext); + this.deleteEntryLinkCallable = + callableFactory.createUnaryCallable( + deleteEntryLinkTransportSettings, settings.deleteEntryLinkSettings(), clientContext); + this.getEntryLinkCallable = + callableFactory.createUnaryCallable( + getEntryLinkTransportSettings, settings.getEntryLinkSettings(), clientContext); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -1193,6 +1271,21 @@ public UnaryCallable cancelMetadataJobCallable( return cancelMetadataJobCallable; } + @Override + public UnaryCallable createEntryLinkCallable() { + return createEntryLinkCallable; + } + + @Override + public UnaryCallable deleteEntryLinkCallable() { + return deleteEntryLinkCallable; + } + + @Override + public UnaryCallable getEntryLinkCallable() { + return getEntryLinkCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonBusinessGlossaryServiceCallableFactory.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonBusinessGlossaryServiceCallableFactory.java new file mode 100644 index 000000000000..d80bde8ed3f6 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonBusinessGlossaryServiceCallableFactory.java @@ -0,0 +1,101 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST callable factory implementation for the BusinessGlossaryService service API. + * + *

        This class is for advanced usage. + */ +@Generated("by gapic-generator-java") +public class HttpJsonBusinessGlossaryServiceCallableFactory + 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-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonBusinessGlossaryServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonBusinessGlossaryServiceStub.java new file mode 100644 index 000000000000..79ae36979614 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonBusinessGlossaryServiceStub.java @@ -0,0 +1,1360 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.stub; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.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.dataplex.v1.CreateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.CreateGlossaryTermRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryRequest; +import com.google.cloud.dataplex.v1.GetGlossaryTermRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.ListGlossariesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; +import com.google.cloud.dataplex.v1.ListGlossaryTermsResponse; +import com.google.cloud.dataplex.v1.OperationMetadata; +import com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest; +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.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * REST stub implementation for the BusinessGlossaryService service API. + * + *

        This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public class HttpJsonBusinessGlossaryServiceStub extends BusinessGlossaryServiceStub { + private static final TypeRegistry typeRegistry = + TypeRegistry.newBuilder() + .add(Empty.getDescriptor()) + .add(Glossary.getDescriptor()) + .add(OperationMetadata.getDescriptor()) + .build(); + + private static final ApiMethodDescriptor + createGlossaryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/CreateGlossary") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/glossaries", + 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, "glossaryId", request.getGlossaryId()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("glossary", request.getGlossary(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (CreateGlossaryRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + updateGlossaryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/UpdateGlossary") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{glossary.name=projects/*/locations/*/glossaries/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "glossary.name", request.getGlossary().getName()); + return fields; + }) + .setQueryParamsExtractor( + request -> { + Map> fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); + serializer.putQueryParam( + fields, "validateOnly", request.getValidateOnly()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("glossary", request.getGlossary(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(Operation.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .setOperationSnapshotFactory( + (UpdateGlossaryRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + deleteGlossaryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/DeleteGlossary") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/glossaries/*}", + 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( + (DeleteGlossaryRequest request, Operation response) -> + HttpJsonOperationSnapshot.create(response)) + .build(); + + private static final ApiMethodDescriptor + getGlossaryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/GetGlossary") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/glossaries/*}", + 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(Glossary.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listGlossariesMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/ListGlossaries") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*}/glossaries", + 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(ListGlossariesResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createGlossaryCategoryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/CreateGlossaryCategory") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/glossaries/*}/categories", + 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, "categoryId", request.getCategoryId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("category", request.getCategory(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(GlossaryCategory.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + updateGlossaryCategoryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/UpdateGlossaryCategory") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{category.name=projects/*/locations/*/glossaries/*/categories/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "category.name", request.getCategory().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("category", request.getCategory(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(GlossaryCategory.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + deleteGlossaryCategoryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/DeleteGlossaryCategory") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/glossaries/*/categories/*}", + 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(Empty.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getGlossaryCategoryMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/GetGlossaryCategory") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/glossaries/*/categories/*}", + 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(GlossaryCategory.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor< + ListGlossaryCategoriesRequest, ListGlossaryCategoriesResponse> + listGlossaryCategoriesMethodDescriptor = + ApiMethodDescriptor + .newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/ListGlossaryCategories") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/glossaries/*}/categories", + 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(ListGlossaryCategoriesResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + createGlossaryTermMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/CreateGlossaryTerm") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/glossaries/*}/terms", + 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, "termId", request.getTermId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create().toBody("term", request.getTerm(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(GlossaryTerm.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + updateGlossaryTermMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/UpdateGlossaryTerm") + .setHttpMethod("PATCH") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{term.name=projects/*/locations/*/glossaries/*/terms/*}", + request -> { + Map fields = new HashMap<>(); + ProtoRestSerializer serializer = + ProtoRestSerializer.create(); + serializer.putPathParam( + fields, "term.name", request.getTerm().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("term", request.getTerm(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(GlossaryTerm.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + deleteGlossaryTermMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/DeleteGlossaryTerm") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/glossaries/*/terms/*}", + 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(Empty.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getGlossaryTermMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.BusinessGlossaryService/GetGlossaryTerm") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/glossaries/*/terms/*}", + 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(GlossaryTerm.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + listGlossaryTermsMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName( + "google.cloud.dataplex.v1.BusinessGlossaryService/ListGlossaryTerms") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/glossaries/*}/terms", + 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(ListGlossaryTermsResponse.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 createGlossaryCallable; + private final OperationCallable + createGlossaryOperationCallable; + private final UnaryCallable updateGlossaryCallable; + private final OperationCallable + updateGlossaryOperationCallable; + private final UnaryCallable deleteGlossaryCallable; + private final OperationCallable + deleteGlossaryOperationCallable; + private final UnaryCallable getGlossaryCallable; + private final UnaryCallable listGlossariesCallable; + private final UnaryCallable + listGlossariesPagedCallable; + private final UnaryCallable + createGlossaryCategoryCallable; + private final UnaryCallable + updateGlossaryCategoryCallable; + private final UnaryCallable deleteGlossaryCategoryCallable; + private final UnaryCallable + getGlossaryCategoryCallable; + private final UnaryCallable + listGlossaryCategoriesCallable; + private final UnaryCallable + listGlossaryCategoriesPagedCallable; + private final UnaryCallable createGlossaryTermCallable; + private final UnaryCallable updateGlossaryTermCallable; + private final UnaryCallable deleteGlossaryTermCallable; + private final UnaryCallable getGlossaryTermCallable; + private final UnaryCallable + listGlossaryTermsCallable; + private final UnaryCallable + listGlossaryTermsPagedCallable; + 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 HttpJsonBusinessGlossaryServiceStub create( + BusinessGlossaryServiceStubSettings settings) throws IOException { + return new HttpJsonBusinessGlossaryServiceStub(settings, ClientContext.create(settings)); + } + + public static final HttpJsonBusinessGlossaryServiceStub create(ClientContext clientContext) + throws IOException { + return new HttpJsonBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings.newHttpJsonBuilder().build(), clientContext); + } + + public static final HttpJsonBusinessGlossaryServiceStub create( + ClientContext clientContext, HttpJsonStubCallableFactory callableFactory) throws IOException { + return new HttpJsonBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings.newHttpJsonBuilder().build(), + clientContext, + callableFactory); + } + + /** + * Constructs an instance of HttpJsonBusinessGlossaryServiceStub, 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 HttpJsonBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new HttpJsonBusinessGlossaryServiceCallableFactory()); + } + + /** + * Constructs an instance of HttpJsonBusinessGlossaryServiceStub, 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 HttpJsonBusinessGlossaryServiceStub( + BusinessGlossaryServiceStubSettings 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") + .addAdditionalBindings( + HttpRule.newBuilder() + .setPost( + "/v1/{name=organizations/*/locations/*/operations/*}:cancel") + .build()) + .build()) + .put( + "google.longrunning.Operations.DeleteOperation", + HttpRule.newBuilder() + .setDelete("/v1/{name=projects/*/locations/*/operations/*}") + .addAdditionalBindings( + HttpRule.newBuilder() + .setDelete("/v1/{name=organizations/*/locations/*/operations/*}") + .build()) + .build()) + .put( + "google.longrunning.Operations.GetOperation", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*/operations/*}") + .addAdditionalBindings( + HttpRule.newBuilder() + .setGet("/v1/{name=organizations/*/locations/*/operations/*}") + .build()) + .build()) + .put( + "google.longrunning.Operations.ListOperations", + HttpRule.newBuilder() + .setGet("/v1/{name=projects/*/locations/*}/operations") + .addAdditionalBindings( + HttpRule.newBuilder() + .setGet("/v1/{name=organizations/*/locations/*}/operations") + .build()) + .build()) + .build()); + + HttpJsonCallSettings createGlossaryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createGlossaryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings updateGlossaryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateGlossaryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("glossary.name", String.valueOf(request.getGlossary().getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings deleteGlossaryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteGlossaryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings getGlossaryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getGlossaryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + listGlossariesTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listGlossariesMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + createGlossaryCategoryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createGlossaryCategoryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + updateGlossaryCategoryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateGlossaryCategoryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("category.name", String.valueOf(request.getCategory().getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + deleteGlossaryCategoryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteGlossaryCategoryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + getGlossaryCategoryTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getGlossaryCategoryMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + listGlossaryCategoriesTransportSettings = + HttpJsonCallSettings + .newBuilder() + .setMethodDescriptor(listGlossaryCategoriesMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + createGlossaryTermTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createGlossaryTermMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + updateGlossaryTermTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(updateGlossaryTermMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("term.name", String.valueOf(request.getTerm().getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings deleteGlossaryTermTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteGlossaryTermMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings getGlossaryTermTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getGlossaryTermMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings + listGlossaryTermsTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(listGlossaryTermsMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .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.createGlossaryCallable = + callableFactory.createUnaryCallable( + createGlossaryTransportSettings, settings.createGlossarySettings(), clientContext); + this.createGlossaryOperationCallable = + callableFactory.createOperationCallable( + createGlossaryTransportSettings, + settings.createGlossaryOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.updateGlossaryCallable = + callableFactory.createUnaryCallable( + updateGlossaryTransportSettings, settings.updateGlossarySettings(), clientContext); + this.updateGlossaryOperationCallable = + callableFactory.createOperationCallable( + updateGlossaryTransportSettings, + settings.updateGlossaryOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.deleteGlossaryCallable = + callableFactory.createUnaryCallable( + deleteGlossaryTransportSettings, settings.deleteGlossarySettings(), clientContext); + this.deleteGlossaryOperationCallable = + callableFactory.createOperationCallable( + deleteGlossaryTransportSettings, + settings.deleteGlossaryOperationSettings(), + clientContext, + httpJsonOperationsStub); + this.getGlossaryCallable = + callableFactory.createUnaryCallable( + getGlossaryTransportSettings, settings.getGlossarySettings(), clientContext); + this.listGlossariesCallable = + callableFactory.createUnaryCallable( + listGlossariesTransportSettings, settings.listGlossariesSettings(), clientContext); + this.listGlossariesPagedCallable = + callableFactory.createPagedCallable( + listGlossariesTransportSettings, settings.listGlossariesSettings(), clientContext); + this.createGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + createGlossaryCategoryTransportSettings, + settings.createGlossaryCategorySettings(), + clientContext); + this.updateGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + updateGlossaryCategoryTransportSettings, + settings.updateGlossaryCategorySettings(), + clientContext); + this.deleteGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + deleteGlossaryCategoryTransportSettings, + settings.deleteGlossaryCategorySettings(), + clientContext); + this.getGlossaryCategoryCallable = + callableFactory.createUnaryCallable( + getGlossaryCategoryTransportSettings, + settings.getGlossaryCategorySettings(), + clientContext); + this.listGlossaryCategoriesCallable = + callableFactory.createUnaryCallable( + listGlossaryCategoriesTransportSettings, + settings.listGlossaryCategoriesSettings(), + clientContext); + this.listGlossaryCategoriesPagedCallable = + callableFactory.createPagedCallable( + listGlossaryCategoriesTransportSettings, + settings.listGlossaryCategoriesSettings(), + clientContext); + this.createGlossaryTermCallable = + callableFactory.createUnaryCallable( + createGlossaryTermTransportSettings, + settings.createGlossaryTermSettings(), + clientContext); + this.updateGlossaryTermCallable = + callableFactory.createUnaryCallable( + updateGlossaryTermTransportSettings, + settings.updateGlossaryTermSettings(), + clientContext); + this.deleteGlossaryTermCallable = + callableFactory.createUnaryCallable( + deleteGlossaryTermTransportSettings, + settings.deleteGlossaryTermSettings(), + clientContext); + this.getGlossaryTermCallable = + callableFactory.createUnaryCallable( + getGlossaryTermTransportSettings, settings.getGlossaryTermSettings(), clientContext); + this.listGlossaryTermsCallable = + callableFactory.createUnaryCallable( + listGlossaryTermsTransportSettings, + settings.listGlossaryTermsSettings(), + clientContext); + this.listGlossaryTermsPagedCallable = + callableFactory.createPagedCallable( + listGlossaryTermsTransportSettings, + settings.listGlossaryTermsSettings(), + 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(createGlossaryMethodDescriptor); + methodDescriptors.add(updateGlossaryMethodDescriptor); + methodDescriptors.add(deleteGlossaryMethodDescriptor); + methodDescriptors.add(getGlossaryMethodDescriptor); + methodDescriptors.add(listGlossariesMethodDescriptor); + methodDescriptors.add(createGlossaryCategoryMethodDescriptor); + methodDescriptors.add(updateGlossaryCategoryMethodDescriptor); + methodDescriptors.add(deleteGlossaryCategoryMethodDescriptor); + methodDescriptors.add(getGlossaryCategoryMethodDescriptor); + methodDescriptors.add(listGlossaryCategoriesMethodDescriptor); + methodDescriptors.add(createGlossaryTermMethodDescriptor); + methodDescriptors.add(updateGlossaryTermMethodDescriptor); + methodDescriptors.add(deleteGlossaryTermMethodDescriptor); + methodDescriptors.add(getGlossaryTermMethodDescriptor); + methodDescriptors.add(listGlossaryTermsMethodDescriptor); + methodDescriptors.add(listLocationsMethodDescriptor); + methodDescriptors.add(getLocationMethodDescriptor); + return methodDescriptors; + } + + public HttpJsonOperationsStub getHttpJsonOperationsStub() { + return httpJsonOperationsStub; + } + + @Override + public UnaryCallable createGlossaryCallable() { + return createGlossaryCallable; + } + + @Override + public OperationCallable + createGlossaryOperationCallable() { + return createGlossaryOperationCallable; + } + + @Override + public UnaryCallable updateGlossaryCallable() { + return updateGlossaryCallable; + } + + @Override + public OperationCallable + updateGlossaryOperationCallable() { + return updateGlossaryOperationCallable; + } + + @Override + public UnaryCallable deleteGlossaryCallable() { + return deleteGlossaryCallable; + } + + @Override + public OperationCallable + deleteGlossaryOperationCallable() { + return deleteGlossaryOperationCallable; + } + + @Override + public UnaryCallable getGlossaryCallable() { + return getGlossaryCallable; + } + + @Override + public UnaryCallable listGlossariesCallable() { + return listGlossariesCallable; + } + + @Override + public UnaryCallable + listGlossariesPagedCallable() { + return listGlossariesPagedCallable; + } + + @Override + public UnaryCallable + createGlossaryCategoryCallable() { + return createGlossaryCategoryCallable; + } + + @Override + public UnaryCallable + updateGlossaryCategoryCallable() { + return updateGlossaryCategoryCallable; + } + + @Override + public UnaryCallable deleteGlossaryCategoryCallable() { + return deleteGlossaryCategoryCallable; + } + + @Override + public UnaryCallable getGlossaryCategoryCallable() { + return getGlossaryCategoryCallable; + } + + @Override + public UnaryCallable + listGlossaryCategoriesCallable() { + return listGlossaryCategoriesCallable; + } + + @Override + public UnaryCallable + listGlossaryCategoriesPagedCallable() { + return listGlossaryCategoriesPagedCallable; + } + + @Override + public UnaryCallable createGlossaryTermCallable() { + return createGlossaryTermCallable; + } + + @Override + public UnaryCallable updateGlossaryTermCallable() { + return updateGlossaryTermCallable; + } + + @Override + public UnaryCallable deleteGlossaryTermCallable() { + return deleteGlossaryTermCallable; + } + + @Override + public UnaryCallable getGlossaryTermCallable() { + return getGlossaryTermCallable; + } + + @Override + public UnaryCallable + listGlossaryTermsCallable() { + return listGlossaryTermsCallable; + } + + @Override + public UnaryCallable + listGlossaryTermsPagedCallable() { + return listGlossaryTermsPagedCallable; + } + + @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-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCatalogServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCatalogServiceStub.java index 75cb62a9c017..98d64aff7419 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCatalogServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCatalogServiceStub.java @@ -44,18 +44,22 @@ import com.google.cloud.dataplex.v1.CancelMetadataJobRequest; import com.google.cloud.dataplex.v1.CreateAspectTypeRequest; import com.google.cloud.dataplex.v1.CreateEntryGroupRequest; +import com.google.cloud.dataplex.v1.CreateEntryLinkRequest; import com.google.cloud.dataplex.v1.CreateEntryRequest; import com.google.cloud.dataplex.v1.CreateEntryTypeRequest; import com.google.cloud.dataplex.v1.CreateMetadataJobRequest; import com.google.cloud.dataplex.v1.DeleteAspectTypeRequest; import com.google.cloud.dataplex.v1.DeleteEntryGroupRequest; +import com.google.cloud.dataplex.v1.DeleteEntryLinkRequest; import com.google.cloud.dataplex.v1.DeleteEntryRequest; import com.google.cloud.dataplex.v1.DeleteEntryTypeRequest; import com.google.cloud.dataplex.v1.Entry; import com.google.cloud.dataplex.v1.EntryGroup; +import com.google.cloud.dataplex.v1.EntryLink; import com.google.cloud.dataplex.v1.EntryType; import com.google.cloud.dataplex.v1.GetAspectTypeRequest; import com.google.cloud.dataplex.v1.GetEntryGroupRequest; +import com.google.cloud.dataplex.v1.GetEntryLinkRequest; import com.google.cloud.dataplex.v1.GetEntryRequest; import com.google.cloud.dataplex.v1.GetEntryTypeRequest; import com.google.cloud.dataplex.v1.GetMetadataJobRequest; @@ -1121,6 +1125,113 @@ public class HttpJsonCatalogServiceStub extends CatalogServiceStub { .build()) .build(); + private static final ApiMethodDescriptor + createEntryLinkMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.CatalogService/CreateEntryLink") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{parent=projects/*/locations/*/entryGroups/*}/entryLinks", + 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, "entryLinkId", request.getEntryLinkId()); + serializer.putQueryParam(fields, "$alt", "json;enum-encoding=int"); + return fields; + }) + .setRequestBodyExtractor( + request -> + ProtoRestSerializer.create() + .toBody("entryLink", request.getEntryLink(), true)) + .build()) + .setResponseParser( + ProtoMessageResponseParser.newBuilder() + .setDefaultInstance(EntryLink.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + deleteEntryLinkMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.CatalogService/DeleteEntryLink") + .setHttpMethod("DELETE") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/entryGroups/*/entryLinks/*}", + 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(EntryLink.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + + private static final ApiMethodDescriptor + getEntryLinkMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.dataplex.v1.CatalogService/GetEntryLink") + .setHttpMethod("GET") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/entryGroups/*/entryLinks/*}", + 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(EntryLink.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + private static final ApiMethodDescriptor listLocationsMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -1250,6 +1361,9 @@ public class HttpJsonCatalogServiceStub extends CatalogServiceStub { private final UnaryCallable listMetadataJobsPagedCallable; private final UnaryCallable cancelMetadataJobCallable; + private final UnaryCallable createEntryLinkCallable; + private final UnaryCallable deleteEntryLinkCallable; + private final UnaryCallable getEntryLinkCallable; private final UnaryCallable listLocationsCallable; private final UnaryCallable listLocationsPagedCallable; @@ -1337,7 +1451,7 @@ protected HttpJsonCatalogServiceStub( .setGet("/v1/{name=projects/*/locations/*}/operations") .addAdditionalBindings( HttpRule.newBuilder() - .setGet("/v1/{name=organizations/*/locations/*/operations/*}") + .setGet("/v1/{name=organizations/*/locations/*}/operations") .build()) .build()) .build()); @@ -1635,6 +1749,39 @@ protected HttpJsonCatalogServiceStub( return builder.build(); }) .build(); + HttpJsonCallSettings createEntryLinkTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(createEntryLinkMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("parent", String.valueOf(request.getParent())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings deleteEntryLinkTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(deleteEntryLinkMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); + HttpJsonCallSettings getEntryLinkTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(getEntryLinkMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); HttpJsonCallSettings listLocationsTransportSettings = HttpJsonCallSettings.newBuilder() @@ -1819,6 +1966,15 @@ protected HttpJsonCatalogServiceStub( cancelMetadataJobTransportSettings, settings.cancelMetadataJobSettings(), clientContext); + this.createEntryLinkCallable = + callableFactory.createUnaryCallable( + createEntryLinkTransportSettings, settings.createEntryLinkSettings(), clientContext); + this.deleteEntryLinkCallable = + callableFactory.createUnaryCallable( + deleteEntryLinkTransportSettings, settings.deleteEntryLinkSettings(), clientContext); + this.getEntryLinkCallable = + callableFactory.createUnaryCallable( + getEntryLinkTransportSettings, settings.getEntryLinkSettings(), clientContext); this.listLocationsCallable = callableFactory.createUnaryCallable( listLocationsTransportSettings, settings.listLocationsSettings(), clientContext); @@ -1862,6 +2018,9 @@ public static List getMethodDescriptors() { methodDescriptors.add(getMetadataJobMethodDescriptor); methodDescriptors.add(listMetadataJobsMethodDescriptor); methodDescriptors.add(cancelMetadataJobMethodDescriptor); + methodDescriptors.add(createEntryLinkMethodDescriptor); + methodDescriptors.add(deleteEntryLinkMethodDescriptor); + methodDescriptors.add(getEntryLinkMethodDescriptor); methodDescriptors.add(listLocationsMethodDescriptor); methodDescriptors.add(getLocationMethodDescriptor); return methodDescriptors; @@ -2097,6 +2256,21 @@ public UnaryCallable cancelMetadataJobCallable( return cancelMetadataJobCallable; } + @Override + public UnaryCallable createEntryLinkCallable() { + return createEntryLinkCallable; + } + + @Override + public UnaryCallable deleteEntryLinkCallable() { + return deleteEntryLinkCallable; + } + + @Override + public UnaryCallable getEntryLinkCallable() { + return getEntryLinkCallable; + } + @Override public UnaryCallable listLocationsCallable() { return listLocationsCallable; diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCmekServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCmekServiceStub.java index dc247767f1f1..368cbc2a9611 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCmekServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonCmekServiceStub.java @@ -447,7 +447,7 @@ protected HttpJsonCmekServiceStub( .setGet("/v1/{name=projects/*/locations/*}/operations") .addAdditionalBindings( HttpRule.newBuilder() - .setGet("/v1/{name=organizations/*/locations/*/operations/*}") + .setGet("/v1/{name=organizations/*/locations/*}/operations") .build()) .build()) .build()); diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataScanServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataScanServiceStub.java index 288319898808..7e64334c6ee1 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataScanServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataScanServiceStub.java @@ -608,7 +608,7 @@ protected HttpJsonDataScanServiceStub( .setGet("/v1/{name=projects/*/locations/*}/operations") .addAdditionalBindings( HttpRule.newBuilder() - .setGet("/v1/{name=organizations/*/locations/*/operations/*}") + .setGet("/v1/{name=organizations/*/locations/*}/operations") .build()) .build()) .build()); diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataTaxonomyServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataTaxonomyServiceStub.java index 42a1d9a7acaf..31ff6aba441e 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataTaxonomyServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataTaxonomyServiceStub.java @@ -912,7 +912,7 @@ protected HttpJsonDataTaxonomyServiceStub( .setGet("/v1/{name=projects/*/locations/*}/operations") .addAdditionalBindings( HttpRule.newBuilder() - .setGet("/v1/{name=organizations/*/locations/*/operations/*}") + .setGet("/v1/{name=organizations/*/locations/*}/operations") .build()) .build()) .build()); diff --git a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataplexServiceStub.java b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataplexServiceStub.java index 64b0f2e4a590..2c3f02a2a722 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataplexServiceStub.java +++ b/java-dataplex/google-cloud-dataplex/src/main/java/com/google/cloud/dataplex/v1/stub/HttpJsonDataplexServiceStub.java @@ -1621,7 +1621,7 @@ protected HttpJsonDataplexServiceStub( .setGet("/v1/{name=projects/*/locations/*}/operations") .addAdditionalBindings( HttpRule.newBuilder() - .setGet("/v1/{name=organizations/*/locations/*/operations/*}") + .setGet("/v1/{name=organizations/*/locations/*}/operations") .build()) .build()) .build()); diff --git a/java-dataplex/google-cloud-dataplex/src/main/resources/META-INF/native-image/com.google.cloud.dataplex.v1/reflect-config.json b/java-dataplex/google-cloud-dataplex/src/main/resources/META-INF/native-image/com.google.cloud.dataplex.v1/reflect-config.json index fc4c087cf43b..c8e6789bc188 100644 --- a/java-dataplex/google-cloud-dataplex/src/main/resources/META-INF/native-image/com.google.cloud.dataplex.v1/reflect-config.json +++ b/java-dataplex/google-cloud-dataplex/src/main/resources/META-INF/native-image/com.google.cloud.dataplex.v1/reflect-config.json @@ -1331,6 +1331,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.CreateEntryLinkRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.CreateEntryLinkRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.CreateEntryRequest", "queryAllDeclaredConstructors": true, @@ -1385,6 +1403,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.CreateGlossaryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.CreateGlossaryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.CreateGlossaryTermRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.CreateGlossaryTermRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.CreateLakeRequest", "queryAllDeclaredConstructors": true, @@ -2528,6 +2600,33 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus$State", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.DataScanEvent", "queryAllDeclaredConstructors": true, @@ -2951,6 +3050,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.DeleteEntryLinkRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DeleteEntryLinkRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.DeleteEntryRequest", "queryAllDeclaredConstructors": true, @@ -3005,6 +3122,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DeleteGlossaryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DeleteGlossaryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.DeleteLakeRequest", "queryAllDeclaredConstructors": true, @@ -3365,6 +3536,51 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.EntryLink", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.EntryLink$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.EntryLink$EntryReference", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.EntryLink$EntryReference$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.EntryLink$EntryReference$Type", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.EntryLinkEvent", "queryAllDeclaredConstructors": true, @@ -3887,6 +4103,24 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.GetEntryLinkRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GetEntryLinkRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.GetEntryRequest", "queryAllDeclaredConstructors": true, @@ -3941,6 +4175,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GetGlossaryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GetGlossaryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GetGlossaryTermRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GetGlossaryTermRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.GetJobRequest", "queryAllDeclaredConstructors": true, @@ -4049,6 +4337,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.Glossary", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.Glossary$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GlossaryCategory", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GlossaryCategory$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GlossaryTerm", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.GlossaryTerm$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.GovernanceEvent", "queryAllDeclaredConstructors": true, @@ -4832,6 +5174,114 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossariesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossariesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossariesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossariesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryTermsRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryTermsRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryTermsResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.ListGlossaryTermsResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.ListJobsRequest", "queryAllDeclaredConstructors": true, @@ -6326,6 +6776,60 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.UpdateGlossaryRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.UpdateGlossaryRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.dataplex.v1.UpdateLakeRequest", "queryAllDeclaredConstructors": true, diff --git a/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClientHttpJsonTest.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClientHttpJsonTest.java new file mode 100644 index 000000000000..71eb279d747d --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClientHttpJsonTest.java @@ -0,0 +1,1692 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.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.dataplex.v1.stub.HttpJsonBusinessGlossaryServiceStub; +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.Empty; +import com.google.protobuf.FieldMask; +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 BusinessGlossaryServiceClientHttpJsonTest { + private static MockHttpService mockService; + private static BusinessGlossaryServiceClient client; + + @BeforeClass + public static void startStaticServer() throws IOException { + mockService = + new MockHttpService( + HttpJsonBusinessGlossaryServiceStub.getMethodDescriptors(), + BusinessGlossaryServiceSettings.getDefaultEndpoint()); + BusinessGlossaryServiceSettings settings = + BusinessGlossaryServiceSettings.newHttpJsonBuilder() + .setTransportChannelProvider( + BusinessGlossaryServiceSettings.defaultHttpJsonTransportProviderBuilder() + .setHttpTransport(mockService) + .build()) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = BusinessGlossaryServiceClient.create(settings); + } + + @AfterClass + public static void stopServer() { + client.close(); + } + + @Before + public void setUp() {} + + @After + public void tearDown() throws Exception { + mockService.reset(); + } + + @Test + public void createGlossaryTest() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + + Glossary actualResponse = client.createGlossaryAsync(parent, glossary, glossaryId).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 createGlossaryExceptionTest() 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]"); + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + client.createGlossaryAsync(parent, glossary, glossaryId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void createGlossaryTest2() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String parent = "projects/project-5833/locations/location-5833"; + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + + Glossary actualResponse = client.createGlossaryAsync(parent, glossary, glossaryId).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 createGlossaryExceptionTest2() 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"; + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + client.createGlossaryAsync(parent, glossary, glossaryId).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void updateGlossaryTest() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + Glossary glossary = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Glossary actualResponse = client.updateGlossaryAsync(glossary, 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 updateGlossaryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + Glossary glossary = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGlossaryAsync(glossary, updateMask).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteGlossaryTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + client.deleteGlossaryAsync(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 deleteGlossaryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.deleteGlossaryAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void deleteGlossaryTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockService.addResponse(resultOperation); + + String name = "projects/project-9868/locations/location-9868/glossaries/glossarie-9868"; + + client.deleteGlossaryAsync(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 deleteGlossaryExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-9868/locations/location-9868/glossaries/glossarie-9868"; + client.deleteGlossaryAsync(name).get(); + Assert.fail("No exception raised"); + } catch (ExecutionException e) { + } + } + + @Test + public void getGlossaryTest() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + mockService.addResponse(expectedResponse); + + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + Glossary actualResponse = client.getGlossary(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 getGlossaryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.getGlossary(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryTest2() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + mockService.addResponse(expectedResponse); + + String name = "projects/project-9868/locations/location-9868/glossaries/glossarie-9868"; + + Glossary actualResponse = client.getGlossary(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 getGlossaryExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = "projects/project-9868/locations/location-9868/glossaries/glossarie-9868"; + client.getGlossary(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossariesTest() throws Exception { + Glossary responsesElement = Glossary.newBuilder().build(); + ListGlossariesResponse expectedResponse = + ListGlossariesResponse.newBuilder() + .setNextPageToken("") + .addAllGlossaries(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListGlossariesPagedResponse pagedListResponse = client.listGlossaries(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getGlossariesList().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 listGlossariesExceptionTest() 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.listGlossaries(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossariesTest2() throws Exception { + Glossary responsesElement = Glossary.newBuilder().build(); + ListGlossariesResponse expectedResponse = + ListGlossariesResponse.newBuilder() + .setNextPageToken("") + .addAllGlossaries(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-5833/locations/location-5833"; + + ListGlossariesPagedResponse pagedListResponse = client.listGlossaries(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getGlossariesList().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 listGlossariesExceptionTest2() 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.listGlossaries(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryCategoryTest() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + + GlossaryCategory actualResponse = client.createGlossaryCategory(parent, category, categoryId); + 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 createGlossaryCategoryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + client.createGlossaryCategory(parent, category, categoryId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryCategoryTest2() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + + GlossaryCategory actualResponse = client.createGlossaryCategory(parent, category, categoryId); + 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 createGlossaryCategoryExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + client.createGlossaryCategory(parent, category, categoryId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGlossaryCategoryTest() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockService.addResponse(expectedResponse); + + GlossaryCategory category = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GlossaryCategory actualResponse = client.updateGlossaryCategory(category, 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 updateGlossaryCategoryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryCategory category = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGlossaryCategory(category, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryCategoryTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockService.addResponse(expectedResponse); + + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + + client.deleteGlossaryCategory(name); + + 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 deleteGlossaryCategoryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + client.deleteGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryCategoryTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-9606/locations/location-9606/glossaries/glossarie-9606/categories/categorie-9606"; + + client.deleteGlossaryCategory(name); + + 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 deleteGlossaryCategoryExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9606/locations/location-9606/glossaries/glossarie-9606/categories/categorie-9606"; + client.deleteGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryCategoryTest() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockService.addResponse(expectedResponse); + + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + + GlossaryCategory actualResponse = client.getGlossaryCategory(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 getGlossaryCategoryExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + client.getGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryCategoryTest2() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-9606/locations/location-9606/glossaries/glossarie-9606/categories/categorie-9606"; + + GlossaryCategory actualResponse = client.getGlossaryCategory(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 getGlossaryCategoryExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9606/locations/location-9606/glossaries/glossarie-9606/categories/categorie-9606"; + client.getGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryCategoriesTest() throws Exception { + GlossaryCategory responsesElement = GlossaryCategory.newBuilder().build(); + ListGlossaryCategoriesResponse expectedResponse = + ListGlossaryCategoriesResponse.newBuilder() + .setNextPageToken("") + .addAllCategories(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + ListGlossaryCategoriesPagedResponse pagedListResponse = client.listGlossaryCategories(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getCategoriesList().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 listGlossaryCategoriesExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.listGlossaryCategories(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryCategoriesTest2() throws Exception { + GlossaryCategory responsesElement = GlossaryCategory.newBuilder().build(); + ListGlossaryCategoriesResponse expectedResponse = + ListGlossaryCategoriesResponse.newBuilder() + .setNextPageToken("") + .addAllCategories(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + + ListGlossaryCategoriesPagedResponse pagedListResponse = client.listGlossaryCategories(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getCategoriesList().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 listGlossaryCategoriesExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + client.listGlossaryCategories(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryTermTest() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + + GlossaryTerm actualResponse = client.createGlossaryTerm(parent, term, termId); + 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 createGlossaryTermExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + client.createGlossaryTerm(parent, term, termId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryTermTest2() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + + GlossaryTerm actualResponse = client.createGlossaryTerm(parent, term, termId); + 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 createGlossaryTermExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + client.createGlossaryTerm(parent, term, termId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGlossaryTermTest() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockService.addResponse(expectedResponse); + + GlossaryTerm term = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GlossaryTerm actualResponse = client.updateGlossaryTerm(term, 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 updateGlossaryTermExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryTerm term = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGlossaryTerm(term, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryTermTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockService.addResponse(expectedResponse); + + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + + client.deleteGlossaryTerm(name); + + 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 deleteGlossaryTermExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + client.deleteGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryTermTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-1743/locations/location-1743/glossaries/glossarie-1743/terms/term-1743"; + + client.deleteGlossaryTerm(name); + + 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 deleteGlossaryTermExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-1743/locations/location-1743/glossaries/glossarie-1743/terms/term-1743"; + client.deleteGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryTermTest() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockService.addResponse(expectedResponse); + + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + + GlossaryTerm actualResponse = client.getGlossaryTerm(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 getGlossaryTermExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + client.getGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryTermTest2() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-1743/locations/location-1743/glossaries/glossarie-1743/terms/term-1743"; + + GlossaryTerm actualResponse = client.getGlossaryTerm(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 getGlossaryTermExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-1743/locations/location-1743/glossaries/glossarie-1743/terms/term-1743"; + client.getGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryTermsTest() throws Exception { + GlossaryTerm responsesElement = GlossaryTerm.newBuilder().build(); + ListGlossaryTermsResponse expectedResponse = + ListGlossaryTermsResponse.newBuilder() + .setNextPageToken("") + .addAllTerms(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + ListGlossaryTermsPagedResponse pagedListResponse = client.listGlossaryTerms(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTermsList().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 listGlossaryTermsExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.listGlossaryTerms(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryTermsTest2() throws Exception { + GlossaryTerm responsesElement = GlossaryTerm.newBuilder().build(); + ListGlossaryTermsResponse expectedResponse = + ListGlossaryTermsResponse.newBuilder() + .setNextPageToken("") + .addAllTerms(Arrays.asList(responsesElement)) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + + ListGlossaryTermsPagedResponse pagedListResponse = client.listGlossaryTerms(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTermsList().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 listGlossaryTermsExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-1837/locations/location-1837/glossaries/glossarie-1837"; + client.listGlossaryTerms(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-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClientTest.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClientTest.java new file mode 100644 index 000000000000..ba08f9184597 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceClientTest.java @@ -0,0 +1,1480 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1; + +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossariesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryCategoriesPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListGlossaryTermsPagedResponse; +import static com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient.ListLocationsPagedResponse; + +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.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Any; +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.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 BusinessGlossaryServiceClientTest { + private static MockBusinessGlossaryService mockBusinessGlossaryService; + private static MockIAMPolicy mockIAMPolicy; + private static MockLocations mockLocations; + private static MockServiceHelper mockServiceHelper; + private LocalChannelProvider channelProvider; + private BusinessGlossaryServiceClient client; + + @BeforeClass + public static void startStaticServer() { + mockBusinessGlossaryService = new MockBusinessGlossaryService(); + mockLocations = new MockLocations(); + mockIAMPolicy = new MockIAMPolicy(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), + Arrays.asList( + mockBusinessGlossaryService, mockLocations, mockIAMPolicy)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + BusinessGlossaryServiceSettings settings = + BusinessGlossaryServiceSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = BusinessGlossaryServiceClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void createGlossaryTest() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockBusinessGlossaryService.addResponse(resultOperation); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + + Glossary actualResponse = client.createGlossaryAsync(parent, glossary, glossaryId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGlossaryRequest actualRequest = ((CreateGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(glossary, actualRequest.getGlossary()); + Assert.assertEquals(glossaryId, actualRequest.getGlossaryId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGlossaryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + client.createGlossaryAsync(parent, glossary, glossaryId).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 createGlossaryTest2() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("createGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockBusinessGlossaryService.addResponse(resultOperation); + + String parent = "parent-995424086"; + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + + Glossary actualResponse = client.createGlossaryAsync(parent, glossary, glossaryId).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGlossaryRequest actualRequest = ((CreateGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(glossary, actualRequest.getGlossary()); + Assert.assertEquals(glossaryId, actualRequest.getGlossaryId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGlossaryExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String parent = "parent-995424086"; + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + client.createGlossaryAsync(parent, glossary, glossaryId).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 updateGlossaryTest() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + Operation resultOperation = + Operation.newBuilder() + .setName("updateGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockBusinessGlossaryService.addResponse(resultOperation); + + Glossary glossary = Glossary.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Glossary actualResponse = client.updateGlossaryAsync(glossary, updateMask).get(); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateGlossaryRequest actualRequest = ((UpdateGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(glossary, actualRequest.getGlossary()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateGlossaryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + Glossary glossary = Glossary.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGlossaryAsync(glossary, 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 deleteGlossaryTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockBusinessGlossaryService.addResponse(resultOperation); + + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + client.deleteGlossaryAsync(name).get(); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGlossaryRequest actualRequest = ((DeleteGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGlossaryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.deleteGlossaryAsync(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 deleteGlossaryTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + Operation resultOperation = + Operation.newBuilder() + .setName("deleteGlossaryTest") + .setDone(true) + .setResponse(Any.pack(expectedResponse)) + .build(); + mockBusinessGlossaryService.addResponse(resultOperation); + + String name = "name3373707"; + + client.deleteGlossaryAsync(name).get(); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGlossaryRequest actualRequest = ((DeleteGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGlossaryExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String name = "name3373707"; + client.deleteGlossaryAsync(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 getGlossaryTest() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + Glossary actualResponse = client.getGlossary(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGlossaryRequest actualRequest = ((GetGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGlossaryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.getGlossary(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryTest2() throws Exception { + Glossary expectedResponse = + Glossary.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setTermCount(-1604847748) + .setCategoryCount(1899510414) + .setEtag("etag3123477") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String name = "name3373707"; + + Glossary actualResponse = client.getGlossary(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGlossaryRequest actualRequest = ((GetGlossaryRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGlossaryExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String name = "name3373707"; + client.getGlossary(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossariesTest() throws Exception { + Glossary responsesElement = Glossary.newBuilder().build(); + ListGlossariesResponse expectedResponse = + ListGlossariesResponse.newBuilder() + .setNextPageToken("") + .addAllGlossaries(Arrays.asList(responsesElement)) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListGlossariesPagedResponse pagedListResponse = client.listGlossaries(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getGlossariesList().get(0), resources.get(0)); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGlossariesRequest actualRequest = ((ListGlossariesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGlossariesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listGlossaries(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossariesTest2() throws Exception { + Glossary responsesElement = Glossary.newBuilder().build(); + ListGlossariesResponse expectedResponse = + ListGlossariesResponse.newBuilder() + .setNextPageToken("") + .addAllGlossaries(Arrays.asList(responsesElement)) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListGlossariesPagedResponse pagedListResponse = client.listGlossaries(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getGlossariesList().get(0), resources.get(0)); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGlossariesRequest actualRequest = ((ListGlossariesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGlossariesExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listGlossaries(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryCategoryTest() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + + GlossaryCategory actualResponse = client.createGlossaryCategory(parent, category, categoryId); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGlossaryCategoryRequest actualRequest = + ((CreateGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(category, actualRequest.getCategory()); + Assert.assertEquals(categoryId, actualRequest.getCategoryId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGlossaryCategoryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + client.createGlossaryCategory(parent, category, categoryId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryCategoryTest2() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + + GlossaryCategory actualResponse = client.createGlossaryCategory(parent, category, categoryId); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGlossaryCategoryRequest actualRequest = + ((CreateGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(category, actualRequest.getCategory()); + Assert.assertEquals(categoryId, actualRequest.getCategoryId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGlossaryCategoryExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String parent = "parent-995424086"; + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + client.createGlossaryCategory(parent, category, categoryId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGlossaryCategoryTest() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GlossaryCategory actualResponse = client.updateGlossaryCategory(category, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateGlossaryCategoryRequest actualRequest = + ((UpdateGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(category, actualRequest.getCategory()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateGlossaryCategoryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGlossaryCategory(category, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryCategoryTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + + client.deleteGlossaryCategory(name); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGlossaryCategoryRequest actualRequest = + ((DeleteGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGlossaryCategoryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + client.deleteGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryCategoryTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String name = "name3373707"; + + client.deleteGlossaryCategory(name); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGlossaryCategoryRequest actualRequest = + ((DeleteGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGlossaryCategoryExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String name = "name3373707"; + client.deleteGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryCategoryTest() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + + GlossaryCategory actualResponse = client.getGlossaryCategory(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGlossaryCategoryRequest actualRequest = ((GetGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGlossaryCategoryExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + client.getGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryCategoryTest2() throws Exception { + GlossaryCategory expectedResponse = + GlossaryCategory.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent("parent-995424086") + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String name = "name3373707"; + + GlossaryCategory actualResponse = client.getGlossaryCategory(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGlossaryCategoryRequest actualRequest = ((GetGlossaryCategoryRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGlossaryCategoryExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String name = "name3373707"; + client.getGlossaryCategory(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryCategoriesTest() throws Exception { + GlossaryCategory responsesElement = GlossaryCategory.newBuilder().build(); + ListGlossaryCategoriesResponse expectedResponse = + ListGlossaryCategoriesResponse.newBuilder() + .setNextPageToken("") + .addAllCategories(Arrays.asList(responsesElement)) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + ListGlossaryCategoriesPagedResponse pagedListResponse = client.listGlossaryCategories(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getCategoriesList().get(0), resources.get(0)); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGlossaryCategoriesRequest actualRequest = + ((ListGlossaryCategoriesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGlossaryCategoriesExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.listGlossaryCategories(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryCategoriesTest2() throws Exception { + GlossaryCategory responsesElement = GlossaryCategory.newBuilder().build(); + ListGlossaryCategoriesResponse expectedResponse = + ListGlossaryCategoriesResponse.newBuilder() + .setNextPageToken("") + .addAllCategories(Arrays.asList(responsesElement)) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListGlossaryCategoriesPagedResponse pagedListResponse = client.listGlossaryCategories(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getCategoriesList().get(0), resources.get(0)); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGlossaryCategoriesRequest actualRequest = + ((ListGlossaryCategoriesRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGlossaryCategoriesExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listGlossaryCategories(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryTermTest() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + + GlossaryTerm actualResponse = client.createGlossaryTerm(parent, term, termId); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGlossaryTermRequest actualRequest = ((CreateGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(term, actualRequest.getTerm()); + Assert.assertEquals(termId, actualRequest.getTermId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGlossaryTermExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + client.createGlossaryTerm(parent, term, termId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createGlossaryTermTest2() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + + GlossaryTerm actualResponse = client.createGlossaryTerm(parent, term, termId); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateGlossaryTermRequest actualRequest = ((CreateGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(term, actualRequest.getTerm()); + Assert.assertEquals(termId, actualRequest.getTermId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createGlossaryTermExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String parent = "parent-995424086"; + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + client.createGlossaryTerm(parent, term, termId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateGlossaryTermTest() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + GlossaryTerm actualResponse = client.updateGlossaryTerm(term, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateGlossaryTermRequest actualRequest = ((UpdateGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(term, actualRequest.getTerm()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateGlossaryTermExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateGlossaryTerm(term, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryTermTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + + client.deleteGlossaryTerm(name); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGlossaryTermRequest actualRequest = ((DeleteGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGlossaryTermExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + client.deleteGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteGlossaryTermTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String name = "name3373707"; + + client.deleteGlossaryTerm(name); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteGlossaryTermRequest actualRequest = ((DeleteGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteGlossaryTermExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String name = "name3373707"; + client.deleteGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryTermTest() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + + GlossaryTerm actualResponse = client.getGlossaryTerm(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGlossaryTermRequest actualRequest = ((GetGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGlossaryTermExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + client.getGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getGlossaryTermTest2() throws Exception { + GlossaryTerm expectedResponse = + GlossaryTerm.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .setUid("uid115792") + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .putAllLabels(new HashMap()) + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String name = "name3373707"; + + GlossaryTerm actualResponse = client.getGlossaryTerm(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetGlossaryTermRequest actualRequest = ((GetGlossaryTermRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getGlossaryTermExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String name = "name3373707"; + client.getGlossaryTerm(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryTermsTest() throws Exception { + GlossaryTerm responsesElement = GlossaryTerm.newBuilder().build(); + ListGlossaryTermsResponse expectedResponse = + ListGlossaryTermsResponse.newBuilder() + .setNextPageToken("") + .addAllTerms(Arrays.asList(responsesElement)) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + + ListGlossaryTermsPagedResponse pagedListResponse = client.listGlossaryTerms(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTermsList().get(0), resources.get(0)); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGlossaryTermsRequest actualRequest = ((ListGlossaryTermsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGlossaryTermsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + client.listGlossaryTerms(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listGlossaryTermsTest2() throws Exception { + GlossaryTerm responsesElement = GlossaryTerm.newBuilder().build(); + ListGlossaryTermsResponse expectedResponse = + ListGlossaryTermsResponse.newBuilder() + .setNextPageToken("") + .addAllTerms(Arrays.asList(responsesElement)) + .build(); + mockBusinessGlossaryService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListGlossaryTermsPagedResponse pagedListResponse = client.listGlossaryTerms(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getTermsList().get(0), resources.get(0)); + + List actualRequests = mockBusinessGlossaryService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListGlossaryTermsRequest actualRequest = ((ListGlossaryTermsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listGlossaryTermsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockBusinessGlossaryService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listGlossaryTerms(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(); + 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. + } + } +} diff --git a/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientHttpJsonTest.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientHttpJsonTest.java index 012f1128d902..eb22eb7702e8 100644 --- a/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientHttpJsonTest.java +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientHttpJsonTest.java @@ -2689,6 +2689,322 @@ public void cancelMetadataJobExceptionTest2() throws Exception { } } + @Test + public void createEntryLinkTest() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + EntryGroupName parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]"); + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + + EntryLink actualResponse = client.createEntryLink(parent, entryLink, entryLinkId); + 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 createEntryLinkExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + EntryGroupName parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]"); + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + client.createEntryLink(parent, entryLink, entryLinkId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createEntryLinkTest2() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + String parent = "projects/project-3515/locations/location-3515/entryGroups/entryGroup-3515"; + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + + EntryLink actualResponse = client.createEntryLink(parent, entryLink, entryLinkId); + 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 createEntryLinkExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String parent = "projects/project-3515/locations/location-3515/entryGroups/entryGroup-3515"; + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + client.createEntryLink(parent, entryLink, entryLinkId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteEntryLinkTest() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + + EntryLink actualResponse = client.deleteEntryLink(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 deleteEntryLinkExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + client.deleteEntryLink(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteEntryLinkTest2() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-9349/locations/location-9349/entryGroups/entryGroup-9349/entryLinks/entryLink-9349"; + + EntryLink actualResponse = client.deleteEntryLink(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 deleteEntryLinkExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9349/locations/location-9349/entryGroups/entryGroup-9349/entryLinks/entryLink-9349"; + client.deleteEntryLink(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getEntryLinkTest() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + + EntryLink actualResponse = client.getEntryLink(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 getEntryLinkExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + client.getEntryLink(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getEntryLinkTest2() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockService.addResponse(expectedResponse); + + String name = + "projects/project-9349/locations/location-9349/entryGroups/entryGroup-9349/entryLinks/entryLink-9349"; + + EntryLink actualResponse = client.getEntryLink(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 getEntryLinkExceptionTest2() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + String name = + "projects/project-9349/locations/location-9349/entryGroups/entryGroup-9349/entryLinks/entryLink-9349"; + client.getEntryLink(name); + 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-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientTest.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientTest.java index 8eaf2e32b596..60ecf16c2dae 100644 --- a/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientTest.java +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/CatalogServiceClientTest.java @@ -2394,6 +2394,286 @@ public void cancelMetadataJobExceptionTest2() throws Exception { } } + @Test + public void createEntryLinkTest() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockCatalogService.addResponse(expectedResponse); + + EntryGroupName parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]"); + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + + EntryLink actualResponse = client.createEntryLink(parent, entryLink, entryLinkId); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockCatalogService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateEntryLinkRequest actualRequest = ((CreateEntryLinkRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(entryLink, actualRequest.getEntryLink()); + Assert.assertEquals(entryLinkId, actualRequest.getEntryLinkId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createEntryLinkExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockCatalogService.addException(exception); + + try { + EntryGroupName parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]"); + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + client.createEntryLink(parent, entryLink, entryLinkId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createEntryLinkTest2() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockCatalogService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + + EntryLink actualResponse = client.createEntryLink(parent, entryLink, entryLinkId); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockCatalogService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateEntryLinkRequest actualRequest = ((CreateEntryLinkRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(entryLink, actualRequest.getEntryLink()); + Assert.assertEquals(entryLinkId, actualRequest.getEntryLinkId()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createEntryLinkExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockCatalogService.addException(exception); + + try { + String parent = "parent-995424086"; + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + client.createEntryLink(parent, entryLink, entryLinkId); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteEntryLinkTest() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockCatalogService.addResponse(expectedResponse); + + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + + EntryLink actualResponse = client.deleteEntryLink(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockCatalogService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteEntryLinkRequest actualRequest = ((DeleteEntryLinkRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteEntryLinkExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockCatalogService.addException(exception); + + try { + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + client.deleteEntryLink(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteEntryLinkTest2() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockCatalogService.addResponse(expectedResponse); + + String name = "name3373707"; + + EntryLink actualResponse = client.deleteEntryLink(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockCatalogService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteEntryLinkRequest actualRequest = ((DeleteEntryLinkRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteEntryLinkExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockCatalogService.addException(exception); + + try { + String name = "name3373707"; + client.deleteEntryLink(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getEntryLinkTest() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockCatalogService.addResponse(expectedResponse); + + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + + EntryLink actualResponse = client.getEntryLink(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockCatalogService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetEntryLinkRequest actualRequest = ((GetEntryLinkRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getEntryLinkExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockCatalogService.addException(exception); + + try { + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + client.getEntryLink(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getEntryLinkTest2() throws Exception { + EntryLink expectedResponse = + EntryLink.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .setEntryLinkType("entryLinkType129827046") + .setCreateTime(Timestamp.newBuilder().build()) + .setUpdateTime(Timestamp.newBuilder().build()) + .addAllEntryReferences(new ArrayList()) + .build(); + mockCatalogService.addResponse(expectedResponse); + + String name = "name3373707"; + + EntryLink actualResponse = client.getEntryLink(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockCatalogService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetEntryLinkRequest actualRequest = ((GetEntryLinkRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getEntryLinkExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockCatalogService.addException(exception); + + try { + String name = "name3373707"; + client.getEntryLink(name); + 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-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockBusinessGlossaryService.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockBusinessGlossaryService.java new file mode 100644 index 000000000000..1b7d40ff8287 --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockBusinessGlossaryService.java @@ -0,0 +1,59 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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 MockBusinessGlossaryService implements MockGrpcService { + private final MockBusinessGlossaryServiceImpl serviceImpl; + + public MockBusinessGlossaryService() { + serviceImpl = new MockBusinessGlossaryServiceImpl(); + } + + @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-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockBusinessGlossaryServiceImpl.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockBusinessGlossaryServiceImpl.java new file mode 100644 index 000000000000..47ed87a08eeb --- /dev/null +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockBusinessGlossaryServiceImpl.java @@ -0,0 +1,382 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1; + +import com.google.api.core.BetaApi; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceGrpc.BusinessGlossaryServiceImplBase; +import com.google.longrunning.Operation; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Empty; +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 MockBusinessGlossaryServiceImpl extends BusinessGlossaryServiceImplBase { + private List requests; + private Queue responses; + + public MockBusinessGlossaryServiceImpl() { + 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 createGlossary( + CreateGlossaryRequest 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 CreateGlossary, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateGlossary( + UpdateGlossaryRequest 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 UpdateGlossary, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteGlossary( + DeleteGlossaryRequest 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 DeleteGlossary, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Operation.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getGlossary(GetGlossaryRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Glossary) { + requests.add(request); + responseObserver.onNext(((Glossary) 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 GetGlossary, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Glossary.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listGlossaries( + ListGlossariesRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListGlossariesResponse) { + requests.add(request); + responseObserver.onNext(((ListGlossariesResponse) 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 ListGlossaries, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListGlossariesResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createGlossaryCategory( + CreateGlossaryCategoryRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GlossaryCategory) { + requests.add(request); + responseObserver.onNext(((GlossaryCategory) 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 CreateGlossaryCategory, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + GlossaryCategory.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateGlossaryCategory( + UpdateGlossaryCategoryRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GlossaryCategory) { + requests.add(request); + responseObserver.onNext(((GlossaryCategory) 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 UpdateGlossaryCategory, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + GlossaryCategory.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteGlossaryCategory( + DeleteGlossaryCategoryRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Empty) { + requests.add(request); + responseObserver.onNext(((Empty) 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 DeleteGlossaryCategory, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + Empty.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getGlossaryCategory( + GetGlossaryCategoryRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GlossaryCategory) { + requests.add(request); + responseObserver.onNext(((GlossaryCategory) 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 GetGlossaryCategory, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + GlossaryCategory.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listGlossaryCategories( + ListGlossaryCategoriesRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListGlossaryCategoriesResponse) { + requests.add(request); + responseObserver.onNext(((ListGlossaryCategoriesResponse) 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 ListGlossaryCategories, expected %s or" + + " %s", + response == null ? "null" : response.getClass().getName(), + ListGlossaryCategoriesResponse.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void createGlossaryTerm( + CreateGlossaryTermRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GlossaryTerm) { + requests.add(request); + responseObserver.onNext(((GlossaryTerm) 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 CreateGlossaryTerm, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + GlossaryTerm.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void updateGlossaryTerm( + UpdateGlossaryTermRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GlossaryTerm) { + requests.add(request); + responseObserver.onNext(((GlossaryTerm) 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 UpdateGlossaryTerm, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + GlossaryTerm.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteGlossaryTerm( + DeleteGlossaryTermRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof Empty) { + requests.add(request); + responseObserver.onNext(((Empty) 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 DeleteGlossaryTerm, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + Empty.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getGlossaryTerm( + GetGlossaryTermRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof GlossaryTerm) { + requests.add(request); + responseObserver.onNext(((GlossaryTerm) 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 GetGlossaryTerm, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + GlossaryTerm.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void listGlossaryTerms( + ListGlossaryTermsRequest request, + StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof ListGlossaryTermsResponse) { + requests.add(request); + responseObserver.onNext(((ListGlossaryTermsResponse) 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 ListGlossaryTerms, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + ListGlossaryTermsResponse.class.getName(), + Exception.class.getName()))); + } + } +} diff --git a/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockCatalogServiceImpl.java b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockCatalogServiceImpl.java index 90384f619a5f..34b7417effaa 100644 --- a/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockCatalogServiceImpl.java +++ b/java-dataplex/google-cloud-dataplex/src/test/java/com/google/cloud/dataplex/v1/MockCatalogServiceImpl.java @@ -600,4 +600,67 @@ public void cancelMetadataJob( Exception.class.getName()))); } } + + @Override + public void createEntryLink( + CreateEntryLinkRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof EntryLink) { + requests.add(request); + responseObserver.onNext(((EntryLink) 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 CreateEntryLink, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + EntryLink.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void deleteEntryLink( + DeleteEntryLinkRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof EntryLink) { + requests.add(request); + responseObserver.onNext(((EntryLink) 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 DeleteEntryLink, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + EntryLink.class.getName(), + Exception.class.getName()))); + } + } + + @Override + public void getEntryLink( + GetEntryLinkRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof EntryLink) { + requests.add(request); + responseObserver.onNext(((EntryLink) 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 GetEntryLink, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + EntryLink.class.getName(), + Exception.class.getName()))); + } + } } diff --git a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceGrpc.java b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceGrpc.java new file mode 100644 index 000000000000..716b62455495 --- /dev/null +++ b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryServiceGrpc.java @@ -0,0 +1,2333 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.dataplex.v1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; + +/** + * + * + *
        + * BusinessGlossaryService provides APIs for managing business glossary
        + * resources for enterprise customers.
        + * The resources currently supported in Business Glossary are:
        + * 1. Glossary
        + * 2. GlossaryCategory
        + * 3. GlossaryTerm
        + * 
        + */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/cloud/dataplex/v1/business_glossary.proto") +@io.grpc.stub.annotations.GrpcGenerated +public final class BusinessGlossaryServiceGrpc { + + private BusinessGlossaryServiceGrpc() {} + + public static final java.lang.String SERVICE_NAME = + "google.cloud.dataplex.v1.BusinessGlossaryService"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryRequest, com.google.longrunning.Operation> + getCreateGlossaryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateGlossary", + requestType = com.google.cloud.dataplex.v1.CreateGlossaryRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryRequest, com.google.longrunning.Operation> + getCreateGlossaryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryRequest, com.google.longrunning.Operation> + getCreateGlossaryMethod; + if ((getCreateGlossaryMethod = BusinessGlossaryServiceGrpc.getCreateGlossaryMethod) == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getCreateGlossaryMethod = BusinessGlossaryServiceGrpc.getCreateGlossaryMethod) + == null) { + BusinessGlossaryServiceGrpc.getCreateGlossaryMethod = + getCreateGlossaryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateGlossary")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.CreateGlossaryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("CreateGlossary")) + .build(); + } + } + } + return getCreateGlossaryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryRequest, com.google.longrunning.Operation> + getUpdateGlossaryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateGlossary", + requestType = com.google.cloud.dataplex.v1.UpdateGlossaryRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryRequest, com.google.longrunning.Operation> + getUpdateGlossaryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryRequest, com.google.longrunning.Operation> + getUpdateGlossaryMethod; + if ((getUpdateGlossaryMethod = BusinessGlossaryServiceGrpc.getUpdateGlossaryMethod) == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getUpdateGlossaryMethod = BusinessGlossaryServiceGrpc.getUpdateGlossaryMethod) + == null) { + BusinessGlossaryServiceGrpc.getUpdateGlossaryMethod = + getUpdateGlossaryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateGlossary")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("UpdateGlossary")) + .build(); + } + } + } + return getUpdateGlossaryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryRequest, com.google.longrunning.Operation> + getDeleteGlossaryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteGlossary", + requestType = com.google.cloud.dataplex.v1.DeleteGlossaryRequest.class, + responseType = com.google.longrunning.Operation.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryRequest, com.google.longrunning.Operation> + getDeleteGlossaryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryRequest, com.google.longrunning.Operation> + getDeleteGlossaryMethod; + if ((getDeleteGlossaryMethod = BusinessGlossaryServiceGrpc.getDeleteGlossaryMethod) == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getDeleteGlossaryMethod = BusinessGlossaryServiceGrpc.getDeleteGlossaryMethod) + == null) { + BusinessGlossaryServiceGrpc.getDeleteGlossaryMethod = + getDeleteGlossaryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteGlossary")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.longrunning.Operation.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("DeleteGlossary")) + .build(); + } + } + } + return getDeleteGlossaryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryRequest, com.google.cloud.dataplex.v1.Glossary> + getGetGlossaryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetGlossary", + requestType = com.google.cloud.dataplex.v1.GetGlossaryRequest.class, + responseType = com.google.cloud.dataplex.v1.Glossary.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryRequest, com.google.cloud.dataplex.v1.Glossary> + getGetGlossaryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryRequest, com.google.cloud.dataplex.v1.Glossary> + getGetGlossaryMethod; + if ((getGetGlossaryMethod = BusinessGlossaryServiceGrpc.getGetGlossaryMethod) == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getGetGlossaryMethod = BusinessGlossaryServiceGrpc.getGetGlossaryMethod) == null) { + BusinessGlossaryServiceGrpc.getGetGlossaryMethod = + getGetGlossaryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetGlossary")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GetGlossaryRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.Glossary.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("GetGlossary")) + .build(); + } + } + } + return getGetGlossaryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossariesRequest, + com.google.cloud.dataplex.v1.ListGlossariesResponse> + getListGlossariesMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListGlossaries", + requestType = com.google.cloud.dataplex.v1.ListGlossariesRequest.class, + responseType = com.google.cloud.dataplex.v1.ListGlossariesResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossariesRequest, + com.google.cloud.dataplex.v1.ListGlossariesResponse> + getListGlossariesMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossariesRequest, + com.google.cloud.dataplex.v1.ListGlossariesResponse> + getListGlossariesMethod; + if ((getListGlossariesMethod = BusinessGlossaryServiceGrpc.getListGlossariesMethod) == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getListGlossariesMethod = BusinessGlossaryServiceGrpc.getListGlossariesMethod) + == null) { + BusinessGlossaryServiceGrpc.getListGlossariesMethod = + getListGlossariesMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListGlossaries")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.ListGlossariesRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.ListGlossariesResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("ListGlossaries")) + .build(); + } + } + } + return getListGlossariesMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getCreateGlossaryCategoryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateGlossaryCategory", + requestType = com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.class, + responseType = com.google.cloud.dataplex.v1.GlossaryCategory.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getCreateGlossaryCategoryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getCreateGlossaryCategoryMethod; + if ((getCreateGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getCreateGlossaryCategoryMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getCreateGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getCreateGlossaryCategoryMethod) + == null) { + BusinessGlossaryServiceGrpc.getCreateGlossaryCategoryMethod = + getCreateGlossaryCategoryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateGlossaryCategory")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier( + "CreateGlossaryCategory")) + .build(); + } + } + } + return getCreateGlossaryCategoryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getUpdateGlossaryCategoryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateGlossaryCategory", + requestType = com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.class, + responseType = com.google.cloud.dataplex.v1.GlossaryCategory.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getUpdateGlossaryCategoryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getUpdateGlossaryCategoryMethod; + if ((getUpdateGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getUpdateGlossaryCategoryMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getUpdateGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getUpdateGlossaryCategoryMethod) + == null) { + BusinessGlossaryServiceGrpc.getUpdateGlossaryCategoryMethod = + getUpdateGlossaryCategoryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateGlossaryCategory")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier( + "UpdateGlossaryCategory")) + .build(); + } + } + } + return getUpdateGlossaryCategoryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest, com.google.protobuf.Empty> + getDeleteGlossaryCategoryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteGlossaryCategory", + requestType = com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.class, + responseType = com.google.protobuf.Empty.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest, com.google.protobuf.Empty> + getDeleteGlossaryCategoryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest, com.google.protobuf.Empty> + getDeleteGlossaryCategoryMethod; + if ((getDeleteGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getDeleteGlossaryCategoryMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getDeleteGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getDeleteGlossaryCategoryMethod) + == null) { + BusinessGlossaryServiceGrpc.getDeleteGlossaryCategoryMethod = + getDeleteGlossaryCategoryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteGlossaryCategory")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.protobuf.Empty.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier( + "DeleteGlossaryCategory")) + .build(); + } + } + } + return getDeleteGlossaryCategoryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getGetGlossaryCategoryMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetGlossaryCategory", + requestType = com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.class, + responseType = com.google.cloud.dataplex.v1.GlossaryCategory.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getGetGlossaryCategoryMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory> + getGetGlossaryCategoryMethod; + if ((getGetGlossaryCategoryMethod = BusinessGlossaryServiceGrpc.getGetGlossaryCategoryMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getGetGlossaryCategoryMethod = + BusinessGlossaryServiceGrpc.getGetGlossaryCategoryMethod) + == null) { + BusinessGlossaryServiceGrpc.getGetGlossaryCategoryMethod = + getGetGlossaryCategoryMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetGlossaryCategory")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier( + "GetGlossaryCategory")) + .build(); + } + } + } + return getGetGlossaryCategoryMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse> + getListGlossaryCategoriesMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListGlossaryCategories", + requestType = com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.class, + responseType = com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse> + getListGlossaryCategoriesMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse> + getListGlossaryCategoriesMethod; + if ((getListGlossaryCategoriesMethod = + BusinessGlossaryServiceGrpc.getListGlossaryCategoriesMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getListGlossaryCategoriesMethod = + BusinessGlossaryServiceGrpc.getListGlossaryCategoriesMethod) + == null) { + BusinessGlossaryServiceGrpc.getListGlossaryCategoriesMethod = + getListGlossaryCategoriesMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListGlossaryCategories")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier( + "ListGlossaryCategories")) + .build(); + } + } + } + return getListGlossaryCategoriesMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getCreateGlossaryTermMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateGlossaryTerm", + requestType = com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.class, + responseType = com.google.cloud.dataplex.v1.GlossaryTerm.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getCreateGlossaryTermMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getCreateGlossaryTermMethod; + if ((getCreateGlossaryTermMethod = BusinessGlossaryServiceGrpc.getCreateGlossaryTermMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getCreateGlossaryTermMethod = BusinessGlossaryServiceGrpc.getCreateGlossaryTermMethod) + == null) { + BusinessGlossaryServiceGrpc.getCreateGlossaryTermMethod = + getCreateGlossaryTermMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateGlossaryTerm")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("CreateGlossaryTerm")) + .build(); + } + } + } + return getCreateGlossaryTermMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getUpdateGlossaryTermMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateGlossaryTerm", + requestType = com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.class, + responseType = com.google.cloud.dataplex.v1.GlossaryTerm.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getUpdateGlossaryTermMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getUpdateGlossaryTermMethod; + if ((getUpdateGlossaryTermMethod = BusinessGlossaryServiceGrpc.getUpdateGlossaryTermMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getUpdateGlossaryTermMethod = BusinessGlossaryServiceGrpc.getUpdateGlossaryTermMethod) + == null) { + BusinessGlossaryServiceGrpc.getUpdateGlossaryTermMethod = + getUpdateGlossaryTermMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateGlossaryTerm")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("UpdateGlossaryTerm")) + .build(); + } + } + } + return getUpdateGlossaryTermMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest, com.google.protobuf.Empty> + getDeleteGlossaryTermMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteGlossaryTerm", + requestType = com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.class, + responseType = com.google.protobuf.Empty.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest, com.google.protobuf.Empty> + getDeleteGlossaryTermMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest, com.google.protobuf.Empty> + getDeleteGlossaryTermMethod; + if ((getDeleteGlossaryTermMethod = BusinessGlossaryServiceGrpc.getDeleteGlossaryTermMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getDeleteGlossaryTermMethod = BusinessGlossaryServiceGrpc.getDeleteGlossaryTermMethod) + == null) { + BusinessGlossaryServiceGrpc.getDeleteGlossaryTermMethod = + getDeleteGlossaryTermMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteGlossaryTerm")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.protobuf.Empty.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("DeleteGlossaryTerm")) + .build(); + } + } + } + return getDeleteGlossaryTermMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getGetGlossaryTermMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetGlossaryTerm", + requestType = com.google.cloud.dataplex.v1.GetGlossaryTermRequest.class, + responseType = com.google.cloud.dataplex.v1.GlossaryTerm.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getGetGlossaryTermMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm> + getGetGlossaryTermMethod; + if ((getGetGlossaryTermMethod = BusinessGlossaryServiceGrpc.getGetGlossaryTermMethod) == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getGetGlossaryTermMethod = BusinessGlossaryServiceGrpc.getGetGlossaryTermMethod) + == null) { + BusinessGlossaryServiceGrpc.getGetGlossaryTermMethod = + getGetGlossaryTermMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetGlossaryTerm")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("GetGlossaryTerm")) + .build(); + } + } + } + return getGetGlossaryTermMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest, + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse> + getListGlossaryTermsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListGlossaryTerms", + requestType = com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.class, + responseType = com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest, + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse> + getListGlossaryTermsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest, + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse> + getListGlossaryTermsMethod; + if ((getListGlossaryTermsMethod = BusinessGlossaryServiceGrpc.getListGlossaryTermsMethod) + == null) { + synchronized (BusinessGlossaryServiceGrpc.class) { + if ((getListGlossaryTermsMethod = BusinessGlossaryServiceGrpc.getListGlossaryTermsMethod) + == null) { + BusinessGlossaryServiceGrpc.getListGlossaryTermsMethod = + getListGlossaryTermsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListGlossaryTerms")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new BusinessGlossaryServiceMethodDescriptorSupplier("ListGlossaryTerms")) + .build(); + } + } + } + return getListGlossaryTermsMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static BusinessGlossaryServiceStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public BusinessGlossaryServiceStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceStub(channel, callOptions); + } + }; + return BusinessGlossaryServiceStub.newStub(factory, channel); + } + + /** Creates a new blocking-style stub that supports all types of calls on the service */ + public static BusinessGlossaryServiceBlockingV2Stub newBlockingV2Stub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public BusinessGlossaryServiceBlockingV2Stub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceBlockingV2Stub(channel, callOptions); + } + }; + return BusinessGlossaryServiceBlockingV2Stub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static BusinessGlossaryServiceBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public BusinessGlossaryServiceBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceBlockingStub(channel, callOptions); + } + }; + return BusinessGlossaryServiceBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static BusinessGlossaryServiceFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public BusinessGlossaryServiceFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceFutureStub(channel, callOptions); + } + }; + return BusinessGlossaryServiceFutureStub.newStub(factory, channel); + } + + /** + * + * + *
        +   * BusinessGlossaryService provides APIs for managing business glossary
        +   * resources for enterprise customers.
        +   * The resources currently supported in Business Glossary are:
        +   * 1. Glossary
        +   * 2. GlossaryCategory
        +   * 3. GlossaryTerm
        +   * 
        + */ + public interface AsyncService { + + /** + * + * + *
        +     * Creates a new Glossary resource.
        +     * 
        + */ + default void createGlossary( + com.google.cloud.dataplex.v1.CreateGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateGlossaryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Updates a Glossary resource.
        +     * 
        + */ + default void updateGlossary( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateGlossaryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Deletes a Glossary resource. All the categories and terms within the
        +     * Glossary must be deleted before the Glossary can be deleted.
        +     * 
        + */ + default void deleteGlossary( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteGlossaryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Gets a Glossary resource.
        +     * 
        + */ + default void getGlossary( + com.google.cloud.dataplex.v1.GetGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetGlossaryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Lists Glossary resources in a project and location.
        +     * 
        + */ + default void listGlossaries( + com.google.cloud.dataplex.v1.ListGlossariesRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListGlossariesMethod(), responseObserver); + } + + /** + * + * + *
        +     * Creates a new GlossaryCategory resource.
        +     * 
        + */ + default void createGlossaryCategory( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateGlossaryCategoryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Updates a GlossaryCategory resource.
        +     * 
        + */ + default void updateGlossaryCategory( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateGlossaryCategoryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Deletes a GlossaryCategory resource. All the GlossaryCategories and
        +     * GlossaryTerms nested directly under the specified GlossaryCategory will be
        +     * moved one level up to the parent in the hierarchy.
        +     * 
        + */ + default void deleteGlossaryCategory( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteGlossaryCategoryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Gets a GlossaryCategory resource.
        +     * 
        + */ + default void getGlossaryCategory( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetGlossaryCategoryMethod(), responseObserver); + } + + /** + * + * + *
        +     * Lists GlossaryCategory resources in a Glossary.
        +     * 
        + */ + default void listGlossaryCategories( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListGlossaryCategoriesMethod(), responseObserver); + } + + /** + * + * + *
        +     * Creates a new GlossaryTerm resource.
        +     * 
        + */ + default void createGlossaryTerm( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateGlossaryTermMethod(), responseObserver); + } + + /** + * + * + *
        +     * Updates a GlossaryTerm resource.
        +     * 
        + */ + default void updateGlossaryTerm( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getUpdateGlossaryTermMethod(), responseObserver); + } + + /** + * + * + *
        +     * Deletes a GlossaryTerm resource.
        +     * 
        + */ + default void deleteGlossaryTerm( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteGlossaryTermMethod(), responseObserver); + } + + /** + * + * + *
        +     * Gets a GlossaryTerm resource.
        +     * 
        + */ + default void getGlossaryTerm( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetGlossaryTermMethod(), responseObserver); + } + + /** + * + * + *
        +     * Lists GlossaryTerm resources in a Glossary.
        +     * 
        + */ + default void listGlossaryTerms( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getListGlossaryTermsMethod(), responseObserver); + } + } + + /** + * Base class for the server implementation of the service BusinessGlossaryService. + * + *
        +   * BusinessGlossaryService provides APIs for managing business glossary
        +   * resources for enterprise customers.
        +   * The resources currently supported in Business Glossary are:
        +   * 1. Glossary
        +   * 2. GlossaryCategory
        +   * 3. GlossaryTerm
        +   * 
        + */ + public abstract static class BusinessGlossaryServiceImplBase + implements io.grpc.BindableService, AsyncService { + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return BusinessGlossaryServiceGrpc.bindService(this); + } + } + + /** + * A stub to allow clients to do asynchronous rpc calls to service BusinessGlossaryService. + * + *
        +   * BusinessGlossaryService provides APIs for managing business glossary
        +   * resources for enterprise customers.
        +   * The resources currently supported in Business Glossary are:
        +   * 1. Glossary
        +   * 2. GlossaryCategory
        +   * 3. GlossaryTerm
        +   * 
        + */ + public static final class BusinessGlossaryServiceStub + extends io.grpc.stub.AbstractAsyncStub { + private BusinessGlossaryServiceStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected BusinessGlossaryServiceStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceStub(channel, callOptions); + } + + /** + * + * + *
        +     * Creates a new Glossary resource.
        +     * 
        + */ + public void createGlossary( + com.google.cloud.dataplex.v1.CreateGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateGlossaryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Updates a Glossary resource.
        +     * 
        + */ + public void updateGlossary( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateGlossaryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Deletes a Glossary resource. All the categories and terms within the
        +     * Glossary must be deleted before the Glossary can be deleted.
        +     * 
        + */ + public void deleteGlossary( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteGlossaryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Gets a Glossary resource.
        +     * 
        + */ + public void getGlossary( + com.google.cloud.dataplex.v1.GetGlossaryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetGlossaryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Lists Glossary resources in a project and location.
        +     * 
        + */ + public void listGlossaries( + com.google.cloud.dataplex.v1.ListGlossariesRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListGlossariesMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Creates a new GlossaryCategory resource.
        +     * 
        + */ + public void createGlossaryCategory( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateGlossaryCategoryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Updates a GlossaryCategory resource.
        +     * 
        + */ + public void updateGlossaryCategory( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateGlossaryCategoryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Deletes a GlossaryCategory resource. All the GlossaryCategories and
        +     * GlossaryTerms nested directly under the specified GlossaryCategory will be
        +     * moved one level up to the parent in the hierarchy.
        +     * 
        + */ + public void deleteGlossaryCategory( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteGlossaryCategoryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Gets a GlossaryCategory resource.
        +     * 
        + */ + public void getGlossaryCategory( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetGlossaryCategoryMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Lists GlossaryCategory resources in a Glossary.
        +     * 
        + */ + public void listGlossaryCategories( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListGlossaryCategoriesMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Creates a new GlossaryTerm resource.
        +     * 
        + */ + public void createGlossaryTerm( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateGlossaryTermMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Updates a GlossaryTerm resource.
        +     * 
        + */ + public void updateGlossaryTerm( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getUpdateGlossaryTermMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Deletes a GlossaryTerm resource.
        +     * 
        + */ + public void deleteGlossaryTerm( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteGlossaryTermMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Gets a GlossaryTerm resource.
        +     * 
        + */ + public void getGlossaryTerm( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetGlossaryTermMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Lists GlossaryTerm resources in a Glossary.
        +     * 
        + */ + public void listGlossaryTerms( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getListGlossaryTermsMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * A stub to allow clients to do synchronous rpc calls to service BusinessGlossaryService. + * + *
        +   * BusinessGlossaryService provides APIs for managing business glossary
        +   * resources for enterprise customers.
        +   * The resources currently supported in Business Glossary are:
        +   * 1. Glossary
        +   * 2. GlossaryCategory
        +   * 3. GlossaryTerm
        +   * 
        + */ + public static final class BusinessGlossaryServiceBlockingV2Stub + extends io.grpc.stub.AbstractBlockingStub { + private BusinessGlossaryServiceBlockingV2Stub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected BusinessGlossaryServiceBlockingV2Stub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceBlockingV2Stub(channel, callOptions); + } + + /** + * + * + *
        +     * Creates a new Glossary resource.
        +     * 
        + */ + public com.google.longrunning.Operation createGlossary( + com.google.cloud.dataplex.v1.CreateGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Updates a Glossary resource.
        +     * 
        + */ + public com.google.longrunning.Operation updateGlossary( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes a Glossary resource. All the categories and terms within the
        +     * Glossary must be deleted before the Glossary can be deleted.
        +     * 
        + */ + public com.google.longrunning.Operation deleteGlossary( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets a Glossary resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.Glossary getGlossary( + com.google.cloud.dataplex.v1.GetGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Lists Glossary resources in a project and location.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.ListGlossariesResponse listGlossaries( + com.google.cloud.dataplex.v1.ListGlossariesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGlossariesMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Creates a new GlossaryCategory resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryCategory createGlossaryCategory( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Updates a GlossaryCategory resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryCategory updateGlossaryCategory( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes a GlossaryCategory resource. All the GlossaryCategories and
        +     * GlossaryTerms nested directly under the specified GlossaryCategory will be
        +     * moved one level up to the parent in the hierarchy.
        +     * 
        + */ + public com.google.protobuf.Empty deleteGlossaryCategory( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets a GlossaryCategory resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryCategory getGlossaryCategory( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Lists GlossaryCategory resources in a Glossary.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse listGlossaryCategories( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGlossaryCategoriesMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Creates a new GlossaryTerm resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryTerm createGlossaryTerm( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Updates a GlossaryTerm resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryTerm updateGlossaryTerm( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes a GlossaryTerm resource.
        +     * 
        + */ + public com.google.protobuf.Empty deleteGlossaryTerm( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets a GlossaryTerm resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryTerm getGlossaryTerm( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Lists GlossaryTerm resources in a Glossary.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.ListGlossaryTermsResponse listGlossaryTerms( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGlossaryTermsMethod(), getCallOptions(), request); + } + } + + /** + * A stub to allow clients to do limited synchronous rpc calls to service BusinessGlossaryService. + * + *
        +   * BusinessGlossaryService provides APIs for managing business glossary
        +   * resources for enterprise customers.
        +   * The resources currently supported in Business Glossary are:
        +   * 1. Glossary
        +   * 2. GlossaryCategory
        +   * 3. GlossaryTerm
        +   * 
        + */ + public static final class BusinessGlossaryServiceBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private BusinessGlossaryServiceBlockingStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected BusinessGlossaryServiceBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceBlockingStub(channel, callOptions); + } + + /** + * + * + *
        +     * Creates a new Glossary resource.
        +     * 
        + */ + public com.google.longrunning.Operation createGlossary( + com.google.cloud.dataplex.v1.CreateGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Updates a Glossary resource.
        +     * 
        + */ + public com.google.longrunning.Operation updateGlossary( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes a Glossary resource. All the categories and terms within the
        +     * Glossary must be deleted before the Glossary can be deleted.
        +     * 
        + */ + public com.google.longrunning.Operation deleteGlossary( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets a Glossary resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.Glossary getGlossary( + com.google.cloud.dataplex.v1.GetGlossaryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGlossaryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Lists Glossary resources in a project and location.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.ListGlossariesResponse listGlossaries( + com.google.cloud.dataplex.v1.ListGlossariesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGlossariesMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Creates a new GlossaryCategory resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryCategory createGlossaryCategory( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Updates a GlossaryCategory resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryCategory updateGlossaryCategory( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes a GlossaryCategory resource. All the GlossaryCategories and
        +     * GlossaryTerms nested directly under the specified GlossaryCategory will be
        +     * moved one level up to the parent in the hierarchy.
        +     * 
        + */ + public com.google.protobuf.Empty deleteGlossaryCategory( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets a GlossaryCategory resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryCategory getGlossaryCategory( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGlossaryCategoryMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Lists GlossaryCategory resources in a Glossary.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse listGlossaryCategories( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGlossaryCategoriesMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Creates a new GlossaryTerm resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryTerm createGlossaryTerm( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Updates a GlossaryTerm resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryTerm updateGlossaryTerm( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getUpdateGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes a GlossaryTerm resource.
        +     * 
        + */ + public com.google.protobuf.Empty deleteGlossaryTerm( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets a GlossaryTerm resource.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.GlossaryTerm getGlossaryTerm( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetGlossaryTermMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Lists GlossaryTerm resources in a Glossary.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.ListGlossaryTermsResponse listGlossaryTerms( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getListGlossaryTermsMethod(), getCallOptions(), request); + } + } + + /** + * A stub to allow clients to do ListenableFuture-style rpc calls to service + * BusinessGlossaryService. + * + *
        +   * BusinessGlossaryService provides APIs for managing business glossary
        +   * resources for enterprise customers.
        +   * The resources currently supported in Business Glossary are:
        +   * 1. Glossary
        +   * 2. GlossaryCategory
        +   * 3. GlossaryTerm
        +   * 
        + */ + public static final class BusinessGlossaryServiceFutureStub + extends io.grpc.stub.AbstractFutureStub { + private BusinessGlossaryServiceFutureStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected BusinessGlossaryServiceFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new BusinessGlossaryServiceFutureStub(channel, callOptions); + } + + /** + * + * + *
        +     * Creates a new Glossary resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture + createGlossary(com.google.cloud.dataplex.v1.CreateGlossaryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateGlossaryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Updates a Glossary resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture + updateGlossary(com.google.cloud.dataplex.v1.UpdateGlossaryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateGlossaryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Deletes a Glossary resource. All the categories and terms within the
        +     * Glossary must be deleted before the Glossary can be deleted.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture + deleteGlossary(com.google.cloud.dataplex.v1.DeleteGlossaryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteGlossaryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Gets a Glossary resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture + getGlossary(com.google.cloud.dataplex.v1.GetGlossaryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetGlossaryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Lists Glossary resources in a project and location.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.ListGlossariesResponse> + listGlossaries(com.google.cloud.dataplex.v1.ListGlossariesRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListGlossariesMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Creates a new GlossaryCategory resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.GlossaryCategory> + createGlossaryCategory(com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateGlossaryCategoryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Updates a GlossaryCategory resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.GlossaryCategory> + updateGlossaryCategory(com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateGlossaryCategoryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Deletes a GlossaryCategory resource. All the GlossaryCategories and
        +     * GlossaryTerms nested directly under the specified GlossaryCategory will be
        +     * moved one level up to the parent in the hierarchy.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture + deleteGlossaryCategory(com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteGlossaryCategoryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Gets a GlossaryCategory resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.GlossaryCategory> + getGlossaryCategory(com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetGlossaryCategoryMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Lists GlossaryCategory resources in a Glossary.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse> + listGlossaryCategories(com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListGlossaryCategoriesMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Creates a new GlossaryTerm resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.GlossaryTerm> + createGlossaryTerm(com.google.cloud.dataplex.v1.CreateGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateGlossaryTermMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Updates a GlossaryTerm resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.GlossaryTerm> + updateGlossaryTerm(com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getUpdateGlossaryTermMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Deletes a GlossaryTerm resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture + deleteGlossaryTerm(com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteGlossaryTermMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Gets a GlossaryTerm resource.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.GlossaryTerm> + getGlossaryTerm(com.google.cloud.dataplex.v1.GetGlossaryTermRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetGlossaryTermMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Lists GlossaryTerm resources in a Glossary.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse> + listGlossaryTerms(com.google.cloud.dataplex.v1.ListGlossaryTermsRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getListGlossaryTermsMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_CREATE_GLOSSARY = 0; + private static final int METHODID_UPDATE_GLOSSARY = 1; + private static final int METHODID_DELETE_GLOSSARY = 2; + private static final int METHODID_GET_GLOSSARY = 3; + private static final int METHODID_LIST_GLOSSARIES = 4; + private static final int METHODID_CREATE_GLOSSARY_CATEGORY = 5; + private static final int METHODID_UPDATE_GLOSSARY_CATEGORY = 6; + private static final int METHODID_DELETE_GLOSSARY_CATEGORY = 7; + private static final int METHODID_GET_GLOSSARY_CATEGORY = 8; + private static final int METHODID_LIST_GLOSSARY_CATEGORIES = 9; + private static final int METHODID_CREATE_GLOSSARY_TERM = 10; + private static final int METHODID_UPDATE_GLOSSARY_TERM = 11; + private static final int METHODID_DELETE_GLOSSARY_TERM = 12; + private static final int METHODID_GET_GLOSSARY_TERM = 13; + private static final int METHODID_LIST_GLOSSARY_TERMS = 14; + + 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_CREATE_GLOSSARY: + serviceImpl.createGlossary( + (com.google.cloud.dataplex.v1.CreateGlossaryRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_UPDATE_GLOSSARY: + serviceImpl.updateGlossary( + (com.google.cloud.dataplex.v1.UpdateGlossaryRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_DELETE_GLOSSARY: + serviceImpl.deleteGlossary( + (com.google.cloud.dataplex.v1.DeleteGlossaryRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_GLOSSARY: + serviceImpl.getGlossary( + (com.google.cloud.dataplex.v1.GetGlossaryRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_GLOSSARIES: + serviceImpl.listGlossaries( + (com.google.cloud.dataplex.v1.ListGlossariesRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_GLOSSARY_CATEGORY: + serviceImpl.createGlossaryCategory( + (com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_GLOSSARY_CATEGORY: + serviceImpl.updateGlossaryCategory( + (com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_DELETE_GLOSSARY_CATEGORY: + serviceImpl.deleteGlossaryCategory( + (com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_GLOSSARY_CATEGORY: + serviceImpl.getGlossaryCategory( + (com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_GLOSSARY_CATEGORIES: + serviceImpl.listGlossaryCategories( + (com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse>) + responseObserver); + break; + case METHODID_CREATE_GLOSSARY_TERM: + serviceImpl.createGlossaryTerm( + (com.google.cloud.dataplex.v1.CreateGlossaryTermRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_GLOSSARY_TERM: + serviceImpl.updateGlossaryTerm( + (com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_DELETE_GLOSSARY_TERM: + serviceImpl.deleteGlossaryTerm( + (com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_GET_GLOSSARY_TERM: + serviceImpl.getGlossaryTerm( + (com.google.cloud.dataplex.v1.GetGlossaryTermRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_GLOSSARY_TERMS: + serviceImpl.listGlossaryTerms( + (com.google.cloud.dataplex.v1.ListGlossaryTermsRequest) 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( + getCreateGlossaryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.CreateGlossaryRequest, + com.google.longrunning.Operation>(service, METHODID_CREATE_GLOSSARY))) + .addMethod( + getUpdateGlossaryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.UpdateGlossaryRequest, + com.google.longrunning.Operation>(service, METHODID_UPDATE_GLOSSARY))) + .addMethod( + getDeleteGlossaryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.DeleteGlossaryRequest, + com.google.longrunning.Operation>(service, METHODID_DELETE_GLOSSARY))) + .addMethod( + getGetGlossaryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.GetGlossaryRequest, + com.google.cloud.dataplex.v1.Glossary>(service, METHODID_GET_GLOSSARY))) + .addMethod( + getListGlossariesMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.ListGlossariesRequest, + com.google.cloud.dataplex.v1.ListGlossariesResponse>( + service, METHODID_LIST_GLOSSARIES))) + .addMethod( + getCreateGlossaryCategoryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory>( + service, METHODID_CREATE_GLOSSARY_CATEGORY))) + .addMethod( + getUpdateGlossaryCategoryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory>( + service, METHODID_UPDATE_GLOSSARY_CATEGORY))) + .addMethod( + getDeleteGlossaryCategoryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest, + com.google.protobuf.Empty>(service, METHODID_DELETE_GLOSSARY_CATEGORY))) + .addMethod( + getGetGlossaryCategoryMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest, + com.google.cloud.dataplex.v1.GlossaryCategory>( + service, METHODID_GET_GLOSSARY_CATEGORY))) + .addMethod( + getListGlossaryCategoriesMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse>( + service, METHODID_LIST_GLOSSARY_CATEGORIES))) + .addMethod( + getCreateGlossaryTermMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm>( + service, METHODID_CREATE_GLOSSARY_TERM))) + .addMethod( + getUpdateGlossaryTermMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm>( + service, METHODID_UPDATE_GLOSSARY_TERM))) + .addMethod( + getDeleteGlossaryTermMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest, + com.google.protobuf.Empty>(service, METHODID_DELETE_GLOSSARY_TERM))) + .addMethod( + getGetGlossaryTermMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.GetGlossaryTermRequest, + com.google.cloud.dataplex.v1.GlossaryTerm>( + service, METHODID_GET_GLOSSARY_TERM))) + .addMethod( + getListGlossaryTermsMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest, + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse>( + service, METHODID_LIST_GLOSSARY_TERMS))) + .build(); + } + + private abstract static class BusinessGlossaryServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + BusinessGlossaryServiceBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("BusinessGlossaryService"); + } + } + + private static final class BusinessGlossaryServiceFileDescriptorSupplier + extends BusinessGlossaryServiceBaseDescriptorSupplier { + BusinessGlossaryServiceFileDescriptorSupplier() {} + } + + private static final class BusinessGlossaryServiceMethodDescriptorSupplier + extends BusinessGlossaryServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final java.lang.String methodName; + + BusinessGlossaryServiceMethodDescriptorSupplier(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 (BusinessGlossaryServiceGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new BusinessGlossaryServiceFileDescriptorSupplier()) + .addMethod(getCreateGlossaryMethod()) + .addMethod(getUpdateGlossaryMethod()) + .addMethod(getDeleteGlossaryMethod()) + .addMethod(getGetGlossaryMethod()) + .addMethod(getListGlossariesMethod()) + .addMethod(getCreateGlossaryCategoryMethod()) + .addMethod(getUpdateGlossaryCategoryMethod()) + .addMethod(getDeleteGlossaryCategoryMethod()) + .addMethod(getGetGlossaryCategoryMethod()) + .addMethod(getListGlossaryCategoriesMethod()) + .addMethod(getCreateGlossaryTermMethod()) + .addMethod(getUpdateGlossaryTermMethod()) + .addMethod(getDeleteGlossaryTermMethod()) + .addMethod(getGetGlossaryTermMethod()) + .addMethod(getListGlossaryTermsMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceGrpc.java b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceGrpc.java index af16c2532dd1..9fa0b43196bd 100644 --- a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceGrpc.java +++ b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogServiceGrpc.java @@ -22,10 +22,10 @@ * *
          * The primary resources offered by this service are EntryGroups, EntryTypes,
        - * AspectTypes, and Entries. They collectively let data administrators organize,
        - * manage, secure, and catalog data located across cloud projects in their
        - * organization in a variety of storage systems, including Cloud Storage and
        - * BigQuery.
        + * AspectTypes, Entries and EntryLinks. They collectively let data
        + * administrators organize, manage, secure, and catalog data located across
        + * cloud projects in their organization in a variety of storage systems,
        + * including Cloud Storage and BigQuery.
          * 
        */ @javax.annotation.Generated( @@ -1184,6 +1184,142 @@ private CatalogServiceGrpc() {} return getCancelMetadataJobMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getCreateEntryLinkMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateEntryLink", + requestType = com.google.cloud.dataplex.v1.CreateEntryLinkRequest.class, + responseType = com.google.cloud.dataplex.v1.EntryLink.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getCreateEntryLinkMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.CreateEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getCreateEntryLinkMethod; + if ((getCreateEntryLinkMethod = CatalogServiceGrpc.getCreateEntryLinkMethod) == null) { + synchronized (CatalogServiceGrpc.class) { + if ((getCreateEntryLinkMethod = CatalogServiceGrpc.getCreateEntryLinkMethod) == null) { + CatalogServiceGrpc.getCreateEntryLinkMethod = + getCreateEntryLinkMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateEntryLink")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance())) + .setSchemaDescriptor( + new CatalogServiceMethodDescriptorSupplier("CreateEntryLink")) + .build(); + } + } + } + return getCreateEntryLinkMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getDeleteEntryLinkMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteEntryLink", + requestType = com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.class, + responseType = com.google.cloud.dataplex.v1.EntryLink.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getDeleteEntryLinkMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getDeleteEntryLinkMethod; + if ((getDeleteEntryLinkMethod = CatalogServiceGrpc.getDeleteEntryLinkMethod) == null) { + synchronized (CatalogServiceGrpc.class) { + if ((getDeleteEntryLinkMethod = CatalogServiceGrpc.getDeleteEntryLinkMethod) == null) { + CatalogServiceGrpc.getDeleteEntryLinkMethod = + getDeleteEntryLinkMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteEntryLink")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance())) + .setSchemaDescriptor( + new CatalogServiceMethodDescriptorSupplier("DeleteEntryLink")) + .build(); + } + } + } + return getDeleteEntryLinkMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetEntryLinkRequest, com.google.cloud.dataplex.v1.EntryLink> + getGetEntryLinkMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetEntryLink", + requestType = com.google.cloud.dataplex.v1.GetEntryLinkRequest.class, + responseType = com.google.cloud.dataplex.v1.EntryLink.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetEntryLinkRequest, com.google.cloud.dataplex.v1.EntryLink> + getGetEntryLinkMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dataplex.v1.GetEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink> + getGetEntryLinkMethod; + if ((getGetEntryLinkMethod = CatalogServiceGrpc.getGetEntryLinkMethod) == null) { + synchronized (CatalogServiceGrpc.class) { + if ((getGetEntryLinkMethod = CatalogServiceGrpc.getGetEntryLinkMethod) == null) { + CatalogServiceGrpc.getGetEntryLinkMethod = + getGetEntryLinkMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetEntryLink")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.GetEntryLinkRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance())) + .setSchemaDescriptor( + new CatalogServiceMethodDescriptorSupplier("GetEntryLink")) + .build(); + } + } + } + return getGetEntryLinkMethod; + } + /** Creates a new async stub that supports all call types for the service */ public static CatalogServiceStub newStub(io.grpc.Channel channel) { io.grpc.stub.AbstractStub.StubFactory factory = @@ -1243,10 +1379,10 @@ public CatalogServiceFutureStub newStub( * *
            * The primary resources offered by this service are EntryGroups, EntryTypes,
        -   * AspectTypes, and Entries. They collectively let data administrators organize,
        -   * manage, secure, and catalog data located across cloud projects in their
        -   * organization in a variety of storage systems, including Cloud Storage and
        -   * BigQuery.
        +   * AspectTypes, Entries and EntryLinks. They collectively let data
        +   * administrators organize, manage, secure, and catalog data located across
        +   * cloud projects in their organization in a variety of storage systems,
        +   * including Cloud Storage and BigQuery.
            * 
        */ public interface AsyncService { @@ -1567,8 +1703,8 @@ default void searchEntries( * * *
        -     * Creates a metadata job. For example, use a metadata job to import Dataplex
        -     * Catalog entries and aspects from a third-party system into Dataplex.
        +     * Creates a metadata job. For example, use a metadata job to import metadata
        +     * from a third-party system into Dataplex Universal Catalog.
              * 
        */ default void createMetadataJob( @@ -1624,6 +1760,48 @@ default void cancelMetadataJob( io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( getCancelMetadataJobMethod(), responseObserver); } + + /** + * + * + *
        +     * Creates an Entry Link.
        +     * 
        + */ + default void createEntryLink( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getCreateEntryLinkMethod(), responseObserver); + } + + /** + * + * + *
        +     * Deletes an Entry Link.
        +     * 
        + */ + default void deleteEntryLink( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDeleteEntryLinkMethod(), responseObserver); + } + + /** + * + * + *
        +     * Gets an Entry Link.
        +     * 
        + */ + default void getEntryLink( + com.google.cloud.dataplex.v1.GetEntryLinkRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getGetEntryLinkMethod(), responseObserver); + } } /** @@ -1631,10 +1809,10 @@ default void cancelMetadataJob( * *
            * The primary resources offered by this service are EntryGroups, EntryTypes,
        -   * AspectTypes, and Entries. They collectively let data administrators organize,
        -   * manage, secure, and catalog data located across cloud projects in their
        -   * organization in a variety of storage systems, including Cloud Storage and
        -   * BigQuery.
        +   * AspectTypes, Entries and EntryLinks. They collectively let data
        +   * administrators organize, manage, secure, and catalog data located across
        +   * cloud projects in their organization in a variety of storage systems,
        +   * including Cloud Storage and BigQuery.
            * 
        */ public abstract static class CatalogServiceImplBase @@ -1651,10 +1829,10 @@ public final io.grpc.ServerServiceDefinition bindService() { * *
            * The primary resources offered by this service are EntryGroups, EntryTypes,
        -   * AspectTypes, and Entries. They collectively let data administrators organize,
        -   * manage, secure, and catalog data located across cloud projects in their
        -   * organization in a variety of storage systems, including Cloud Storage and
        -   * BigQuery.
        +   * AspectTypes, Entries and EntryLinks. They collectively let data
        +   * administrators organize, manage, secure, and catalog data located across
        +   * cloud projects in their organization in a variety of storage systems,
        +   * including Cloud Storage and BigQuery.
            * 
        */ public static final class CatalogServiceStub @@ -2027,8 +2205,8 @@ public void searchEntries( * * *
        -     * Creates a metadata job. For example, use a metadata job to import Dataplex
        -     * Catalog entries and aspects from a third-party system into Dataplex.
        +     * Creates a metadata job. For example, use a metadata job to import metadata
        +     * from a third-party system into Dataplex Universal Catalog.
              * 
        */ public void createMetadataJob( @@ -2092,6 +2270,54 @@ public void cancelMetadataJob( request, responseObserver); } + + /** + * + * + *
        +     * Creates an Entry Link.
        +     * 
        + */ + public void createEntryLink( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getCreateEntryLinkMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Deletes an Entry Link.
        +     * 
        + */ + public void deleteEntryLink( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDeleteEntryLinkMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
        +     * Gets an Entry Link.
        +     * 
        + */ + public void getEntryLink( + com.google.cloud.dataplex.v1.GetEntryLinkRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getGetEntryLinkMethod(), getCallOptions()), + request, + responseObserver); + } } /** @@ -2099,10 +2325,10 @@ public void cancelMetadataJob( * *
            * The primary resources offered by this service are EntryGroups, EntryTypes,
        -   * AspectTypes, and Entries. They collectively let data administrators organize,
        -   * manage, secure, and catalog data located across cloud projects in their
        -   * organization in a variety of storage systems, including Cloud Storage and
        -   * BigQuery.
        +   * AspectTypes, Entries and EntryLinks. They collectively let data
        +   * administrators organize, manage, secure, and catalog data located across
        +   * cloud projects in their organization in a variety of storage systems,
        +   * including Cloud Storage and BigQuery.
            * 
        */ public static final class CatalogServiceBlockingV2Stub @@ -2407,8 +2633,8 @@ public com.google.cloud.dataplex.v1.SearchEntriesResponse searchEntries( * * *
        -     * Creates a metadata job. For example, use a metadata job to import Dataplex
        -     * Catalog entries and aspects from a third-party system into Dataplex.
        +     * Creates a metadata job. For example, use a metadata job to import metadata
        +     * from a third-party system into Dataplex Universal Catalog.
              * 
        */ public com.google.longrunning.Operation createMetadataJob( @@ -2459,6 +2685,45 @@ public com.google.protobuf.Empty cancelMetadataJob( return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getCancelMetadataJobMethod(), getCallOptions(), request); } + + /** + * + * + *
        +     * Creates an Entry Link.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.EntryLink createEntryLink( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateEntryLinkMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes an Entry Link.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.EntryLink deleteEntryLink( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteEntryLinkMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets an Entry Link.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.EntryLink getEntryLink( + com.google.cloud.dataplex.v1.GetEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetEntryLinkMethod(), getCallOptions(), request); + } } /** @@ -2466,10 +2731,10 @@ public com.google.protobuf.Empty cancelMetadataJob( * *
            * The primary resources offered by this service are EntryGroups, EntryTypes,
        -   * AspectTypes, and Entries. They collectively let data administrators organize,
        -   * manage, secure, and catalog data located across cloud projects in their
        -   * organization in a variety of storage systems, including Cloud Storage and
        -   * BigQuery.
        +   * AspectTypes, Entries and EntryLinks. They collectively let data
        +   * administrators organize, manage, secure, and catalog data located across
        +   * cloud projects in their organization in a variety of storage systems,
        +   * including Cloud Storage and BigQuery.
            * 
        */ public static final class CatalogServiceBlockingStub @@ -2774,8 +3039,8 @@ public com.google.cloud.dataplex.v1.SearchEntriesResponse searchEntries( * * *
        -     * Creates a metadata job. For example, use a metadata job to import Dataplex
        -     * Catalog entries and aspects from a third-party system into Dataplex.
        +     * Creates a metadata job. For example, use a metadata job to import metadata
        +     * from a third-party system into Dataplex Universal Catalog.
              * 
        */ public com.google.longrunning.Operation createMetadataJob( @@ -2826,6 +3091,45 @@ public com.google.protobuf.Empty cancelMetadataJob( return io.grpc.stub.ClientCalls.blockingUnaryCall( getChannel(), getCancelMetadataJobMethod(), getCallOptions(), request); } + + /** + * + * + *
        +     * Creates an Entry Link.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.EntryLink createEntryLink( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getCreateEntryLinkMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Deletes an Entry Link.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.EntryLink deleteEntryLink( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDeleteEntryLinkMethod(), getCallOptions(), request); + } + + /** + * + * + *
        +     * Gets an Entry Link.
        +     * 
        + */ + public com.google.cloud.dataplex.v1.EntryLink getEntryLink( + com.google.cloud.dataplex.v1.GetEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getGetEntryLinkMethod(), getCallOptions(), request); + } } /** @@ -2833,10 +3137,10 @@ public com.google.protobuf.Empty cancelMetadataJob( * *
            * The primary resources offered by this service are EntryGroups, EntryTypes,
        -   * AspectTypes, and Entries. They collectively let data administrators organize,
        -   * manage, secure, and catalog data located across cloud projects in their
        -   * organization in a variety of storage systems, including Cloud Storage and
        -   * BigQuery.
        +   * AspectTypes, Entries and EntryLinks. They collectively let data
        +   * administrators organize, manage, secure, and catalog data located across
        +   * cloud projects in their organization in a variety of storage systems,
        +   * including Cloud Storage and BigQuery.
            * 
        */ public static final class CatalogServiceFutureStub @@ -3149,8 +3453,8 @@ protected CatalogServiceFutureStub build( * * *
        -     * Creates a metadata job. For example, use a metadata job to import Dataplex
        -     * Catalog entries and aspects from a third-party system into Dataplex.
        +     * Creates a metadata job. For example, use a metadata job to import metadata
        +     * from a third-party system into Dataplex Universal Catalog.
              * 
        */ public com.google.common.util.concurrent.ListenableFuture @@ -3203,6 +3507,48 @@ protected CatalogServiceFutureStub build( return io.grpc.stub.ClientCalls.futureUnaryCall( getChannel().newCall(getCancelMetadataJobMethod(), getCallOptions()), request); } + + /** + * + * + *
        +     * Creates an Entry Link.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.EntryLink> + createEntryLink(com.google.cloud.dataplex.v1.CreateEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getCreateEntryLinkMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Deletes an Entry Link.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.EntryLink> + deleteEntryLink(com.google.cloud.dataplex.v1.DeleteEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDeleteEntryLinkMethod(), getCallOptions()), request); + } + + /** + * + * + *
        +     * Gets an Entry Link.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dataplex.v1.EntryLink> + getEntryLink(com.google.cloud.dataplex.v1.GetEntryLinkRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getGetEntryLinkMethod(), getCallOptions()), request); + } } private static final int METHODID_CREATE_ENTRY_TYPE = 0; @@ -3231,6 +3577,9 @@ protected CatalogServiceFutureStub build( private static final int METHODID_GET_METADATA_JOB = 23; private static final int METHODID_LIST_METADATA_JOBS = 24; private static final int METHODID_CANCEL_METADATA_JOB = 25; + private static final int METHODID_CREATE_ENTRY_LINK = 26; + private static final int METHODID_DELETE_ENTRY_LINK = 27; + private static final int METHODID_GET_ENTRY_LINK = 28; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -3389,6 +3738,24 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (com.google.cloud.dataplex.v1.CancelMetadataJobRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_CREATE_ENTRY_LINK: + serviceImpl.createEntryLink( + (com.google.cloud.dataplex.v1.CreateEntryLinkRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_DELETE_ENTRY_LINK: + serviceImpl.deleteEntryLink( + (com.google.cloud.dataplex.v1.DeleteEntryLinkRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_GET_ENTRY_LINK: + serviceImpl.getEntryLink( + (com.google.cloud.dataplex.v1.GetEntryLinkRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; default: throw new AssertionError(); } @@ -3569,6 +3936,24 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser new MethodHandlers< com.google.cloud.dataplex.v1.CancelMetadataJobRequest, com.google.protobuf.Empty>(service, METHODID_CANCEL_METADATA_JOB))) + .addMethod( + getCreateEntryLinkMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.CreateEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink>(service, METHODID_CREATE_ENTRY_LINK))) + .addMethod( + getDeleteEntryLinkMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink>(service, METHODID_DELETE_ENTRY_LINK))) + .addMethod( + getGetEntryLinkMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dataplex.v1.GetEntryLinkRequest, + com.google.cloud.dataplex.v1.EntryLink>(service, METHODID_GET_ENTRY_LINK))) .build(); } @@ -3646,6 +4031,9 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getGetMetadataJobMethod()) .addMethod(getListMetadataJobsMethod()) .addMethod(getCancelMetadataJobMethod()) + .addMethod(getCreateEntryLinkMethod()) + .addMethod(getDeleteEntryLinkMethod()) + .addMethod(getGetEntryLinkMethod()) .build(); } } diff --git a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CmekServiceGrpc.java b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CmekServiceGrpc.java index 4ffb6e1fb978..920c345c471b 100644 --- a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CmekServiceGrpc.java +++ b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CmekServiceGrpc.java @@ -21,7 +21,7 @@ * * *
        - * Dataplex Cmek Service
        + * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
          * 
        */ @javax.annotation.Generated( @@ -335,7 +335,7 @@ public CmekServiceFutureStub newStub( * * *
        -   * Dataplex Cmek Service
        +   * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
            * 
        */ public interface AsyncService { @@ -417,7 +417,7 @@ default void getEncryptionConfig( * Base class for the server implementation of the service CmekService. * *
        -   * Dataplex Cmek Service
        +   * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
            * 
        */ public abstract static class CmekServiceImplBase @@ -433,7 +433,7 @@ public final io.grpc.ServerServiceDefinition bindService() { * A stub to allow clients to do asynchronous rpc calls to service CmekService. * *
        -   * Dataplex Cmek Service
        +   * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
            * 
        */ public static final class CmekServiceStub @@ -534,7 +534,7 @@ public void getEncryptionConfig( * A stub to allow clients to do synchronous rpc calls to service CmekService. * *
        -   * Dataplex Cmek Service
        +   * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
            * 
        */ public static final class CmekServiceBlockingV2Stub @@ -619,7 +619,7 @@ public com.google.cloud.dataplex.v1.EncryptionConfig getEncryptionConfig( * A stub to allow clients to do limited synchronous rpc calls to service CmekService. * *
        -   * Dataplex Cmek Service
        +   * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
            * 
        */ public static final class CmekServiceBlockingStub @@ -704,7 +704,7 @@ public com.google.cloud.dataplex.v1.EncryptionConfig getEncryptionConfig( * A stub to allow clients to do ListenableFuture-style rpc calls to service CmekService. * *
        -   * Dataplex Cmek Service
        +   * Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service
            * 
        */ public static final class CmekServiceFutureStub diff --git a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ContentServiceGrpc.java b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ContentServiceGrpc.java index 73019c99f18c..713a7e249a76 100644 --- a/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ContentServiceGrpc.java +++ b/java-dataplex/grpc-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ContentServiceGrpc.java @@ -21,7 +21,8 @@ * * *
        - * ContentService manages Notebook and SQL Scripts for Dataplex.
        + * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        + * Catalog.
          * 
        */ @javax.annotation.Generated( @@ -431,7 +432,8 @@ public ContentServiceFutureStub newStub( * * *
        -   * ContentService manages Notebook and SQL Scripts for Dataplex.
        +   * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        +   * Catalog.
            * 
        */ public interface AsyncService { @@ -568,7 +570,8 @@ default void listContent( * Base class for the server implementation of the service ContentService. * *
        -   * ContentService manages Notebook and SQL Scripts for Dataplex.
        +   * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        +   * Catalog.
            * 
        */ public abstract static class ContentServiceImplBase @@ -584,7 +587,8 @@ public final io.grpc.ServerServiceDefinition bindService() { * A stub to allow clients to do asynchronous rpc calls to service ContentService. * *
        -   * ContentService manages Notebook and SQL Scripts for Dataplex.
        +   * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        +   * Catalog.
            * 
        */ public static final class ContentServiceStub @@ -745,7 +749,8 @@ public void listContent( * A stub to allow clients to do synchronous rpc calls to service ContentService. * *
        -   * ContentService manages Notebook and SQL Scripts for Dataplex.
        +   * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        +   * Catalog.
            * 
        */ public static final class ContentServiceBlockingV2Stub @@ -881,7 +886,8 @@ public com.google.cloud.dataplex.v1.ListContentResponse listContent( * A stub to allow clients to do limited synchronous rpc calls to service ContentService. * *
        -   * ContentService manages Notebook and SQL Scripts for Dataplex.
        +   * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        +   * Catalog.
            * 
        */ public static final class ContentServiceBlockingStub @@ -1017,7 +1023,8 @@ public com.google.cloud.dataplex.v1.ListContentResponse listContent( * A stub to allow clients to do ListenableFuture-style rpc calls to service ContentService. * *
        -   * ContentService manages Notebook and SQL Scripts for Dataplex.
        +   * ContentService manages Notebook and SQL Scripts for Dataplex Universal
        +   * Catalog.
            * 
        */ public static final class ContentServiceFutureStub diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/AspectType.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/AspectType.java index ac8d078cfb0a..ab9ce2f6e4c6 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/AspectType.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/AspectType.java @@ -92,8 +92,8 @@ public interface AuthorizationOrBuilder * *
              * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -     * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -     * Dataplex owned Types.
        +     * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +     * only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -107,8 +107,8 @@ public interface AuthorizationOrBuilder * *
              * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -     * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -     * Dataplex owned Types.
        +     * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +     * only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -122,7 +122,7 @@ public interface AuthorizationOrBuilder * * *
        -   * Autorization for an AspectType.
        +   * Authorization for an AspectType.
            * 
        * * Protobuf type {@code google.cloud.dataplex.v1.AspectType.Authorization} @@ -173,8 +173,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * *
              * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -     * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -     * Dataplex owned Types.
        +     * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +     * only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -199,8 +199,8 @@ public java.lang.String getAlternateUsePermission() { * *
              * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -     * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -     * Dataplex owned Types.
        +     * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +     * only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -387,7 +387,7 @@ protected Builder newBuilderForType( * * *
        -     * Autorization for an AspectType.
        +     * Authorization for an AspectType.
              * 
        * * Protobuf type {@code google.cloud.dataplex.v1.AspectType.Authorization} @@ -576,8 +576,8 @@ public Builder mergeFrom( * *
                * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -       * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -       * Dataplex owned Types.
        +       * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +       * only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -602,8 +602,8 @@ public java.lang.String getAlternateUsePermission() { * *
                * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -       * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -       * Dataplex owned Types.
        +       * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +       * only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -628,8 +628,8 @@ public com.google.protobuf.ByteString getAlternateUsePermissionBytes() { * *
                * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -       * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -       * Dataplex owned Types.
        +       * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +       * only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -653,8 +653,8 @@ public Builder setAlternateUsePermission(java.lang.String value) { * *
                * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -       * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -       * Dataplex owned Types.
        +       * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +       * only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -674,8 +674,8 @@ public Builder clearAlternateUsePermission() { * *
                * Immutable. The IAM permission grantable on the EntryGroup to allow access
        -       * to instantiate Aspects of Dataplex owned AspectTypes, only settable for
        -       * Dataplex owned Types.
        +       * to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes,
        +       * only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -817,8 +817,8 @@ public interface MetadataTemplateOrBuilder * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -846,8 +846,8 @@ public interface MetadataTemplateOrBuilder * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -4833,8 +4833,8 @@ public com.google.protobuf.ByteString getNameBytes() { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -4873,8 +4873,8 @@ public java.lang.String getType() { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -6402,8 +6402,8 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -6441,8 +6441,8 @@ public java.lang.String getType() { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -6480,8 +6480,8 @@ public com.google.protobuf.ByteString getTypeBytes() { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -6518,8 +6518,8 @@ public Builder setType(java.lang.String value) { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -6552,8 +6552,8 @@ public Builder clearType() { * Primitive types: * * * string - * * integer - * * boolean + * * int + * * bool * * double * * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: * "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryProto.java new file mode 100644 index 000000000000..d64f3f21012a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/BusinessGlossaryProto.java @@ -0,0 +1,606 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public final class BusinessGlossaryProto { + private BusinessGlossaryProto() {} + + 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_dataplex_v1_Glossary_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_Glossary_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_Glossary_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_Glossary_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GlossaryCategory_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GlossaryCategory_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GlossaryCategory_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GlossaryCategory_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GlossaryTerm_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GlossaryTerm_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GlossaryTerm_LabelsEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GlossaryTerm_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_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" + + "0google/cloud/dataplex/v1/business_glos" + + "sary.proto\022\030google.cloud.dataplex.v1\032\034go" + + "ogle/api/annotations.proto\032\027google/api/c" + + "lient.proto\032\037google/api/field_behavior.p" + + "roto\032\033google/api/field_info.proto\032\031googl" + + "e/api/resource.proto\032&google/cloud/dataplex/v1/service.proto\032#google/longrunning" + + "/operations.proto\032\033google/protobuf/empty.proto\032" + + " google/protobuf/field_mask.proto\032\037google/protobuf/timestamp.proto\"\224\004\n" + + "\010Glossary\022\024\n" + + "\004name\030\001 \001(\tB\006\340A\003\340A\010\022\030\n" + + "\003uid\030\002 \001(\tB\013\340A\003\342\214\317\327\010\002\010\001\022\031\n" + + "\014display_name\030\003 \001(\tB\003\340A\001\022\030\n" + + "\013description\030\004 \001(\tB\003\340A\001\0224\n" + + "\013create_time\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0224\n" + + "\013update_time\030\006 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022C\n" + + "\006labels\030\007 \003(\0132..google" + + ".cloud.dataplex.v1.Glossary.LabelsEntryB\003\340A\001\022\027\n\n" + + "term_count\030\010 \001(\005B\003\340A\003\022\033\n" + + "\016category_count\030\t \001(\005B\003\340A\003\022\021\n" + + "\004etag\030\n" + + " \001(\tB\003\340A\001\032-\n" + + "\013LabelsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001:z\352Aw\n" + + " dataplex.googleapis.com/Gloss" + + "ary\022=projects/{project}/locations/{location}/glossaries/{glossary}*\n" + + "glossaries2\010glossary\"\231\004\n" + + "\020GlossaryCategory\022\024\n" + + "\004name\030\001 \001(\tB\006\340A\003\340A\010\022\030\n" + + "\003uid\030\002 \001(\tB\013\340A\003\342\214\317\327\010\002\010\001\022\031\n" + + "\014display_name\030\003 \001(\tB\003\340A\001\022\030\n" + + "\013description\030\004 \001(\tB\003\340A\001\0224\n" + + "\013create_time\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0224\n" + + "\013update_time\030\006 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022K\n" + + "\006labels\030\007" + + " \003(\01326.google.cloud.dataplex.v1.GlossaryCategory.LabelsEntryB\003\340A\001\022\023\n" + + "\006parent\030\010 \001(\tB\003\340A\002\032-\n" + + "\013LabelsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001:\242\001\352A\236\001\n" + + "(dataplex.googleapis.com/GlossaryCategory\022\\projec" + + "ts/{project}/locations/{location}/glossa" + + "ries/{glossary}/categories/{glossary_category}*\n" + + "categories2\010category\"\240\004\n" + + "\014GlossaryTerm\022\024\n" + + "\004name\030\001 \001(\tB\006\340A\003\340A\010\022\030\n" + + "\003uid\030\002 \001(\tB\013\340A\003\342\214\317\327\010\002\010\001\022\031\n" + + "\014display_name\030\003 \001(\tB\003\340A\001\022\030\n" + + "\013description\030\004 \001(\tB\003\340A\001\0224\n" + + "\013create_time\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0224\n" + + "\013update_time\030\006 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022G\n" + + "\006labels\030\007 \003(\01322.google." + + "cloud.dataplex.v1.GlossaryTerm.LabelsEntryB\003\340A\001\0228\n" + + "\006parent\030\010 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\032-\n" + + "\013LabelsEntry\022\013\n" + + "\003key\030\001 \001(\t\022\r\n" + + "\005value\030\002 \001(\t:\0028\001:\214\001\352A\210\001\n" + + "$dataplex.googleapis.com/GlossaryTerm\022Sprojects/{project}/locations/{location}/g" + + "lossaries/{glossary}/terms/{glossary_term}*\005terms2\004term\"\303\001\n" + + "\025CreateGlossaryRequest\0229\n" + + "\006parent\030\001 \001(\tB)\340A\002\372A#\n" + + "!locations.googleapis.com/Location\022\030\n" + + "\013glossary_id\030\002 \001(\tB\003\340A\002\0229\n" + + "\010glossary\030\003" + + " \001(\0132\".google.cloud.dataplex.v1.GlossaryB\003\340A\002\022\032\n\r" + + "validate_only\030\004 \001(\010B\003\340A\001\"\244\001\n" + + "\025UpdateGlossaryRequest\0229\n" + + "\010glossary\030\001" + + " \001(\0132\".google.cloud.dataplex.v1.GlossaryB\003\340A\002\0224\n" + + "\013update_mask\030\002" + + " \001(\0132\032.google.protobuf.FieldMaskB\003\340A\002\022\032\n\r" + + "validate_only\030\003 \001(\010B\003\340A\001\"b\n" + + "\025DeleteGlossaryRequest\0226\n" + + "\004name\030\001 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\022\021\n" + + "\004etag\030\002 \001(\tB\003\340A\001\"L\n" + + "\022GetGlossaryRequest\0226\n" + + "\004name\030\001 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\"\257\001\n" + + "\025ListGlossariesRequest\0229\n" + + "\006parent\030\001 \001(\tB)\340A\002\372A#\n" + + "!locations.googleapis.com/Location\022\026\n" + + "\tpage_size\030\002 \001(\005B\003\340A\001\022\027\n\n" + + "page_token\030\003 \001(\tB\003\340A\001\022\023\n" + + "\006filter\030\004 \001(\tB\003\340A\001\022\025\n" + + "\010order_by\030\005 \001(\tB\003\340A\001\"\210\001\n" + + "\026ListGlossariesResponse\0226\n\n" + + "glossaries\030\001 \003(\0132\".google.cloud.dataplex.v1.Glossary\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\035\n" + + "\025unreachable_locations\030\003 \003(\t\"\266\001\n" + + "\035CreateGlossaryCategoryRequest\0228\n" + + "\006parent\030\001 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\022\030\n" + + "\013category_id\030\002 \001(\tB\003\340A\002\022A\n" + + "\010category\030\003" + + " \001(\0132*.google.cloud.dataplex.v1.GlossaryCategoryB\003\340A\002\"\230\001\n" + + "\035UpdateGlossaryCategoryRequest\022A\n" + + "\010category\030\001 \001(\0132*.googl" + + "e.cloud.dataplex.v1.GlossaryCategoryB\003\340A\002\0224\n" + + "\013update_mask\030\002 \001(\0132\032.google.protobuf.FieldMaskB\003\340A\002\"_\n" + + "\035DeleteGlossaryCategoryRequest\022>\n" + + "\004name\030\001 \001(\tB0\340A\002\372A*\n" + + "(dataplex.googleapis.com/GlossaryCategory\"\\\n" + + "\032GetGlossaryCategoryRequest\022>\n" + + "\004name\030\001 \001(\tB0\340A\002\372A*\n" + + "(dataplex.googleapis.com/GlossaryCategory\"\266\001\n" + + "\035ListGlossaryCategoriesRequest\0228\n" + + "\006parent\030\001 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\022\026\n" + + "\tpage_size\030\002 \001(\005B\003\340A\001\022\027\n\n" + + "page_token\030\003 \001(\tB\003\340A\001\022\023\n" + + "\006filter\030\004 \001(\tB\003\340A\001\022\025\n" + + "\010order_by\030\005 \001(\tB\003\340A\001\"\230\001\n" + + "\036ListGlossaryCategoriesResponse\022>\n\n" + + "categories\030\001 \003(\0132*.google.cloud.dataplex.v1.GlossaryCategory\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\035\n" + + "\025unreachable_locations\030\003 \003(\t\"\246\001\n" + + "\031CreateGlossaryTermRequest\0228\n" + + "\006parent\030\001 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\022\024\n" + + "\007term_id\030\002 \001(\tB\003\340A\002\0229\n" + + "\004term\030\003" + + " \001(\0132&.google.cloud.dataplex.v1.GlossaryTermB\003\340A\002\"\214\001\n" + + "\031UpdateGlossaryTermRequest\0229\n" + + "\004term\030\001 \001(\0132" + + "&.google.cloud.dataplex.v1.GlossaryTermB\003\340A\002\0224\n" + + "\013update_mask\030\002 \001(\0132\032.google.protobuf.FieldMaskB\003\340A\002\"W\n" + + "\031DeleteGlossaryTermRequest\022:\n" + + "\004name\030\001 \001(\tB,\340A\002\372A&\n" + + "$dataplex.googleapis.com/GlossaryTerm\"T\n" + + "\026GetGlossaryTermRequest\022:\n" + + "\004name\030\001 \001(\tB,\340A\002\372A&\n" + + "$dataplex.googleapis.com/GlossaryTerm\"\261\001\n" + + "\030ListGlossaryTermsRequest\0228\n" + + "\006parent\030\001 \001(\tB(\340A\002\372A\"\n" + + " dataplex.googleapis.com/Glossary\022\026\n" + + "\tpage_size\030\002 \001(\005B\003\340A\001\022\027\n\n" + + "page_token\030\003 \001(\tB\003\340A\001\022\023\n" + + "\006filter\030\004 \001(\tB\003\340A\001\022\025\n" + + "\010order_by\030\005 \001(\tB\003\340A\001\"\212\001\n" + + "\031ListGlossaryTermsResponse\0225\n" + + "\005terms\030\001 \003(\0132&.google.cloud.dataplex.v1.GlossaryTerm\022\027\n" + + "\017next_page_token\030\002 \001(\t\022\035\n" + + "\025unreachable_locations\030\003 \003(\t2\326\030\n" + + "\027BusinessGlossaryService\022\340\001\n" + + "\016CreateGlossary\022/.google.cloud.dataplex.v1.CreateGloss" + + "aryRequest\032\035.google.longrunning.Operation\"~\312A\035\n" + + "\010Glossary\022\021OperationMetadata\332A\033pa" + + "rent,glossary,glossary_id\202\323\344\223\002:\"./v1/{pa" + + "rent=projects/*/locations/*}/glossaries:\010glossary\022\343\001\n" + + "\016UpdateGlossary\022/.google.cl" + + "oud.dataplex.v1.UpdateGlossaryRequest\032\035.google.longrunning.Operation\"\200\001\312A\035\n" + + "\010Glossary\022\021OperationMetadata\332A\024glossary,updat" + + "e_mask\202\323\344\223\002C27/v1/{glossary.name=project" + + "s/*/locations/*/glossaries/*}:\010glossary\022\314\001\n" + + "\016DeleteGlossary\022/.google.cloud.datapl" + + "ex.v1.DeleteGlossaryRequest\032\035.google.longrunning.Operation\"j\312A*\n" + + "\025google.protobuf.Empty\022\021OperationMetadata\332A\004name\202\323\344\223\0020*." + + "/v1/{name=projects/*/locations/*/glossaries/*}\022\236\001\n" + + "\013GetGlossary\022,.google.cloud.dataplex.v1.GetGlossaryRequest\032\".google.cl" + + "oud.dataplex.v1.Glossary\"=\332A\004name\202\323\344\223\0020\022" + + "./v1/{name=projects/*/locations/*/glossaries/*}\022\264\001\n" + + "\016ListGlossaries\022/.google.cloud.dataplex.v1.ListGlossariesRequest\0320.go" + + "ogle.cloud.dataplex.v1.ListGlossariesRes" + + "ponse\"?\332A\006parent\202\323\344\223\0020\022./v1/{parent=projects/*/locations/*}/glossaries\022\352\001\n" + + "\026CreateGlossaryCategory\0227.google.cloud.dataple" + + "x.v1.CreateGlossaryCategoryRequest\032*.google.cloud.dataplex.v1.GlossaryCategory\"k" + + "\332A\033parent,category,category_id\202\323\344\223\002G\";/v" + + "1/{parent=projects/*/locations/*/glossaries/*}/categories:\010category\022\354\001\n" + + "\026UpdateGlossaryCategory\0227.google.cloud.dataplex.v" + + "1.UpdateGlossaryCategoryRequest\032*.google" + + ".cloud.dataplex.v1.GlossaryCategory\"m\332A\024" + + "category,update_mask\202\323\344\223\002P2D/v1/{categor" + + "y.name=projects/*/locations/*/glossaries/*/categories/*}:\010category\022\265\001\n" + + "\026DeleteGlossaryCategory\0227.google.cloud.dataplex.v1" + + ".DeleteGlossaryCategoryRequest\032\026.google." + + "protobuf.Empty\"J\332A\004name\202\323\344\223\002=*;/v1/{name" + + "=projects/*/locations/*/glossaries/*/categories/*}\022\303\001\n" + + "\023GetGlossaryCategory\0224.google.cloud.dataplex.v1.GetGlossaryCategor" + + "yRequest\032*.google.cloud.dataplex.v1.Glos" + + "saryCategory\"J\332A\004name\202\323\344\223\002=\022;/v1/{name=p" + + "rojects/*/locations/*/glossaries/*/categories/*}\022\331\001\n" + + "\026ListGlossaryCategories\0227.google.cloud.dataplex.v1.ListGlossaryCateg" + + "oriesRequest\0328.google.cloud.dataplex.v1." + + "ListGlossaryCategoriesResponse\"L\332A\006paren" + + "t\202\323\344\223\002=\022;/v1/{parent=projects/*/locations/*/glossaries/*}/categories\022\315\001\n" + + "\022CreateGlossaryTerm\0223.google.cloud.dataplex.v1.C" + + "reateGlossaryTermRequest\032&.google.cloud." + + "dataplex.v1.GlossaryTerm\"Z\332A\023parent,term" + + ",term_id\202\323\344\223\002>\"6/v1/{parent=projects/*/locations/*/glossaries/*}/terms:\004term\022\317\001\n" + + "\022UpdateGlossaryTerm\0223.google.cloud.datap" + + "lex.v1.UpdateGlossaryTermRequest\032&.googl" + + "e.cloud.dataplex.v1.GlossaryTerm\"\\\332A\020ter" + + "m,update_mask\202\323\344\223\002C2;/v1/{term.name=proj" + + "ects/*/locations/*/glossaries/*/terms/*}:\004term\022\250\001\n" + + "\022DeleteGlossaryTerm\0223.google.cloud.dataplex.v1.DeleteGlossaryTermReque" + + "st\032\026.google.protobuf.Empty\"E\332A\004name\202\323\344\223\002" + + "8*6/v1/{name=projects/*/locations/*/glossaries/*/terms/*}\022\262\001\n" + + "\017GetGlossaryTerm\0220.google.cloud.dataplex.v1.GetGlossaryTerm" + + "Request\032&.google.cloud.dataplex.v1.Gloss" + + "aryTerm\"E\332A\004name\202\323\344\223\0028\0226/v1/{name=projec" + + "ts/*/locations/*/glossaries/*/terms/*}\022\305\001\n" + + "\021ListGlossaryTerms\0222.google.cloud.data" + + "plex.v1.ListGlossaryTermsRequest\0323.google.cloud.dataplex.v1.ListGlossaryTermsRes" + + "ponse\"G\332A\006parent\202\323\344\223\0028\0226/v1/{parent=proj" + + "ects/*/locations/*/glossaries/*}/terms\032K" + + "\312A\027dataplex.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformBq\n" + + "\034com.google.cloud.dataplex.v1B\025BusinessGlo" + + "ssaryProtoP\001Z8cloud.google.com/go/dataplex/apiv1/dataplexpb;dataplexpbb\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.FieldInfoProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.cloud.dataplex.v1.ServiceProto.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_dataplex_v1_Glossary_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_dataplex_v1_Glossary_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_Glossary_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "DisplayName", + "Description", + "CreateTime", + "UpdateTime", + "Labels", + "TermCount", + "CategoryCount", + "Etag", + }); + internal_static_google_cloud_dataplex_v1_Glossary_LabelsEntry_descriptor = + internal_static_google_cloud_dataplex_v1_Glossary_descriptor.getNestedTypes().get(0); + internal_static_google_cloud_dataplex_v1_Glossary_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_Glossary_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_dataplex_v1_GlossaryCategory_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_cloud_dataplex_v1_GlossaryCategory_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GlossaryCategory_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "DisplayName", + "Description", + "CreateTime", + "UpdateTime", + "Labels", + "Parent", + }); + internal_static_google_cloud_dataplex_v1_GlossaryCategory_LabelsEntry_descriptor = + internal_static_google_cloud_dataplex_v1_GlossaryCategory_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dataplex_v1_GlossaryCategory_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GlossaryCategory_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_dataplex_v1_GlossaryTerm_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_cloud_dataplex_v1_GlossaryTerm_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GlossaryTerm_descriptor, + new java.lang.String[] { + "Name", + "Uid", + "DisplayName", + "Description", + "CreateTime", + "UpdateTime", + "Labels", + "Parent", + }); + internal_static_google_cloud_dataplex_v1_GlossaryTerm_LabelsEntry_descriptor = + internal_static_google_cloud_dataplex_v1_GlossaryTerm_descriptor.getNestedTypes().get(0); + internal_static_google_cloud_dataplex_v1_GlossaryTerm_LabelsEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GlossaryTerm_LabelsEntry_descriptor, + new java.lang.String[] { + "Key", "Value", + }); + internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_descriptor, + new java.lang.String[] { + "Parent", "GlossaryId", "Glossary", "ValidateOnly", + }); + internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_descriptor, + new java.lang.String[] { + "Glossary", "UpdateMask", "ValidateOnly", + }); + internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_descriptor, + new java.lang.String[] { + "Name", "Etag", + }); + internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_descriptor = + getDescriptor().getMessageTypes().get(7); + internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_descriptor = + getDescriptor().getMessageTypes().get(8); + internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_descriptor, + new java.lang.String[] { + "Glossaries", "NextPageToken", "UnreachableLocations", + }); + internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_descriptor = + getDescriptor().getMessageTypes().get(9); + internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_descriptor, + new java.lang.String[] { + "Parent", "CategoryId", "Category", + }); + internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_descriptor, + new java.lang.String[] { + "Category", "UpdateMask", + }); + internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_descriptor = + getDescriptor().getMessageTypes().get(11); + internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_descriptor = + getDescriptor().getMessageTypes().get(12); + internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_descriptor = + getDescriptor().getMessageTypes().get(13); + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_descriptor = + getDescriptor().getMessageTypes().get(14); + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_descriptor, + new java.lang.String[] { + "Categories", "NextPageToken", "UnreachableLocations", + }); + internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_descriptor = + getDescriptor().getMessageTypes().get(15); + internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_descriptor, + new java.lang.String[] { + "Parent", "TermId", "Term", + }); + internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_descriptor = + getDescriptor().getMessageTypes().get(16); + internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_descriptor, + new java.lang.String[] { + "Term", "UpdateMask", + }); + internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_descriptor = + getDescriptor().getMessageTypes().get(17); + internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_descriptor = + getDescriptor().getMessageTypes().get(18); + internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_descriptor = + getDescriptor().getMessageTypes().get(19); + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", "Filter", "OrderBy", + }); + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_descriptor = + getDescriptor().getMessageTypes().get(20); + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_descriptor, + new java.lang.String[] { + "Terms", "NextPageToken", "UnreachableLocations", + }); + 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.FieldInfoProto.fieldInfo); + 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); + com.google.api.AnnotationsProto.getDescriptor(); + com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.FieldInfoProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.dataplex.v1.ServiceProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.EmptyProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); + com.google.protobuf.TimestampProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogProto.java index f3b4eabde44d..7f741c5b5a98 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CatalogProto.java @@ -284,6 +284,26 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dataplex_v1_MetadataJob_LabelsEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_dataplex_v1_MetadataJob_LabelsEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_EntryLink_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_EntryLink_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -616,9 +636,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "le.cloud.dataplex.v1.SearchEntriesResult\022\022\n\n" + "total_size\030\002 \001(\005\022\027\n" + "\017next_page_token\030\003 \001(\t\022\023\n" - + "\013unreachable\030\004 \003(\t\"\202\001\n\n" + + "\013unreachable\030\004 \003(\t\"\273\001\n\n" + "ImportItem\022.\n" - + "\005entry\030\001 \001(\0132\037.google.cloud.dataplex.v1.Entry\022/\n" + + "\005entry\030\001 \001(\0132\037.google.cloud.dataplex.v1.Entry\0227\n\n" + + "entry_link\030\004 \001(\0132#.google.cloud.dataplex.v1.EntryLink\022/\n" + "\013update_mask\030\002 \001(\0132\032.google.protobuf.FieldMask\022\023\n" + "\013aspect_keys\030\003 \003(\t\"\321\001\n" + "\030CreateMetadataJobRequest\0229\n" @@ -644,55 +665,62 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\025unreachable_locations\030\003 \003(\t\"U\n" + "\030CancelMetadataJobRequest\0229\n" + "\004name\030\001 \001(\tB+\340A\002\372A%\n" - + "#dataplex.googleapis.com/MetadataJob\"\203\026\n" + + "#dataplex.googleapis.com/MetadataJob\"\356\027\n" + "\013MetadataJob\022\024\n" + "\004name\030\001 \001(\tB\006\340A\003\340A\010\022\030\n" + "\003uid\030\002 \001(\tB\013\340A\003\342\214\317\327\010\002\010\001\0224\n" + "\013create_time\030\003 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0224\n" + "\013update_time\030\004 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022F\n" - + "\006labels\030\005" - + " \003(\01321.google.cloud.dataplex.v1.MetadataJob.LabelsEntryB\003\340A\001\022=\n" + + "\006labels\030\005 \003(\01321.goo" + + "gle.cloud.dataplex.v1.MetadataJob.LabelsEntryB\003\340A\001\022=\n" + "\004type\030\006" + " \001(\0162*.google.cloud.dataplex.v1.MetadataJob.TypeB\003\340A\002\022J\n" - + "\013import_spec\030d \001(\01323." - + "google.cloud.dataplex.v1.MetadataJob.ImportJobSpecH\000\022J\n" - + "\013export_spec\030e \001(\01323.goog" - + "le.cloud.dataplex.v1.MetadataJob.ExportJobSpecH\000\022T\n\r" - + "import_result\030\310\001 \001(\01325.googl" - + "e.cloud.dataplex.v1.MetadataJob.ImportJobResultB\003\340A\003H\001\022T\n\r" - + "export_result\030\311\001 \001(\01325" - + ".google.cloud.dataplex.v1.MetadataJob.ExportJobResultB\003\340A\003H\001\022A\n" - + "\006status\030\007 \001(\0132,.g" - + "oogle.cloud.dataplex.v1.MetadataJob.StatusB\003\340A\003\032\341\001\n" + + "\013import_spec\030d" + + " \001(\01323.google.cloud.dataplex.v1.MetadataJob.ImportJobSpecH\000\022J\n" + + "\013export_spec\030e" + + " \001(\01323.google.cloud.dataplex.v1.MetadataJob.ExportJobSpecH\000\022T\n\r" + + "import_result\030\310\001" + + " \001(\01325.google.cloud.dataplex.v1.MetadataJob.ImportJobResultB\003\340A\003H\001\022T\n\r" + + "export_result\030\311\001" + + " \001(\01325.google.cloud.dataplex.v1.MetadataJob.ExportJobResultB\003\340A\003H\001\022A\n" + + "\006status\030\007" + + " \001(\0132,.google.cloud.dataplex.v1.MetadataJob.StatusB\003\340A\003\032\311\002\n" + "\017ImportJobResult\022\034\n" + "\017deleted_entries\030\001 \001(\003B\003\340A\003\022\034\n" + "\017updated_entries\030\002 \001(\003B\003\340A\003\022\034\n" + "\017created_entries\030\003 \001(\003B\003\340A\003\022\036\n" + "\021unchanged_entries\030\004 \001(\003B\003\340A\003\022\036\n" + "\021recreated_entries\030\006 \001(\003B\003\340A\003\0224\n" - + "\013update_time\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\032L\n" + + "\013update_time\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022 \n" + + "\023deleted_entry_links\030\007 \001(\003B\003\340A\003\022 \n" + + "\023created_entry_links\030\010 \001(\003B\003\340A\003\022\"\n" + + "\025unchanged_entry_links\030\t \001(\003B\003\340A\003\032L\n" + "\017ExportJobResult\022\035\n" + "\020exported_entries\030\001 \001(\003B\003\340A\003\022\032\n\r" - + "error_message\030\002 \001(\tB\003\340A\003\032\263\006\n\r" + + "error_message\030\002 \001(\tB\003\340A\003\032\266\007\n\r" + "ImportJobSpec\022\037\n" + "\022source_storage_uri\030\001 \001(\tB\003\340A\001\022;\n" + "\022source_create_time\030\005" + " \001(\0132\032.google.protobuf.TimestampB\003\340A\001\022V\n" - + "\005scope\030\002 \001(\013" - + "2B.google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScopeB\003\340A\002\022Z\n" - + "\017entry_sync_mode\030\003 \001(\0162<.google.cloud.datapl" - + "ex.v1.MetadataJob.ImportJobSpec.SyncModeB\003\340A\002\022[\n" - + "\020aspect_sync_mode\030\004 \001(\0162<.google" - + ".cloud.dataplex.v1.MetadataJob.ImportJobSpec.SyncModeB\003\340A\002\022T\n" - + "\tlog_level\030\006 \001(\0162<." - + "google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.LogLevelB\003\340A\001\032\324\001\n" + + "\005scope\030\002 \001(" + + "\0132B.google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScopeB\003\340A\002\022Z\n" + + "\017entry_sync_mode\030\003 \001(\0162<.google.cloud.datap" + + "lex.v1.MetadataJob.ImportJobSpec.SyncModeB\003\340A\002\022[\n" + + "\020aspect_sync_mode\030\004 \001(\0162<.googl" + + "e.cloud.dataplex.v1.MetadataJob.ImportJobSpec.SyncModeB\003\340A\002\022T\n" + + "\tlog_level\030\006 \001(\0162<" + + ".google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.LogLevelB\003\340A\001\032\327\002\n" + "\016ImportJobScope\022@\n" + "\014entry_groups\030\001 \003(\tB*\340A\002\372A$\n" + "\"dataplex.googleapis.com/EntryGroup\022>\n" + "\013entry_types\030\002 \003(\tB)\340A\002\372A#\n" + "!dataplex.googleapis.com/EntryType\022@\n" + "\014aspect_types\030\003 \003(\tB*\340A\001\372A$\n" - + "\"dataplex.googleapis.com/AspectType\"J\n" + + "\"dataplex.googleapis.com/AspectType\022<\n\n" + + "glossaries\030\004 \003(\tB(\340A\001\372A\"\n" + + " dataplex.googleapis.com/Glossary\022\035\n" + + "\020entry_link_types\030\005 \003(\tB\003\340A\001\022$\n" + + "\027referenced_entry_scopes\030\006 \003(\tB\003\340A\001\"J\n" + "\010SyncMode\022\031\n" + "\025SYNC_MODE_UNSPECIFIED\020\000\022\010\n" + "\004FULL\020\001\022\017\n" @@ -703,8 +731,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005DEBUG\020\001\022\010\n" + "\004INFO\020\002\032\257\003\n\r" + "ExportJobSpec\022V\n" - + "\005scope\030\002 \001(\0132B.google.cloud.dataplex.v1.Meta" - + "dataJob.ExportJobSpec.ExportJobScopeB\003\340A\002\022\030\n" + + "\005scope\030\002 \001(\0132B.google.cloud.data" + + "plex.v1.MetadataJob.ExportJobSpec.ExportJobScopeB\003\340A\002\022\030\n" + "\013output_path\030\003 \001(\tB\003\340A\002\032\253\002\n" + "\016ExportJobScope\022\032\n" + "\022organization_level\030\001 \001(\010\022B\n" @@ -717,8 +745,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\014aspect_types\030\005 \003(\tB\'\372A$\n" + "\"dataplex.googleapis.com/AspectType\032\312\002\n" + "\006Status\022F\n" - + "\005state\030\001 \001(\01622.go" - + "ogle.cloud.dataplex.v1.MetadataJob.Status.StateB\003\340A\003\022\024\n" + + "\005state\030\001" + + " \001(\01622.google.cloud.dataplex.v1.MetadataJob.Status.StateB\003\340A\003\022\024\n" + "\007message\030\002 \001(\tB\003\340A\003\022\037\n" + "\022completion_percent\030\003 \001(\005B\003\340A\003\0224\n" + "\013update_time\030\004" @@ -739,10 +767,42 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020TYPE_UNSPECIFIED\020\000\022\n\n" + "\006IMPORT\020\001\022\n\n" + "\006EXPORT\020\002:l\352Ai\n" - + "#dataplex.googleapis.com/Metada" - + "taJob\022Bprojects/{project}/locations/{location}/metadataJobs/{metadataJob}B\006\n" + + "#dataplex.googleapis.com/MetadataJob\022Bprojects/{project}/lo" + + "cations/{location}/metadataJobs/{metadataJob}B\006\n" + "\004specB\010\n" - + "\006result*Q\n" + + "\006result\"\202\005\n" + + "\tEntryLink\022=\n" + + "\004name\030\001 \001(\tB/\340A\003\340A\005\340A\010\372A#\n" + + "!dataplex.googleapis.com/EntryLink\022\037\n" + + "\017entry_link_type\030\002 \001(\tB\006\340A\002\340A\005\0224\n" + + "\013create_time\030\003 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0224\n" + + "\013update_time\030\004 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022Q\n" + + "\020entry_references\030\n" + + " \003(\01322.google.clo" + + "ud.dataplex.v1.EntryLink.EntryReferenceB\003\340A\002\032\271\001\n" + + "\016EntryReference\022\024\n" + + "\004name\030\001 \001(\tB\006\340A\002\340A\005\022\021\n" + + "\004path\030\002 \001(\tB\003\340A\005\022M\n" + + "\004type\030\003 \001(\01627" + + ".google.cloud.dataplex.v1.EntryLink.EntryReference.TypeB\006\340A\002\340A\005\"/\n" + + "\004Type\022\017\n" + + "\013UNSPECIFIED\020\000\022\n\n" + + "\006SOURCE\020\002\022\n\n" + + "\006TARGET\020\003:\231\001\352A\225\001\n" + + "!dataplex.googleapis.com/EntryLink\022Yprojects/{project}/locations/{location}/entr" + + "yGroups/{entry_group}/entryLinks/{entry_link}*\n" + + "entryLinks2\tentryLink\"\256\001\n" + + "\026CreateEntryLinkRequest\022:\n" + + "\006parent\030\001 \001(\tB*\340A\002\372A$\n" + + "\"dataplex.googleapis.com/EntryGroup\022\032\n\r" + + "entry_link_id\030\002 \001(\tB\003\340A\002\022<\n\n" + + "entry_link\030\003 \001(\0132#.google.cloud.dataplex.v1.EntryLinkB\003\340A\002\"Q\n" + + "\026DeleteEntryLinkRequest\0227\n" + + "\004name\030\001 \001(\tB)\340A\002\372A#\n" + + "!dataplex.googleapis.com/EntryLink\"N\n" + + "\023GetEntryLinkRequest\0227\n" + + "\004name\030\001 \001(\tB)\340A\002\372A#\n" + + "!dataplex.googleapis.com/EntryLink*Q\n" + "\tEntryView\022\032\n" + "\026ENTRY_VIEW_UNSPECIFIED\020\000\022\t\n" + "\005BASIC\020\001\022\010\n" @@ -752,132 +812,155 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016TransferStatus\022\037\n" + "\033TRANSFER_STATUS_UNSPECIFIED\020\000\022\034\n" + "\030TRANSFER_STATUS_MIGRATED\020\001\022\037\n" - + "\033TRANSFER_STATUS_TRANSFERRED\020\0022\225)\n" + + "\033TRANSFER_STATUS_TRANSFERRED\020\0022\336-\n" + "\016CatalogService\022\352\001\n" - + "\017CreateEntryType\0220.google.cloud.dataplex.v1.Creat" - + "eEntryTypeRequest\032\035.google.longrunning.Operation\"\205\001\312A\036\n" - + "\tEntryType\022\021OperationMetadata\332A\037parent,entry_type,entry_type_id\202\323" - + "\344\223\002<\"./v1/{parent=projects/*/locations/*}/entryTypes:\n" - + "entry_type\022\354\001\n" - + "\017UpdateEntryType\0220.google.cloud.dataplex.v1.UpdateEn" - + "tryTypeRequest\032\035.google.longrunning.Operation\"\207\001\312A\036\n" + + "\017CreateEntryType\0220.google.cloud.dataplex.v1.CreateEn" + + "tryTypeRequest\032\035.google.longrunning.Operation\"\205\001\312A\036\n" + "\tEntryType\022\021OperationMetadat" - + "a\332A\026entry_type,update_mask\202\323\344\223\002G29/v1/{e" - + "ntry_type.name=projects/*/locations/*/entryTypes/*}:\n" + + "a\332A\037parent,entry_type,entry_type_id\202\323\344\223\002" + + "<\"./v1/{parent=projects/*/locations/*}/entryTypes:\n" + + "entry_type\022\354\001\n" + + "\017UpdateEntryType\0220.google.cloud.dataplex.v1.UpdateEntry" + + "TypeRequest\032\035.google.longrunning.Operation\"\207\001\312A\036\n" + + "\tEntryType\022\021OperationMetadata\332A" + + "\026entry_type,update_mask\202\323\344\223\002G29/v1/{entr" + + "y_type.name=projects/*/locations/*/entryTypes/*}:\n" + "entry_type\022\316\001\n" - + "\017DeleteEntryType\0220.google.cloud.dataplex.v1.DeleteEnt" - + "ryTypeRequest\032\035.google.longrunning.Operation\"j\312A*\n" - + "\025google.protobuf.Empty\022\021Operat" - + "ionMetadata\332A\004name\202\323\344\223\0020*./v1/{name=projects/*/locations/*/entryTypes/*}\022\264\001\n" - + "\016ListEntryTypes\022/.google.cloud.dataplex.v1.L" - + "istEntryTypesRequest\0320.google.cloud.data" - + "plex.v1.ListEntryTypesResponse\"?\332A\006paren" - + "t\202\323\344\223\0020\022./v1/{parent=projects/*/locations/*}/entryTypes\022\241\001\n" - + "\014GetEntryType\022-.google.cloud.dataplex.v1.GetEntryTypeRequest\032" - + "#.google.cloud.dataplex.v1.EntryType\"=\332A" - + "\004name\202\323\344\223\0020\022./v1/{name=projects/*/locations/*/entryTypes/*}\022\361\001\n" - + "\020CreateAspectType\0221.google.cloud.dataplex.v1.CreateAspect" - + "TypeRequest\032\035.google.longrunning.Operation\"\212\001\312A\037\n\n" - + "AspectType\022\021OperationMetadata\332" - + "A!parent,aspect_type,aspect_type_id\202\323\344\223\002" - + ">\"//v1/{parent=projects/*/locations/*}/aspectTypes:\013aspect_type\022\363\001\n" - + "\020UpdateAspectType\0221.google.cloud.dataplex.v1.UpdateAs" - + "pectTypeRequest\032\035.google.longrunning.Operation\"\214\001\312A\037\n\n" - + "AspectType\022\021OperationMetad" - + "ata\332A\027aspect_type,update_mask\202\323\344\223\002J2;/v1" - + "/{aspect_type.name=projects/*/locations/*/aspectTypes/*}:\013aspect_type\022\321\001\n" - + "\020DeleteAspectType\0221.google.cloud.dataplex.v1.De" - + "leteAspectTypeRequest\032\035.google.longrunning.Operation\"k\312A*\n" - + "\025google.protobuf.Empty" - + "\022\021OperationMetadata\332A\004name\202\323\344\223\0021*//v1/{n" - + "ame=projects/*/locations/*/aspectTypes/*}\022\270\001\n" - + "\017ListAspectTypes\0220.google.cloud.dataplex.v1.ListAspectTypesRequest\0321.google" - + ".cloud.dataplex.v1.ListAspectTypesRespon" - + "se\"@\332A\006parent\202\323\344\223\0021\022//v1/{parent=projects/*/locations/*}/aspectTypes\022\245\001\n\r" - + "GetAspectType\022..google.cloud.dataplex.v1.GetAsp" - + "ectTypeRequest\032$.google.cloud.dataplex.v" - + "1.AspectType\">\332A\004name\202\323\344\223\0021\022//v1/{name=projects/*/locations/*/aspectTypes/*}\022\361\001\n" - + "\020CreateEntryGroup\0221.google.cloud.dataple" - + "x.v1.CreateEntryGroupRequest\032\035.google.longrunning.Operation\"\212\001\312A\037\n\n" - + "EntryGroup\022\021OperationMetadata\332A!parent,entry_group,en" - + "try_group_id\202\323\344\223\002>\"//v1/{parent=projects" - + "/*/locations/*}/entryGroups:\013entry_group\022\363\001\n" - + "\020UpdateEntryGroup\0221.google.cloud.dat" - + "aplex.v1.UpdateEntryGroupRequest\032\035.google.longrunning.Operation\"\214\001\312A\037\n\n" - + "EntryGroup\022\021OperationMetadata\332A\027entry_group,updat" - + "e_mask\202\323\344\223\002J2;/v1/{entry_group.name=proj" - + "ects/*/locations/*/entryGroups/*}:\013entry_group\022\321\001\n" - + "\020DeleteEntryGroup\0221.google.cloud.dataplex.v1.DeleteEntryGroupRequest\032\035", - ".google.longrunning.Operation\"k\312A*\n\025goog" - + "le.protobuf.Empty\022\021OperationMetadata\332A\004n" - + "ame\202\323\344\223\0021*//v1/{name=projects/*/location" - + "s/*/entryGroups/*}\022\270\001\n\017ListEntryGroups\0220" - + ".google.cloud.dataplex.v1.ListEntryGroup" - + "sRequest\0321.google.cloud.dataplex.v1.List" - + "EntryGroupsResponse\"@\332A\006parent\202\323\344\223\0021\022//v" - + "1/{parent=projects/*/locations/*}/entryG" - + "roups\022\245\001\n\rGetEntryGroup\022..google.cloud.d" - + "ataplex.v1.GetEntryGroupRequest\032$.google" - + ".cloud.dataplex.v1.EntryGroup\">\332A\004name\202\323" - + "\344\223\0021\022//v1/{name=projects/*/locations/*/e" - + "ntryGroups/*}\022\276\001\n\013CreateEntry\022,.google.c" - + "loud.dataplex.v1.CreateEntryRequest\032\037.go" - + "ogle.cloud.dataplex.v1.Entry\"`\332A\025parent," - + "entry,entry_id\202\323\344\223\002B\"9/v1/{parent=projec" - + "ts/*/locations/*/entryGroups/*}/entries:" - + "\005entry\022\301\001\n\013UpdateEntry\022,.google.cloud.da" - + "taplex.v1.UpdateEntryRequest\032\037.google.cl" - + "oud.dataplex.v1.Entry\"c\332A\021entry,update_m" - + "ask\202\323\344\223\002I2@/v1/{entry.name=projects/*/lo" - + "cations/*/entryGroups/*/entries/**}:\005ent" - + "ry\022\247\001\n\013DeleteEntry\022,.google.cloud.datapl" - + "ex.v1.DeleteEntryRequest\032\037.google.cloud." - + "dataplex.v1.Entry\"I\332A\004name\202\323\344\223\002<*:/v1/{n" - + "ame=projects/*/locations/*/entryGroups/*" - + "/entries/**}\022\266\001\n\013ListEntries\022,.google.cl" - + "oud.dataplex.v1.ListEntriesRequest\032-.goo" - + "gle.cloud.dataplex.v1.ListEntriesRespons" - + "e\"J\332A\006parent\202\323\344\223\002;\0229/v1/{parent=projects" - + "/*/locations/*/entryGroups/*}/entries\022\241\001" - + "\n\010GetEntry\022).google.cloud.dataplex.v1.Ge" - + "tEntryRequest\032\037.google.cloud.dataplex.v1" - + ".Entry\"I\332A\004name\202\323\344\223\002<\022:/v1/{name=project" - + "s/*/locations/*/entryGroups/*/entries/**" - + "}\022\223\001\n\013LookupEntry\022,.google.cloud.dataple" - + "x.v1.LookupEntryRequest\032\037.google.cloud.d" - + "ataplex.v1.Entry\"5\202\323\344\223\002/\022-/v1/{name=proj" - + "ects/*/locations/*}:lookupEntry\022\266\001\n\rSear" - + "chEntries\022..google.cloud.dataplex.v1.Sea" - + "rchEntriesRequest\032/.google.cloud.dataple" - + "x.v1.SearchEntriesResponse\"D\332A\nname,quer" - + "y\202\323\344\223\0021\"//v1/{name=projects/*/locations/" - + "*}:searchEntries\022\370\001\n\021CreateMetadataJob\0222" - + ".google.cloud.dataplex.v1.CreateMetadata" - + "JobRequest\032\035.google.longrunning.Operatio" - + "n\"\217\001\312A \n\013MetadataJob\022\021OperationMetadata\332" - + "A#parent,metadata_job,metadata_job_id\202\323\344" - + "\223\002@\"0/v1/{parent=projects/*/locations/*}" - + "/metadataJobs:\014metadata_job\022\251\001\n\016GetMetad" - + "ataJob\022/.google.cloud.dataplex.v1.GetMet" - + "adataJobRequest\032%.google.cloud.dataplex." - + "v1.MetadataJob\"?\332A\004name\202\323\344\223\0022\0220/v1/{name" - + "=projects/*/locations/*/metadataJobs/*}\022" - + "\274\001\n\020ListMetadataJobs\0221.google.cloud.data" - + "plex.v1.ListMetadataJobsRequest\0322.google" - + ".cloud.dataplex.v1.ListMetadataJobsRespo" - + "nse\"A\332A\006parent\202\323\344\223\0022\0220/v1/{parent=projec" - + "ts/*/locations/*}/metadataJobs\022\252\001\n\021Cance" - + "lMetadataJob\0222.google.cloud.dataplex.v1." - + "CancelMetadataJobRequest\032\026.google.protob" - + "uf.Empty\"I\332A\004name\202\323\344\223\002<\"7/v1/{name=proje" - + "cts/*/locations/*/metadataJobs/*}:cancel" - + ":\001*\032K\312A\027dataplex.googleapis.com\322A.https:" - + "//www.googleapis.com/auth/cloud-platform" - + "B\274\001\n\034com.google.cloud.dataplex.v1B\014Catal" - + "ogProtoP\001Z8cloud.google.com/go/dataplex/" - + "apiv1/dataplexpb;dataplexpb\252\002\030Google.Clo" - + "ud.Dataplex.V1\312\002\030Google\\Cloud\\Dataplex\\V" - + "1\352\002\033Google::Cloud::Dataplex::V1b\006proto3" + + "\017DeleteEntryType\0220.google.cloud.dataplex.v1.DeleteEntryT" + + "ypeRequest\032\035.google.longrunning.Operation\"j\312A*\n" + + "\025google.protobuf.Empty\022\021Operation" + + "Metadata\332A\004name\202\323\344\223\0020*./v1/{name=projects/*/locations/*/entryTypes/*}\022\264\001\n" + + "\016ListEntryTypes\022/.google.cloud.dataplex.v1.List" + + "EntryTypesRequest\0320.google.cloud.dataple" + + "x.v1.ListEntryTypesResponse\"?\332A\006parent\202\323" + + "\344\223\0020\022./v1/{parent=projects/*/locations/*}/entryTypes\022\241\001\n" + + "\014GetEntryType\022-.google.cloud.dataplex.v1.GetEntryTypeRequest\032#.g" + + "oogle.cloud.dataplex.v1.EntryType\"=\332A\004na" + + "me\202\323\344\223\0020\022./v1/{name=projects/*/locations/*/entryTypes/*}\022\361\001\n" + + "\020CreateAspectType\0221.google.cloud.dataplex.v1.CreateAspectTyp" + + "eRequest\032\035.google.longrunning.Operation\"\212\001\312A\037\n\n" + + "AspectType\022\021OperationMetadata\332A!p" + + "arent,aspect_type,aspect_type_id\202\323\344\223\002>\"/" + + "/v1/{parent=projects/*/locations/*}/aspectTypes:\013aspect_type\022\363\001\n" + + "\020UpdateAspectType\0221.google.cloud.dataplex.v1.UpdateAspec" + + "tTypeRequest\032\035.google.longrunning.Operat", + "ion\"\214\001\312A\037\n\nAspectType\022\021OperationMetadata" + + "\332A\027aspect_type,update_mask\202\323\344\223\002J2;/v1/{a" + + "spect_type.name=projects/*/locations/*/a" + + "spectTypes/*}:\013aspect_type\022\321\001\n\020DeleteAsp" + + "ectType\0221.google.cloud.dataplex.v1.Delet" + + "eAspectTypeRequest\032\035.google.longrunning." + + "Operation\"k\312A*\n\025google.protobuf.Empty\022\021O" + + "perationMetadata\332A\004name\202\323\344\223\0021*//v1/{name" + + "=projects/*/locations/*/aspectTypes/*}\022\270" + + "\001\n\017ListAspectTypes\0220.google.cloud.datapl" + + "ex.v1.ListAspectTypesRequest\0321.google.cl" + + "oud.dataplex.v1.ListAspectTypesResponse\"" + + "@\332A\006parent\202\323\344\223\0021\022//v1/{parent=projects/*" + + "/locations/*}/aspectTypes\022\245\001\n\rGetAspectT" + + "ype\022..google.cloud.dataplex.v1.GetAspect" + + "TypeRequest\032$.google.cloud.dataplex.v1.A" + + "spectType\">\332A\004name\202\323\344\223\0021\022//v1/{name=proj" + + "ects/*/locations/*/aspectTypes/*}\022\361\001\n\020Cr" + + "eateEntryGroup\0221.google.cloud.dataplex.v" + + "1.CreateEntryGroupRequest\032\035.google.longr" + + "unning.Operation\"\212\001\312A\037\n\nEntryGroup\022\021Oper" + + "ationMetadata\332A!parent,entry_group,entry" + + "_group_id\202\323\344\223\002>\"//v1/{parent=projects/*/" + + "locations/*}/entryGroups:\013entry_group\022\363\001" + + "\n\020UpdateEntryGroup\0221.google.cloud.datapl" + + "ex.v1.UpdateEntryGroupRequest\032\035.google.l" + + "ongrunning.Operation\"\214\001\312A\037\n\nEntryGroup\022\021" + + "OperationMetadata\332A\027entry_group,update_m" + + "ask\202\323\344\223\002J2;/v1/{entry_group.name=project" + + "s/*/locations/*/entryGroups/*}:\013entry_gr" + + "oup\022\321\001\n\020DeleteEntryGroup\0221.google.cloud." + + "dataplex.v1.DeleteEntryGroupRequest\032\035.go" + + "ogle.longrunning.Operation\"k\312A*\n\025google." + + "protobuf.Empty\022\021OperationMetadata\332A\004name" + + "\202\323\344\223\0021*//v1/{name=projects/*/locations/*" + + "/entryGroups/*}\022\270\001\n\017ListEntryGroups\0220.go" + + "ogle.cloud.dataplex.v1.ListEntryGroupsRe" + + "quest\0321.google.cloud.dataplex.v1.ListEnt" + + "ryGroupsResponse\"@\332A\006parent\202\323\344\223\0021\022//v1/{" + + "parent=projects/*/locations/*}/entryGrou" + + "ps\022\245\001\n\rGetEntryGroup\022..google.cloud.data" + + "plex.v1.GetEntryGroupRequest\032$.google.cl" + + "oud.dataplex.v1.EntryGroup\">\332A\004name\202\323\344\223\002" + + "1\022//v1/{name=projects/*/locations/*/entr" + + "yGroups/*}\022\276\001\n\013CreateEntry\022,.google.clou" + + "d.dataplex.v1.CreateEntryRequest\032\037.googl" + + "e.cloud.dataplex.v1.Entry\"`\332A\025parent,ent" + + "ry,entry_id\202\323\344\223\002B\"9/v1/{parent=projects/" + + "*/locations/*/entryGroups/*}/entries:\005en" + + "try\022\301\001\n\013UpdateEntry\022,.google.cloud.datap" + + "lex.v1.UpdateEntryRequest\032\037.google.cloud" + + ".dataplex.v1.Entry\"c\332A\021entry,update_mask" + + "\202\323\344\223\002I2@/v1/{entry.name=projects/*/locat" + + "ions/*/entryGroups/*/entries/**}:\005entry\022" + + "\247\001\n\013DeleteEntry\022,.google.cloud.dataplex." + + "v1.DeleteEntryRequest\032\037.google.cloud.dat" + + "aplex.v1.Entry\"I\332A\004name\202\323\344\223\002<*:/v1/{name" + + "=projects/*/locations/*/entryGroups/*/en" + + "tries/**}\022\266\001\n\013ListEntries\022,.google.cloud" + + ".dataplex.v1.ListEntriesRequest\032-.google" + + ".cloud.dataplex.v1.ListEntriesResponse\"J" + + "\332A\006parent\202\323\344\223\002;\0229/v1/{parent=projects/*/" + + "locations/*/entryGroups/*}/entries\022\241\001\n\010G" + + "etEntry\022).google.cloud.dataplex.v1.GetEn" + + "tryRequest\032\037.google.cloud.dataplex.v1.En" + + "try\"I\332A\004name\202\323\344\223\002<\022:/v1/{name=projects/*" + + "/locations/*/entryGroups/*/entries/**}\022\223" + + "\001\n\013LookupEntry\022,.google.cloud.dataplex.v" + + "1.LookupEntryRequest\032\037.google.cloud.data" + + "plex.v1.Entry\"5\202\323\344\223\002/\022-/v1/{name=project" + + "s/*/locations/*}:lookupEntry\022\266\001\n\rSearchE" + + "ntries\022..google.cloud.dataplex.v1.Search" + + "EntriesRequest\032/.google.cloud.dataplex.v" + + "1.SearchEntriesResponse\"D\332A\nname,query\202\323" + + "\344\223\0021\"//v1/{name=projects/*/locations/*}:" + + "searchEntries\022\370\001\n\021CreateMetadataJob\0222.go" + + "ogle.cloud.dataplex.v1.CreateMetadataJob" + + "Request\032\035.google.longrunning.Operation\"\217" + + "\001\312A \n\013MetadataJob\022\021OperationMetadata\332A#p" + + "arent,metadata_job,metadata_job_id\202\323\344\223\002@" + + "\"0/v1/{parent=projects/*/locations/*}/me" + + "tadataJobs:\014metadata_job\022\251\001\n\016GetMetadata" + + "Job\022/.google.cloud.dataplex.v1.GetMetada" + + "taJobRequest\032%.google.cloud.dataplex.v1." + + "MetadataJob\"?\332A\004name\202\323\344\223\0022\0220/v1/{name=pr" + + "ojects/*/locations/*/metadataJobs/*}\022\274\001\n" + + "\020ListMetadataJobs\0221.google.cloud.dataple" + + "x.v1.ListMetadataJobsRequest\0322.google.cl" + + "oud.dataplex.v1.ListMetadataJobsResponse" + + "\"A\332A\006parent\202\323\344\223\0022\0220/v1/{parent=projects/" + + "*/locations/*}/metadataJobs\022\252\001\n\021CancelMe" + + "tadataJob\0222.google.cloud.dataplex.v1.Can" + + "celMetadataJobRequest\032\026.google.protobuf." + + "Empty\"I\332A\004name\202\323\344\223\002<\"7/v1/{name=projects" + + "/*/locations/*/metadataJobs/*}:cancel:\001*" + + "\022\334\001\n\017CreateEntryLink\0220.google.cloud.data" + + "plex.v1.CreateEntryLinkRequest\032#.google." + + "cloud.dataplex.v1.EntryLink\"r\332A\037parent,e" + + "ntry_link,entry_link_id\202\323\344\223\002J\"*\022 * * @@ -107,7 +107,7 @@ public java.lang.String getParent() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -714,7 +714,7 @@ public Builder mergeFrom( * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -742,7 +742,7 @@ public java.lang.String getParent() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -770,7 +770,7 @@ public com.google.protobuf.ByteString getParentBytes() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -797,7 +797,7 @@ public Builder setParent(java.lang.String value) { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -820,7 +820,7 @@ public Builder clearParent() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateDataScanRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateDataScanRequestOrBuilder.java index 606eff91a7d0..744ca34a4052 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateDataScanRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateDataScanRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface CreateDataScanRequestOrBuilder * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface CreateDataScanRequestOrBuilder * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequest.java index f2c2dca7e978..2668bac9c826 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequest.java @@ -77,7 +77,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
            * Required. The resource name of the entryGroup, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -105,7 +105,7 @@ public java.lang.String getParent() { *
            * Required. The resource name of the entryGroup, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -699,7 +699,7 @@ public Builder mergeFrom( *
              * Required. The resource name of the entryGroup, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -726,7 +726,7 @@ public java.lang.String getParent() { *
              * Required. The resource name of the entryGroup, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -753,7 +753,7 @@ public com.google.protobuf.ByteString getParentBytes() { *
              * Required. The resource name of the entryGroup, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -779,7 +779,7 @@ public Builder setParent(java.lang.String value) { *
              * Required. The resource name of the entryGroup, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -801,7 +801,7 @@ public Builder clearParent() { *
              * Required. The resource name of the entryGroup, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequestOrBuilder.java index 72d1c5a5e62a..f827826bab11 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryGroupRequestOrBuilder.java @@ -30,7 +30,7 @@ public interface CreateEntryGroupRequestOrBuilder *
            * Required. The resource name of the entryGroup, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -47,7 +47,7 @@ public interface CreateEntryGroupRequestOrBuilder *
            * Required. The resource name of the entryGroup, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryLinkRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryLinkRequest.java new file mode 100644 index 000000000000..0581b4ba8627 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryLinkRequest.java @@ -0,0 +1,1194 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Request message for CreateEntryLink.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateEntryLinkRequest} + */ +public final class CreateEntryLinkRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.CreateEntryLinkRequest) + CreateEntryLinkRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CreateEntryLinkRequest.newBuilder() to construct. + private CreateEntryLinkRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateEntryLinkRequest() { + parent_ = ""; + entryLinkId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateEntryLinkRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest.class, + com.google.cloud.dataplex.v1.CreateEntryLinkRequest.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 parent Entry Group:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +   * 
        + * + * + * 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 parent Entry Group:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +   * 
        + * + * + * 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 ENTRY_LINK_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object entryLinkId_ = ""; + + /** + * + * + *
        +   * Required. Entry Link identifier
        +   * * Must contain only lowercase letters, numbers and hyphens.
        +   * * Must start with a letter.
        +   * * Must be between 1-63 characters.
        +   * * Must end with a number or a letter.
        +   * * Must be unique within the EntryGroup.
        +   * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The entryLinkId. + */ + @java.lang.Override + public java.lang.String getEntryLinkId() { + java.lang.Object ref = entryLinkId_; + 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(); + entryLinkId_ = s; + return s; + } + } + + /** + * + * + *
        +   * Required. Entry Link identifier
        +   * * Must contain only lowercase letters, numbers and hyphens.
        +   * * Must start with a letter.
        +   * * Must be between 1-63 characters.
        +   * * Must end with a number or a letter.
        +   * * Must be unique within the EntryGroup.
        +   * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for entryLinkId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEntryLinkIdBytes() { + java.lang.Object ref = entryLinkId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + entryLinkId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int ENTRY_LINK_FIELD_NUMBER = 3; + private com.google.cloud.dataplex.v1.EntryLink entryLink_; + + /** + * + * + *
        +   * Required. Entry Link resource.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the entryLink field is set. + */ + @java.lang.Override + public boolean hasEntryLink() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. Entry Link resource.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The entryLink. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink getEntryLink() { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } + + /** + * + * + *
        +   * Required. Entry Link resource.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLinkOrBuilder getEntryLinkOrBuilder() { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } + + 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entryLinkId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, entryLinkId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getEntryLink()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entryLinkId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, entryLinkId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getEntryLink()); + } + 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.dataplex.v1.CreateEntryLinkRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.CreateEntryLinkRequest other = + (com.google.cloud.dataplex.v1.CreateEntryLinkRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getEntryLinkId().equals(other.getEntryLinkId())) return false; + if (hasEntryLink() != other.hasEntryLink()) return false; + if (hasEntryLink()) { + if (!getEntryLink().equals(other.getEntryLink())) 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) + ENTRY_LINK_ID_FIELD_NUMBER; + hash = (53 * hash) + getEntryLinkId().hashCode(); + if (hasEntryLink()) { + hash = (37 * hash) + ENTRY_LINK_FIELD_NUMBER; + hash = (53 * hash) + getEntryLink().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest 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.dataplex.v1.CreateEntryLinkRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest 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.dataplex.v1.CreateEntryLinkRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.CreateEntryLinkRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Request message for CreateEntryLink.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateEntryLinkRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.CreateEntryLinkRequest) + com.google.cloud.dataplex.v1.CreateEntryLinkRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateEntryLinkRequest.class, + com.google.cloud.dataplex.v1.CreateEntryLinkRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.CreateEntryLinkRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getEntryLinkFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + entryLinkId_ = ""; + entryLink_ = null; + if (entryLinkBuilder_ != null) { + entryLinkBuilder_.dispose(); + entryLinkBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_CreateEntryLinkRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateEntryLinkRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.CreateEntryLinkRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateEntryLinkRequest build() { + com.google.cloud.dataplex.v1.CreateEntryLinkRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateEntryLinkRequest buildPartial() { + com.google.cloud.dataplex.v1.CreateEntryLinkRequest result = + new com.google.cloud.dataplex.v1.CreateEntryLinkRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.CreateEntryLinkRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.entryLinkId_ = entryLinkId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.entryLink_ = entryLinkBuilder_ == null ? entryLink_ : entryLinkBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.CreateEntryLinkRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.CreateEntryLinkRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.CreateEntryLinkRequest other) { + if (other == com.google.cloud.dataplex.v1.CreateEntryLinkRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getEntryLinkId().isEmpty()) { + entryLinkId_ = other.entryLinkId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasEntryLink()) { + mergeEntryLink(other.getEntryLink()); + } + 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: + { + entryLinkId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(getEntryLinkFieldBuilder().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 parent Entry Group:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +     * 
        + * + * + * 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 parent Entry Group:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +     * 
        + * + * + * 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 parent Entry Group:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +     * 
        + * + * + * 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 parent Entry Group:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +     * 
        + * + * + * 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 parent Entry Group:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +     * 
        + * + * + * 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 entryLinkId_ = ""; + + /** + * + * + *
        +     * Required. Entry Link identifier
        +     * * Must contain only lowercase letters, numbers and hyphens.
        +     * * Must start with a letter.
        +     * * Must be between 1-63 characters.
        +     * * Must end with a number or a letter.
        +     * * Must be unique within the EntryGroup.
        +     * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The entryLinkId. + */ + public java.lang.String getEntryLinkId() { + java.lang.Object ref = entryLinkId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + entryLinkId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +     * Required. Entry Link identifier
        +     * * Must contain only lowercase letters, numbers and hyphens.
        +     * * Must start with a letter.
        +     * * Must be between 1-63 characters.
        +     * * Must end with a number or a letter.
        +     * * Must be unique within the EntryGroup.
        +     * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for entryLinkId. + */ + public com.google.protobuf.ByteString getEntryLinkIdBytes() { + java.lang.Object ref = entryLinkId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + entryLinkId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +     * Required. Entry Link identifier
        +     * * Must contain only lowercase letters, numbers and hyphens.
        +     * * Must start with a letter.
        +     * * Must be between 1-63 characters.
        +     * * Must end with a number or a letter.
        +     * * Must be unique within the EntryGroup.
        +     * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The entryLinkId to set. + * @return This builder for chaining. + */ + public Builder setEntryLinkId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + entryLinkId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Entry Link identifier
        +     * * Must contain only lowercase letters, numbers and hyphens.
        +     * * Must start with a letter.
        +     * * Must be between 1-63 characters.
        +     * * Must end with a number or a letter.
        +     * * Must be unique within the EntryGroup.
        +     * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearEntryLinkId() { + entryLinkId_ = getDefaultInstance().getEntryLinkId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Entry Link identifier
        +     * * Must contain only lowercase letters, numbers and hyphens.
        +     * * Must start with a letter.
        +     * * Must be between 1-63 characters.
        +     * * Must end with a number or a letter.
        +     * * Must be unique within the EntryGroup.
        +     * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for entryLinkId to set. + * @return This builder for chaining. + */ + public Builder setEntryLinkIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + entryLinkId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.dataplex.v1.EntryLink entryLink_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink, + com.google.cloud.dataplex.v1.EntryLink.Builder, + com.google.cloud.dataplex.v1.EntryLinkOrBuilder> + entryLinkBuilder_; + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the entryLink field is set. + */ + public boolean hasEntryLink() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The entryLink. + */ + public com.google.cloud.dataplex.v1.EntryLink getEntryLink() { + if (entryLinkBuilder_ == null) { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } else { + return entryLinkBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setEntryLink(com.google.cloud.dataplex.v1.EntryLink value) { + if (entryLinkBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + entryLink_ = value; + } else { + entryLinkBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setEntryLink(com.google.cloud.dataplex.v1.EntryLink.Builder builderForValue) { + if (entryLinkBuilder_ == null) { + entryLink_ = builderForValue.build(); + } else { + entryLinkBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeEntryLink(com.google.cloud.dataplex.v1.EntryLink value) { + if (entryLinkBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && entryLink_ != null + && entryLink_ != com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance()) { + getEntryLinkBuilder().mergeFrom(value); + } else { + entryLink_ = value; + } + } else { + entryLinkBuilder_.mergeFrom(value); + } + if (entryLink_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearEntryLink() { + bitField0_ = (bitField0_ & ~0x00000004); + entryLink_ = null; + if (entryLinkBuilder_ != null) { + entryLinkBuilder_.dispose(); + entryLinkBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLink.Builder getEntryLinkBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return getEntryLinkFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLinkOrBuilder getEntryLinkOrBuilder() { + if (entryLinkBuilder_ != null) { + return entryLinkBuilder_.getMessageOrBuilder(); + } else { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } + } + + /** + * + * + *
        +     * Required. Entry Link resource.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink, + com.google.cloud.dataplex.v1.EntryLink.Builder, + com.google.cloud.dataplex.v1.EntryLinkOrBuilder> + getEntryLinkFieldBuilder() { + if (entryLinkBuilder_ == null) { + entryLinkBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink, + com.google.cloud.dataplex.v1.EntryLink.Builder, + com.google.cloud.dataplex.v1.EntryLinkOrBuilder>( + getEntryLink(), getParentForChildren(), isClean()); + entryLink_ = null; + } + return entryLinkBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.CreateEntryLinkRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.CreateEntryLinkRequest) + private static final com.google.cloud.dataplex.v1.CreateEntryLinkRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.CreateEntryLinkRequest(); + } + + public static com.google.cloud.dataplex.v1.CreateEntryLinkRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateEntryLinkRequest 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.dataplex.v1.CreateEntryLinkRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryLinkRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryLinkRequestOrBuilder.java new file mode 100644 index 000000000000..b0a70942ddba --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateEntryLinkRequestOrBuilder.java @@ -0,0 +1,137 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface CreateEntryLinkRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.CreateEntryLinkRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The resource name of the parent Entry Group:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +   * 
        + * + * + * 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 parent Entry Group:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
        +   * Required. Entry Link identifier
        +   * * Must contain only lowercase letters, numbers and hyphens.
        +   * * Must start with a letter.
        +   * * Must be between 1-63 characters.
        +   * * Must end with a number or a letter.
        +   * * Must be unique within the EntryGroup.
        +   * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The entryLinkId. + */ + java.lang.String getEntryLinkId(); + + /** + * + * + *
        +   * Required. Entry Link identifier
        +   * * Must contain only lowercase letters, numbers and hyphens.
        +   * * Must start with a letter.
        +   * * Must be between 1-63 characters.
        +   * * Must end with a number or a letter.
        +   * * Must be unique within the EntryGroup.
        +   * 
        + * + * string entry_link_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for entryLinkId. + */ + com.google.protobuf.ByteString getEntryLinkIdBytes(); + + /** + * + * + *
        +   * Required. Entry Link resource.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the entryLink field is set. + */ + boolean hasEntryLink(); + + /** + * + * + *
        +   * Required. Entry Link resource.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The entryLink. + */ + com.google.cloud.dataplex.v1.EntryLink getEntryLink(); + + /** + * + * + *
        +   * Required. Entry Link resource.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.EntryLinkOrBuilder getEntryLinkOrBuilder(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryCategoryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryCategoryRequest.java new file mode 100644 index 000000000000..29a45df848b4 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryCategoryRequest.java @@ -0,0 +1,1175 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Creates a new GlossaryCategory under the specified Glossary.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateGlossaryCategoryRequest} + */ +public final class CreateGlossaryCategoryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) + CreateGlossaryCategoryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CreateGlossaryCategoryRequest.newBuilder() to construct. + private CreateGlossaryCategoryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateGlossaryCategoryRequest() { + parent_ = ""; + categoryId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateGlossaryCategoryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.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 where this GlossaryCategory will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `locationId` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 GlossaryCategory will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `locationId` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 CATEGORY_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object categoryId_ = ""; + + /** + * + * + *
        +   * Required. GlossaryCategory identifier.
        +   * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The categoryId. + */ + @java.lang.Override + public java.lang.String getCategoryId() { + java.lang.Object ref = categoryId_; + 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(); + categoryId_ = s; + return s; + } + } + + /** + * + * + *
        +   * Required. GlossaryCategory identifier.
        +   * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for categoryId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCategoryIdBytes() { + java.lang.Object ref = categoryId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + categoryId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int CATEGORY_FIELD_NUMBER = 3; + private com.google.cloud.dataplex.v1.GlossaryCategory category_; + + /** + * + * + *
        +   * Required. The GlossaryCategory to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the category field is set. + */ + @java.lang.Override + public boolean hasCategory() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. The GlossaryCategory to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The category. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategory getCategory() { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } + + /** + * + * + *
        +   * Required. The GlossaryCategory to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoryOrBuilder() { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } + + 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(categoryId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, categoryId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getCategory()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(categoryId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, categoryId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCategory()); + } + 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.dataplex.v1.CreateGlossaryCategoryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest other = + (com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getCategoryId().equals(other.getCategoryId())) return false; + if (hasCategory() != other.hasCategory()) return false; + if (hasCategory()) { + if (!getCategory().equals(other.getCategory())) 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) + CATEGORY_ID_FIELD_NUMBER; + hash = (53 * hash) + getCategoryId().hashCode(); + if (hasCategory()) { + hash = (37 * hash) + CATEGORY_FIELD_NUMBER; + hash = (53 * hash) + getCategory().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest 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.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest 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.dataplex.v1.CreateGlossaryCategoryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.CreateGlossaryCategoryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Creates a new GlossaryCategory under the specified Glossary.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateGlossaryCategoryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCategoryFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + categoryId_ = ""; + category_ = null; + if (categoryBuilder_ != null) { + categoryBuilder_.dispose(); + categoryBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest build() { + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest buildPartial() { + com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest result = + new com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.categoryId_ = categoryId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.category_ = categoryBuilder_ == null ? category_ : categoryBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest other) { + if (other == com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getCategoryId().isEmpty()) { + categoryId_ = other.categoryId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasCategory()) { + mergeCategory(other.getCategory()); + } + 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: + { + categoryId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(getCategoryFieldBuilder().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 parent resource where this GlossaryCategory will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `locationId` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 GlossaryCategory will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `locationId` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 GlossaryCategory will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `locationId` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 GlossaryCategory will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `locationId` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 GlossaryCategory will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `locationId` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 categoryId_ = ""; + + /** + * + * + *
        +     * Required. GlossaryCategory identifier.
        +     * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The categoryId. + */ + public java.lang.String getCategoryId() { + java.lang.Object ref = categoryId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + categoryId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +     * Required. GlossaryCategory identifier.
        +     * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for categoryId. + */ + public com.google.protobuf.ByteString getCategoryIdBytes() { + java.lang.Object ref = categoryId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + categoryId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +     * Required. GlossaryCategory identifier.
        +     * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The categoryId to set. + * @return This builder for chaining. + */ + public Builder setCategoryId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + categoryId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. GlossaryCategory identifier.
        +     * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearCategoryId() { + categoryId_ = getDefaultInstance().getCategoryId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. GlossaryCategory identifier.
        +     * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for categoryId to set. + * @return This builder for chaining. + */ + public Builder setCategoryIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + categoryId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.dataplex.v1.GlossaryCategory category_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder> + categoryBuilder_; + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the category field is set. + */ + public boolean hasCategory() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The category. + */ + public com.google.cloud.dataplex.v1.GlossaryCategory getCategory() { + if (categoryBuilder_ == null) { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } else { + return categoryBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setCategory(com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + category_ = value; + } else { + categoryBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setCategory( + com.google.cloud.dataplex.v1.GlossaryCategory.Builder builderForValue) { + if (categoryBuilder_ == null) { + category_ = builderForValue.build(); + } else { + categoryBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeCategory(com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoryBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && category_ != null + && category_ != com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance()) { + getCategoryBuilder().mergeFrom(value); + } else { + category_ = value; + } + } else { + categoryBuilder_.mergeFrom(value); + } + if (category_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearCategory() { + bitField0_ = (bitField0_ & ~0x00000004); + category_ = null; + if (categoryBuilder_ != null) { + categoryBuilder_.dispose(); + categoryBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryCategory.Builder getCategoryBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return getCategoryFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoryOrBuilder() { + if (categoryBuilder_ != null) { + return categoryBuilder_.getMessageOrBuilder(); + } else { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder> + getCategoryFieldBuilder() { + if (categoryBuilder_ == null) { + categoryBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder>( + getCategory(), getParentForChildren(), isClean()); + category_ = null; + } + return categoryBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) + private static final com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest(); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateGlossaryCategoryRequest 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.dataplex.v1.CreateGlossaryCategoryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryCategoryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryCategoryRequestOrBuilder.java new file mode 100644 index 000000000000..460dbd2e8361 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryCategoryRequestOrBuilder.java @@ -0,0 +1,131 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface CreateGlossaryCategoryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.CreateGlossaryCategoryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The parent resource where this GlossaryCategory will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `locationId` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 GlossaryCategory will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `locationId` refers to a Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
        +   * Required. GlossaryCategory identifier.
        +   * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The categoryId. + */ + java.lang.String getCategoryId(); + + /** + * + * + *
        +   * Required. GlossaryCategory identifier.
        +   * 
        + * + * string category_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for categoryId. + */ + com.google.protobuf.ByteString getCategoryIdBytes(); + + /** + * + * + *
        +   * Required. The GlossaryCategory to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the category field is set. + */ + boolean hasCategory(); + + /** + * + * + *
        +   * Required. The GlossaryCategory to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The category. + */ + com.google.cloud.dataplex.v1.GlossaryCategory getCategory(); + + /** + * + * + *
        +   * Required. The GlossaryCategory to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoryOrBuilder(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryRequest.java new file mode 100644 index 000000000000..cf42b5b68778 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryRequest.java @@ -0,0 +1,1267 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Create Glossary Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateGlossaryRequest} + */ +public final class CreateGlossaryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.CreateGlossaryRequest) + CreateGlossaryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CreateGlossaryRequest.newBuilder() to construct. + private CreateGlossaryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateGlossaryRequest() { + parent_ = ""; + glossaryId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateGlossaryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateGlossaryRequest.class, + com.google.cloud.dataplex.v1.CreateGlossaryRequest.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 where this Glossary will be created.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 Glossary will be created.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 GLOSSARY_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object glossaryId_ = ""; + + /** + * + * + *
        +   * Required. Glossary ID: Glossary identifier.
        +   * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The glossaryId. + */ + @java.lang.Override + public java.lang.String getGlossaryId() { + java.lang.Object ref = glossaryId_; + 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(); + glossaryId_ = s; + return s; + } + } + + /** + * + * + *
        +   * Required. Glossary ID: Glossary identifier.
        +   * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for glossaryId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getGlossaryIdBytes() { + java.lang.Object ref = glossaryId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + glossaryId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int GLOSSARY_FIELD_NUMBER = 3; + private com.google.cloud.dataplex.v1.Glossary glossary_; + + /** + * + * + *
        +   * Required. The Glossary to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the glossary field is set. + */ + @java.lang.Override + public boolean hasGlossary() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. The Glossary to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The glossary. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.Glossary getGlossary() { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } + + /** + * + * + *
        +   * Required. The Glossary to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossaryOrBuilder() { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; + private boolean validateOnly_ = false; + + /** + * + * + *
        +   * Optional. Validates the request without actually creating the Glossary.
        +   * Default: false.
        +   * 
        + * + * bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(glossaryId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, glossaryId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getGlossary()); + } + if (validateOnly_ != false) { + output.writeBool(4, validateOnly_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(glossaryId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, glossaryId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getGlossary()); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); + } + 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.dataplex.v1.CreateGlossaryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.CreateGlossaryRequest other = + (com.google.cloud.dataplex.v1.CreateGlossaryRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getGlossaryId().equals(other.getGlossaryId())) return false; + if (hasGlossary() != other.hasGlossary()) return false; + if (hasGlossary()) { + if (!getGlossary().equals(other.getGlossary())) return false; + } + if (getValidateOnly() != other.getValidateOnly()) 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) + GLOSSARY_ID_FIELD_NUMBER; + hash = (53 * hash) + getGlossaryId().hashCode(); + if (hasGlossary()) { + hash = (37 * hash) + GLOSSARY_FIELD_NUMBER; + hash = (53 * hash) + getGlossary().hashCode(); + } + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest 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.dataplex.v1.CreateGlossaryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest 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.dataplex.v1.CreateGlossaryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.CreateGlossaryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Create Glossary Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateGlossaryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.CreateGlossaryRequest) + com.google.cloud.dataplex.v1.CreateGlossaryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateGlossaryRequest.class, + com.google.cloud.dataplex.v1.CreateGlossaryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.CreateGlossaryRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getGlossaryFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + glossaryId_ = ""; + glossary_ = null; + if (glossaryBuilder_ != null) { + glossaryBuilder_.dispose(); + glossaryBuilder_ = null; + } + validateOnly_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.CreateGlossaryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryRequest build() { + com.google.cloud.dataplex.v1.CreateGlossaryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryRequest buildPartial() { + com.google.cloud.dataplex.v1.CreateGlossaryRequest result = + new com.google.cloud.dataplex.v1.CreateGlossaryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.CreateGlossaryRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.glossaryId_ = glossaryId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.glossary_ = glossaryBuilder_ == null ? glossary_ : glossaryBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.validateOnly_ = validateOnly_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.CreateGlossaryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.CreateGlossaryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.CreateGlossaryRequest other) { + if (other == com.google.cloud.dataplex.v1.CreateGlossaryRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getGlossaryId().isEmpty()) { + glossaryId_ = other.glossaryId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasGlossary()) { + mergeGlossary(other.getGlossary()); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + 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: + { + glossaryId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(getGlossaryFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 32: + { + validateOnly_ = input.readBool(); + 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 parent_ = ""; + + /** + * + * + *
        +     * Required. The parent resource where this Glossary will be created.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 Glossary will be created.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 Glossary will be created.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 Glossary will be created.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 Glossary will be created.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 glossaryId_ = ""; + + /** + * + * + *
        +     * Required. Glossary ID: Glossary identifier.
        +     * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The glossaryId. + */ + public java.lang.String getGlossaryId() { + java.lang.Object ref = glossaryId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + glossaryId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +     * Required. Glossary ID: Glossary identifier.
        +     * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for glossaryId. + */ + public com.google.protobuf.ByteString getGlossaryIdBytes() { + java.lang.Object ref = glossaryId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + glossaryId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +     * Required. Glossary ID: Glossary identifier.
        +     * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The glossaryId to set. + * @return This builder for chaining. + */ + public Builder setGlossaryId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + glossaryId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Glossary ID: Glossary identifier.
        +     * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearGlossaryId() { + glossaryId_ = getDefaultInstance().getGlossaryId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Glossary ID: Glossary identifier.
        +     * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for glossaryId to set. + * @return This builder for chaining. + */ + public Builder setGlossaryIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + glossaryId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.dataplex.v1.Glossary glossary_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder> + glossaryBuilder_; + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the glossary field is set. + */ + public boolean hasGlossary() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The glossary. + */ + public com.google.cloud.dataplex.v1.Glossary getGlossary() { + if (glossaryBuilder_ == null) { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } else { + return glossaryBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGlossary(com.google.cloud.dataplex.v1.Glossary value) { + if (glossaryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + glossary_ = value; + } else { + glossaryBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGlossary(com.google.cloud.dataplex.v1.Glossary.Builder builderForValue) { + if (glossaryBuilder_ == null) { + glossary_ = builderForValue.build(); + } else { + glossaryBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeGlossary(com.google.cloud.dataplex.v1.Glossary value) { + if (glossaryBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && glossary_ != null + && glossary_ != com.google.cloud.dataplex.v1.Glossary.getDefaultInstance()) { + getGlossaryBuilder().mergeFrom(value); + } else { + glossary_ = value; + } + } else { + glossaryBuilder_.mergeFrom(value); + } + if (glossary_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearGlossary() { + bitField0_ = (bitField0_ & ~0x00000004); + glossary_ = null; + if (glossaryBuilder_ != null) { + glossaryBuilder_.dispose(); + glossaryBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.Glossary.Builder getGlossaryBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return getGlossaryFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossaryOrBuilder() { + if (glossaryBuilder_ != null) { + return glossaryBuilder_.getMessageOrBuilder(); + } else { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } + } + + /** + * + * + *
        +     * Required. The Glossary to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder> + getGlossaryFieldBuilder() { + if (glossaryBuilder_ == null) { + glossaryBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder>( + getGlossary(), getParentForChildren(), isClean()); + glossary_ = null; + } + return glossaryBuilder_; + } + + private boolean validateOnly_; + + /** + * + * + *
        +     * Optional. Validates the request without actually creating the Glossary.
        +     * Default: false.
        +     * 
        + * + * bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + /** + * + * + *
        +     * Optional. Validates the request without actually creating the Glossary.
        +     * Default: false.
        +     * 
        + * + * bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. Validates the request without actually creating the Glossary.
        +     * Default: false.
        +     * 
        + * + * bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + bitField0_ = (bitField0_ & ~0x00000008); + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.CreateGlossaryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.CreateGlossaryRequest) + private static final com.google.cloud.dataplex.v1.CreateGlossaryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.CreateGlossaryRequest(); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateGlossaryRequest 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.dataplex.v1.CreateGlossaryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryRequestOrBuilder.java new file mode 100644 index 000000000000..b46f0d7ddfae --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryRequestOrBuilder.java @@ -0,0 +1,143 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface CreateGlossaryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.CreateGlossaryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The parent resource where this Glossary will be created.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 Glossary will be created.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
        +   * Required. Glossary ID: Glossary identifier.
        +   * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The glossaryId. + */ + java.lang.String getGlossaryId(); + + /** + * + * + *
        +   * Required. Glossary ID: Glossary identifier.
        +   * 
        + * + * string glossary_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for glossaryId. + */ + com.google.protobuf.ByteString getGlossaryIdBytes(); + + /** + * + * + *
        +   * Required. The Glossary to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the glossary field is set. + */ + boolean hasGlossary(); + + /** + * + * + *
        +   * Required. The Glossary to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The glossary. + */ + com.google.cloud.dataplex.v1.Glossary getGlossary(); + + /** + * + * + *
        +   * Required. The Glossary to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossaryOrBuilder(); + + /** + * + * + *
        +   * Optional. Validates the request without actually creating the Glossary.
        +   * Default: false.
        +   * 
        + * + * bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryTermRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryTermRequest.java new file mode 100644 index 000000000000..e7c3453414a2 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryTermRequest.java @@ -0,0 +1,1170 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Creates a new GlossaryTerm under the specified Glossary.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateGlossaryTermRequest} + */ +public final class CreateGlossaryTermRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.CreateGlossaryTermRequest) + CreateGlossaryTermRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CreateGlossaryTermRequest.newBuilder() to construct. + private CreateGlossaryTermRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateGlossaryTermRequest() { + parent_ = ""; + termId_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateGlossaryTermRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.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 where the GlossaryTerm will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 the GlossaryTerm will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 TERM_ID_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object termId_ = ""; + + /** + * + * + *
        +   * Required. GlossaryTerm identifier.
        +   * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The termId. + */ + @java.lang.Override + public java.lang.String getTermId() { + java.lang.Object ref = termId_; + 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(); + termId_ = s; + return s; + } + } + + /** + * + * + *
        +   * Required. GlossaryTerm identifier.
        +   * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for termId. + */ + @java.lang.Override + public com.google.protobuf.ByteString getTermIdBytes() { + java.lang.Object ref = termId_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + termId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TERM_FIELD_NUMBER = 3; + private com.google.cloud.dataplex.v1.GlossaryTerm term_; + + /** + * + * + *
        +   * Required. The GlossaryTerm to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the term field is set. + */ + @java.lang.Override + public boolean hasTerm() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. The GlossaryTerm to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The term. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTerm getTerm() { + return term_ == null ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() : term_; + } + + /** + * + * + *
        +   * Required. The GlossaryTerm to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermOrBuilder() { + return term_ == null ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() : term_; + } + + 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(termId_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, termId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getTerm()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(termId_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, termId_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTerm()); + } + 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.dataplex.v1.CreateGlossaryTermRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest other = + (com.google.cloud.dataplex.v1.CreateGlossaryTermRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (!getTermId().equals(other.getTermId())) return false; + if (hasTerm() != other.hasTerm()) return false; + if (hasTerm()) { + if (!getTerm().equals(other.getTerm())) 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) + TERM_ID_FIELD_NUMBER; + hash = (53 * hash) + getTermId().hashCode(); + if (hasTerm()) { + hash = (37 * hash) + TERM_FIELD_NUMBER; + hash = (53 * hash) + getTerm().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest 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.dataplex.v1.CreateGlossaryTermRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest 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.dataplex.v1.CreateGlossaryTermRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.CreateGlossaryTermRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Creates a new GlossaryTerm under the specified Glossary.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.CreateGlossaryTermRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.CreateGlossaryTermRequest) + com.google.cloud.dataplex.v1.CreateGlossaryTermRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getTermFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + parent_ = ""; + termId_ = ""; + term_ = null; + if (termBuilder_ != null) { + termBuilder_.dispose(); + termBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_CreateGlossaryTermRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryTermRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryTermRequest build() { + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.CreateGlossaryTermRequest buildPartial() { + com.google.cloud.dataplex.v1.CreateGlossaryTermRequest result = + new com.google.cloud.dataplex.v1.CreateGlossaryTermRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.CreateGlossaryTermRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.parent_ = parent_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.termId_ = termId_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.term_ = termBuilder_ == null ? term_ : termBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.CreateGlossaryTermRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.CreateGlossaryTermRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.CreateGlossaryTermRequest other) { + if (other == com.google.cloud.dataplex.v1.CreateGlossaryTermRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getTermId().isEmpty()) { + termId_ = other.termId_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasTerm()) { + mergeTerm(other.getTerm()); + } + 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: + { + termId_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(getTermFieldBuilder().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 parent resource where the GlossaryTerm will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 the GlossaryTerm will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 the GlossaryTerm will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 the GlossaryTerm will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 the GlossaryTerm will be created.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 termId_ = ""; + + /** + * + * + *
        +     * Required. GlossaryTerm identifier.
        +     * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The termId. + */ + public java.lang.String getTermId() { + java.lang.Object ref = termId_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + termId_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +     * Required. GlossaryTerm identifier.
        +     * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for termId. + */ + public com.google.protobuf.ByteString getTermIdBytes() { + java.lang.Object ref = termId_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + termId_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +     * Required. GlossaryTerm identifier.
        +     * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The termId to set. + * @return This builder for chaining. + */ + public Builder setTermId(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + termId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. GlossaryTerm identifier.
        +     * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearTermId() { + termId_ = getDefaultInstance().getTermId(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. GlossaryTerm identifier.
        +     * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for termId to set. + * @return This builder for chaining. + */ + public Builder setTermIdBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + termId_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.cloud.dataplex.v1.GlossaryTerm term_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder> + termBuilder_; + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the term field is set. + */ + public boolean hasTerm() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The term. + */ + public com.google.cloud.dataplex.v1.GlossaryTerm getTerm() { + if (termBuilder_ == null) { + return term_ == null + ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() + : term_; + } else { + return termBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTerm(com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + term_ = value; + } else { + termBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTerm(com.google.cloud.dataplex.v1.GlossaryTerm.Builder builderForValue) { + if (termBuilder_ == null) { + term_ = builderForValue.build(); + } else { + termBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeTerm(com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && term_ != null + && term_ != com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance()) { + getTermBuilder().mergeFrom(value); + } else { + term_ = value; + } + } else { + termBuilder_.mergeFrom(value); + } + if (term_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearTerm() { + bitField0_ = (bitField0_ & ~0x00000004); + term_ = null; + if (termBuilder_ != null) { + termBuilder_.dispose(); + termBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryTerm.Builder getTermBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return getTermFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermOrBuilder() { + if (termBuilder_ != null) { + return termBuilder_.getMessageOrBuilder(); + } else { + return term_ == null + ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() + : term_; + } + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to create.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder> + getTermFieldBuilder() { + if (termBuilder_ == null) { + termBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder>( + getTerm(), getParentForChildren(), isClean()); + term_ = null; + } + return termBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.CreateGlossaryTermRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.CreateGlossaryTermRequest) + private static final com.google.cloud.dataplex.v1.CreateGlossaryTermRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.CreateGlossaryTermRequest(); + } + + public static com.google.cloud.dataplex.v1.CreateGlossaryTermRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateGlossaryTermRequest 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.dataplex.v1.CreateGlossaryTermRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryTermRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryTermRequestOrBuilder.java new file mode 100644 index 000000000000..8b8db829660a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateGlossaryTermRequestOrBuilder.java @@ -0,0 +1,131 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface CreateGlossaryTermRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.CreateGlossaryTermRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The parent resource where the GlossaryTerm will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
        +   * Required. The parent resource where the GlossaryTerm will be created.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
        +   * Required. GlossaryTerm identifier.
        +   * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The termId. + */ + java.lang.String getTermId(); + + /** + * + * + *
        +   * Required. GlossaryTerm identifier.
        +   * 
        + * + * string term_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for termId. + */ + com.google.protobuf.ByteString getTermIdBytes(); + + /** + * + * + *
        +   * Required. The GlossaryTerm to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the term field is set. + */ + boolean hasTerm(); + + /** + * + * + *
        +   * Required. The GlossaryTerm to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The term. + */ + com.google.cloud.dataplex.v1.GlossaryTerm getTerm(); + + /** + * + * + *
        +   * Required. The GlossaryTerm to create.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 3 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermOrBuilder(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequest.java index f7a4992f7c0c..aec22b0ffd4d 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequest.java @@ -77,7 +77,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
            * Required. The resource name of the lake location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -105,7 +105,7 @@ public java.lang.String getParent() { *
            * Required. The resource name of the lake location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -702,7 +702,7 @@ public Builder mergeFrom( *
              * Required. The resource name of the lake location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -729,7 +729,7 @@ public java.lang.String getParent() { *
              * Required. The resource name of the lake location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -756,7 +756,7 @@ public com.google.protobuf.ByteString getParentBytes() { *
              * Required. The resource name of the lake location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -782,7 +782,7 @@ public Builder setParent(java.lang.String value) { *
              * Required. The resource name of the lake location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -804,7 +804,7 @@ public Builder clearParent() { *
              * Required. The resource name of the lake location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequestOrBuilder.java index 24b969ec4678..7944f8484a24 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/CreateLakeRequestOrBuilder.java @@ -30,7 +30,7 @@ public interface CreateLakeRequestOrBuilder *
            * Required. The resource name of the lake location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -47,7 +47,7 @@ public interface CreateLakeRequestOrBuilder *
            * Required. The resource name of the lake location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoveryProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoveryProto.java index ece2a263a451..f3326bca28d7 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoveryProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoveryProto.java @@ -69,66 +69,59 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { static { java.lang.String[] descriptorData = { - "\n" - + "-google/cloud/dataplex/v1/data_discover" + "\n-google/cloud/dataplex/v1/data_discover" + "y.proto\022\030google.cloud.dataplex.v1\032\037googl" - + "e/api/field_behavior.proto\032\031google/api/resource.proto\"\205\010\n" - + "\021DataDiscoverySpec\022m\n" - + "\032bigquery_publishing_config\030\001 \001(\0132D.google" - + ".cloud.dataplex.v1.DataDiscoverySpec.BigQueryPublishingConfigB\003\340A\001\022S\n" - + "\016storage_config\030d" - + " \001(\01329.google.cloud.dataplex.v1.DataDiscoverySpec.StorageConfigH\000\032\250\002\n" - + "\030BigQueryPublishingConfig\022g\n\n" - + "table_type\030\002 \001(\0162N.google.cloud.dataplex.v1.DataDiscover" - + "ySpec.BigQueryPublishingConfig.TableTypeB\003\340A\001\022H\n\n" - + "connection\030\003 \001(\tB4\340A\001\372A.\n" - + ",bigqueryconnection.googleapis.com/Connection\022\025\n" - + "\010location\030\004 \001(\tB\003\340A\001\"B\n" - + "\tTableType\022\032\n" - + "\026TABLE_TYPE_UNSPECIFIED\020\000\022\014\n" - + "\010EXTERNAL\020\001\022\013\n" - + "\007BIGLAKE\020\002\032\355\003\n\r" - + "StorageConfig\022\035\n" - + "\020include_patterns\030\001 \003(\tB\003\340A\001\022\035\n" - + "\020exclude_patterns\030\002 \003(\tB\003\340A\001\022^\n" - + "\013csv_options\030\003 \001(\0132D.google" - + ".cloud.dataplex.v1.DataDiscoverySpec.StorageConfig.CsvOptionsB\003\340A\001\022`\n" - + "\014json_options\030\004 \001(\0132E.google.cloud.dataplex.v1.Data" - + "DiscoverySpec.StorageConfig.JsonOptionsB\003\340A\001\032\217\001\n\n" - + "CsvOptions\022\030\n" - + "\013header_rows\030\001 \001(\005B\003\340A\001\022\026\n" - + "\tdelimiter\030\002 \001(\tB\003\340A\001\022\025\n" - + "\010encoding\030\003 \001(\tB\003\340A\001\022$\n" - + "\027type_inference_disabled\030\004 \001(\010B\003\340A\001\022\022\n" - + "\005quote\030\005 \001(\tB\003\340A\001\032J\n" - + "\013JsonOptions\022\025\n" - + "\010encoding\030\001 \001(\tB\003\340A\001\022$\n" - + "\027type_inference_disabled\030\002 \001(\010B\003\340A\001B\021\n" - + "\017resource_config\"\267\004\n" - + "\023DataDiscoveryResult\022b\n" - + "\023bigquery_publishing\030\001 \001(\0132@.google.cloud.datapl" - + "ex.v1.DataDiscoveryResult.BigQueryPublishingB\003\340A\003\022Z\n" - + "\017scan_statistics\030\002 \001(\0132<.goo" - + "gle.cloud.dataplex.v1.DataDiscoveryResult.ScanStatisticsB\003\340A\003\032e\n" - + "\022BigQueryPublishing\0228\n" - + "\007dataset\030\001 \001(\tB\'\340A\003\372A!\n" - + "\037bigquery.googleapis.com/Dataset\022\025\n" - + "\010location\030\002 \001(\tB\003\340A\003\032\370\001\n" - + "\016ScanStatistics\022\032\n" - + "\022scanned_file_count\030\001 \001(\005\022\034\n" - + "\024data_processed_bytes\030\002 \001(\003\022\026\n" - + "\016files_excluded\030\003 \001(\005\022\026\n" - + "\016tables_created\030\004 \001(\005\022\026\n" - + "\016tables_deleted\030\005 \001(\005\022\026\n" - + "\016tables_updated\030\006 \001(\005\022\030\n" - + "\020filesets_created\030\007 \001(\005\022\030\n" - + "\020filesets_deleted\030\010 \001(\005\022\030\n" - + "\020filesets_updated\030\t \001(\005B\254\002\n" - + "\034com.google.cloud.dataplex.v1B\022DataDiscoveryProtoP\001Z8cloud.go" - + "ogle.com/go/dataplex/apiv1/dataplexpb;dataplexpb\352AH\n" - + "\037bigquery.googleapis.com/Dataset\022%projects/{project}/datasets/{dataset}\352Ap\n" - + ",bigqueryconnection.googleapis.com/Connection\022@projects/{project}/locatio" - + "ns/{location}/connections/{connection}b\006proto3" + + "e/api/field_behavior.proto\032\031google/api/r" + + "esource.proto\"\313\010\n\021DataDiscoverySpec\022m\n\032b" + + "igquery_publishing_config\030\001 \001(\0132D.google" + + ".cloud.dataplex.v1.DataDiscoverySpec.Big" + + "QueryPublishingConfigB\003\340A\001\022S\n\016storage_co" + + "nfig\030d \001(\01329.google.cloud.dataplex.v1.Da" + + "taDiscoverySpec.StorageConfigH\000\032\356\002\n\030BigQ" + + "ueryPublishingConfig\022g\n\ntable_type\030\002 \001(\016" + + "2N.google.cloud.dataplex.v1.DataDiscover" + + "ySpec.BigQueryPublishingConfig.TableType" + + "B\003\340A\001\022H\n\nconnection\030\003 \001(\tB4\340A\001\372A.\n,bigqu" + + "eryconnection.googleapis.com/Connection\022" + + "\025\n\010location\030\004 \001(\tB\003\340A\001\022D\n\007project\030\005 \001(\tB" + + "3\340A\001\372A-\n+cloudresourcemanager.googleapis" + + ".com/Project\"B\n\tTableType\022\032\n\026TABLE_TYPE_" + + "UNSPECIFIED\020\000\022\014\n\010EXTERNAL\020\001\022\013\n\007BIGLAKE\020\002" + + "\032\355\003\n\rStorageConfig\022\035\n\020include_patterns\030\001" + + " \003(\tB\003\340A\001\022\035\n\020exclude_patterns\030\002 \003(\tB\003\340A\001" + + "\022^\n\013csv_options\030\003 \001(\0132D.google.cloud.dat" + + "aplex.v1.DataDiscoverySpec.StorageConfig" + + ".CsvOptionsB\003\340A\001\022`\n\014json_options\030\004 \001(\0132E" + + ".google.cloud.dataplex.v1.DataDiscoveryS" + + "pec.StorageConfig.JsonOptionsB\003\340A\001\032\217\001\n\nC" + + "svOptions\022\030\n\013header_rows\030\001 \001(\005B\003\340A\001\022\026\n\td" + + "elimiter\030\002 \001(\tB\003\340A\001\022\025\n\010encoding\030\003 \001(\tB\003\340" + + "A\001\022$\n\027type_inference_disabled\030\004 \001(\010B\003\340A\001" + + "\022\022\n\005quote\030\005 \001(\tB\003\340A\001\032J\n\013JsonOptions\022\025\n\010e" + + "ncoding\030\001 \001(\tB\003\340A\001\022$\n\027type_inference_dis" + + "abled\030\002 \001(\010B\003\340A\001B\021\n\017resource_config\"\267\004\n\023" + + "DataDiscoveryResult\022b\n\023bigquery_publishi" + + "ng\030\001 \001(\0132@.google.cloud.dataplex.v1.Data" + + "DiscoveryResult.BigQueryPublishingB\003\340A\003\022" + + "Z\n\017scan_statistics\030\002 \001(\0132<.google.cloud." + + "dataplex.v1.DataDiscoveryResult.ScanStat" + + "isticsB\003\340A\003\032e\n\022BigQueryPublishing\0228\n\007dat" + + "aset\030\001 \001(\tB\'\340A\003\372A!\n\037bigquery.googleapis." + + "com/Dataset\022\025\n\010location\030\002 \001(\tB\003\340A\003\032\370\001\n\016S" + + "canStatistics\022\032\n\022scanned_file_count\030\001 \001(" + + "\005\022\034\n\024data_processed_bytes\030\002 \001(\003\022\026\n\016files" + + "_excluded\030\003 \001(\005\022\026\n\016tables_created\030\004 \001(\005\022" + + "\026\n\016tables_deleted\030\005 \001(\005\022\026\n\016tables_update" + + "d\030\006 \001(\005\022\030\n\020filesets_created\030\007 \001(\005\022\030\n\020fil" + + "esets_deleted\030\010 \001(\005\022\030\n\020filesets_updated\030" + + "\t \001(\005B\254\002\n\034com.google.cloud.dataplex.v1B\022" + + "DataDiscoveryProtoP\001Z8cloud.google.com/g" + + "o/dataplex/apiv1/dataplexpb;dataplexpb\352A" + + "H\n\037bigquery.googleapis.com/Dataset\022%proj" + + "ects/{project}/datasets/{dataset}\352Ap\n,bi" + + "gqueryconnection.googleapis.com/Connecti" + + "on\022@projects/{project}/locations/{locati" + + "on}/connections/{connection}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -153,7 +146,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_dataplex_v1_DataDiscoverySpec_BigQueryPublishingConfig_descriptor, new java.lang.String[] { - "TableType", "Connection", "Location", + "TableType", "Connection", "Location", "Project", }); internal_static_google_cloud_dataplex_v1_DataDiscoverySpec_StorageConfig_descriptor = internal_static_google_cloud_dataplex_v1_DataDiscoverySpec_descriptor diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoverySpec.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoverySpec.java index e609bc63455d..9028a884901b 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoverySpec.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataDiscoverySpec.java @@ -199,6 +199,42 @@ public interface BigQueryPublishingConfigOrBuilder * @return The bytes for location. */ com.google.protobuf.ByteString getLocationBytes(); + + /** + * + * + *
        +     * Optional. The project of the BigQuery dataset to publish BigLake external
        +     * or non-BigLake external tables to. If not specified, the project of the
        +     * Cloud Storage bucket will be used. The format is
        +     * "projects/{project_id_or_number}".
        +     * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The project. + */ + java.lang.String getProject(); + + /** + * + * + *
        +     * Optional. The project of the BigQuery dataset to publish BigLake external
        +     * or non-BigLake external tables to. If not specified, the project of the
        +     * Cloud Storage bucket will be used. The format is
        +     * "projects/{project_id_or_number}".
        +     * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for project. + */ + com.google.protobuf.ByteString getProjectBytes(); } /** @@ -225,6 +261,7 @@ private BigQueryPublishingConfig() { tableType_ = 0; connection_ = ""; location_ = ""; + project_ = ""; } @java.lang.Override @@ -622,6 +659,69 @@ public com.google.protobuf.ByteString getLocationBytes() { } } + public static final int PROJECT_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private volatile java.lang.Object project_ = ""; + + /** + * + * + *
        +     * Optional. The project of the BigQuery dataset to publish BigLake external
        +     * or non-BigLake external tables to. If not specified, the project of the
        +     * Cloud Storage bucket will be used. The format is
        +     * "projects/{project_id_or_number}".
        +     * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The project. + */ + @java.lang.Override + public java.lang.String getProject() { + java.lang.Object ref = project_; + 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(); + project_ = s; + return s; + } + } + + /** + * + * + *
        +     * Optional. The project of the BigQuery dataset to publish BigLake external
        +     * or non-BigLake external tables to. If not specified, the project of the
        +     * Cloud Storage bucket will be used. The format is
        +     * "projects/{project_id_or_number}".
        +     * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for project. + */ + @java.lang.Override + public com.google.protobuf.ByteString getProjectBytes() { + java.lang.Object ref = project_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + project_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -648,6 +748,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, location_); } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(project_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, project_); + } getUnknownFields().writeTo(output); } @@ -669,6 +772,9 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, location_); } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(project_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, project_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -689,6 +795,7 @@ public boolean equals(final java.lang.Object obj) { if (tableType_ != other.tableType_) return false; if (!getConnection().equals(other.getConnection())) return false; if (!getLocation().equals(other.getLocation())) return false; + if (!getProject().equals(other.getProject())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -706,6 +813,8 @@ public int hashCode() { hash = (53 * hash) + getConnection().hashCode(); hash = (37 * hash) + LOCATION_FIELD_NUMBER; hash = (53 * hash) + getLocation().hashCode(); + hash = (37 * hash) + PROJECT_FIELD_NUMBER; + hash = (53 * hash) + getProject().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -855,6 +964,7 @@ public Builder clear() { tableType_ = 0; connection_ = ""; location_ = ""; + project_ = ""; return this; } @@ -905,6 +1015,9 @@ private void buildPartial0( if (((from_bitField0_ & 0x00000004) != 0)) { result.location_ = location_; } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.project_ = project_; + } } @java.lang.Override @@ -972,6 +1085,11 @@ public Builder mergeFrom( bitField0_ |= 0x00000004; onChanged(); } + if (!other.getProject().isEmpty()) { + project_ = other.project_; + bitField0_ |= 0x00000008; + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1016,6 +1134,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000004; break; } // case 34 + case 42: + { + project_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 42 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1493,6 +1617,142 @@ public Builder setLocationBytes(com.google.protobuf.ByteString value) { return this; } + private java.lang.Object project_ = ""; + + /** + * + * + *
        +       * Optional. The project of the BigQuery dataset to publish BigLake external
        +       * or non-BigLake external tables to. If not specified, the project of the
        +       * Cloud Storage bucket will be used. The format is
        +       * "projects/{project_id_or_number}".
        +       * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The project. + */ + public java.lang.String getProject() { + java.lang.Object ref = project_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + project_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +       * Optional. The project of the BigQuery dataset to publish BigLake external
        +       * or non-BigLake external tables to. If not specified, the project of the
        +       * Cloud Storage bucket will be used. The format is
        +       * "projects/{project_id_or_number}".
        +       * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for project. + */ + public com.google.protobuf.ByteString getProjectBytes() { + java.lang.Object ref = project_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + project_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +       * Optional. The project of the BigQuery dataset to publish BigLake external
        +       * or non-BigLake external tables to. If not specified, the project of the
        +       * Cloud Storage bucket will be used. The format is
        +       * "projects/{project_id_or_number}".
        +       * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The project to set. + * @return This builder for chaining. + */ + public Builder setProject(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + project_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +       * Optional. The project of the BigQuery dataset to publish BigLake external
        +       * or non-BigLake external tables to. If not specified, the project of the
        +       * Cloud Storage bucket will be used. The format is
        +       * "projects/{project_id_or_number}".
        +       * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearProject() { + project_ = getDefaultInstance().getProject(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + return this; + } + + /** + * + * + *
        +       * Optional. The project of the BigQuery dataset to publish BigLake external
        +       * or non-BigLake external tables to. If not specified, the project of the
        +       * Cloud Storage bucket will be used. The format is
        +       * "projects/{project_id_or_number}".
        +       * 
        + * + * + * string project = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for project to set. + * @return This builder for chaining. + */ + public Builder setProjectBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + project_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileProto.java index 91ea457acf9c..e58e27e9bf7e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileProto.java @@ -112,69 +112,71 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016BigQueryExport\022\032\n\r" + "results_table\030\001 \001(\tB\003\340A\001\032*\n" + "\016SelectedFields\022\030\n" - + "\013field_names\030\001 \003(\tB\003\340A\001\"\344\r\n" - + "\021DataProfileResult\022\021\n" - + "\trow_count\030\003 \001(\003\022D\n" - + "\007profile\030\004 \001(\013" - + "23.google.cloud.dataplex.v1.DataProfileResult.Profile\022;\n" - + "\014scanned_data\030\005 \001(\0132%.google.cloud.dataplex.v1.ScannedData\022h\n" - + "\030post_scan_actions_result\030\006 \001(\0132A.google.cl" - + "oud.dataplex.v1.DataProfileResult.PostScanActionsResultB\003\340A\003\032\316\010\n" - + "\007Profile\022I\n" - + "\006fields\030\002" - + " \003(\01329.google.cloud.dataplex.v1.DataProfileResult.Profile.Field\032\367\007\n" - + "\005Field\022\014\n" - + "\004name\030\001 \001(\t\022\014\n" - + "\004type\030\002 \001(\t\022\014\n" - + "\004mode\030\003 \001(\t\022V\n" - + "\007profile\030\004 \001(\0132E.google.cloud.dataplex" - + ".v1.DataProfileResult.Profile.Field.ProfileInfo\032\353\006\n" - + "\013ProfileInfo\022\022\n\n" - + "null_ratio\030\002 \001(\001\022\026\n" - + "\016distinct_ratio\030\003 \001(\001\022e\n" - + "\014top_n_values\030\004 \003(\0132O.google.cloud.dataplex.v1.Dat" - + "aProfileResult.Profile.Field.ProfileInfo.TopNValue\022o\n" - + "\016string_profile\030e \001(\0132U.google.cloud.dataplex.v1.DataProfileResult." - + "Profile.Field.ProfileInfo.StringFieldInfoH\000\022q\n" - + "\017integer_profile\030f \001(\0132V.google.cloud.dataplex.v1.DataProfileResult.Profil" - + "e.Field.ProfileInfo.IntegerFieldInfoH\000\022o\n" - + "\016double_profile\030g \001(\0132U.google.cloud.da" - + "taplex.v1.DataProfileResult.Profile.Field.ProfileInfo.DoubleFieldInfoH\000\032Q\n" - + "\017StringFieldInfo\022\022\n\n" - + "min_length\030\001 \001(\003\022\022\n\n" - + "max_length\030\002 \001(\003\022\026\n" - + "\016average_length\030\003 \001(\001\032l\n" - + "\020IntegerFieldInfo\022\017\n" - + "\007average\030\001 \001(\001\022\032\n" - + "\022standard_deviation\030\003 \001(\001\022\013\n" - + "\003min\030\004 \001(\003\022\021\n" - + "\tquartiles\030\006 \003(\003\022\013\n" - + "\003max\030\005 \001(\003\032k\n" - + "\017DoubleFieldInfo\022\017\n" - + "\007average\030\001 \001(\001\022\032\n" - + "\022standard_deviation\030\003 \001(\001\022\013\n" - + "\003min\030\004 \001(\001\022\021\n" - + "\tquartiles\030\006 \003(\001\022\013\n" - + "\003max\030\005 \001(\001\0328\n" - + "\tTopNValue\022\r\n" - + "\005value\030\001 \001(\t\022\r\n" - + "\005count\030\002 \001(\003\022\r\n" - + "\005ratio\030\003 \001(\001B\014\n\n" + + "\013field_names\030\001 \003(\tB\003\340A\001\"\355\016\n" + + "\021DataProfileResult\022\026\n" + + "\trow_count\030\003 \001(\003B\003\340A\003\022I\n" + + "\007profile\030\004" + + " \001(\01323.google.cloud.dataplex.v1.DataProfileResult.ProfileB\003\340A\003\022@\n" + + "\014scanned_data\030\005" + + " \001(\0132%.google.cloud.dataplex.v1.ScannedDataB\003\340A\003\022h\n" + + "\030post_scan_actions_result\030\006 " + + "\001(\0132A.google.cloud.dataplex.v1.DataProfileResult.PostScanActionsResultB\003\340A\003\032\310" + + "\t\n" + + "\007Profile\022N\n" + + "\006fields\030\002 \003(\01329.google.cloud.d" + + "ataplex.v1.DataProfileResult.Profile.FieldB\003\340A\003\032\354\010\n" + + "\005Field\022\021\n" + + "\004name\030\001 \001(\tB\003\340A\003\022\021\n" + + "\004type\030\002 \001(\tB\003\340A\003\022\021\n" + + "\004mode\030\003 \001(\tB\003\340A\003\022[\n" + + "\007profile\030\004 \001(\0132E.google.cloud.dataplex.v1.D" + + "ataProfileResult.Profile.Field.ProfileInfoB\003\340A\003\032\314\007\n" + + "\013ProfileInfo\022\027\n\n" + + "null_ratio\030\002 \001(\001B\003\340A\003\022\033\n" + + "\016distinct_ratio\030\003 \001(\001B\003\340A\003\022j\n" + + "\014top_n_values\030\004 \003(\0132O.google.cloud.datap" + + "lex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValueB\003\340A\003\022o\n" + + "\016string_profile\030e \001(\0132U.google.cloud.dataplex.v1.Dat" + + "aProfileResult.Profile.Field.ProfileInfo.StringFieldInfoH\000\022q\n" + + "\017integer_profile\030f \001(\0132V.google.cloud.dataplex.v1.DataProfi" + + "leResult.Profile.Field.ProfileInfo.IntegerFieldInfoH\000\022o\n" + + "\016double_profile\030g \001(\0132U.google.cloud.dataplex.v1.DataProfileResu" + + "lt.Profile.Field.ProfileInfo.DoubleFieldInfoH\000\032`\n" + + "\017StringFieldInfo\022\027\n\n" + + "min_length\030\001 \001(\003B\003\340A\003\022\027\n\n" + + "max_length\030\002 \001(\003B\003\340A\003\022\033\n" + + "\016average_length\030\003 \001(\001B\003\340A\003\032\205\001\n" + + "\020IntegerFieldInfo\022\024\n" + + "\007average\030\001 \001(\001B\003\340A\003\022\037\n" + + "\022standard_deviation\030\003 \001(\001B\003\340A\003\022\020\n" + + "\003min\030\004 \001(\003B\003\340A\003\022\026\n" + + "\tquartiles\030\006 \003(\003B\003\340A\003\022\020\n" + + "\003max\030\005 \001(\003B\003\340A\003\032\204\001\n" + + "\017DoubleFieldInfo\022\024\n" + + "\007average\030\001 \001(\001B\003\340A\003\022\037\n" + + "\022standard_deviation\030\003 \001(\001B\003\340A\003\022\020\n" + + "\003min\030\004 \001(\001B\003\340A\003\022\026\n" + + "\tquartiles\030\006 \003(\001B\003\340A\003\022\020\n" + + "\003max\030\005 \001(\001B\003\340A\003\032G\n" + + "\tTopNValue\022\022\n" + + "\005value\030\001 \001(\tB\003\340A\003\022\022\n" + + "\005count\030\002 \001(\003B\003\340A\003\022\022\n" + + "\005ratio\030\003 \001(\001B\003\340A\003B\014\n\n" + "field_info\032\375\002\n" + "\025PostScanActionsResult\022{\n" - + "\026bigquery_export_result\030\001 \001(\0132V.google.cloud.d" - + "ataplex.v1.DataProfileResult.PostScanActionsResult.BigQueryExportResultB\003\340A\003\032\346\001\n" + + "\026bigquery_export_result\030\001 \001(\0132V.google.cloud.dataplex.v1.DataProfileR" + + "esult.PostScanActionsResult.BigQueryExportResultB\003\340A\003\032\346\001\n" + "\024BigQueryExportResult\022p\n" - + "\005state\030\001 \001(\0162\\.google.cloud.dataplex.v1.DataProfileResul" - + "t.PostScanActionsResult.BigQueryExportResult.StateB\003\340A\003\022\024\n" + + "\005state\030\001 \001(\0162\\.google.cloud.dataplex.v1" + + ".DataProfileResult.PostScanActionsResult.BigQueryExportResult.StateB\003\340A\003\022\024\n" + "\007message\030\002 \001(\tB\003\340A\003\"F\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\r\n" + "\tSUCCEEDED\020\001\022\n\n" + "\006FAILED\020\002\022\013\n" + "\007SKIPPED\020\003Bl\n" - + "\034com.google.cloud.dataplex.v1B\020DataProfileProtoP" - + "\001Z8cloud.google.com/go/dataplex/apiv1/dataplexpb;dataplexpbb\006proto3" + + "\034com.google.cloud.dataplex.v1B\020DataProfileProtoP\001Z8cloud.google.com/go/" + + "dataplex/apiv1/dataplexpb;dataplexpbb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResult.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResult.java index eb5aec220d30..e10f4f54130a 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResult.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResult.java @@ -72,10 +72,13 @@ public interface ProfileOrBuilder * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ java.util.List getFieldsList(); @@ -83,10 +86,13 @@ public interface ProfileOrBuilder * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field getFields(int index); @@ -94,10 +100,13 @@ public interface ProfileOrBuilder * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ int getFieldsCount(); @@ -105,10 +114,13 @@ public interface ProfileOrBuilder * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ java.util.List getFieldsOrBuilderList(); @@ -117,10 +129,13 @@ public interface ProfileOrBuilder * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.dataplex.v1.DataProfileResult.Profile.FieldOrBuilder getFieldsOrBuilder( int index); @@ -180,10 +195,10 @@ public interface FieldOrBuilder * * *
        -       * The name of the field.
        +       * Output only. The name of the field.
                * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @@ -193,10 +208,10 @@ public interface FieldOrBuilder * * *
        -       * The name of the field.
        +       * Output only. The name of the field.
                * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ @@ -206,14 +221,15 @@ public interface FieldOrBuilder * * *
        -       * The data type retrieved from the schema of the data source. For
        -       * instance, for a BigQuery native table, it is the [BigQuery Table
        +       * Output only. The data type retrieved from the schema of the data
        +       * source. For instance, for a BigQuery native table, it is the [BigQuery
        +       * Table
                * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -       * For a Dataplex Entity, it is the [Entity
        +       * For a Dataplex Universal Catalog Entity, it is the [Entity
                * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The type. */ @@ -223,14 +239,15 @@ public interface FieldOrBuilder * * *
        -       * The data type retrieved from the schema of the data source. For
        -       * instance, for a BigQuery native table, it is the [BigQuery Table
        +       * Output only. The data type retrieved from the schema of the data
        +       * source. For instance, for a BigQuery native table, it is the [BigQuery
        +       * Table
                * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -       * For a Dataplex Entity, it is the [Entity
        +       * For a Dataplex Universal Catalog Entity, it is the [Entity
                * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for type. */ @@ -240,14 +257,14 @@ public interface FieldOrBuilder * * *
        -       * The mode of the field. Possible values include:
        +       * Output only. The mode of the field. Possible values include:
                *
                * * REQUIRED, if it is a required field.
                * * NULLABLE, if it is an optional field.
                * * REPEATED, if it is a repeated field.
                * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The mode. */ @@ -257,14 +274,14 @@ public interface FieldOrBuilder * * *
        -       * The mode of the field. Possible values include:
        +       * Output only. The mode of the field. Possible values include:
                *
                * * REQUIRED, if it is a required field.
                * * NULLABLE, if it is an optional field.
                * * REPEATED, if it is a repeated field.
                * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for mode. */ @@ -274,10 +291,11 @@ public interface FieldOrBuilder * * *
        -       * Profile information for the corresponding field.
        +       * Output only. Profile information for the corresponding field.
                * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the profile field is set. @@ -288,10 +306,11 @@ public interface FieldOrBuilder * * *
        -       * Profile information for the corresponding field.
        +       * Output only. Profile information for the corresponding field.
                * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The profile. @@ -302,10 +321,11 @@ public interface FieldOrBuilder * * *
        -       * Profile information for the corresponding field.
        +       * Output only. Profile information for the corresponding field.
                * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfoOrBuilder @@ -368,10 +388,11 @@ public interface ProfileInfoOrBuilder * * *
        -         * Ratio of rows with null value against total scanned rows.
        +         * Output only. Ratio of rows with null value against total scanned
        +         * rows.
                  * 
        * - * double null_ratio = 2; + * double null_ratio = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The nullRatio. */ @@ -381,12 +402,13 @@ public interface ProfileInfoOrBuilder * * *
        -         * Ratio of rows with distinct values against total scanned rows.
        -         * Not available for complex non-groupable field type, including RECORD,
        -         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. Ratio of rows with distinct values against total scanned
        +         * rows. Not available for complex non-groupable field type, including
        +         * RECORD, ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE
        +         * mode.
                  * 
        * - * double distinct_ratio = 3; + * double distinct_ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The distinctRatio. */ @@ -396,15 +418,15 @@ public interface ProfileInfoOrBuilder * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ java.util.List< @@ -415,15 +437,15 @@ public interface ProfileInfoOrBuilder * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue @@ -433,15 +455,15 @@ public interface ProfileInfoOrBuilder * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ int getTopNValuesCount(); @@ -450,15 +472,15 @@ public interface ProfileInfoOrBuilder * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ java.util.List< @@ -471,15 +493,15 @@ public interface ProfileInfoOrBuilder * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValueOrBuilder @@ -682,10 +704,10 @@ public interface StringFieldInfoOrBuilder * * *
        -           * Minimum length of non-null values in the scanned data.
        +           * Output only. Minimum length of non-null values in the scanned data.
                    * 
        * - * int64 min_length = 1; + * int64 min_length = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The minLength. */ @@ -695,10 +717,10 @@ public interface StringFieldInfoOrBuilder * * *
        -           * Maximum length of non-null values in the scanned data.
        +           * Output only. Maximum length of non-null values in the scanned data.
                    * 
        * - * int64 max_length = 2; + * int64 max_length = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The maxLength. */ @@ -708,10 +730,10 @@ public interface StringFieldInfoOrBuilder * * *
        -           * Average length of non-null values in the scanned data.
        +           * Output only. Average length of non-null values in the scanned data.
                    * 
        * - * double average_length = 3; + * double average_length = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The averageLength. */ @@ -771,10 +793,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -           * Minimum length of non-null values in the scanned data.
        +           * Output only. Minimum length of non-null values in the scanned data.
                    * 
        * - * int64 min_length = 1; + * int64 min_length = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The minLength. */ @@ -790,10 +812,10 @@ public long getMinLength() { * * *
        -           * Maximum length of non-null values in the scanned data.
        +           * Output only. Maximum length of non-null values in the scanned data.
                    * 
        * - * int64 max_length = 2; + * int64 max_length = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The maxLength. */ @@ -809,10 +831,10 @@ public long getMaxLength() { * * *
        -           * Average length of non-null values in the scanned data.
        +           * Output only. Average length of non-null values in the scanned data.
                    * 
        * - * double average_length = 3; + * double average_length = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The averageLength. */ @@ -1282,10 +1304,10 @@ public Builder mergeFrom( * * *
        -             * Minimum length of non-null values in the scanned data.
        +             * Output only. Minimum length of non-null values in the scanned data.
                      * 
        * - * int64 min_length = 1; + * int64 min_length = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The minLength. */ @@ -1298,10 +1320,10 @@ public long getMinLength() { * * *
        -             * Minimum length of non-null values in the scanned data.
        +             * Output only. Minimum length of non-null values in the scanned data.
                      * 
        * - * int64 min_length = 1; + * int64 min_length = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The minLength to set. * @return This builder for chaining. @@ -1318,10 +1340,10 @@ public Builder setMinLength(long value) { * * *
        -             * Minimum length of non-null values in the scanned data.
        +             * Output only. Minimum length of non-null values in the scanned data.
                      * 
        * - * int64 min_length = 1; + * int64 min_length = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -1338,10 +1360,10 @@ public Builder clearMinLength() { * * *
        -             * Maximum length of non-null values in the scanned data.
        +             * Output only. Maximum length of non-null values in the scanned data.
                      * 
        * - * int64 max_length = 2; + * int64 max_length = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The maxLength. */ @@ -1354,10 +1376,10 @@ public long getMaxLength() { * * *
        -             * Maximum length of non-null values in the scanned data.
        +             * Output only. Maximum length of non-null values in the scanned data.
                      * 
        * - * int64 max_length = 2; + * int64 max_length = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The maxLength to set. * @return This builder for chaining. @@ -1374,10 +1396,10 @@ public Builder setMaxLength(long value) { * * *
        -             * Maximum length of non-null values in the scanned data.
        +             * Output only. Maximum length of non-null values in the scanned data.
                      * 
        * - * int64 max_length = 2; + * int64 max_length = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -1394,10 +1416,10 @@ public Builder clearMaxLength() { * * *
        -             * Average length of non-null values in the scanned data.
        +             * Output only. Average length of non-null values in the scanned data.
                      * 
        * - * double average_length = 3; + * double average_length = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The averageLength. */ @@ -1410,10 +1432,10 @@ public double getAverageLength() { * * *
        -             * Average length of non-null values in the scanned data.
        +             * Output only. Average length of non-null values in the scanned data.
                      * 
        * - * double average_length = 3; + * double average_length = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The averageLength to set. * @return This builder for chaining. @@ -1430,10 +1452,10 @@ public Builder setAverageLength(double value) { * * *
        -             * Average length of non-null values in the scanned data.
        +             * Output only. Average length of non-null values in the scanned data.
                      * 
        * - * double average_length = 3; + * double average_length = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -1525,11 +1547,11 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * Average of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Average of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The average. */ @@ -1539,11 +1561,12 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * Standard deviation of non-null values in the scanned data. NaN, if
        -           * the field has a NaN.
        +           * Output only. Standard deviation of non-null values in the scanned
        +           * data. NaN, if the field has a NaN.
                    * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The standardDeviation. */ @@ -1553,11 +1576,11 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * Minimum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Minimum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * int64 min = 4; + * int64 min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The min. */ @@ -1567,21 +1590,21 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of approximate
        -           * quartile values for the scanned data, occurring in order Q1,
        -           * median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * approximate quartile values for the scanned data, occurring in
        +           * order Q1, median, Q3.
                    * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return A list containing the quartiles. */ @@ -1591,21 +1614,21 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of approximate
        -           * quartile values for the scanned data, occurring in order Q1,
        -           * median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * approximate quartile values for the scanned data, occurring in
        +           * order Q1, median, Q3.
                    * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The count of quartiles. */ @@ -1615,21 +1638,21 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of approximate
        -           * quartile values for the scanned data, occurring in order Q1,
        -           * median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * approximate quartile values for the scanned data, occurring in
        +           * order Q1, median, Q3.
                    * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param index The index of the element to return. * @return The quartiles at the given index. @@ -1640,11 +1663,11 @@ public interface IntegerFieldInfoOrBuilder * * *
        -           * Maximum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Maximum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * int64 max = 5; + * int64 max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The max. */ @@ -1706,11 +1729,11 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -           * Average of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Average of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The average. */ @@ -1726,11 +1749,12 @@ public double getAverage() { * * *
        -           * Standard deviation of non-null values in the scanned data. NaN, if
        -           * the field has a NaN.
        +           * Output only. Standard deviation of non-null values in the scanned
        +           * data. NaN, if the field has a NaN.
                    * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The standardDeviation. */ @@ -1746,11 +1770,11 @@ public double getStandardDeviation() { * * *
        -           * Minimum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Minimum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * int64 min = 4; + * int64 min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The min. */ @@ -1768,21 +1792,21 @@ public long getMin() { * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of approximate
        -           * quartile values for the scanned data, occurring in order Q1,
        -           * median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * approximate quartile values for the scanned data, occurring in
        +           * order Q1, median, Q3.
                    * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return A list containing the quartiles. */ @@ -1795,21 +1819,21 @@ public java.util.List getQuartilesList() { * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of approximate
        -           * quartile values for the scanned data, occurring in order Q1,
        -           * median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * approximate quartile values for the scanned data, occurring in
        +           * order Q1, median, Q3.
                    * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The count of quartiles. */ @@ -1821,21 +1845,21 @@ public int getQuartilesCount() { * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of approximate
        -           * quartile values for the scanned data, occurring in order Q1,
        -           * median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * approximate quartile values for the scanned data, occurring in
        +           * order Q1, median, Q3.
                    * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param index The index of the element to return. * @return The quartiles at the given index. @@ -1853,11 +1877,11 @@ public long getQuartiles(int index) { * * *
        -           * Maximum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Maximum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * int64 max = 5; + * int64 max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The max. */ @@ -2416,11 +2440,11 @@ public Builder mergeFrom( * * *
        -             * Average of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Average of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The average. */ @@ -2433,11 +2457,11 @@ public double getAverage() { * * *
        -             * Average of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Average of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The average to set. * @return This builder for chaining. @@ -2454,11 +2478,11 @@ public Builder setAverage(double value) { * * *
        -             * Average of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Average of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -2475,11 +2499,12 @@ public Builder clearAverage() { * * *
        -             * Standard deviation of non-null values in the scanned data. NaN, if
        -             * the field has a NaN.
        +             * Output only. Standard deviation of non-null values in the scanned
        +             * data. NaN, if the field has a NaN.
                      * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The standardDeviation. */ @@ -2492,11 +2517,12 @@ public double getStandardDeviation() { * * *
        -             * Standard deviation of non-null values in the scanned data. NaN, if
        -             * the field has a NaN.
        +             * Output only. Standard deviation of non-null values in the scanned
        +             * data. NaN, if the field has a NaN.
                      * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param value The standardDeviation to set. * @return This builder for chaining. @@ -2513,11 +2539,12 @@ public Builder setStandardDeviation(double value) { * * *
        -             * Standard deviation of non-null values in the scanned data. NaN, if
        -             * the field has a NaN.
        +             * Output only. Standard deviation of non-null values in the scanned
        +             * data. NaN, if the field has a NaN.
                      * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return This builder for chaining. */ @@ -2534,11 +2561,11 @@ public Builder clearStandardDeviation() { * * *
        -             * Minimum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Minimum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * int64 min = 4; + * int64 min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The min. */ @@ -2551,11 +2578,11 @@ public long getMin() { * * *
        -             * Minimum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Minimum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * int64 min = 4; + * int64 min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The min to set. * @return This builder for chaining. @@ -2572,11 +2599,11 @@ public Builder setMin(long value) { * * *
        -             * Minimum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Minimum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * int64 min = 4; + * int64 min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -2600,21 +2627,22 @@ private void ensureQuartilesIsMutable() { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return A list containing the quartiles. */ @@ -2627,21 +2655,22 @@ public java.util.List getQuartilesList() { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The count of quartiles. */ @@ -2653,21 +2682,22 @@ public int getQuartilesCount() { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the element to return. * @return The quartiles at the given index. @@ -2680,21 +2710,22 @@ public long getQuartiles(int index) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index to set the value at. * @param value The quartiles to set. @@ -2713,21 +2744,22 @@ public Builder setQuartiles(int index, long value) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param value The quartiles to add. * @return This builder for chaining. @@ -2745,21 +2777,22 @@ public Builder addQuartiles(long value) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param values The quartiles to add. * @return This builder for chaining. @@ -2776,21 +2809,22 @@ public Builder addAllQuartiles(java.lang.Iterable valu * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of approximate
        -             * quartile values for the scanned data, occurring in order Q1,
        -             * median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * approximate quartile values for the scanned data, occurring in
        +             * order Q1, median, Q3.
                      * 
        * - * repeated int64 quartiles = 6; + * repeated int64 quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return This builder for chaining. */ @@ -2807,11 +2841,11 @@ public Builder clearQuartiles() { * * *
        -             * Maximum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Maximum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * int64 max = 5; + * int64 max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The max. */ @@ -2824,11 +2858,11 @@ public long getMax() { * * *
        -             * Maximum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Maximum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * int64 max = 5; + * int64 max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The max to set. * @return This builder for chaining. @@ -2845,11 +2879,11 @@ public Builder setMax(long value) { * * *
        -             * Maximum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Maximum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * int64 max = 5; + * int64 max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -2941,11 +2975,11 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * Average of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Average of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The average. */ @@ -2955,11 +2989,12 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * Standard deviation of non-null values in the scanned data. NaN, if
        -           * the field has a NaN.
        +           * Output only. Standard deviation of non-null values in the scanned
        +           * data. NaN, if the field has a NaN.
                    * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The standardDeviation. */ @@ -2969,11 +3004,11 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * Minimum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Minimum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double min = 4; + * double min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The min. */ @@ -2983,20 +3018,22 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of quartile
        -           * values for the scanned data, occurring in order Q1, median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * quartile values for the scanned data, occurring in order Q1,
        +           * median, Q3.
                    * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return A list containing the quartiles. */ @@ -3006,20 +3043,22 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of quartile
        -           * values for the scanned data, occurring in order Q1, median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * quartile values for the scanned data, occurring in order Q1,
        +           * median, Q3.
                    * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The count of quartiles. */ @@ -3029,20 +3068,22 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of quartile
        -           * values for the scanned data, occurring in order Q1, median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * quartile values for the scanned data, occurring in order Q1,
        +           * median, Q3.
                    * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the element to return. * @return The quartiles at the given index. @@ -3053,11 +3094,11 @@ public interface DoubleFieldInfoOrBuilder * * *
        -           * Maximum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Maximum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double max = 5; + * double max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The max. */ @@ -3119,11 +3160,11 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -           * Average of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Average of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The average. */ @@ -3139,11 +3180,12 @@ public double getAverage() { * * *
        -           * Standard deviation of non-null values in the scanned data. NaN, if
        -           * the field has a NaN.
        +           * Output only. Standard deviation of non-null values in the scanned
        +           * data. NaN, if the field has a NaN.
                    * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The standardDeviation. */ @@ -3159,11 +3201,11 @@ public double getStandardDeviation() { * * *
        -           * Minimum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Minimum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double min = 4; + * double min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The min. */ @@ -3181,20 +3223,22 @@ public double getMin() { * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of quartile
        -           * values for the scanned data, occurring in order Q1, median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * quartile values for the scanned data, occurring in order Q1,
        +           * median, Q3.
                    * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return A list containing the quartiles. */ @@ -3207,20 +3251,22 @@ public java.util.List getQuartilesList() { * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of quartile
        -           * values for the scanned data, occurring in order Q1, median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * quartile values for the scanned data, occurring in order Q1,
        +           * median, Q3.
                    * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The count of quartiles. */ @@ -3232,20 +3278,22 @@ public int getQuartilesCount() { * * *
        -           * A quartile divides the number of data points into four parts, or
        -           * quarters, of more-or-less equal size. Three main quartiles used
        -           * are: The first quartile (Q1) splits off the lowest 25% of data from
        -           * the highest 75%. It is also known as the lower or 25th empirical
        -           * quartile, as 25% of the data is below this point. The second
        -           * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -           * below this point. The third quartile (Q3) splits off the highest
        -           * 25% of data from the lowest 75%. It is known as the upper or 75th
        -           * empirical quartile, as 75% of the data lies below this point.
        -           * Here, the quartiles is provided as an ordered list of quartile
        -           * values for the scanned data, occurring in order Q1, median, Q3.
        +           * Output only. A quartile divides the number of data points into four
        +           * parts, or quarters, of more-or-less equal size. Three main
        +           * quartiles used are: The first quartile (Q1) splits off the lowest
        +           * 25% of data from the highest 75%. It is also known as the lower or
        +           * 25th empirical quartile, as 25% of the data is below this point.
        +           * The second quartile (Q2) is the median of a data set. So, 50% of
        +           * the data lies below this point. The third quartile (Q3) splits off
        +           * the highest 25% of data from the lowest 75%. It is known as the
        +           * upper or 75th empirical quartile, as 75% of the data lies below
        +           * this point. Here, the quartiles is provided as an ordered list of
        +           * quartile values for the scanned data, occurring in order Q1,
        +           * median, Q3.
                    * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the element to return. * @return The quartiles at the given index. @@ -3263,11 +3311,11 @@ public double getQuartiles(int index) { * * *
        -           * Maximum of non-null values in the scanned data. NaN, if the field
        -           * has a NaN.
        +           * Output only. Maximum of non-null values in the scanned data. NaN,
        +           * if the field has a NaN.
                    * 
        * - * double max = 5; + * double max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The max. */ @@ -3830,11 +3878,11 @@ public Builder mergeFrom( * * *
        -             * Average of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Average of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The average. */ @@ -3847,11 +3895,11 @@ public double getAverage() { * * *
        -             * Average of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Average of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The average to set. * @return This builder for chaining. @@ -3868,11 +3916,11 @@ public Builder setAverage(double value) { * * *
        -             * Average of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Average of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double average = 1; + * double average = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -3889,11 +3937,12 @@ public Builder clearAverage() { * * *
        -             * Standard deviation of non-null values in the scanned data. NaN, if
        -             * the field has a NaN.
        +             * Output only. Standard deviation of non-null values in the scanned
        +             * data. NaN, if the field has a NaN.
                      * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The standardDeviation. */ @@ -3906,11 +3955,12 @@ public double getStandardDeviation() { * * *
        -             * Standard deviation of non-null values in the scanned data. NaN, if
        -             * the field has a NaN.
        +             * Output only. Standard deviation of non-null values in the scanned
        +             * data. NaN, if the field has a NaN.
                      * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param value The standardDeviation to set. * @return This builder for chaining. @@ -3927,11 +3977,12 @@ public Builder setStandardDeviation(double value) { * * *
        -             * Standard deviation of non-null values in the scanned data. NaN, if
        -             * the field has a NaN.
        +             * Output only. Standard deviation of non-null values in the scanned
        +             * data. NaN, if the field has a NaN.
                      * 
        * - * double standard_deviation = 3; + * double standard_deviation = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return This builder for chaining. */ @@ -3948,11 +3999,11 @@ public Builder clearStandardDeviation() { * * *
        -             * Minimum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Minimum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double min = 4; + * double min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The min. */ @@ -3965,11 +4016,11 @@ public double getMin() { * * *
        -             * Minimum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Minimum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double min = 4; + * double min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The min to set. * @return This builder for chaining. @@ -3986,11 +4037,11 @@ public Builder setMin(double value) { * * *
        -             * Minimum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Minimum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double min = 4; + * double min = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -4021,20 +4072,22 @@ private void ensureQuartilesIsMutable(int capacity) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return A list containing the quartiles. */ @@ -4047,20 +4100,22 @@ public java.util.List getQuartilesList() { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The count of quartiles. */ @@ -4072,20 +4127,22 @@ public int getQuartilesCount() { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index of the element to return. * @return The quartiles at the given index. @@ -4098,20 +4155,22 @@ public double getQuartiles(int index) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param index The index to set the value at. * @param value The quartiles to set. @@ -4130,20 +4189,22 @@ public Builder setQuartiles(int index, double value) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param value The quartiles to add. * @return This builder for chaining. @@ -4161,20 +4222,22 @@ public Builder addQuartiles(double value) { * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @param values The quartiles to add. * @return This builder for chaining. @@ -4191,20 +4254,22 @@ public Builder addAllQuartiles(java.lang.Iterable va * * *
        -             * A quartile divides the number of data points into four parts, or
        -             * quarters, of more-or-less equal size. Three main quartiles used
        -             * are: The first quartile (Q1) splits off the lowest 25% of data from
        -             * the highest 75%. It is also known as the lower or 25th empirical
        -             * quartile, as 25% of the data is below this point. The second
        -             * quartile (Q2) is the median of a data set. So, 50% of the data lies
        -             * below this point. The third quartile (Q3) splits off the highest
        -             * 25% of data from the lowest 75%. It is known as the upper or 75th
        -             * empirical quartile, as 75% of the data lies below this point.
        -             * Here, the quartiles is provided as an ordered list of quartile
        -             * values for the scanned data, occurring in order Q1, median, Q3.
        +             * Output only. A quartile divides the number of data points into four
        +             * parts, or quarters, of more-or-less equal size. Three main
        +             * quartiles used are: The first quartile (Q1) splits off the lowest
        +             * 25% of data from the highest 75%. It is also known as the lower or
        +             * 25th empirical quartile, as 25% of the data is below this point.
        +             * The second quartile (Q2) is the median of a data set. So, 50% of
        +             * the data lies below this point. The third quartile (Q3) splits off
        +             * the highest 25% of data from the lowest 75%. It is known as the
        +             * upper or 75th empirical quartile, as 75% of the data lies below
        +             * this point. Here, the quartiles is provided as an ordered list of
        +             * quartile values for the scanned data, occurring in order Q1,
        +             * median, Q3.
                      * 
        * - * repeated double quartiles = 6; + * repeated double quartiles = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return This builder for chaining. */ @@ -4221,11 +4286,11 @@ public Builder clearQuartiles() { * * *
        -             * Maximum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Maximum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double max = 5; + * double max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The max. */ @@ -4238,11 +4303,11 @@ public double getMax() { * * *
        -             * Maximum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Maximum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double max = 5; + * double max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The max to set. * @return This builder for chaining. @@ -4259,11 +4324,11 @@ public Builder setMax(double value) { * * *
        -             * Maximum of non-null values in the scanned data. NaN, if the field
        -             * has a NaN.
        +             * Output only. Maximum of non-null values in the scanned data. NaN,
        +             * if the field has a NaN.
                      * 
        * - * double max = 5; + * double max = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -4355,10 +4420,10 @@ public interface TopNValueOrBuilder * * *
        -           * String value of a top N non-null value.
        +           * Output only. String value of a top N non-null value.
                    * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The value. */ @@ -4368,10 +4433,10 @@ public interface TopNValueOrBuilder * * *
        -           * String value of a top N non-null value.
        +           * Output only. String value of a top N non-null value.
                    * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for value. */ @@ -4381,10 +4446,10 @@ public interface TopNValueOrBuilder * * *
        -           * Count of the corresponding value in the scanned data.
        +           * Output only. Count of the corresponding value in the scanned data.
                    * 
        * - * int64 count = 2; + * int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The count. */ @@ -4394,11 +4459,11 @@ public interface TopNValueOrBuilder * * *
        -           * Ratio of the corresponding value in the field against the total
        -           * number of rows in the scanned data.
        +           * Output only. Ratio of the corresponding value in the field against
        +           * the total number of rows in the scanned data.
                    * 
        * - * double ratio = 3; + * double ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The ratio. */ @@ -4462,10 +4527,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -           * String value of a top N non-null value.
        +           * Output only. String value of a top N non-null value.
                    * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The value. */ @@ -4486,10 +4551,10 @@ public java.lang.String getValue() { * * *
        -           * String value of a top N non-null value.
        +           * Output only. String value of a top N non-null value.
                    * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for value. */ @@ -4513,10 +4578,10 @@ public com.google.protobuf.ByteString getValueBytes() { * * *
        -           * Count of the corresponding value in the scanned data.
        +           * Output only. Count of the corresponding value in the scanned data.
                    * 
        * - * int64 count = 2; + * int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The count. */ @@ -4532,11 +4597,11 @@ public long getCount() { * * *
        -           * Ratio of the corresponding value in the field against the total
        -           * number of rows in the scanned data.
        +           * Output only. Ratio of the corresponding value in the field against
        +           * the total number of rows in the scanned data.
                    * 
        * - * double ratio = 3; + * double ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The ratio. */ @@ -5003,10 +5068,10 @@ public Builder mergeFrom( * * *
        -             * String value of a top N non-null value.
        +             * Output only. String value of a top N non-null value.
                      * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The value. */ @@ -5026,10 +5091,10 @@ public java.lang.String getValue() { * * *
        -             * String value of a top N non-null value.
        +             * Output only. String value of a top N non-null value.
                      * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for value. */ @@ -5049,10 +5114,10 @@ public com.google.protobuf.ByteString getValueBytes() { * * *
        -             * String value of a top N non-null value.
        +             * Output only. String value of a top N non-null value.
                      * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The value to set. * @return This builder for chaining. @@ -5071,10 +5136,10 @@ public Builder setValue(java.lang.String value) { * * *
        -             * String value of a top N non-null value.
        +             * Output only. String value of a top N non-null value.
                      * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -5089,10 +5154,10 @@ public Builder clearValue() { * * *
        -             * String value of a top N non-null value.
        +             * Output only. String value of a top N non-null value.
                      * 
        * - * string value = 1; + * string value = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for value to set. * @return This builder for chaining. @@ -5114,10 +5179,10 @@ public Builder setValueBytes(com.google.protobuf.ByteString value) { * * *
        -             * Count of the corresponding value in the scanned data.
        +             * Output only. Count of the corresponding value in the scanned data.
                      * 
        * - * int64 count = 2; + * int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The count. */ @@ -5130,10 +5195,10 @@ public long getCount() { * * *
        -             * Count of the corresponding value in the scanned data.
        +             * Output only. Count of the corresponding value in the scanned data.
                      * 
        * - * int64 count = 2; + * int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The count to set. * @return This builder for chaining. @@ -5150,10 +5215,10 @@ public Builder setCount(long value) { * * *
        -             * Count of the corresponding value in the scanned data.
        +             * Output only. Count of the corresponding value in the scanned data.
                      * 
        * - * int64 count = 2; + * int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -5170,11 +5235,11 @@ public Builder clearCount() { * * *
        -             * Ratio of the corresponding value in the field against the total
        -             * number of rows in the scanned data.
        +             * Output only. Ratio of the corresponding value in the field against
        +             * the total number of rows in the scanned data.
                      * 
        * - * double ratio = 3; + * double ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The ratio. */ @@ -5187,11 +5252,11 @@ public double getRatio() { * * *
        -             * Ratio of the corresponding value in the field against the total
        -             * number of rows in the scanned data.
        +             * Output only. Ratio of the corresponding value in the field against
        +             * the total number of rows in the scanned data.
                      * 
        * - * double ratio = 3; + * double ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The ratio to set. * @return This builder for chaining. @@ -5208,11 +5273,11 @@ public Builder setRatio(double value) { * * *
        -             * Ratio of the corresponding value in the field against the total
        -             * number of rows in the scanned data.
        +             * Output only. Ratio of the corresponding value in the field against
        +             * the total number of rows in the scanned data.
                      * 
        * - * double ratio = 3; + * double ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -5354,10 +5419,11 @@ public FieldInfoCase getFieldInfoCase() { * * *
        -         * Ratio of rows with null value against total scanned rows.
        +         * Output only. Ratio of rows with null value against total scanned
        +         * rows.
                  * 
        * - * double null_ratio = 2; + * double null_ratio = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The nullRatio. */ @@ -5373,12 +5439,13 @@ public double getNullRatio() { * * *
        -         * Ratio of rows with distinct values against total scanned rows.
        -         * Not available for complex non-groupable field type, including RECORD,
        -         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. Ratio of rows with distinct values against total scanned
        +         * rows. Not available for complex non-groupable field type, including
        +         * RECORD, ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE
        +         * mode.
                  * 
        * - * double distinct_ratio = 3; + * double distinct_ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The distinctRatio. */ @@ -5398,15 +5465,15 @@ public double getDistinctRatio() { * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override @@ -5420,15 +5487,15 @@ public double getDistinctRatio() { * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override @@ -5444,15 +5511,15 @@ public double getDistinctRatio() { * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override @@ -5464,15 +5531,15 @@ public int getTopNValuesCount() { * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override @@ -5485,15 +5552,15 @@ public int getTopNValuesCount() { * * *
        -         * The list of top N non-null values, frequency and ratio with which
        -         * they occur in the scanned data. N is 10 or equal to the number of
        -         * distinct values in the field, whichever is smaller. Not available for
        -         * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -         * and JSON, as well as fields with REPEATABLE mode.
        +         * Output only. The list of top N non-null values, frequency and ratio
        +         * with which they occur in the scanned data. N is 10 or equal to the
        +         * number of distinct values in the field, whichever is smaller. Not
        +         * available for complex non-groupable field type, including RECORD,
        +         * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                  * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override @@ -6355,10 +6422,11 @@ public Builder clearFieldInfo() { * * *
        -           * Ratio of rows with null value against total scanned rows.
        +           * Output only. Ratio of rows with null value against total scanned
        +           * rows.
                    * 
        * - * double null_ratio = 2; + * double null_ratio = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The nullRatio. */ @@ -6371,10 +6439,11 @@ public double getNullRatio() { * * *
        -           * Ratio of rows with null value against total scanned rows.
        +           * Output only. Ratio of rows with null value against total scanned
        +           * rows.
                    * 
        * - * double null_ratio = 2; + * double null_ratio = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The nullRatio to set. * @return This builder for chaining. @@ -6391,10 +6460,11 @@ public Builder setNullRatio(double value) { * * *
        -           * Ratio of rows with null value against total scanned rows.
        +           * Output only. Ratio of rows with null value against total scanned
        +           * rows.
                    * 
        * - * double null_ratio = 2; + * double null_ratio = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -6411,12 +6481,13 @@ public Builder clearNullRatio() { * * *
        -           * Ratio of rows with distinct values against total scanned rows.
        -           * Not available for complex non-groupable field type, including RECORD,
        -           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. Ratio of rows with distinct values against total scanned
        +           * rows. Not available for complex non-groupable field type, including
        +           * RECORD, ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE
        +           * mode.
                    * 
        * - * double distinct_ratio = 3; + * double distinct_ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The distinctRatio. */ @@ -6429,12 +6500,13 @@ public double getDistinctRatio() { * * *
        -           * Ratio of rows with distinct values against total scanned rows.
        -           * Not available for complex non-groupable field type, including RECORD,
        -           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. Ratio of rows with distinct values against total scanned
        +           * rows. Not available for complex non-groupable field type, including
        +           * RECORD, ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE
        +           * mode.
                    * 
        * - * double distinct_ratio = 3; + * double distinct_ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The distinctRatio to set. * @return This builder for chaining. @@ -6451,12 +6523,13 @@ public Builder setDistinctRatio(double value) { * * *
        -           * Ratio of rows with distinct values against total scanned rows.
        -           * Not available for complex non-groupable field type, including RECORD,
        -           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. Ratio of rows with distinct values against total scanned
        +           * rows. Not available for complex non-groupable field type, including
        +           * RECORD, ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE
        +           * mode.
                    * 
        * - * double distinct_ratio = 3; + * double distinct_ratio = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -6495,15 +6568,15 @@ private void ensureTopNValuesIsMutable() { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List< @@ -6521,15 +6594,15 @@ private void ensureTopNValuesIsMutable() { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public int getTopNValuesCount() { @@ -6544,15 +6617,15 @@ public int getTopNValuesCount() { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue @@ -6568,15 +6641,15 @@ public int getTopNValuesCount() { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setTopNValues( @@ -6600,15 +6673,15 @@ public Builder setTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setTopNValues( @@ -6630,15 +6703,15 @@ public Builder setTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addTopNValues( @@ -6661,15 +6734,15 @@ public Builder addTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addTopNValues( @@ -6693,15 +6766,15 @@ public Builder addTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addTopNValues( @@ -6722,15 +6795,15 @@ public Builder addTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addTopNValues( @@ -6752,15 +6825,15 @@ public Builder addTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder addAllTopNValues( @@ -6783,15 +6856,15 @@ public Builder addAllTopNValues( * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearTopNValues() { @@ -6809,15 +6882,15 @@ public Builder clearTopNValues() { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder removeTopNValues(int index) { @@ -6835,15 +6908,15 @@ public Builder removeTopNValues(int index) { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue @@ -6856,15 +6929,15 @@ public Builder removeTopNValues(int index) { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo @@ -6881,15 +6954,15 @@ public Builder removeTopNValues(int index) { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List< @@ -6908,15 +6981,15 @@ public Builder removeTopNValues(int index) { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue @@ -6932,15 +7005,15 @@ public Builder removeTopNValues(int index) { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue @@ -6957,15 +7030,15 @@ public Builder removeTopNValues(int index) { * * *
        -           * The list of top N non-null values, frequency and ratio with which
        -           * they occur in the scanned data. N is 10 or equal to the number of
        -           * distinct values in the field, whichever is smaller. Not available for
        -           * complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY,
        -           * and JSON, as well as fields with REPEATABLE mode.
        +           * Output only. The list of top N non-null values, frequency and ratio
        +           * with which they occur in the scanned data. N is 10 or equal to the
        +           * number of distinct values in the field, whichever is smaller. Not
        +           * available for complex non-groupable field type, including RECORD,
        +           * ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode.
                    * 
        * * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4; + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.TopNValue top_n_values = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public java.util.List< @@ -7905,10 +7978,10 @@ public com.google.protobuf.Parser getParserForType() { * * *
        -       * The name of the field.
        +       * Output only. The name of the field.
                * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @@ -7929,10 +8002,10 @@ public java.lang.String getName() { * * *
        -       * The name of the field.
        +       * Output only. The name of the field.
                * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ @@ -7958,14 +8031,15 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
        -       * The data type retrieved from the schema of the data source. For
        -       * instance, for a BigQuery native table, it is the [BigQuery Table
        +       * Output only. The data type retrieved from the schema of the data
        +       * source. For instance, for a BigQuery native table, it is the [BigQuery
        +       * Table
                * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -       * For a Dataplex Entity, it is the [Entity
        +       * For a Dataplex Universal Catalog Entity, it is the [Entity
                * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The type. */ @@ -7986,14 +8060,15 @@ public java.lang.String getType() { * * *
        -       * The data type retrieved from the schema of the data source. For
        -       * instance, for a BigQuery native table, it is the [BigQuery Table
        +       * Output only. The data type retrieved from the schema of the data
        +       * source. For instance, for a BigQuery native table, it is the [BigQuery
        +       * Table
                * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -       * For a Dataplex Entity, it is the [Entity
        +       * For a Dataplex Universal Catalog Entity, it is the [Entity
                * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for type. */ @@ -8019,14 +8094,14 @@ public com.google.protobuf.ByteString getTypeBytes() { * * *
        -       * The mode of the field. Possible values include:
        +       * Output only. The mode of the field. Possible values include:
                *
                * * REQUIRED, if it is a required field.
                * * NULLABLE, if it is an optional field.
                * * REPEATED, if it is a repeated field.
                * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The mode. */ @@ -8047,14 +8122,14 @@ public java.lang.String getMode() { * * *
        -       * The mode of the field. Possible values include:
        +       * Output only. The mode of the field. Possible values include:
                *
                * * REQUIRED, if it is a required field.
                * * NULLABLE, if it is an optional field.
                * * REPEATED, if it is a repeated field.
                * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for mode. */ @@ -8078,10 +8153,11 @@ public com.google.protobuf.ByteString getModeBytes() { * * *
        -       * Profile information for the corresponding field.
        +       * Output only. Profile information for the corresponding field.
                * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the profile field is set. @@ -8095,10 +8171,11 @@ public boolean hasProfile() { * * *
        -       * Profile information for the corresponding field.
        +       * Output only. Profile information for the corresponding field.
                * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The profile. @@ -8115,10 +8192,11 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo * * *
        -       * Profile information for the corresponding field.
        +       * Output only. Profile information for the corresponding field.
                * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ @java.lang.Override @@ -8579,10 +8657,10 @@ public Builder mergeFrom( * * *
        -         * The name of the field.
        +         * Output only. The name of the field.
                  * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @@ -8602,10 +8680,10 @@ public java.lang.String getName() { * * *
        -         * The name of the field.
        +         * Output only. The name of the field.
                  * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ @@ -8625,10 +8703,10 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
        -         * The name of the field.
        +         * Output only. The name of the field.
                  * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The name to set. * @return This builder for chaining. @@ -8647,10 +8725,10 @@ public Builder setName(java.lang.String value) { * * *
        -         * The name of the field.
        +         * Output only. The name of the field.
                  * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -8665,10 +8743,10 @@ public Builder clearName() { * * *
        -         * The name of the field.
        +         * Output only. The name of the field.
                  * 
        * - * string name = 1; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for name to set. * @return This builder for chaining. @@ -8690,14 +8768,15 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * * *
        -         * The data type retrieved from the schema of the data source. For
        -         * instance, for a BigQuery native table, it is the [BigQuery Table
        +         * Output only. The data type retrieved from the schema of the data
        +         * source. For instance, for a BigQuery native table, it is the [BigQuery
        +         * Table
                  * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -         * For a Dataplex Entity, it is the [Entity
        +         * For a Dataplex Universal Catalog Entity, it is the [Entity
                  * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                  * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The type. */ @@ -8717,14 +8796,15 @@ public java.lang.String getType() { * * *
        -         * The data type retrieved from the schema of the data source. For
        -         * instance, for a BigQuery native table, it is the [BigQuery Table
        +         * Output only. The data type retrieved from the schema of the data
        +         * source. For instance, for a BigQuery native table, it is the [BigQuery
        +         * Table
                  * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -         * For a Dataplex Entity, it is the [Entity
        +         * For a Dataplex Universal Catalog Entity, it is the [Entity
                  * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                  * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for type. */ @@ -8744,14 +8824,15 @@ public com.google.protobuf.ByteString getTypeBytes() { * * *
        -         * The data type retrieved from the schema of the data source. For
        -         * instance, for a BigQuery native table, it is the [BigQuery Table
        +         * Output only. The data type retrieved from the schema of the data
        +         * source. For instance, for a BigQuery native table, it is the [BigQuery
        +         * Table
                  * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -         * For a Dataplex Entity, it is the [Entity
        +         * For a Dataplex Universal Catalog Entity, it is the [Entity
                  * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                  * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The type to set. * @return This builder for chaining. @@ -8770,14 +8851,15 @@ public Builder setType(java.lang.String value) { * * *
        -         * The data type retrieved from the schema of the data source. For
        -         * instance, for a BigQuery native table, it is the [BigQuery Table
        +         * Output only. The data type retrieved from the schema of the data
        +         * source. For instance, for a BigQuery native table, it is the [BigQuery
        +         * Table
                  * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -         * For a Dataplex Entity, it is the [Entity
        +         * For a Dataplex Universal Catalog Entity, it is the [Entity
                  * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                  * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -8792,14 +8874,15 @@ public Builder clearType() { * * *
        -         * The data type retrieved from the schema of the data source. For
        -         * instance, for a BigQuery native table, it is the [BigQuery Table
        +         * Output only. The data type retrieved from the schema of the data
        +         * source. For instance, for a BigQuery native table, it is the [BigQuery
        +         * Table
                  * Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema).
        -         * For a Dataplex Entity, it is the [Entity
        +         * For a Dataplex Universal Catalog Entity, it is the [Entity
                  * Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3).
                  * 
        * - * string type = 2; + * string type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for type to set. * @return This builder for chaining. @@ -8821,14 +8904,14 @@ public Builder setTypeBytes(com.google.protobuf.ByteString value) { * * *
        -         * The mode of the field. Possible values include:
        +         * Output only. The mode of the field. Possible values include:
                  *
                  * * REQUIRED, if it is a required field.
                  * * NULLABLE, if it is an optional field.
                  * * REPEATED, if it is a repeated field.
                  * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The mode. */ @@ -8848,14 +8931,14 @@ public java.lang.String getMode() { * * *
        -         * The mode of the field. Possible values include:
        +         * Output only. The mode of the field. Possible values include:
                  *
                  * * REQUIRED, if it is a required field.
                  * * NULLABLE, if it is an optional field.
                  * * REPEATED, if it is a repeated field.
                  * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for mode. */ @@ -8875,14 +8958,14 @@ public com.google.protobuf.ByteString getModeBytes() { * * *
        -         * The mode of the field. Possible values include:
        +         * Output only. The mode of the field. Possible values include:
                  *
                  * * REQUIRED, if it is a required field.
                  * * NULLABLE, if it is an optional field.
                  * * REPEATED, if it is a repeated field.
                  * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The mode to set. * @return This builder for chaining. @@ -8901,14 +8984,14 @@ public Builder setMode(java.lang.String value) { * * *
        -         * The mode of the field. Possible values include:
        +         * Output only. The mode of the field. Possible values include:
                  *
                  * * REQUIRED, if it is a required field.
                  * * NULLABLE, if it is an optional field.
                  * * REPEATED, if it is a repeated field.
                  * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -8923,14 +9006,14 @@ public Builder clearMode() { * * *
        -         * The mode of the field. Possible values include:
        +         * Output only. The mode of the field. Possible values include:
                  *
                  * * REQUIRED, if it is a required field.
                  * * NULLABLE, if it is an optional field.
                  * * REPEATED, if it is a repeated field.
                  * 
        * - * string mode = 3; + * string mode = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for mode to set. * @return This builder for chaining. @@ -8957,10 +9040,11 @@ public Builder setModeBytes(com.google.protobuf.ByteString value) { * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return Whether the profile field is set. @@ -8973,10 +9057,11 @@ public boolean hasProfile() { * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * * @return The profile. @@ -8997,10 +9082,11 @@ public boolean hasProfile() { * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setProfile( @@ -9022,10 +9108,11 @@ public Builder setProfile( * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder setProfile( @@ -9045,10 +9132,11 @@ public Builder setProfile( * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder mergeProfile( @@ -9077,10 +9165,11 @@ public Builder mergeProfile( * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public Builder clearProfile() { @@ -9098,10 +9187,11 @@ public Builder clearProfile() { * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo.Builder @@ -9115,10 +9205,11 @@ public Builder clearProfile() { * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfoOrBuilder @@ -9137,10 +9228,11 @@ public Builder clearProfile() { * * *
        -         * Profile information for the corresponding field.
        +         * Output only. Profile information for the corresponding field.
                  * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile.Field.ProfileInfo profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; * */ private com.google.protobuf.SingleFieldBuilderV3< @@ -9237,10 +9329,13 @@ public com.google.protobuf.Parser getParserForType() { * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public java.util.List @@ -9252,10 +9347,13 @@ public com.google.protobuf.Parser getParserForType() { * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public java.util.List< @@ -9268,10 +9366,13 @@ public com.google.protobuf.Parser getParserForType() { * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public int getFieldsCount() { @@ -9282,10 +9383,13 @@ public int getFieldsCount() { * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field getFields(int index) { @@ -9296,10 +9400,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field getFields(in * * *
        -     * List of fields with structural and profile information for each field.
        +     * Output only. List of fields with structural and profile information for
        +     * each field.
              * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.dataplex.v1.DataProfileResult.Profile.FieldOrBuilder getFieldsOrBuilder( @@ -9726,10 +9833,13 @@ private void ensureFieldsIsMutable() { * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List getFieldsList() { @@ -9744,10 +9854,13 @@ private void ensureFieldsIsMutable() { * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public int getFieldsCount() { if (fieldsBuilder_ == null) { @@ -9761,10 +9874,13 @@ public int getFieldsCount() { * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field getFields(int index) { if (fieldsBuilder_ == null) { @@ -9778,10 +9894,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field getFields(in * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setFields( int index, com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field value) { @@ -9802,10 +9921,13 @@ public Builder setFields( * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setFields( int index, @@ -9824,10 +9946,13 @@ public Builder setFields( * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFields(com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field value) { if (fieldsBuilder_ == null) { @@ -9847,10 +9972,13 @@ public Builder addFields(com.google.cloud.dataplex.v1.DataProfileResult.Profile. * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFields( int index, com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field value) { @@ -9871,10 +9999,13 @@ public Builder addFields( * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFields( com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder builderForValue) { @@ -9892,10 +10023,13 @@ public Builder addFields( * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addFields( int index, @@ -9914,10 +10048,13 @@ public Builder addFields( * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder addAllFields( java.lang.Iterable @@ -9936,10 +10073,13 @@ public Builder addAllFields( * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearFields() { if (fieldsBuilder_ == null) { @@ -9956,10 +10096,13 @@ public Builder clearFields() { * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder removeFields(int index) { if (fieldsBuilder_ == null) { @@ -9976,10 +10119,13 @@ public Builder removeFields(int index) { * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder getFieldsBuilder( int index) { @@ -9990,10 +10136,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder getF * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.FieldOrBuilder getFieldsOrBuilder(int index) { @@ -10008,10 +10157,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder getF * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List< ? extends com.google.cloud.dataplex.v1.DataProfileResult.Profile.FieldOrBuilder> @@ -10027,10 +10179,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder getF * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder addFieldsBuilder() { @@ -10043,10 +10198,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder getF * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder addFieldsBuilder( int index) { @@ -10060,10 +10218,13 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Field.Builder addF * * *
        -       * List of fields with structural and profile information for each field.
        +       * Output only. List of fields with structural and profile information for
        +       * each field.
                * 
        * - * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2; + * + * repeated .google.cloud.dataplex.v1.DataProfileResult.Profile.Field fields = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public java.util.List getFieldsBuilderList() { @@ -12143,10 +12304,10 @@ public com.google.protobuf.Parser getParserForType() { * * *
        -   * The count of rows scanned.
        +   * Output only. The count of rows scanned.
            * 
        * - * int64 row_count = 3; + * int64 row_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The rowCount. */ @@ -12162,10 +12323,12 @@ public long getRowCount() { * * *
        -   * The profile information per field.
        +   * Output only. The profile information per field.
            * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return Whether the profile field is set. */ @@ -12178,10 +12341,12 @@ public boolean hasProfile() { * * *
        -   * The profile information per field.
        +   * Output only. The profile information per field.
            * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The profile. */ @@ -12196,10 +12361,12 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile getProfile() { * * *
        -   * The profile information per field.
        +   * Output only. The profile information per field.
            * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.dataplex.v1.DataProfileResult.ProfileOrBuilder getProfileOrBuilder() { @@ -12215,10 +12382,12 @@ public com.google.cloud.dataplex.v1.DataProfileResult.ProfileOrBuilder getProfil * * *
        -   * The data scanned for this result.
        +   * Output only. The data scanned for this result.
            * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return Whether the scannedData field is set. */ @@ -12231,10 +12400,12 @@ public boolean hasScannedData() { * * *
        -   * The data scanned for this result.
        +   * Output only. The data scanned for this result.
            * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The scannedData. */ @@ -12249,10 +12420,12 @@ public com.google.cloud.dataplex.v1.ScannedData getScannedData() { * * *
        -   * The data scanned for this result.
        +   * Output only. The data scanned for this result.
            * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ @java.lang.Override public com.google.cloud.dataplex.v1.ScannedDataOrBuilder getScannedDataOrBuilder() { @@ -12785,10 +12958,10 @@ public Builder mergeFrom( * * *
        -     * The count of rows scanned.
        +     * Output only. The count of rows scanned.
              * 
        * - * int64 row_count = 3; + * int64 row_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The rowCount. */ @@ -12801,10 +12974,10 @@ public long getRowCount() { * * *
        -     * The count of rows scanned.
        +     * Output only. The count of rows scanned.
              * 
        * - * int64 row_count = 3; + * int64 row_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The rowCount to set. * @return This builder for chaining. @@ -12821,10 +12994,10 @@ public Builder setRowCount(long value) { * * *
        -     * The count of rows scanned.
        +     * Output only. The count of rows scanned.
              * 
        * - * int64 row_count = 3; + * int64 row_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -12846,10 +13019,12 @@ public Builder clearRowCount() { * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return Whether the profile field is set. */ @@ -12861,10 +13036,12 @@ public boolean hasProfile() { * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The profile. */ @@ -12882,10 +13059,12 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile getProfile() { * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setProfile(com.google.cloud.dataplex.v1.DataProfileResult.Profile value) { if (profileBuilder_ == null) { @@ -12905,10 +13084,12 @@ public Builder setProfile(com.google.cloud.dataplex.v1.DataProfileResult.Profile * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setProfile( com.google.cloud.dataplex.v1.DataProfileResult.Profile.Builder builderForValue) { @@ -12926,10 +13107,12 @@ public Builder setProfile( * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeProfile(com.google.cloud.dataplex.v1.DataProfileResult.Profile value) { if (profileBuilder_ == null) { @@ -12955,10 +13138,12 @@ public Builder mergeProfile(com.google.cloud.dataplex.v1.DataProfileResult.Profi * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearProfile() { bitField0_ = (bitField0_ & ~0x00000002); @@ -12975,10 +13160,12 @@ public Builder clearProfile() { * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Builder getProfileBuilder() { bitField0_ |= 0x00000002; @@ -12990,10 +13177,12 @@ public com.google.cloud.dataplex.v1.DataProfileResult.Profile.Builder getProfile * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.DataProfileResult.ProfileOrBuilder getProfileOrBuilder() { if (profileBuilder_ != null) { @@ -13009,10 +13198,12 @@ public com.google.cloud.dataplex.v1.DataProfileResult.ProfileOrBuilder getProfil * * *
        -     * The profile information per field.
        +     * Output only. The profile information per field.
              * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dataplex.v1.DataProfileResult.Profile, @@ -13042,10 +13233,12 @@ public com.google.cloud.dataplex.v1.DataProfileResult.ProfileOrBuilder getProfil * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return Whether the scannedData field is set. */ @@ -13057,10 +13250,12 @@ public boolean hasScannedData() { * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The scannedData. */ @@ -13078,10 +13273,12 @@ public com.google.cloud.dataplex.v1.ScannedData getScannedData() { * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setScannedData(com.google.cloud.dataplex.v1.ScannedData value) { if (scannedDataBuilder_ == null) { @@ -13101,10 +13298,12 @@ public Builder setScannedData(com.google.cloud.dataplex.v1.ScannedData value) { * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder setScannedData( com.google.cloud.dataplex.v1.ScannedData.Builder builderForValue) { @@ -13122,10 +13321,12 @@ public Builder setScannedData( * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder mergeScannedData(com.google.cloud.dataplex.v1.ScannedData value) { if (scannedDataBuilder_ == null) { @@ -13150,10 +13351,12 @@ public Builder mergeScannedData(com.google.cloud.dataplex.v1.ScannedData value) * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public Builder clearScannedData() { bitField0_ = (bitField0_ & ~0x00000004); @@ -13170,10 +13373,12 @@ public Builder clearScannedData() { * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.ScannedData.Builder getScannedDataBuilder() { bitField0_ |= 0x00000004; @@ -13185,10 +13390,12 @@ public com.google.cloud.dataplex.v1.ScannedData.Builder getScannedDataBuilder() * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ public com.google.cloud.dataplex.v1.ScannedDataOrBuilder getScannedDataOrBuilder() { if (scannedDataBuilder_ != null) { @@ -13204,10 +13411,12 @@ public com.google.cloud.dataplex.v1.ScannedDataOrBuilder getScannedDataOrBuilder * * *
        -     * The data scanned for this result.
        +     * Output only. The data scanned for this result.
              * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dataplex.v1.ScannedData, diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResultOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResultOrBuilder.java index fea31d33bd66..740e75a6357b 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResultOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileResultOrBuilder.java @@ -28,10 +28,10 @@ public interface DataProfileResultOrBuilder * * *
        -   * The count of rows scanned.
        +   * Output only. The count of rows scanned.
            * 
        * - * int64 row_count = 3; + * int64 row_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The rowCount. */ @@ -41,10 +41,12 @@ public interface DataProfileResultOrBuilder * * *
        -   * The profile information per field.
        +   * Output only. The profile information per field.
            * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return Whether the profile field is set. */ @@ -54,10 +56,12 @@ public interface DataProfileResultOrBuilder * * *
        -   * The profile information per field.
        +   * Output only. The profile information per field.
            * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The profile. */ @@ -67,10 +71,12 @@ public interface DataProfileResultOrBuilder * * *
        -   * The profile information per field.
        +   * Output only. The profile information per field.
            * 
        * - * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4; + * + * .google.cloud.dataplex.v1.DataProfileResult.Profile profile = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.dataplex.v1.DataProfileResult.ProfileOrBuilder getProfileOrBuilder(); @@ -78,10 +84,12 @@ public interface DataProfileResultOrBuilder * * *
        -   * The data scanned for this result.
        +   * Output only. The data scanned for this result.
            * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return Whether the scannedData field is set. */ @@ -91,10 +99,12 @@ public interface DataProfileResultOrBuilder * * *
        -   * The data scanned for this result.
        +   * Output only. The data scanned for this result.
            * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * * @return The scannedData. */ @@ -104,10 +114,12 @@ public interface DataProfileResultOrBuilder * * *
        -   * The data scanned for this result.
        +   * Output only. The data scanned for this result.
            * 
        * - * .google.cloud.dataplex.v1.ScannedData scanned_data = 5; + * + * .google.cloud.dataplex.v1.ScannedData scanned_data = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * */ com.google.cloud.dataplex.v1.ScannedDataOrBuilder getScannedDataOrBuilder(); diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpec.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpec.java index 360e6c697176..1da9f109c58c 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpec.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpec.java @@ -172,8 +172,6 @@ public interface BigQueryExportOrBuilder * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -189,8 +187,6 @@ public interface BigQueryExportOrBuilder * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -258,8 +254,6 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -286,8 +280,6 @@ public java.lang.String getResultsTable() { * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -688,8 +680,6 @@ public Builder mergeFrom( * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -715,8 +705,6 @@ public java.lang.String getResultsTable() { * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -742,8 +730,6 @@ public com.google.protobuf.ByteString getResultsTableBytes() { * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -768,8 +754,6 @@ public Builder setResultsTable(java.lang.String value) { * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -790,8 +774,6 @@ public Builder clearResultsTable() { * Optional. The BigQuery table to export DataProfileScan results to. * Format: * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - * or - * projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID * * * string results_table = 1 [(.google.api.field_behavior) = OPTIONAL]; @@ -2545,10 +2527,8 @@ public float getSamplingPercent() { * *
            * Optional. A filter applied to all rows in a single DataScan job.
        -   * The filter needs to be a valid SQL expression for a [WHERE clause in
        -   * GoogleSQL
        -   * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -   *
        +   * The filter needs to be a valid SQL expression for a WHERE clause in
        +   * BigQuery standard SQL syntax.
            * Example: col1 >= 0 AND col2 < 10
            * 
        * @@ -2574,10 +2554,8 @@ public java.lang.String getRowFilter() { * *
            * Optional. A filter applied to all rows in a single DataScan job.
        -   * The filter needs to be a valid SQL expression for a [WHERE clause in
        -   * GoogleSQL
        -   * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -   *
        +   * The filter needs to be a valid SQL expression for a WHERE clause in
        +   * BigQuery standard SQL syntax.
            * Example: col1 >= 0 AND col2 < 10
            * 
        * @@ -3354,10 +3332,8 @@ public Builder clearSamplingPercent() { * *
              * Optional. A filter applied to all rows in a single DataScan job.
        -     * The filter needs to be a valid SQL expression for a [WHERE clause in
        -     * GoogleSQL
        -     * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -     *
        +     * The filter needs to be a valid SQL expression for a WHERE clause in
        +     * BigQuery standard SQL syntax.
              * Example: col1 >= 0 AND col2 < 10
              * 
        * @@ -3382,10 +3358,8 @@ public java.lang.String getRowFilter() { * *
              * Optional. A filter applied to all rows in a single DataScan job.
        -     * The filter needs to be a valid SQL expression for a [WHERE clause in
        -     * GoogleSQL
        -     * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -     *
        +     * The filter needs to be a valid SQL expression for a WHERE clause in
        +     * BigQuery standard SQL syntax.
              * Example: col1 >= 0 AND col2 < 10
              * 
        * @@ -3410,10 +3384,8 @@ public com.google.protobuf.ByteString getRowFilterBytes() { * *
              * Optional. A filter applied to all rows in a single DataScan job.
        -     * The filter needs to be a valid SQL expression for a [WHERE clause in
        -     * GoogleSQL
        -     * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -     *
        +     * The filter needs to be a valid SQL expression for a WHERE clause in
        +     * BigQuery standard SQL syntax.
              * Example: col1 >= 0 AND col2 < 10
              * 
        * @@ -3437,10 +3409,8 @@ public Builder setRowFilter(java.lang.String value) { * *
              * Optional. A filter applied to all rows in a single DataScan job.
        -     * The filter needs to be a valid SQL expression for a [WHERE clause in
        -     * GoogleSQL
        -     * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -     *
        +     * The filter needs to be a valid SQL expression for a WHERE clause in
        +     * BigQuery standard SQL syntax.
              * Example: col1 >= 0 AND col2 < 10
              * 
        * @@ -3460,10 +3430,8 @@ public Builder clearRowFilter() { * *
              * Optional. A filter applied to all rows in a single DataScan job.
        -     * The filter needs to be a valid SQL expression for a [WHERE clause in
        -     * GoogleSQL
        -     * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -     *
        +     * The filter needs to be a valid SQL expression for a WHERE clause in
        +     * BigQuery standard SQL syntax.
              * Example: col1 >= 0 AND col2 < 10
              * 
        * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpecOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpecOrBuilder.java index 2372355dda09..5ae0b7c903b5 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpecOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataProfileSpecOrBuilder.java @@ -48,10 +48,8 @@ public interface DataProfileSpecOrBuilder * *
            * Optional. A filter applied to all rows in a single DataScan job.
        -   * The filter needs to be a valid SQL expression for a [WHERE clause in
        -   * GoogleSQL
        -   * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -   *
        +   * The filter needs to be a valid SQL expression for a WHERE clause in
        +   * BigQuery standard SQL syntax.
            * Example: col1 >= 0 AND col2 < 10
            * 
        * @@ -66,10 +64,8 @@ public interface DataProfileSpecOrBuilder * *
            * Optional. A filter applied to all rows in a single DataScan job.
        -   * The filter needs to be a valid SQL expression for a [WHERE clause in
        -   * GoogleSQL
        -   * syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause).
        -   *
        +   * The filter needs to be a valid SQL expression for a WHERE clause in
        +   * BigQuery standard SQL syntax.
            * Example: col1 >= 0 AND col2 < 10
            * 
        * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResult.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResult.java index 9e73004a7f6b..1f5f6678617f 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResult.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResult.java @@ -42,6 +42,7 @@ private DataQualityColumnResult(com.google.protobuf.GeneratedMessageV3.Builder + * Output only. Whether the column passed or failed. + * + * + * bool passed = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The passed. + */ + @java.lang.Override + public boolean getPassed() { + return passed_; + } + + public static final int DIMENSIONS_FIELD_NUMBER = 4; + + @SuppressWarnings("serial") + private java.util.List dimensions_; + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getDimensionsList() { + return dimensions_; + } + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public java.util.List + getDimensionsOrBuilderList() { + return dimensions_; + } + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public int getDimensionsCount() { + return dimensions_.size(); + } + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataQualityDimensionResult getDimensions(int index) { + return dimensions_.get(index); + } + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder getDimensionsOrBuilder( + int index) { + return dimensions_.get(index); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -182,6 +290,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeFloat(2, score_); } + if (passed_ != false) { + output.writeBool(3, passed_); + } + for (int i = 0; i < dimensions_.size(); i++) { + output.writeMessage(4, dimensions_.get(i)); + } getUnknownFields().writeTo(output); } @@ -197,6 +311,12 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, score_); } + if (passed_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, passed_); + } + for (int i = 0; i < dimensions_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, dimensions_.get(i)); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -219,6 +339,8 @@ public boolean equals(final java.lang.Object obj) { if (java.lang.Float.floatToIntBits(getScore()) != java.lang.Float.floatToIntBits(other.getScore())) return false; } + if (getPassed() != other.getPassed()) return false; + if (!getDimensionsList().equals(other.getDimensionsList())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -236,6 +358,12 @@ public int hashCode() { hash = (37 * hash) + SCORE_FIELD_NUMBER; hash = (53 * hash) + java.lang.Float.floatToIntBits(getScore()); } + hash = (37 * hash) + PASSED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getPassed()); + if (getDimensionsCount() > 0) { + hash = (37 * hash) + DIMENSIONS_FIELD_NUMBER; + hash = (53 * hash) + getDimensionsList().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -379,6 +507,14 @@ public Builder clear() { bitField0_ = 0; column_ = ""; score_ = 0F; + passed_ = false; + if (dimensionsBuilder_ == null) { + dimensions_ = java.util.Collections.emptyList(); + } else { + dimensions_ = null; + dimensionsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000008); return this; } @@ -406,6 +542,7 @@ public com.google.cloud.dataplex.v1.DataQualityColumnResult build() { public com.google.cloud.dataplex.v1.DataQualityColumnResult buildPartial() { com.google.cloud.dataplex.v1.DataQualityColumnResult result = new com.google.cloud.dataplex.v1.DataQualityColumnResult(this); + buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } @@ -413,6 +550,19 @@ public com.google.cloud.dataplex.v1.DataQualityColumnResult buildPartial() { return result; } + private void buildPartialRepeatedFields( + com.google.cloud.dataplex.v1.DataQualityColumnResult result) { + if (dimensionsBuilder_ == null) { + if (((bitField0_ & 0x00000008) != 0)) { + dimensions_ = java.util.Collections.unmodifiableList(dimensions_); + bitField0_ = (bitField0_ & ~0x00000008); + } + result.dimensions_ = dimensions_; + } else { + result.dimensions_ = dimensionsBuilder_.build(); + } + } + private void buildPartial0(com.google.cloud.dataplex.v1.DataQualityColumnResult result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { @@ -423,6 +573,9 @@ private void buildPartial0(com.google.cloud.dataplex.v1.DataQualityColumnResult result.score_ = score_; to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.passed_ = passed_; + } result.bitField0_ |= to_bitField0_; } @@ -480,6 +633,36 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.DataQualityColumnResult ot if (other.hasScore()) { setScore(other.getScore()); } + if (other.getPassed() != false) { + setPassed(other.getPassed()); + } + if (dimensionsBuilder_ == null) { + if (!other.dimensions_.isEmpty()) { + if (dimensions_.isEmpty()) { + dimensions_ = other.dimensions_; + bitField0_ = (bitField0_ & ~0x00000008); + } else { + ensureDimensionsIsMutable(); + dimensions_.addAll(other.dimensions_); + } + onChanged(); + } + } else { + if (!other.dimensions_.isEmpty()) { + if (dimensionsBuilder_.isEmpty()) { + dimensionsBuilder_.dispose(); + dimensionsBuilder_ = null; + dimensions_ = other.dimensions_; + bitField0_ = (bitField0_ & ~0x00000008); + dimensionsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getDimensionsFieldBuilder() + : null; + } else { + dimensionsBuilder_.addAllMessages(other.dimensions_); + } + } + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -518,6 +701,26 @@ public Builder mergeFrom( bitField0_ |= 0x00000002; break; } // case 21 + case 24: + { + passed_ = input.readBool(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 34: + { + com.google.cloud.dataplex.v1.DataQualityDimensionResult m = + input.readMessage( + com.google.cloud.dataplex.v1.DataQualityDimensionResult.parser(), + extensionRegistry); + if (dimensionsBuilder_ == null) { + ensureDimensionsIsMutable(); + dimensions_.add(m); + } else { + dimensionsBuilder_.addMessage(m); + } + break; + } // case 34 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -736,6 +939,478 @@ public Builder clearScore() { return this; } + private boolean passed_; + + /** + * + * + *
        +     * Output only. Whether the column passed or failed.
        +     * 
        + * + * bool passed = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The passed. + */ + @java.lang.Override + public boolean getPassed() { + return passed_; + } + + /** + * + * + *
        +     * Output only. Whether the column passed or failed.
        +     * 
        + * + * bool passed = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The passed to set. + * @return This builder for chaining. + */ + public Builder setPassed(boolean value) { + + passed_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Whether the column passed or failed.
        +     * 
        + * + * bool passed = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearPassed() { + bitField0_ = (bitField0_ & ~0x00000004); + passed_ = false; + onChanged(); + return this; + } + + private java.util.List dimensions_ = + java.util.Collections.emptyList(); + + private void ensureDimensionsIsMutable() { + if (!((bitField0_ & 0x00000008) != 0)) { + dimensions_ = + new java.util.ArrayList( + dimensions_); + bitField0_ |= 0x00000008; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.DataQualityDimensionResult, + com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder, + com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder> + dimensionsBuilder_; + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getDimensionsList() { + if (dimensionsBuilder_ == null) { + return java.util.Collections.unmodifiableList(dimensions_); + } else { + return dimensionsBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public int getDimensionsCount() { + if (dimensionsBuilder_ == null) { + return dimensions_.size(); + } else { + return dimensionsBuilder_.getCount(); + } + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataQualityDimensionResult getDimensions(int index) { + if (dimensionsBuilder_ == null) { + return dimensions_.get(index); + } else { + return dimensionsBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setDimensions( + int index, com.google.cloud.dataplex.v1.DataQualityDimensionResult value) { + if (dimensionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionsIsMutable(); + dimensions_.set(index, value); + onChanged(); + } else { + dimensionsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setDimensions( + int index, + com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder builderForValue) { + if (dimensionsBuilder_ == null) { + ensureDimensionsIsMutable(); + dimensions_.set(index, builderForValue.build()); + onChanged(); + } else { + dimensionsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addDimensions(com.google.cloud.dataplex.v1.DataQualityDimensionResult value) { + if (dimensionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionsIsMutable(); + dimensions_.add(value); + onChanged(); + } else { + dimensionsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addDimensions( + int index, com.google.cloud.dataplex.v1.DataQualityDimensionResult value) { + if (dimensionsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureDimensionsIsMutable(); + dimensions_.add(index, value); + onChanged(); + } else { + dimensionsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addDimensions( + com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder builderForValue) { + if (dimensionsBuilder_ == null) { + ensureDimensionsIsMutable(); + dimensions_.add(builderForValue.build()); + onChanged(); + } else { + dimensionsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addDimensions( + int index, + com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder builderForValue) { + if (dimensionsBuilder_ == null) { + ensureDimensionsIsMutable(); + dimensions_.add(index, builderForValue.build()); + onChanged(); + } else { + dimensionsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder addAllDimensions( + java.lang.Iterable + values) { + if (dimensionsBuilder_ == null) { + ensureDimensionsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, dimensions_); + onChanged(); + } else { + dimensionsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearDimensions() { + if (dimensionsBuilder_ == null) { + dimensions_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + onChanged(); + } else { + dimensionsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder removeDimensions(int index) { + if (dimensionsBuilder_ == null) { + ensureDimensionsIsMutable(); + dimensions_.remove(index); + onChanged(); + } else { + dimensionsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder getDimensionsBuilder( + int index) { + return getDimensionsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder getDimensionsOrBuilder( + int index) { + if (dimensionsBuilder_ == null) { + return dimensions_.get(index); + } else { + return dimensionsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List< + ? extends com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder> + getDimensionsOrBuilderList() { + if (dimensionsBuilder_ != null) { + return dimensionsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(dimensions_); + } + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder addDimensionsBuilder() { + return getDimensionsFieldBuilder() + .addBuilder(com.google.cloud.dataplex.v1.DataQualityDimensionResult.getDefaultInstance()); + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder addDimensionsBuilder( + int index) { + return getDimensionsFieldBuilder() + .addBuilder( + index, com.google.cloud.dataplex.v1.DataQualityDimensionResult.getDefaultInstance()); + } + + /** + * + * + *
        +     * Output only. The dimension-level results for this column.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public java.util.List + getDimensionsBuilderList() { + return getDimensionsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.DataQualityDimensionResult, + com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder, + com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder> + getDimensionsFieldBuilder() { + if (dimensionsBuilder_ == null) { + dimensionsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.DataQualityDimensionResult, + com.google.cloud.dataplex.v1.DataQualityDimensionResult.Builder, + com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder>( + dimensions_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); + dimensions_ = null; + } + return dimensionsBuilder_; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResultOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResultOrBuilder.java index d092efa7b1c0..f7e5aa73e92a 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResultOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityColumnResultOrBuilder.java @@ -83,4 +83,84 @@ public interface DataQualityColumnResultOrBuilder * @return The score. */ float getScore(); + + /** + * + * + *
        +   * Output only. Whether the column passed or failed.
        +   * 
        + * + * bool passed = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The passed. + */ + boolean getPassed(); + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List getDimensionsList(); + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.dataplex.v1.DataQualityDimensionResult getDimensions(int index); + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + int getDimensionsCount(); + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + java.util.List + getDimensionsOrBuilderList(); + + /** + * + * + *
        +   * Output only. The dimension-level results for this column.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.DataQualityDimensionResult dimensions = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder getDimensionsOrBuilder( + int index); } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimension.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimension.java index 5a7d3938cbfb..159c7e3710cf 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimension.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimension.java @@ -74,11 +74,11 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -   * Optional. The dimension name a rule belongs to. Custom dimension name is
        +   * Output only. The dimension name a rule belongs to. Custom dimension name is
            * supported with all uppercase letters and maximum length of 30 characters.
            * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @@ -99,11 +99,11 @@ public java.lang.String getName() { * * *
        -   * Optional. The dimension name a rule belongs to. Custom dimension name is
        +   * Output only. The dimension name a rule belongs to. Custom dimension name is
            * supported with all uppercase letters and maximum length of 30 characters.
            * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ @@ -470,11 +470,11 @@ public Builder mergeFrom( * * *
        -     * Optional. The dimension name a rule belongs to. Custom dimension name is
        +     * Output only. The dimension name a rule belongs to. Custom dimension name is
              * supported with all uppercase letters and maximum length of 30 characters.
              * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @@ -494,11 +494,11 @@ public java.lang.String getName() { * * *
        -     * Optional. The dimension name a rule belongs to. Custom dimension name is
        +     * Output only. The dimension name a rule belongs to. Custom dimension name is
              * supported with all uppercase letters and maximum length of 30 characters.
              * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ @@ -518,11 +518,11 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
        -     * Optional. The dimension name a rule belongs to. Custom dimension name is
        +     * Output only. The dimension name a rule belongs to. Custom dimension name is
              * supported with all uppercase letters and maximum length of 30 characters.
              * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The name to set. * @return This builder for chaining. @@ -541,11 +541,11 @@ public Builder setName(java.lang.String value) { * * *
        -     * Optional. The dimension name a rule belongs to. Custom dimension name is
        +     * Output only. The dimension name a rule belongs to. Custom dimension name is
              * supported with all uppercase letters and maximum length of 30 characters.
              * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -560,11 +560,11 @@ public Builder clearName() { * * *
        -     * Optional. The dimension name a rule belongs to. Custom dimension name is
        +     * Output only. The dimension name a rule belongs to. Custom dimension name is
              * supported with all uppercase letters and maximum length of 30 characters.
              * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for name to set. * @return This builder for chaining. diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimensionOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimensionOrBuilder.java index 0722e36874f9..2105108f3e71 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimensionOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityDimensionOrBuilder.java @@ -28,11 +28,11 @@ public interface DataQualityDimensionOrBuilder * * *
        -   * Optional. The dimension name a rule belongs to. Custom dimension name is
        +   * Output only. The dimension name a rule belongs to. Custom dimension name is
            * supported with all uppercase letters and maximum length of 30 characters.
            * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The name. */ @@ -42,11 +42,11 @@ public interface DataQualityDimensionOrBuilder * * *
        -   * Optional. The dimension name a rule belongs to. Custom dimension name is
        +   * Output only. The dimension name a rule belongs to. Custom dimension name is
            * supported with all uppercase letters and maximum length of 30 characters.
            * 
        * - * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for name. */ diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityProto.java index 9867f03b0eaf..924485b29e36 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityProto.java @@ -141,59 +141,61 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "+google/cloud/dataplex/v1/data_quality." + "proto\022\030google.cloud.dataplex.v1\032\037google/" + "api/field_behavior.proto\032\031google/api/res" - + "ource.proto\032)google/cloud/dataplex/v1/processing.proto\"\300\010\n" + + "ource.proto\032/google/cloud/dataplex/v1/da" + + "tascans_common.proto\032)google/cloud/dataplex/v1/processing.proto\"\351\010\n" + "\017DataQualitySpec\022=\n" + "\005rules\030\001" + " \003(\0132).google.cloud.dataplex.v1.DataQualityRuleB\003\340A\002\022\035\n" + "\020sampling_percent\030\004 \001(\002B\003\340A\001\022\027\n\n" + "row_filter\030\005 \001(\tB\003\340A\001\022Y\n" - + "\021post_scan_actions\030\006 \001(\01329.google.cloud.data" - + "plex.v1.DataQualitySpec.PostScanActionsB\003\340A\001\032\332\006\n" + + "\021post_scan_actions\030\006 \001(\01329.google.c" + + "loud.dataplex.v1.DataQualitySpec.PostScanActionsB\003\340A\001\022\'\n" + + "\032catalog_publishing_enabled\030\010 \001(\010B\003\340A\001\032\332\006\n" + "\017PostScanActions\022f\n" - + "\017bigquery_export\030\001 \001(\0132H.google.cloud.dataplex.v1.Dat" - + "aQualitySpec.PostScanActions.BigQueryExportB\003\340A\001\022n\n" - + "\023notification_report\030\002 \001(\0132L.google.cloud.dataplex.v1.DataQualitySpec" - + ".PostScanActions.NotificationReportB\003\340A\001\032,\n" + + "\017bigquery_export\030\001 \001(\0132H.google.cloud.datap" + + "lex.v1.DataQualitySpec.PostScanActions.BigQueryExportB\003\340A\001\022n\n" + + "\023notification_report\030\002 \001(\0132L.google.cloud.dataplex.v1.DataQ" + + "ualitySpec.PostScanActions.NotificationReportB\003\340A\001\032,\n" + "\016BigQueryExport\022\032\n\r" + "results_table\030\001 \001(\tB\003\340A\001\032!\n\n" + "Recipients\022\023\n" + "\006emails\030\001 \003(\tB\003\340A\001\0325\n" + "\025ScoreThresholdTrigger\022\034\n" + "\017score_threshold\030\002 \001(\002B\003\340A\001\032\023\n" - + "\021JobFailureTrigger\032\017\n" - + "\r" + + "\021JobFailureTrigger\032\017\n\r" + "JobEndTrigger\032\300\003\n" - + "\022NotificationReport\022]\n" - + "\n" - + "recipients\030\001 \001(\0132D.google.cloud.dataple" - + "x.v1.DataQualitySpec.PostScanActions.RecipientsB\003\340A\002\022u\n" - + "\027score_threshold_trigger\030\002 \001(\0132O.google.cloud.dataplex.v1.DataQua" - + "litySpec.PostScanActions.ScoreThresholdTriggerB\003\340A\001\022m\n" - + "\023job_failure_trigger\030\004 \001(\0132K.google.cloud.dataplex.v1.DataQualityS" - + "pec.PostScanActions.JobFailureTriggerB\003\340A\001\022e\n" - + "\017job_end_trigger\030\005 \001(\0132G.google.clo" - + "ud.dataplex.v1.DataQualitySpec.PostScanActions.JobEndTriggerB\003\340A\001\"\354\006\n" + + "\022NotificationReport\022]\n\n" + + "recipients\030\001 \001(\0132D.google.clo" + + "ud.dataplex.v1.DataQualitySpec.PostScanActions.RecipientsB\003\340A\002\022u\n" + + "\027score_threshold_trigger\030\002 \001(\0132O.google.cloud.dataplex." + + "v1.DataQualitySpec.PostScanActions.ScoreThresholdTriggerB\003\340A\001\022m\n" + + "\023job_failure_trigger\030\004 \001(\0132K.google.cloud.dataplex.v1.Da" + + "taQualitySpec.PostScanActions.JobFailureTriggerB\003\340A\001\022e\n" + + "\017job_end_trigger\030\005 \001(\0132G." + + "google.cloud.dataplex.v1.DataQualitySpec.PostScanActions.JobEndTriggerB\003\340A\001\"\317\007\n" + "\021DataQualityResult\022\023\n" + "\006passed\030\005 \001(\010B\003\340A\003\022\027\n" + "\005score\030\t \001(\002B\003\340A\003H\000\210\001\001\022M\n\n" - + "dimensions\030\002 \003(\01324.goog" - + "le.cloud.dataplex.v1.DataQualityDimensionResultB\003\340A\003\022G\n" + + "dimensions\030\002 " + + "\003(\01324.google.cloud.dataplex.v1.DataQualityDimensionResultB\003\340A\003\022G\n" + "\007columns\030\n" + " \003(\01321.google.cloud.dataplex.v1.DataQualityColumnResultB\003\340A\003\022C\n" - + "\005rules\030\003" - + " \003(\0132/.google.cloud.dataplex.v1.DataQualityRuleResultB\003\340A\003\022\026\n" + + "\005rules\030\003 \003(\0132/.google." + + "cloud.dataplex.v1.DataQualityRuleResultB\003\340A\003\022\026\n" + "\trow_count\030\004 \001(\003B\003\340A\003\022@\n" - + "\014scanned_data\030\007 \001(\013" - + "2%.google.cloud.dataplex.v1.ScannedDataB\003\340A\003\022h\n" - + "\030post_scan_actions_result\030\010 \001(\0132A" - + ".google.cloud.dataplex.v1.DataQualityResult.PostScanActionsResultB\003\340A\003\032\375\002\n" + + "\014scanned_data\030\007" + + " \001(\0132%.google.cloud.dataplex.v1.ScannedDataB\003\340A\003\022h\n" + + "\030post_scan_actions_result\030\010 \001(\0132A.google.cloud.dataplex.v1.Data" + + "QualityResult.PostScanActionsResultB\003\340A\003\022a\n" + + "\031catalog_publishing_status\030\013 \001(\01329.go" + + "ogle.cloud.dataplex.v1.DataScanCatalogPublishingStatusB\003\340A\003\032\375\002\n" + "\025PostScanActionsResult\022{\n" - + "\026bigquery_export_result\030\001 \001(\0132V.google.cloud.dataplex.v1.Data" - + "QualityResult.PostScanActionsResult.BigQueryExportResultB\003\340A\003\032\346\001\n" + + "\026bigquery_export_result\030\001 \001(\0132V." + + "google.cloud.dataplex.v1.DataQualityResu" + + "lt.PostScanActionsResult.BigQueryExportResultB\003\340A\003\032\346\001\n" + "\024BigQueryExportResult\022p\n" - + "\005state\030\001 \001(\0162\\.google.cloud.dat" - + "aplex.v1.DataQualityResult.PostScanActio" - + "nsResult.BigQueryExportResult.StateB\003\340A\003\022\024\n" + + "\005state\030\001 \001(\0162\\.google.cloud.dataplex.v1.Da" + + "taQualityResult.PostScanActionsResult.BigQueryExportResult.StateB\003\340A\003\022\024\n" + "\007message\030\002 \001(\tB\003\340A\003\"F\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\r\n" @@ -213,32 +215,32 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + " \001(\tB\003\340A\003\022 \n" + "\023assertion_row_count\030\013 \001(\003B\003\340A\003\"\234\001\n" + "\032DataQualityDimensionResult\022F\n" - + "\tdimension\030\001 \001(\0132.." - + "google.cloud.dataplex.v1.DataQualityDimensionB\003\340A\003\022\023\n" + + "\tdimension\030\001 \001(\0132..google.clou" + + "d.dataplex.v1.DataQualityDimensionB\003\340A\003\022\023\n" + "\006passed\030\003 \001(\010B\003\340A\003\022\027\n" + "\005score\030\004 \001(\002B\003\340A\003H\000\210\001\001B\010\n" + "\006_score\")\n" + "\024DataQualityDimension\022\021\n" - + "\004name\030\001 \001(\tB\003\340A\001\"\215\016\n" + + "\004name\030\001 \001(\tB\003\340A\003\"\215\016\n" + "\017DataQualityRule\022W\n" - + "\021range_expectation\030\001 \001(\0132:.g" - + "oogle.cloud.dataplex.v1.DataQualityRule.RangeExpectationH\000\022\\\n" - + "\024non_null_expectation\030\002" - + " \001(\0132<.google.cloud.dataplex.v1.DataQualityRule.NonNullExpectationH\000\022S\n" + + "\021range_expectation\030\001 \001(\0132:.google.cloud" + + ".dataplex.v1.DataQualityRule.RangeExpectationH\000\022\\\n" + + "\024non_null_expectation\030\002 \001(\0132<." + + "google.cloud.dataplex.v1.DataQualityRule.NonNullExpectationH\000\022S\n" + "\017set_expectation\030\003" + " \001(\01328.google.cloud.dataplex.v1.DataQualityRule.SetExpectationH\000\022W\n" - + "\021regex_expectation\030\004 \001(\0132:.google.cloud." - + "dataplex.v1.DataQualityRule.RegexExpectationH\000\022a\n" - + "\026uniqueness_expectation\030d \001(\0132?" - + ".google.cloud.dataplex.v1.DataQualityRule.UniquenessExpectationH\000\022j\n" - + "\033statistic_range_expectation\030e \001(\0132C.google.cloud.da" - + "taplex.v1.DataQualityRule.StatisticRangeExpectationH\000\022g\n" - + "\031row_condition_expectation\030\310\001 \001(\0132A.google.cloud.dataplex.v1.Dat" - + "aQualityRule.RowConditionExpectationH\000\022k\n" - + "\033table_condition_expectation\030\311\001 \001(\0132C.g" - + "oogle.cloud.dataplex.v1.DataQualityRule.TableConditionExpectationH\000\022P\n\r" - + "sql_assertion\030\312\001" - + " \001(\01326.google.cloud.dataplex.v1.DataQualityRule.SqlAssertionH\000\022\024\n" + + "\021regex_expectation\030\004" + + " \001(\0132:.google.cloud.dataplex.v1.DataQualityRule.RegexExpectationH\000\022a\n" + + "\026uniqueness_expectation\030d \001(\0132?.google.clo" + + "ud.dataplex.v1.DataQualityRule.UniquenessExpectationH\000\022j\n" + + "\033statistic_range_expectation\030e \001(\0132C.google.cloud.dataplex.v1.D" + + "ataQualityRule.StatisticRangeExpectationH\000\022g\n" + + "\031row_condition_expectation\030\310\001 \001(\0132A" + + ".google.cloud.dataplex.v1.DataQualityRule.RowConditionExpectationH\000\022k\n" + + "\033table_condition_expectation\030\311\001 \001(\0132C.google.cloud" + + ".dataplex.v1.DataQualityRule.TableConditionExpectationH\000\022P\n\r" + + "sql_assertion\030\312\001 \001(\013" + + "26.google.cloud.dataplex.v1.DataQualityRule.SqlAssertionH\000\022\024\n" + "\006column\030\364\003 \001(\tB\003\340A\001\022\031\n" + "\013ignore_null\030\365\003 \001(\010B\003\340A\001\022\027\n" + "\tdimension\030\366\003 \001(\tB\003\340A\002\022\027\n" @@ -258,8 +260,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005regex\030\001 \001(\tB\003\340A\001\032\027\n" + "\025UniquenessExpectation\032\302\002\n" + "\031StatisticRangeExpectation\022k\n" - + "\tstatistic\030\001 \001(\0162S.google.cloud.dataplex.v1.DataQualityRule.Statis" - + "ticRangeExpectation.ColumnStatisticB\003\340A\001\022\026\n" + + "\tstatistic\030\001 \001(\0162S.google.cloud.datap" + + "lex.v1.DataQualityRule.StatisticRangeExpectation.ColumnStatisticB\003\340A\001\022\026\n" + "\tmin_value\030\002 \001(\tB\003\340A\001\022\026\n" + "\tmax_value\030\003 \001(\tB\003\340A\001\022\037\n" + "\022strict_min_enabled\030\004 \001(\010B\003\340A\001\022\037\n" @@ -275,15 +277,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\016sql_expression\030\001 \001(\tB\003\340A\001\032*\n" + "\014SqlAssertion\022\032\n\r" + "sql_statement\030\001 \001(\tB\003\340A\001B\013\n" - + "\trule_type\"Q\n" + + "\trule_type\"\265\001\n" + "\027DataQualityColumnResult\022\023\n" + "\006column\030\001 \001(\tB\003\340A\003\022\027\n" - + "\005score\030\002 \001(\002B\003\340A\003H\000\210\001\001B\010\n" + + "\005score\030\002 \001(\002B\003\340A\003H\000\210\001\001\022\023\n" + + "\006passed\030\003 \001(\010B\003\340A\003\022M\n\n" + + "dimensions\030\004 \003(\01324.google.cloud.dat" + + "aplex.v1.DataQualityDimensionResultB\003\340A\003B\010\n" + "\006_scoreB\304\001\n" - + "\034com.google.cloud.dataplex.v1B\020DataQ" - + "ualityProtoP\001Z8cloud.google.com/go/dataplex/apiv1/dataplexpb;dataplexpb\352AU\n" - + "\035bigquery.googleapis.com/Table\0224projects/{pro" - + "ject}/datasets/{dataset}/tables/{table}b\006proto3" + + "\034com.google.cloud.dataplex.v1B\020DataQualityProtoP\001Z8cloud.google.co" + + "m/go/dataplex/apiv1/dataplexpb;dataplexpb\352AU\n" + + "\035bigquery.googleapis.com/Table\0224projects/{project}/datasets/{dataset}/table" + + "s/{table}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -291,6 +296,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.cloud.dataplex.v1.DataScansCommonProto.getDescriptor(), com.google.cloud.dataplex.v1.ProcessingProto.getDescriptor(), }); internal_static_google_cloud_dataplex_v1_DataQualitySpec_descriptor = @@ -299,7 +305,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_dataplex_v1_DataQualitySpec_descriptor, new java.lang.String[] { - "Rules", "SamplingPercent", "RowFilter", "PostScanActions", + "Rules", + "SamplingPercent", + "RowFilter", + "PostScanActions", + "CatalogPublishingEnabled", }); internal_static_google_cloud_dataplex_v1_DataQualitySpec_PostScanActions_descriptor = internal_static_google_cloud_dataplex_v1_DataQualitySpec_descriptor.getNestedTypes().get(0); @@ -379,6 +389,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "RowCount", "ScannedData", "PostScanActionsResult", + "CatalogPublishingStatus", }); internal_static_google_cloud_dataplex_v1_DataQualityResult_PostScanActionsResult_descriptor = internal_static_google_cloud_dataplex_v1_DataQualityResult_descriptor @@ -529,7 +540,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_dataplex_v1_DataQualityColumnResult_descriptor, new java.lang.String[] { - "Column", "Score", + "Column", "Score", "Passed", "Dimensions", }); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); @@ -539,6 +550,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { descriptor, registry); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.dataplex.v1.DataScansCommonProto.getDescriptor(); com.google.cloud.dataplex.v1.ProcessingProto.getDescriptor(); } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResult.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResult.java index 2ba0548cc40c..57326bd83907 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResult.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResult.java @@ -2540,6 +2540,69 @@ public boolean hasPostScanActionsResult() { : postScanActionsResult_; } + public static final int CATALOG_PUBLISHING_STATUS_FIELD_NUMBER = 11; + private com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalogPublishingStatus_; + + /** + * + * + *
        +   * Output only. The status of publishing the data scan as Dataplex Universal
        +   * Catalog metadata.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the catalogPublishingStatus field is set. + */ + @java.lang.Override + public boolean hasCatalogPublishingStatus() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +   * Output only. The status of publishing the data scan as Dataplex Universal
        +   * Catalog metadata.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The catalogPublishingStatus. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus getCatalogPublishingStatus() { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } + + /** + * + * + *
        +   * Output only. The status of publishing the data scan as Dataplex Universal
        +   * Catalog metadata.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder + getCatalogPublishingStatusOrBuilder() { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -2578,6 +2641,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < columns_.size(); i++) { output.writeMessage(10, columns_.get(i)); } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeMessage(11, getCatalogPublishingStatus()); + } getUnknownFields().writeTo(output); } @@ -2612,6 +2678,11 @@ public int getSerializedSize() { for (int i = 0; i < columns_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, columns_.get(i)); } + if (((bitField0_ & 0x00000008) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 11, getCatalogPublishingStatus()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -2646,6 +2717,10 @@ public boolean equals(final java.lang.Object obj) { if (hasPostScanActionsResult()) { if (!getPostScanActionsResult().equals(other.getPostScanActionsResult())) return false; } + if (hasCatalogPublishingStatus() != other.hasCatalogPublishingStatus()) return false; + if (hasCatalogPublishingStatus()) { + if (!getCatalogPublishingStatus().equals(other.getCatalogPublishingStatus())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2685,6 +2760,10 @@ public int hashCode() { hash = (37 * hash) + POST_SCAN_ACTIONS_RESULT_FIELD_NUMBER; hash = (53 * hash) + getPostScanActionsResult().hashCode(); } + if (hasCatalogPublishingStatus()) { + hash = (37 * hash) + CATALOG_PUBLISHING_STATUS_FIELD_NUMBER; + hash = (53 * hash) + getCatalogPublishingStatus().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -2831,6 +2910,7 @@ private void maybeForceBuilderInitialization() { getRulesFieldBuilder(); getScannedDataFieldBuilder(); getPostScanActionsResultFieldBuilder(); + getCatalogPublishingStatusFieldBuilder(); } } @@ -2872,6 +2952,11 @@ public Builder clear() { postScanActionsResultBuilder_.dispose(); postScanActionsResultBuilder_ = null; } + catalogPublishingStatus_ = null; + if (catalogPublishingStatusBuilder_ != null) { + catalogPublishingStatusBuilder_.dispose(); + catalogPublishingStatusBuilder_ = null; + } return this; } @@ -2962,6 +3047,13 @@ private void buildPartial0(com.google.cloud.dataplex.v1.DataQualityResult result : postScanActionsResultBuilder_.build(); to_bitField0_ |= 0x00000004; } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.catalogPublishingStatus_ = + catalogPublishingStatusBuilder_ == null + ? catalogPublishingStatus_ + : catalogPublishingStatusBuilder_.build(); + to_bitField0_ |= 0x00000008; + } result.bitField0_ |= to_bitField0_; } @@ -3106,6 +3198,9 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.DataQualityResult other) { if (other.hasPostScanActionsResult()) { mergePostScanActionsResult(other.getPostScanActionsResult()); } + if (other.hasCatalogPublishingStatus()) { + mergeCatalogPublishingStatus(other.getCatalogPublishingStatus()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -3205,6 +3300,13 @@ public Builder mergeFrom( } break; } // case 82 + case 90: + { + input.readMessage( + getCatalogPublishingStatusFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000100; + break; + } // case 90 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -5193,6 +5295,235 @@ public Builder clearPostScanActionsResult() { return postScanActionsResultBuilder_; } + private com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalogPublishingStatus_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder> + catalogPublishingStatusBuilder_; + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the catalogPublishingStatus field is set. + */ + public boolean hasCatalogPublishingStatus() { + return ((bitField0_ & 0x00000100) != 0); + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The catalogPublishingStatus. + */ + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus + getCatalogPublishingStatus() { + if (catalogPublishingStatusBuilder_ == null) { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } else { + return catalogPublishingStatusBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCatalogPublishingStatus( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus value) { + if (catalogPublishingStatusBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + catalogPublishingStatus_ = value; + } else { + catalogPublishingStatusBuilder_.setMessage(value); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder setCatalogPublishingStatus( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder builderForValue) { + if (catalogPublishingStatusBuilder_ == null) { + catalogPublishingStatus_ = builderForValue.build(); + } else { + catalogPublishingStatusBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder mergeCatalogPublishingStatus( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus value) { + if (catalogPublishingStatusBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0) + && catalogPublishingStatus_ != null + && catalogPublishingStatus_ + != com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus + .getDefaultInstance()) { + getCatalogPublishingStatusBuilder().mergeFrom(value); + } else { + catalogPublishingStatus_ = value; + } + } else { + catalogPublishingStatusBuilder_.mergeFrom(value); + } + if (catalogPublishingStatus_ != null) { + bitField0_ |= 0x00000100; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public Builder clearCatalogPublishingStatus() { + bitField0_ = (bitField0_ & ~0x00000100); + catalogPublishingStatus_ = null; + if (catalogPublishingStatusBuilder_ != null) { + catalogPublishingStatusBuilder_.dispose(); + catalogPublishingStatusBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder + getCatalogPublishingStatusBuilder() { + bitField0_ |= 0x00000100; + onChanged(); + return getCatalogPublishingStatusFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder + getCatalogPublishingStatusOrBuilder() { + if (catalogPublishingStatusBuilder_ != null) { + return catalogPublishingStatusBuilder_.getMessageOrBuilder(); + } else { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } + } + + /** + * + * + *
        +     * Output only. The status of publishing the data scan as Dataplex Universal
        +     * Catalog metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder> + getCatalogPublishingStatusFieldBuilder() { + if (catalogPublishingStatusBuilder_ == null) { + catalogPublishingStatusBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder>( + getCatalogPublishingStatus(), getParentForChildren(), isClean()); + catalogPublishingStatus_ = null; + } + return catalogPublishingStatusBuilder_; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResultOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResultOrBuilder.java index 3184783bc4cf..6887e5e8885c 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResultOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityResultOrBuilder.java @@ -395,4 +395,51 @@ com.google.cloud.dataplex.v1.DataQualityDimensionResultOrBuilder getDimensionsOr */ com.google.cloud.dataplex.v1.DataQualityResult.PostScanActionsResultOrBuilder getPostScanActionsResultOrBuilder(); + + /** + * + * + *
        +   * Output only. The status of publishing the data scan as Dataplex Universal
        +   * Catalog metadata.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return Whether the catalogPublishingStatus field is set. + */ + boolean hasCatalogPublishingStatus(); + + /** + * + * + *
        +   * Output only. The status of publishing the data scan as Dataplex Universal
        +   * Catalog metadata.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The catalogPublishingStatus. + */ + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus getCatalogPublishingStatus(); + + /** + * + * + *
        +   * Output only. The status of publishing the data scan as Dataplex Universal
        +   * Catalog metadata.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder + getCatalogPublishingStatusOrBuilder(); } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRule.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRule.java index 53f8b476d23f..2a5d30a448a4 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRule.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRule.java @@ -7895,9 +7895,8 @@ public boolean getIgnoreNull() { * *
            * Required. The dimension a rule belongs to. Results are also aggregated at
        -   * the dimension level. Supported dimensions are **["COMPLETENESS",
        -   * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -   * "VOLUME"]**
        +   * the dimension level. Custom dimension name is supported with all uppercase
        +   * letters and maximum length of 30 characters.
            * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -7922,9 +7921,8 @@ public java.lang.String getDimension() { * *
            * Required. The dimension a rule belongs to. Results are also aggregated at
        -   * the dimension level. Supported dimensions are **["COMPLETENESS",
        -   * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -   * "VOLUME"]**
        +   * the dimension level. Custom dimension name is supported with all uppercase
        +   * letters and maximum length of 30 characters.
            * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -11355,9 +11353,8 @@ public Builder clearIgnoreNull() { * *
              * Required. The dimension a rule belongs to. Results are also aggregated at
        -     * the dimension level. Supported dimensions are **["COMPLETENESS",
        -     * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -     * "VOLUME"]**
        +     * the dimension level. Custom dimension name is supported with all uppercase
        +     * letters and maximum length of 30 characters.
              * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -11381,9 +11378,8 @@ public java.lang.String getDimension() { * *
              * Required. The dimension a rule belongs to. Results are also aggregated at
        -     * the dimension level. Supported dimensions are **["COMPLETENESS",
        -     * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -     * "VOLUME"]**
        +     * the dimension level. Custom dimension name is supported with all uppercase
        +     * letters and maximum length of 30 characters.
              * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -11407,9 +11403,8 @@ public com.google.protobuf.ByteString getDimensionBytes() { * *
              * Required. The dimension a rule belongs to. Results are also aggregated at
        -     * the dimension level. Supported dimensions are **["COMPLETENESS",
        -     * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -     * "VOLUME"]**
        +     * the dimension level. Custom dimension name is supported with all uppercase
        +     * letters and maximum length of 30 characters.
              * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -11432,9 +11427,8 @@ public Builder setDimension(java.lang.String value) { * *
              * Required. The dimension a rule belongs to. Results are also aggregated at
        -     * the dimension level. Supported dimensions are **["COMPLETENESS",
        -     * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -     * "VOLUME"]**
        +     * the dimension level. Custom dimension name is supported with all uppercase
        +     * letters and maximum length of 30 characters.
              * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -11453,9 +11447,8 @@ public Builder clearDimension() { * *
              * Required. The dimension a rule belongs to. Results are also aggregated at
        -     * the dimension level. Supported dimensions are **["COMPLETENESS",
        -     * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -     * "VOLUME"]**
        +     * the dimension level. Custom dimension name is supported with all uppercase
        +     * letters and maximum length of 30 characters.
              * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRuleOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRuleOrBuilder.java index d633f271ffda..de71f6a3012e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRuleOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualityRuleOrBuilder.java @@ -467,9 +467,8 @@ public interface DataQualityRuleOrBuilder * *
            * Required. The dimension a rule belongs to. Results are also aggregated at
        -   * the dimension level. Supported dimensions are **["COMPLETENESS",
        -   * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -   * "VOLUME"]**
        +   * the dimension level. Custom dimension name is supported with all uppercase
        +   * letters and maximum length of 30 characters.
            * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; @@ -483,9 +482,8 @@ public interface DataQualityRuleOrBuilder * *
            * Required. The dimension a rule belongs to. Results are also aggregated at
        -   * the dimension level. Supported dimensions are **["COMPLETENESS",
        -   * "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS",
        -   * "VOLUME"]**
        +   * the dimension level. Custom dimension name is supported with all uppercase
        +   * letters and maximum length of 30 characters.
            * 
        * * string dimension = 502 [(.google.api.field_behavior) = REQUIRED]; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpec.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpec.java index 92cca70ea5e8..ef0de9369578 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpec.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpec.java @@ -6587,6 +6587,26 @@ public com.google.cloud.dataplex.v1.DataQualitySpec.PostScanActions getPostScanA : postScanActions_; } + public static final int CATALOG_PUBLISHING_ENABLED_FIELD_NUMBER = 8; + private boolean catalogPublishingEnabled_ = false; + + /** + * + * + *
        +   * Optional. If set, the latest DataScan job result will be published as
        +   * Dataplex Universal Catalog metadata.
        +   * 
        + * + * bool catalog_publishing_enabled = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The catalogPublishingEnabled. + */ + @java.lang.Override + public boolean getCatalogPublishingEnabled() { + return catalogPublishingEnabled_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -6613,6 +6633,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(6, getPostScanActions()); } + if (catalogPublishingEnabled_ != false) { + output.writeBool(8, catalogPublishingEnabled_); + } getUnknownFields().writeTo(output); } @@ -6634,6 +6657,9 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getPostScanActions()); } + if (catalogPublishingEnabled_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, catalogPublishingEnabled_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -6658,6 +6684,7 @@ public boolean equals(final java.lang.Object obj) { if (hasPostScanActions()) { if (!getPostScanActions().equals(other.getPostScanActions())) return false; } + if (getCatalogPublishingEnabled() != other.getCatalogPublishingEnabled()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -6681,6 +6708,8 @@ public int hashCode() { hash = (37 * hash) + POST_SCAN_ACTIONS_FIELD_NUMBER; hash = (53 * hash) + getPostScanActions().hashCode(); } + hash = (37 * hash) + CATALOG_PUBLISHING_ENABLED_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getCatalogPublishingEnabled()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -6845,6 +6874,7 @@ public Builder clear() { postScanActionsBuilder_.dispose(); postScanActionsBuilder_ = null; } + catalogPublishingEnabled_ = false; return this; } @@ -6906,6 +6936,9 @@ private void buildPartial0(com.google.cloud.dataplex.v1.DataQualitySpec result) postScanActionsBuilder_ == null ? postScanActions_ : postScanActionsBuilder_.build(); to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.catalogPublishingEnabled_ = catalogPublishingEnabled_; + } result.bitField0_ |= to_bitField0_; } @@ -6992,6 +7025,9 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.DataQualitySpec other) { if (other.hasPostScanActions()) { mergePostScanActions(other.getPostScanActions()); } + if (other.getCatalogPublishingEnabled() != false) { + setCatalogPublishingEnabled(other.getCatalogPublishingEnabled()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -7049,6 +7085,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 50 + case 64: + { + catalogPublishingEnabled_ = input.readBool(); + bitField0_ |= 0x00000010; + break; + } // case 64 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -7917,6 +7959,65 @@ public Builder clearPostScanActions() { return postScanActionsBuilder_; } + private boolean catalogPublishingEnabled_; + + /** + * + * + *
        +     * Optional. If set, the latest DataScan job result will be published as
        +     * Dataplex Universal Catalog metadata.
        +     * 
        + * + * bool catalog_publishing_enabled = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The catalogPublishingEnabled. + */ + @java.lang.Override + public boolean getCatalogPublishingEnabled() { + return catalogPublishingEnabled_; + } + + /** + * + * + *
        +     * Optional. If set, the latest DataScan job result will be published as
        +     * Dataplex Universal Catalog metadata.
        +     * 
        + * + * bool catalog_publishing_enabled = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The catalogPublishingEnabled to set. + * @return This builder for chaining. + */ + public Builder setCatalogPublishingEnabled(boolean value) { + + catalogPublishingEnabled_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. If set, the latest DataScan job result will be published as
        +     * Dataplex Universal Catalog metadata.
        +     * 
        + * + * bool catalog_publishing_enabled = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearCatalogPublishingEnabled() { + bitField0_ = (bitField0_ & ~0x00000010); + catalogPublishingEnabled_ = false; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpecOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpecOrBuilder.java index 899920b5829f..1110dc160071 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpecOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataQualitySpecOrBuilder.java @@ -193,4 +193,18 @@ public interface DataQualitySpecOrBuilder */ com.google.cloud.dataplex.v1.DataQualitySpec.PostScanActionsOrBuilder getPostScanActionsOrBuilder(); + + /** + * + * + *
        +   * Optional. If set, the latest DataScan job result will be published as
        +   * Dataplex Universal Catalog metadata.
        +   * 
        + * + * bool catalog_publishing_enabled = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The catalogPublishingEnabled. + */ + boolean getCatalogPublishingEnabled(); } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScan.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScan.java index 7438e4fa3f62..d6824a9fc256 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScan.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScan.java @@ -2958,7 +2958,7 @@ public ResultCase getResultCase() { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -2987,7 +2987,7 @@ public java.lang.String getName() { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -4974,7 +4974,7 @@ public Builder clearResult() { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -5002,7 +5002,7 @@ public java.lang.String getName() { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -5030,7 +5030,7 @@ public com.google.protobuf.ByteString getNameBytes() { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -5057,7 +5057,7 @@ public Builder setName(java.lang.String value) { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -5080,7 +5080,7 @@ public Builder clearName() { * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanCatalogPublishingStatus.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanCatalogPublishingStatus.java new file mode 100644 index 000000000000..471380192dd9 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanCatalogPublishingStatus.java @@ -0,0 +1,792 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/datascans_common.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * The status of publishing the data scan result as Dataplex Universal Catalog
        + * metadata.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DataScanCatalogPublishingStatus} + */ +public final class DataScanCatalogPublishingStatus extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) + DataScanCatalogPublishingStatusOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DataScanCatalogPublishingStatus.newBuilder() to construct. + private DataScanCatalogPublishingStatus( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DataScanCatalogPublishingStatus() { + state_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DataScanCatalogPublishingStatus(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.DataScansCommonProto + .internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.DataScansCommonProto + .internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.class, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder.class); + } + + /** + * + * + *
        +   * Execution state for the publishing.
        +   * 
        + * + * Protobuf enum {@code google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
        +     * The publishing state is unspecified.
        +     * 
        + * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
        +     * Publish to catalog completed successfully.
        +     * 
        + * + * SUCCEEDED = 1; + */ + SUCCEEDED(1), + /** + * + * + *
        +     * Publish to catalog failed.
        +     * 
        + * + * FAILED = 2; + */ + FAILED(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
        +     * The publishing state is unspecified.
        +     * 
        + * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
        +     * Publish to catalog completed successfully.
        +     * 
        + * + * SUCCEEDED = 1; + */ + public static final int SUCCEEDED_VALUE = 1; + + /** + * + * + *
        +     * Publish to catalog failed.
        +     * 
        + * + * FAILED = 2; + */ + public static final int FAILED_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 SUCCEEDED; + case 2: + 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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.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.dataplex.v1.DataScanCatalogPublishingStatus.State) + } + + public static final int STATE_FIELD_NUMBER = 1; + private int state_ = 0; + + /** + * + * + *
        +   * Output only. Execution state for catalog publishing.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.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. Execution state for catalog publishing.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State getState() { + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State result = + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State.forNumber(state_); + return result == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.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 (state_ + != com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State.STATE_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, state_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (state_ + != com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State.STATE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, state_); + } + 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.dataplex.v1.DataScanCatalogPublishingStatus)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus other = + (com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) obj; + + if (state_ != other.state_) 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) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus 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.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus 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.dataplex.v1.DataScanCatalogPublishingStatus parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DataScanCatalogPublishingStatus 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * The status of publishing the data scan result as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DataScanCatalogPublishingStatus} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.DataScansCommonProto + .internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.DataScansCommonProto + .internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.class, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + state_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.DataScansCommonProto + .internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus + getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus build() { + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus buildPartial() { + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus result = + new com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.state_ = state_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) { + return mergeFrom((com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus other) { + if (other + == com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance()) + return this; + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + 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: + { + state_ = 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 state_ = 0; + + /** + * + * + *
        +     * Output only. Execution state for catalog publishing.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.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. Execution state for catalog publishing.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.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_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Execution state for catalog publishing.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State getState() { + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State result = + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State.forNumber(state_); + return result == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State.UNRECOGNIZED + : result; + } + + /** + * + * + *
        +     * Output only. Execution state for catalog publishing.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000001; + state_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Execution state for catalog publishing.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearState() { + bitField0_ = (bitField0_ & ~0x00000001); + state_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) + private static final com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus(); + } + + public static com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DataScanCatalogPublishingStatus 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.dataplex.v1.DataScanCatalogPublishingStatus getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanCatalogPublishingStatusOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanCatalogPublishingStatusOrBuilder.java new file mode 100644 index 000000000000..a46d856d3294 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanCatalogPublishingStatusOrBuilder.java @@ -0,0 +1,56 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/datascans_common.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface DataScanCatalogPublishingStatusOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.DataScanCatalogPublishingStatus) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Output only. Execution state for catalog publishing.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + + /** + * + * + *
        +   * Output only. Execution state for catalog publishing.
        +   * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The state. + */ + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.State getState(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java index fa4e89fd99c0..4dd9169479a6 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEvent.java @@ -318,7 +318,7 @@ public enum State implements com.google.protobuf.ProtocolMessageEnum { * * *
        -     * Data scan job was createed.
        +     * Data scan job was created.
              * 
        * * CREATED = 5; @@ -386,7 +386,7 @@ public enum State implements com.google.protobuf.ProtocolMessageEnum { * * *
        -     * Data scan job was createed.
        +     * Data scan job was created.
              * 
        * * CREATED = 5; @@ -7882,6 +7882,66 @@ public boolean hasPostScanActionsResult() { : postScanActionsResult_; } + public static final int CATALOG_PUBLISHING_STATUS_FIELD_NUMBER = 13; + private com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalogPublishingStatus_; + + /** + * + * + *
        +   * The status of publishing the data scan as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + * + * @return Whether the catalogPublishingStatus field is set. + */ + @java.lang.Override + public boolean hasCatalogPublishingStatus() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +   * The status of publishing the data scan as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + * + * @return The catalogPublishingStatus. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus getCatalogPublishingStatus() { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } + + /** + * + * + *
        +   * The status of publishing the data scan as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder + getCatalogPublishingStatusOrBuilder() { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -7934,6 +7994,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(12, getCreateTime()); } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeMessage(13, getCatalogPublishingStatus()); + } if (resultCase_ == 101) { output.writeMessage( 101, (com.google.cloud.dataplex.v1.DataScanEvent.DataProfileResult) result_); @@ -8000,6 +8063,11 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, getCreateTime()); } + if (((bitField0_ & 0x00000010) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 13, getCatalogPublishingStatus()); + } if (resultCase_ == 101) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( @@ -8064,6 +8132,10 @@ public boolean equals(final java.lang.Object obj) { if (hasPostScanActionsResult()) { if (!getPostScanActionsResult().equals(other.getPostScanActionsResult())) return false; } + if (hasCatalogPublishingStatus() != other.hasCatalogPublishingStatus()) return false; + if (hasCatalogPublishingStatus()) { + if (!getCatalogPublishingStatus().equals(other.getCatalogPublishingStatus())) return false; + } if (!getResultCase().equals(other.getResultCase())) return false; switch (resultCase_) { case 101: @@ -8129,6 +8201,10 @@ public int hashCode() { hash = (37 * hash) + POST_SCAN_ACTIONS_RESULT_FIELD_NUMBER; hash = (53 * hash) + getPostScanActionsResult().hashCode(); } + if (hasCatalogPublishingStatus()) { + hash = (37 * hash) + CATALOG_PUBLISHING_STATUS_FIELD_NUMBER; + hash = (53 * hash) + getCatalogPublishingStatus().hashCode(); + } switch (resultCase_) { case 101: hash = (37 * hash) + DATA_PROFILE_FIELD_NUMBER; @@ -8299,6 +8375,7 @@ private void maybeForceBuilderInitialization() { getStartTimeFieldBuilder(); getEndTimeFieldBuilder(); getPostScanActionsResultFieldBuilder(); + getCatalogPublishingStatusFieldBuilder(); } } @@ -8346,6 +8423,11 @@ public Builder clear() { postScanActionsResultBuilder_.dispose(); postScanActionsResultBuilder_ = null; } + catalogPublishingStatus_ = null; + if (catalogPublishingStatusBuilder_ != null) { + catalogPublishingStatusBuilder_.dispose(); + catalogPublishingStatusBuilder_ = null; + } resultCase_ = 0; result_ = null; appliedConfigsCase_ = 0; @@ -8431,6 +8513,13 @@ private void buildPartial0(com.google.cloud.dataplex.v1.DataScanEvent result) { : postScanActionsResultBuilder_.build(); to_bitField0_ |= 0x00000008; } + if (((from_bitField0_ & 0x00010000) != 0)) { + result.catalogPublishingStatus_ = + catalogPublishingStatusBuilder_ == null + ? catalogPublishingStatus_ + : catalogPublishingStatusBuilder_.build(); + to_bitField0_ |= 0x00000010; + } result.bitField0_ |= to_bitField0_; } @@ -8542,6 +8631,9 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.DataScanEvent other) { if (other.hasPostScanActionsResult()) { mergePostScanActionsResult(other.getPostScanActionsResult()); } + if (other.hasCatalogPublishingStatus()) { + mergeCatalogPublishingStatus(other.getCatalogPublishingStatus()); + } switch (other.getResultCase()) { case DATA_PROFILE: { @@ -8673,6 +8765,13 @@ public Builder mergeFrom( bitField0_ |= 0x00000004; break; } // case 98 + case 106: + { + input.readMessage( + getCatalogPublishingStatusFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00010000; + break; + } // case 106 case 810: { input.readMessage(getDataProfileFieldBuilder().getBuilder(), extensionRegistry); @@ -11328,6 +11427,235 @@ public Builder clearPostScanActionsResult() { return postScanActionsResultBuilder_; } + private com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalogPublishingStatus_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder> + catalogPublishingStatusBuilder_; + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + * + * @return Whether the catalogPublishingStatus field is set. + */ + public boolean hasCatalogPublishingStatus() { + return ((bitField0_ & 0x00010000) != 0); + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + * + * @return The catalogPublishingStatus. + */ + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus + getCatalogPublishingStatus() { + if (catalogPublishingStatusBuilder_ == null) { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } else { + return catalogPublishingStatusBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + public Builder setCatalogPublishingStatus( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus value) { + if (catalogPublishingStatusBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + catalogPublishingStatus_ = value; + } else { + catalogPublishingStatusBuilder_.setMessage(value); + } + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + public Builder setCatalogPublishingStatus( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder builderForValue) { + if (catalogPublishingStatusBuilder_ == null) { + catalogPublishingStatus_ = builderForValue.build(); + } else { + catalogPublishingStatusBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00010000; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + public Builder mergeCatalogPublishingStatus( + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus value) { + if (catalogPublishingStatusBuilder_ == null) { + if (((bitField0_ & 0x00010000) != 0) + && catalogPublishingStatus_ != null + && catalogPublishingStatus_ + != com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus + .getDefaultInstance()) { + getCatalogPublishingStatusBuilder().mergeFrom(value); + } else { + catalogPublishingStatus_ = value; + } + } else { + catalogPublishingStatusBuilder_.mergeFrom(value); + } + if (catalogPublishingStatus_ != null) { + bitField0_ |= 0x00010000; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + public Builder clearCatalogPublishingStatus() { + bitField0_ = (bitField0_ & ~0x00010000); + catalogPublishingStatus_ = null; + if (catalogPublishingStatusBuilder_ != null) { + catalogPublishingStatusBuilder_.dispose(); + catalogPublishingStatusBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder + getCatalogPublishingStatusBuilder() { + bitField0_ |= 0x00010000; + onChanged(); + return getCatalogPublishingStatusFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + public com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder + getCatalogPublishingStatusOrBuilder() { + if (catalogPublishingStatusBuilder_ != null) { + return catalogPublishingStatusBuilder_.getMessageOrBuilder(); + } else { + return catalogPublishingStatus_ == null + ? com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.getDefaultInstance() + : catalogPublishingStatus_; + } + } + + /** + * + * + *
        +     * The status of publishing the data scan as Dataplex Universal Catalog
        +     * metadata.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder> + getCatalogPublishingStatusFieldBuilder() { + if (catalogPublishingStatusBuilder_ == null) { + catalogPublishingStatusBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus.Builder, + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder>( + getCatalogPublishingStatus(), getParentForChildren(), isClean()); + catalogPublishingStatus_ = null; + } + return catalogPublishingStatusBuilder_; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEventOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEventOrBuilder.java index 0f3c64387fde..802c331c3032 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEventOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanEventOrBuilder.java @@ -549,6 +549,50 @@ public interface DataScanEventOrBuilder com.google.cloud.dataplex.v1.DataScanEvent.PostScanActionsResultOrBuilder getPostScanActionsResultOrBuilder(); + /** + * + * + *
        +   * The status of publishing the data scan as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + * + * @return Whether the catalogPublishingStatus field is set. + */ + boolean hasCatalogPublishingStatus(); + + /** + * + * + *
        +   * The status of publishing the data scan as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + * + * @return The catalogPublishingStatus. + */ + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus getCatalogPublishingStatus(); + + /** + * + * + *
        +   * The status of publishing the data scan as Dataplex Universal Catalog
        +   * metadata.
        +   * 
        + * + * .google.cloud.dataplex.v1.DataScanCatalogPublishingStatus catalog_publishing_status = 13; + * + */ + com.google.cloud.dataplex.v1.DataScanCatalogPublishingStatusOrBuilder + getCatalogPublishingStatusOrBuilder(); + com.google.cloud.dataplex.v1.DataScanEvent.ResultCase getResultCase(); com.google.cloud.dataplex.v1.DataScanEvent.AppliedConfigsCase getAppliedConfigsCase(); diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJob.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJob.java index 5ed4cd7d09e2..3886532ee6fc 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJob.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJob.java @@ -439,7 +439,7 @@ public ResultCase getResultCase() { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -469,7 +469,7 @@ public java.lang.String getName() { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -2018,7 +2018,7 @@ public Builder clearResult() { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -2047,7 +2047,7 @@ public java.lang.String getName() { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -2076,7 +2076,7 @@ public com.google.protobuf.ByteString getNameBytes() { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -2104,7 +2104,7 @@ public Builder setName(java.lang.String value) { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -2128,7 +2128,7 @@ public Builder clearName() { * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJobOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJobOrBuilder.java index e09e7ec778c9..bb20794e1b8a 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJobOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanJobOrBuilder.java @@ -32,7 +32,7 @@ public interface DataScanJobOrBuilder * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -51,7 +51,7 @@ public interface DataScanJobOrBuilder * the form: * `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanOrBuilder.java index 329af2d57aa5..fc8bcbc2846a 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScanOrBuilder.java @@ -31,7 +31,7 @@ public interface DataScanOrBuilder * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface DataScanOrBuilder * Output only. Identifier. The relative resource name of the scan, of the * form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScansCommonProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScansCommonProto.java new file mode 100644 index 000000000000..ccbf8e692992 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataScansCommonProto.java @@ -0,0 +1,79 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/datascans_common.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public final class DataScansCommonProto { + private DataScansCommonProto() {} + + 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_dataplex_v1_DataScanCatalogPublishingStatus_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_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/dataplex/v1/datascans_com" + + "mon.proto\022\030google.cloud.dataplex.v1\032\037goo" + + "gle/api/field_behavior.proto\"\261\001\n\037DataSca" + + "nCatalogPublishingStatus\022S\n\005state\030\001 \001(\0162" + + "?.google.cloud.dataplex.v1.DataScanCatal" + + "ogPublishingStatus.StateB\003\340A\003\"9\n\005State\022\025" + + "\n\021STATE_UNSPECIFIED\020\000\022\r\n\tSUCCEEDED\020\001\022\n\n\006" + + "FAILED\020\002Bp\n\034com.google.cloud.dataplex.v1" + + "B\024DataScansCommonProtoP\001Z8cloud.google.c" + + "om/go/dataplex/apiv1/dataplexpb;dataplex" + + "pbb\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.FieldBehaviorProto.getDescriptor(), + }); + internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dataplex_v1_DataScanCatalogPublishingStatus_descriptor, + new java.lang.String[] { + "State", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.api.FieldBehaviorProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSource.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSource.java index a520df472b54..69e33894868c 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSource.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSource.java @@ -118,8 +118,8 @@ public SourceCase getSourceCase() { * * *
        -   * Immutable. The Dataplex entity that represents the data source (e.g.
        -   * BigQuery table) for DataScan, of the form:
        +   * Immutable. The Dataplex Universal Catalog entity that represents the data
        +   * source (e.g. BigQuery table) for DataScan, of the form:
            * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
            * 
        * @@ -137,8 +137,8 @@ public boolean hasEntity() { * * *
        -   * Immutable. The Dataplex entity that represents the data source (e.g.
        -   * BigQuery table) for DataScan, of the form:
        +   * Immutable. The Dataplex Universal Catalog entity that represents the data
        +   * source (e.g. BigQuery table) for DataScan, of the form:
            * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
            * 
        * @@ -169,8 +169,8 @@ public java.lang.String getEntity() { * * *
        -   * Immutable. The Dataplex entity that represents the data source (e.g.
        -   * BigQuery table) for DataScan, of the form:
        +   * Immutable. The Dataplex Universal Catalog entity that represents the data
        +   * source (e.g. BigQuery table) for DataScan, of the form:
            * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
            * 
        * @@ -204,8 +204,12 @@ public com.google.protobuf.ByteString getEntityBytes() { * *
            * Immutable. The service-qualified full resource name of the cloud resource
        -   * for a DataScan job to scan against. The field could be: BigQuery table of
        -   * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +   * for a DataScan job to scan against. The field could either be: Cloud
        +   * Storage bucket for DataDiscoveryScan Format:
        +   * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +   * or
        +   * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +   * Format:
            * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
            * 
        * @@ -222,8 +226,12 @@ public boolean hasResource() { * *
            * Immutable. The service-qualified full resource name of the cloud resource
        -   * for a DataScan job to scan against. The field could be: BigQuery table of
        -   * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +   * for a DataScan job to scan against. The field could either be: Cloud
        +   * Storage bucket for DataDiscoveryScan Format:
        +   * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +   * or
        +   * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +   * Format:
            * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
            * 
        * @@ -253,8 +261,12 @@ public java.lang.String getResource() { * *
            * Immutable. The service-qualified full resource name of the cloud resource
        -   * for a DataScan job to scan against. The field could be: BigQuery table of
        -   * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +   * for a DataScan job to scan against. The field could either be: Cloud
        +   * Storage bucket for DataDiscoveryScan Format:
        +   * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +   * or
        +   * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +   * Format:
            * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
            * 
        * @@ -691,8 +703,8 @@ public Builder clearSource() { * * *
        -     * Immutable. The Dataplex entity that represents the data source (e.g.
        -     * BigQuery table) for DataScan, of the form:
        +     * Immutable. The Dataplex Universal Catalog entity that represents the data
        +     * source (e.g. BigQuery table) for DataScan, of the form:
              * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
              * 
        * @@ -711,8 +723,8 @@ public boolean hasEntity() { * * *
        -     * Immutable. The Dataplex entity that represents the data source (e.g.
        -     * BigQuery table) for DataScan, of the form:
        +     * Immutable. The Dataplex Universal Catalog entity that represents the data
        +     * source (e.g. BigQuery table) for DataScan, of the form:
              * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
              * 
        * @@ -744,8 +756,8 @@ public java.lang.String getEntity() { * * *
        -     * Immutable. The Dataplex entity that represents the data source (e.g.
        -     * BigQuery table) for DataScan, of the form:
        +     * Immutable. The Dataplex Universal Catalog entity that represents the data
        +     * source (e.g. BigQuery table) for DataScan, of the form:
              * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
              * 
        * @@ -777,8 +789,8 @@ public com.google.protobuf.ByteString getEntityBytes() { * * *
        -     * Immutable. The Dataplex entity that represents the data source (e.g.
        -     * BigQuery table) for DataScan, of the form:
        +     * Immutable. The Dataplex Universal Catalog entity that represents the data
        +     * source (e.g. BigQuery table) for DataScan, of the form:
              * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
              * 
        * @@ -803,8 +815,8 @@ public Builder setEntity(java.lang.String value) { * * *
        -     * Immutable. The Dataplex entity that represents the data source (e.g.
        -     * BigQuery table) for DataScan, of the form:
        +     * Immutable. The Dataplex Universal Catalog entity that represents the data
        +     * source (e.g. BigQuery table) for DataScan, of the form:
              * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
              * 
        * @@ -827,8 +839,8 @@ public Builder clearEntity() { * * *
        -     * Immutable. The Dataplex entity that represents the data source (e.g.
        -     * BigQuery table) for DataScan, of the form:
        +     * Immutable. The Dataplex Universal Catalog entity that represents the data
        +     * source (e.g. BigQuery table) for DataScan, of the form:
              * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
              * 
        * @@ -855,8 +867,12 @@ public Builder setEntityBytes(com.google.protobuf.ByteString value) { * *
              * Immutable. The service-qualified full resource name of the cloud resource
        -     * for a DataScan job to scan against. The field could be: BigQuery table of
        -     * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +     * for a DataScan job to scan against. The field could either be: Cloud
        +     * Storage bucket for DataDiscoveryScan Format:
        +     * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +     * or
        +     * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +     * Format:
              * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
              * 
        * @@ -874,8 +890,12 @@ public boolean hasResource() { * *
              * Immutable. The service-qualified full resource name of the cloud resource
        -     * for a DataScan job to scan against. The field could be: BigQuery table of
        -     * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +     * for a DataScan job to scan against. The field could either be: Cloud
        +     * Storage bucket for DataDiscoveryScan Format:
        +     * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +     * or
        +     * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +     * Format:
              * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
              * 
        * @@ -906,8 +926,12 @@ public java.lang.String getResource() { * *
              * Immutable. The service-qualified full resource name of the cloud resource
        -     * for a DataScan job to scan against. The field could be: BigQuery table of
        -     * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +     * for a DataScan job to scan against. The field could either be: Cloud
        +     * Storage bucket for DataDiscoveryScan Format:
        +     * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +     * or
        +     * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +     * Format:
              * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
              * 
        * @@ -938,8 +962,12 @@ public com.google.protobuf.ByteString getResourceBytes() { * *
              * Immutable. The service-qualified full resource name of the cloud resource
        -     * for a DataScan job to scan against. The field could be: BigQuery table of
        -     * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +     * for a DataScan job to scan against. The field could either be: Cloud
        +     * Storage bucket for DataDiscoveryScan Format:
        +     * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +     * or
        +     * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +     * Format:
              * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
              * 
        * @@ -963,8 +991,12 @@ public Builder setResource(java.lang.String value) { * *
              * Immutable. The service-qualified full resource name of the cloud resource
        -     * for a DataScan job to scan against. The field could be: BigQuery table of
        -     * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +     * for a DataScan job to scan against. The field could either be: Cloud
        +     * Storage bucket for DataDiscoveryScan Format:
        +     * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +     * or
        +     * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +     * Format:
              * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
              * 
        * @@ -986,8 +1018,12 @@ public Builder clearResource() { * *
              * Immutable. The service-qualified full resource name of the cloud resource
        -     * for a DataScan job to scan against. The field could be: BigQuery table of
        -     * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +     * for a DataScan job to scan against. The field could either be: Cloud
        +     * Storage bucket for DataDiscoveryScan Format:
        +     * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +     * or
        +     * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +     * Format:
              * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
              * 
        * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSourceOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSourceOrBuilder.java index 67edb0ed3c69..155bf0bba2c4 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSourceOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DataSourceOrBuilder.java @@ -28,8 +28,8 @@ public interface DataSourceOrBuilder * * *
        -   * Immutable. The Dataplex entity that represents the data source (e.g.
        -   * BigQuery table) for DataScan, of the form:
        +   * Immutable. The Dataplex Universal Catalog entity that represents the data
        +   * source (e.g. BigQuery table) for DataScan, of the form:
            * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
            * 
        * @@ -45,8 +45,8 @@ public interface DataSourceOrBuilder * * *
        -   * Immutable. The Dataplex entity that represents the data source (e.g.
        -   * BigQuery table) for DataScan, of the form:
        +   * Immutable. The Dataplex Universal Catalog entity that represents the data
        +   * source (e.g. BigQuery table) for DataScan, of the form:
            * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
            * 
        * @@ -62,8 +62,8 @@ public interface DataSourceOrBuilder * * *
        -   * Immutable. The Dataplex entity that represents the data source (e.g.
        -   * BigQuery table) for DataScan, of the form:
        +   * Immutable. The Dataplex Universal Catalog entity that represents the data
        +   * source (e.g. BigQuery table) for DataScan, of the form:
            * `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`.
            * 
        * @@ -80,8 +80,12 @@ public interface DataSourceOrBuilder * *
            * Immutable. The service-qualified full resource name of the cloud resource
        -   * for a DataScan job to scan against. The field could be: BigQuery table of
        -   * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +   * for a DataScan job to scan against. The field could either be: Cloud
        +   * Storage bucket for DataDiscoveryScan Format:
        +   * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +   * or
        +   * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +   * Format:
            * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
            * 
        * @@ -96,8 +100,12 @@ public interface DataSourceOrBuilder * *
            * Immutable. The service-qualified full resource name of the cloud resource
        -   * for a DataScan job to scan against. The field could be: BigQuery table of
        -   * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +   * for a DataScan job to scan against. The field could either be: Cloud
        +   * Storage bucket for DataDiscoveryScan Format:
        +   * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +   * or
        +   * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +   * Format:
            * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
            * 
        * @@ -112,8 +120,12 @@ public interface DataSourceOrBuilder * *
            * Immutable. The service-qualified full resource name of the cloud resource
        -   * for a DataScan job to scan against. The field could be: BigQuery table of
        -   * type "TABLE" for DataProfileScan/DataQualityScan Format:
        +   * for a DataScan job to scan against. The field could either be: Cloud
        +   * Storage bucket for DataDiscoveryScan Format:
        +   * //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID
        +   * or
        +   * BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan
        +   * Format:
            * //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID
            * 
        * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteAspectTypeRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteAspectTypeRequest.java index cef4d04e21fa..3610d236791a 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteAspectTypeRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteAspectTypeRequest.java @@ -23,7 +23,7 @@ * * *
        - * Delele AspectType Request.
        + * Delete AspectType Request.
          * 
        * * Protobuf type {@code google.cloud.dataplex.v1.DeleteAspectTypeRequest} @@ -354,7 +354,7 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
        -   * Delele AspectType Request.
        +   * Delete AspectType Request.
            * 
        * * Protobuf type {@code google.cloud.dataplex.v1.DeleteAspectTypeRequest} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequest.java index 0475d602d76b..c6b73303a3b7 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequest.java @@ -76,7 +76,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -105,7 +105,7 @@ public java.lang.String getName() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -522,7 +522,7 @@ public Builder mergeFrom( * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -550,7 +550,7 @@ public java.lang.String getName() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -578,7 +578,7 @@ public com.google.protobuf.ByteString getNameBytes() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -605,7 +605,7 @@ public Builder setName(java.lang.String value) { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -628,7 +628,7 @@ public Builder clearName() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequestOrBuilder.java index ee22d359ec8a..750f50de8428 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteDataScanRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface DeleteDataScanRequestOrBuilder * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface DeleteDataScanRequestOrBuilder * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryLinkRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryLinkRequest.java new file mode 100644 index 000000000000..a24e40d1711b --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryLinkRequest.java @@ -0,0 +1,655 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Request message for DeleteEntryLink.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteEntryLinkRequest} + */ +public final class DeleteEntryLinkRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.DeleteEntryLinkRequest) + DeleteEntryLinkRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DeleteEntryLinkRequest.newBuilder() to construct. + private DeleteEntryLinkRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteEntryLinkRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteEntryLinkRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.class, + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The resource name of the Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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 Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteEntryLinkRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest other = + (com.google.cloud.dataplex.v1.DeleteEntryLinkRequest) 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.dataplex.v1.DeleteEntryLinkRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest 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.dataplex.v1.DeleteEntryLinkRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest 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.dataplex.v1.DeleteEntryLinkRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteEntryLinkRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Request message for DeleteEntryLink.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteEntryLinkRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.DeleteEntryLinkRequest) + com.google.cloud.dataplex.v1.DeleteEntryLinkRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.class, + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_DeleteEntryLinkRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteEntryLinkRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteEntryLinkRequest build() { + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteEntryLinkRequest buildPartial() { + com.google.cloud.dataplex.v1.DeleteEntryLinkRequest result = + new com.google.cloud.dataplex.v1.DeleteEntryLinkRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.DeleteEntryLinkRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.DeleteEntryLinkRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.DeleteEntryLinkRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.DeleteEntryLinkRequest other) { + if (other == com.google.cloud.dataplex.v1.DeleteEntryLinkRequest.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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.DeleteEntryLinkRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.DeleteEntryLinkRequest) + private static final com.google.cloud.dataplex.v1.DeleteEntryLinkRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.DeleteEntryLinkRequest(); + } + + public static com.google.cloud.dataplex.v1.DeleteEntryLinkRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteEntryLinkRequest 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.dataplex.v1.DeleteEntryLinkRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryLinkRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryLinkRequestOrBuilder.java new file mode 100644 index 000000000000..67a2bbf271fd --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryLinkRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface DeleteEntryLinkRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.DeleteEntryLinkRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The resource name of the Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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 Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryTypeRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryTypeRequest.java index f59713106066..57e35bd2eb4e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryTypeRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteEntryTypeRequest.java @@ -23,7 +23,7 @@ * * *
        - * Delele EntryType Request.
        + * Delete EntryType Request.
          * 
        * * Protobuf type {@code google.cloud.dataplex.v1.DeleteEntryTypeRequest} @@ -352,7 +352,7 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
        -   * Delele EntryType Request.
        +   * Delete EntryType Request.
            * 
        * * Protobuf type {@code google.cloud.dataplex.v1.DeleteEntryTypeRequest} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryCategoryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryCategoryRequest.java new file mode 100644 index 000000000000..a5923e23390e --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryCategoryRequest.java @@ -0,0 +1,663 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Delete GlossaryCategory Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest} + */ +public final class DeleteGlossaryCategoryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) + DeleteGlossaryCategoryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DeleteGlossaryCategoryRequest.newBuilder() to construct. + private DeleteGlossaryCategoryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteGlossaryCategoryRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteGlossaryCategoryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The name of the GlossaryCategory to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * 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 GlossaryCategory to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteGlossaryCategoryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest other = + (com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) 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.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest 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.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest 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.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteGlossaryCategoryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Delete GlossaryCategory Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest build() { + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest buildPartial() { + com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest result = + new com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest other) { + if (other == com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest.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 GlossaryCategory to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) + private static final com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest(); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteGlossaryCategoryRequest 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.dataplex.v1.DeleteGlossaryCategoryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryCategoryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryCategoryRequestOrBuilder.java new file mode 100644 index 000000000000..c5ddb657afc0 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryCategoryRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface DeleteGlossaryCategoryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The name of the GlossaryCategory to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Required. The name of the GlossaryCategory to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryRequest.java new file mode 100644 index 000000000000..1042b968f302 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryRequest.java @@ -0,0 +1,872 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Delete Glossary Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteGlossaryRequest} + */ +public final class DeleteGlossaryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.DeleteGlossaryRequest) + DeleteGlossaryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DeleteGlossaryRequest.newBuilder() to construct. + private DeleteGlossaryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteGlossaryRequest() { + name_ = ""; + etag_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteGlossaryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest.class, + com.google.cloud.dataplex.v1.DeleteGlossaryRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The name of the Glossary to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * 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 Glossary to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * 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. The etag of the Glossary.
        +   * If this is provided, it must match the server's etag.
        +   * If the etag is provided and does not match the server-computed etag,
        +   * the request must fail with a ABORTED error code.
        +   * 
        + * + * 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. The etag of the Glossary.
        +   * If this is provided, it must match the server's etag.
        +   * If the etag is provided and does not match the server-computed etag,
        +   * the request must fail with a ABORTED error code.
        +   * 
        + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteGlossaryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.DeleteGlossaryRequest other = + (com.google.cloud.dataplex.v1.DeleteGlossaryRequest) 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.dataplex.v1.DeleteGlossaryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest 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.dataplex.v1.DeleteGlossaryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest 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.dataplex.v1.DeleteGlossaryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteGlossaryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Delete Glossary Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteGlossaryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.DeleteGlossaryRequest) + com.google.cloud.dataplex.v1.DeleteGlossaryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteGlossaryRequest.class, + com.google.cloud.dataplex.v1.DeleteGlossaryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.DeleteGlossaryRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.DeleteGlossaryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryRequest build() { + com.google.cloud.dataplex.v1.DeleteGlossaryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryRequest buildPartial() { + com.google.cloud.dataplex.v1.DeleteGlossaryRequest result = + new com.google.cloud.dataplex.v1.DeleteGlossaryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.DeleteGlossaryRequest 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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.DeleteGlossaryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.DeleteGlossaryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.DeleteGlossaryRequest other) { + if (other == com.google.cloud.dataplex.v1.DeleteGlossaryRequest.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 name of the Glossary to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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. The etag of the Glossary.
        +     * If this is provided, it must match the server's etag.
        +     * If the etag is provided and does not match the server-computed etag,
        +     * the request must fail with a ABORTED error code.
        +     * 
        + * + * 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. The etag of the Glossary.
        +     * If this is provided, it must match the server's etag.
        +     * If the etag is provided and does not match the server-computed etag,
        +     * the request must fail with a ABORTED error code.
        +     * 
        + * + * 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. The etag of the Glossary.
        +     * If this is provided, it must match the server's etag.
        +     * If the etag is provided and does not match the server-computed etag,
        +     * the request must fail with a ABORTED error code.
        +     * 
        + * + * 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. The etag of the Glossary.
        +     * If this is provided, it must match the server's etag.
        +     * If the etag is provided and does not match the server-computed etag,
        +     * the request must fail with a ABORTED error code.
        +     * 
        + * + * 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. The etag of the Glossary.
        +     * If this is provided, it must match the server's etag.
        +     * If the etag is provided and does not match the server-computed etag,
        +     * the request must fail with a ABORTED error code.
        +     * 
        + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.DeleteGlossaryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.DeleteGlossaryRequest) + private static final com.google.cloud.dataplex.v1.DeleteGlossaryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.DeleteGlossaryRequest(); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteGlossaryRequest 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.dataplex.v1.DeleteGlossaryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryRequestOrBuilder.java new file mode 100644 index 000000000000..73924b2ae8bb --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryRequestOrBuilder.java @@ -0,0 +1,92 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface DeleteGlossaryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.DeleteGlossaryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The name of the Glossary to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Required. The name of the Glossary to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * Optional. The etag of the Glossary.
        +   * If this is provided, it must match the server's etag.
        +   * If the etag is provided and does not match the server-computed etag,
        +   * the request must fail with a ABORTED error code.
        +   * 
        + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + java.lang.String getEtag(); + + /** + * + * + *
        +   * Optional. The etag of the Glossary.
        +   * If this is provided, it must match the server's etag.
        +   * If the etag is provided and does not match the server-computed etag,
        +   * the request must fail with a ABORTED error code.
        +   * 
        + * + * string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + com.google.protobuf.ByteString getEtagBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryTermRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryTermRequest.java new file mode 100644 index 000000000000..a26ab1625564 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryTermRequest.java @@ -0,0 +1,663 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Delete GlossaryTerm Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteGlossaryTermRequest} + */ +public final class DeleteGlossaryTermRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.DeleteGlossaryTermRequest) + DeleteGlossaryTermRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DeleteGlossaryTermRequest.newBuilder() to construct. + private DeleteGlossaryTermRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteGlossaryTermRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteGlossaryTermRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The name of the GlossaryTerm to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * 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 GlossaryTerm to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteGlossaryTermRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest other = + (com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest) 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.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest 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.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest 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.dataplex.v1.DeleteGlossaryTermRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.DeleteGlossaryTermRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Delete GlossaryTerm Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.DeleteGlossaryTermRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.DeleteGlossaryTermRequest) + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_DeleteGlossaryTermRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest build() { + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest buildPartial() { + com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest result = + new com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest other) { + if (other == com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest.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 GlossaryTerm to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to delete.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.DeleteGlossaryTermRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.DeleteGlossaryTermRequest) + private static final com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest(); + } + + public static com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteGlossaryTermRequest 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.dataplex.v1.DeleteGlossaryTermRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryTermRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryTermRequestOrBuilder.java new file mode 100644 index 000000000000..59d56b226989 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/DeleteGlossaryTermRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface DeleteGlossaryTermRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.DeleteGlossaryTermRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The name of the GlossaryTerm to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Required. The name of the GlossaryTerm to delete.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Entry.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Entry.java index 06407df94efb..a128677da8d0 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Entry.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Entry.java @@ -204,7 +204,8 @@ public com.google.protobuf.ByteString getEntryTypeBytes() { * * *
        -   * Output only. The time when the entry was created in Dataplex.
        +   * Output only. The time when the entry was created in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -221,7 +222,8 @@ public boolean hasCreateTime() { * * *
        -   * Output only. The time when the entry was created in Dataplex.
        +   * Output only. The time when the entry was created in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -238,7 +240,8 @@ public com.google.protobuf.Timestamp getCreateTime() { * * *
        -   * Output only. The time when the entry was created in Dataplex.
        +   * Output only. The time when the entry was created in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -256,7 +259,8 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { * * *
        -   * Output only. The time when the entry was last updated in Dataplex.
        +   * Output only. The time when the entry was last updated in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -273,7 +277,8 @@ public boolean hasUpdateTime() { * * *
        -   * Output only. The time when the entry was last updated in Dataplex.
        +   * Output only. The time when the entry was last updated in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -290,7 +295,8 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * *
        -   * Output only. The time when the entry was last updated in Dataplex.
        +   * Output only. The time when the entry was last updated in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -1469,7 +1475,8 @@ public Builder setEntryTypeBytes(com.google.protobuf.ByteString value) { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1486,7 +1493,8 @@ public boolean hasCreateTime() { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1509,7 +1517,8 @@ public com.google.protobuf.Timestamp getCreateTime() { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1534,7 +1543,8 @@ public Builder setCreateTime(com.google.protobuf.Timestamp value) { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1556,7 +1566,8 @@ public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForVal * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1586,7 +1597,8 @@ public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1608,7 +1620,8 @@ public Builder clearCreateTime() { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1625,7 +1638,8 @@ public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1646,7 +1660,8 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { * * *
        -     * Output only. The time when the entry was created in Dataplex.
        +     * Output only. The time when the entry was created in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1681,7 +1696,8 @@ public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1698,7 +1714,8 @@ public boolean hasUpdateTime() { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1721,7 +1738,8 @@ public com.google.protobuf.Timestamp getUpdateTime() { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1746,7 +1764,8 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp value) { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1768,7 +1787,8 @@ public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForVal * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1798,7 +1818,8 @@ public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1820,7 +1841,8 @@ public Builder clearUpdateTime() { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1837,7 +1859,8 @@ public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * @@ -1858,7 +1881,8 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { * * *
        -     * Output only. The time when the entry was last updated in Dataplex.
        +     * Output only. The time when the entry was last updated in Dataplex Universal
        +     * Catalog.
              * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLink.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLink.java new file mode 100644 index 000000000000..72bb071ab189 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLink.java @@ -0,0 +1,3416 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * EntryLink represents a link between two Entries.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.EntryLink} + */ +public final class EntryLink extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.EntryLink) + EntryLinkOrBuilder { + private static final long serialVersionUID = 0L; + + // Use EntryLink.newBuilder() to construct. + private EntryLink(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EntryLink() { + name_ = ""; + entryLinkType_ = ""; + entryReferences_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EntryLink(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.EntryLink.class, + com.google.cloud.dataplex.v1.EntryLink.Builder.class); + } + + public interface EntryReferenceOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.EntryLink.EntryReference) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +     * Required. Immutable. The relative resource name of the referenced Entry,
        +     * of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +     * Required. Immutable. The relative resource name of the referenced Entry,
        +     * of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +     * Immutable. The path in the Entry that is referenced in the Entry Link.
        +     * Empty path denotes that the Entry itself is referenced in the Entry
        +     * Link.
        +     * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The path. + */ + java.lang.String getPath(); + + /** + * + * + *
        +     * Immutable. The path in the Entry that is referenced in the Entry Link.
        +     * Empty path denotes that the Entry itself is referenced in the Entry
        +     * Link.
        +     * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return The bytes for path. + */ + com.google.protobuf.ByteString getPathBytes(); + + /** + * + * + *
        +     * Required. Immutable. The reference type of the Entry.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + + /** + * + * + *
        +     * Required. Immutable. The reference type of the Entry.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The type. + */ + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type getType(); + } + + /** + * + * + *
        +   * Reference to the Entry that is linked through the Entry Link.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.EntryLink.EntryReference} + */ + public static final class EntryReference extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.EntryLink.EntryReference) + EntryReferenceOrBuilder { + private static final long serialVersionUID = 0L; + + // Use EntryReference.newBuilder() to construct. + private EntryReference(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private EntryReference() { + name_ = ""; + path_ = ""; + type_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EntryReference(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.EntryLink.EntryReference.class, + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder.class); + } + + /** + * + * + *
        +     * Reference type of the Entry.
        +     * 
        + * + * Protobuf enum {@code google.cloud.dataplex.v1.EntryLink.EntryReference.Type} + */ + public enum Type implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
        +       * Unspecified reference type. Implies that the Entry is referenced
        +       * in a non-directional Entry Link.
        +       * 
        + * + * UNSPECIFIED = 0; + */ + UNSPECIFIED(0), + /** + * + * + *
        +       * The Entry is referenced as the source of the directional Entry Link.
        +       * 
        + * + * SOURCE = 2; + */ + SOURCE(2), + /** + * + * + *
        +       * The Entry is referenced as the target of the directional Entry Link.
        +       * 
        + * + * TARGET = 3; + */ + TARGET(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
        +       * Unspecified reference type. Implies that the Entry is referenced
        +       * in a non-directional Entry Link.
        +       * 
        + * + * UNSPECIFIED = 0; + */ + public static final int UNSPECIFIED_VALUE = 0; + + /** + * + * + *
        +       * The Entry is referenced as the source of the directional Entry Link.
        +       * 
        + * + * SOURCE = 2; + */ + public static final int SOURCE_VALUE = 2; + + /** + * + * + *
        +       * The Entry is referenced as the target of the directional Entry Link.
        +       * 
        + * + * TARGET = 3; + */ + public static final int TARGET_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 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 UNSPECIFIED; + case 2: + return SOURCE; + case 3: + return TARGET; + 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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.dataplex.v1.EntryLink.EntryReference.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.dataplex.v1.EntryLink.EntryReference.Type) + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +     * Required. Immutable. The relative resource name of the referenced Entry,
        +     * of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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. Immutable. The relative resource name of the referenced Entry,
        +     * of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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 PATH_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object path_ = ""; + + /** + * + * + *
        +     * Immutable. The path in the Entry that is referenced in the Entry Link.
        +     * Empty path denotes that the Entry itself is referenced in the Entry
        +     * Link.
        +     * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @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; + } + } + + /** + * + * + *
        +     * Immutable. The path in the Entry that is referenced in the Entry Link.
        +     * Empty path denotes that the Entry itself is referenced in the Entry
        +     * Link.
        +     * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @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 TYPE_FIELD_NUMBER = 3; + private int type_ = 0; + + /** + * + * + *
        +     * Required. Immutable. The reference type of the Entry.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
        +     * Required. Immutable. The reference type of the Entry.
        +     * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type getType() { + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type result = + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type.forNumber(type_); + return result == null + ? com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type.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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_); + } + if (type_ + != com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type.UNSPECIFIED.getNumber()) { + output.writeEnum(3, type_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_); + } + if (type_ + != com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type.UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, type_); + } + 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.dataplex.v1.EntryLink.EntryReference)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.EntryLink.EntryReference other = + (com.google.cloud.dataplex.v1.EntryLink.EntryReference) obj; + + if (!getName().equals(other.getName())) return false; + if (!getPath().equals(other.getPath())) return false; + if (type_ != other.type_) 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) + PATH_FIELD_NUMBER; + hash = (53 * hash) + getPath().hashCode(); + hash = (37 * hash) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference 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.dataplex.v1.EntryLink.EntryReference parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference 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.dataplex.v1.EntryLink.EntryReference parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.EntryLink.EntryReference 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +     * Reference to the Entry that is linked through the Entry Link.
        +     * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.EntryLink.EntryReference} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.EntryLink.EntryReference) + com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.EntryLink.EntryReference.class, + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.EntryLink.EntryReference.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + path_ = ""; + type_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_EntryReference_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReference getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.EntryLink.EntryReference.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReference build() { + com.google.cloud.dataplex.v1.EntryLink.EntryReference result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReference buildPartial() { + com.google.cloud.dataplex.v1.EntryLink.EntryReference result = + new com.google.cloud.dataplex.v1.EntryLink.EntryReference(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.EntryLink.EntryReference result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.path_ = path_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.type_ = type_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.EntryLink.EntryReference) { + return mergeFrom((com.google.cloud.dataplex.v1.EntryLink.EntryReference) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.EntryLink.EntryReference other) { + if (other == com.google.cloud.dataplex.v1.EntryLink.EntryReference.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getPath().isEmpty()) { + path_ = other.path_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + 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: + { + path_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + type_ = 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 name_ = ""; + + /** + * + * + *
        +       * Required. Immutable. The relative resource name of the referenced Entry,
        +       * of the form:
        +       * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +       * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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. Immutable. The relative resource name of the referenced Entry,
        +       * of the form:
        +       * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +       * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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. Immutable. The relative resource name of the referenced Entry,
        +       * of the form:
        +       * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +       * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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. Immutable. The relative resource name of the referenced Entry,
        +       * of the form:
        +       * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +       * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +       * Required. Immutable. The relative resource name of the referenced Entry,
        +       * of the form:
        +       * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}`
        +       * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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 path_ = ""; + + /** + * + * + *
        +       * Immutable. The path in the Entry that is referenced in the Entry Link.
        +       * Empty path denotes that the Entry itself is referenced in the Entry
        +       * Link.
        +       * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @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; + } + } + + /** + * + * + *
        +       * Immutable. The path in the Entry that is referenced in the Entry Link.
        +       * Empty path denotes that the Entry itself is referenced in the Entry
        +       * Link.
        +       * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @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; + } + } + + /** + * + * + *
        +       * Immutable. The path in the Entry that is referenced in the Entry Link.
        +       * Empty path denotes that the Entry itself is referenced in the Entry
        +       * Link.
        +       * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @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; + } + + /** + * + * + *
        +       * Immutable. The path in the Entry that is referenced in the Entry Link.
        +       * Empty path denotes that the Entry itself is referenced in the Entry
        +       * Link.
        +       * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @return This builder for chaining. + */ + public Builder clearPath() { + path_ = getDefaultInstance().getPath(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
        +       * Immutable. The path in the Entry that is referenced in the Entry Link.
        +       * Empty path denotes that the Entry itself is referenced in the Entry
        +       * Link.
        +       * 
        + * + * string path = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * + * @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 type_ = 0; + + /** + * + * + *
        +       * Required. Immutable. The reference type of the Entry.
        +       * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + + /** + * + * + *
        +       * Required. Immutable. The reference type of the Entry.
        +       * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @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_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +       * Required. Immutable. The reference type of the Entry.
        +       * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type getType() { + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type result = + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type.forNumber(type_); + return result == null + ? com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type.UNRECOGNIZED + : result; + } + + /** + * + * + *
        +       * Required. Immutable. The reference type of the Entry.
        +       * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType(com.google.cloud.dataplex.v1.EntryLink.EntryReference.Type value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000004; + type_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
        +       * Required. Immutable. The reference type of the Entry.
        +       * 
        + * + * + * .google.cloud.dataplex.v1.EntryLink.EntryReference.Type type = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return This builder for chaining. + */ + public Builder clearType() { + bitField0_ = (bitField0_ & ~0x00000004); + type_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.EntryLink.EntryReference) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.EntryLink.EntryReference) + private static final com.google.cloud.dataplex.v1.EntryLink.EntryReference DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.EntryLink.EntryReference(); + } + + public static com.google.cloud.dataplex.v1.EntryLink.EntryReference getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EntryReference 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.dataplex.v1.EntryLink.EntryReference getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Output only. Immutable. Identifier. The relative resource name of the Entry
        +   * Link, of the form:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.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; + } + } + + /** + * + * + *
        +   * Output only. Immutable. Identifier. The relative resource name of the Entry
        +   * Link, of the form:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.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 ENTRY_LINK_TYPE_FIELD_NUMBER = 2; + + @SuppressWarnings("serial") + private volatile java.lang.Object entryLinkType_ = ""; + + /** + * + * + *
        +   * Required. Immutable. Relative resource name of the Entry Link Type used to
        +   * create this Entry Link. For example:
        +   *
        +   * - Entry link between synonym terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +   * - Entry link between related terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +   * - Entry link between glossary terms and data assets:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +   * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The entryLinkType. + */ + @java.lang.Override + public java.lang.String getEntryLinkType() { + java.lang.Object ref = entryLinkType_; + 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(); + entryLinkType_ = s; + return s; + } + } + + /** + * + * + *
        +   * Required. Immutable. Relative resource name of the Entry Link Type used to
        +   * create this Entry Link. For example:
        +   *
        +   * - Entry link between synonym terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +   * - Entry link between related terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +   * - Entry link between glossary terms and data assets:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +   * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The bytes for entryLinkType. + */ + @java.lang.Override + public com.google.protobuf.ByteString getEntryLinkTypeBytes() { + java.lang.Object ref = entryLinkType_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + entryLinkType_ = 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. The time when the Entry Link 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. The time when the Entry Link 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 when the Entry Link 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 when the Entry Link 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. The time when the Entry Link 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 when the Entry Link 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 ENTRY_REFERENCES_FIELD_NUMBER = 10; + + @SuppressWarnings("serial") + private java.util.List entryReferences_; + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List + getEntryReferencesList() { + return entryReferences_; + } + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public java.util.List + getEntryReferencesOrBuilderList() { + return entryReferences_; + } + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public int getEntryReferencesCount() { + return entryReferences_.size(); + } + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReference getEntryReferences(int index) { + return entryReferences_.get(index); + } + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder getEntryReferencesOrBuilder( + int index) { + return entryReferences_.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 { + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entryLinkType_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, entryLinkType_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getUpdateTime()); + } + for (int i = 0; i < entryReferences_.size(); i++) { + output.writeMessage(10, entryReferences_.get(i)); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entryLinkType_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, entryLinkType_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getUpdateTime()); + } + for (int i = 0; i < entryReferences_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, entryReferences_.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.dataplex.v1.EntryLink)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.EntryLink other = (com.google.cloud.dataplex.v1.EntryLink) obj; + + if (!getName().equals(other.getName())) return false; + if (!getEntryLinkType().equals(other.getEntryLinkType())) 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 (!getEntryReferencesList().equals(other.getEntryReferencesList())) 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) + ENTRY_LINK_TYPE_FIELD_NUMBER; + hash = (53 * hash) + getEntryLinkType().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 (getEntryReferencesCount() > 0) { + hash = (37 * hash) + ENTRY_REFERENCES_FIELD_NUMBER; + hash = (53 * hash) + getEntryReferencesList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.EntryLink parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.EntryLink 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.dataplex.v1.EntryLink parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.EntryLink 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.dataplex.v1.EntryLink parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.EntryLink parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.EntryLink 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * EntryLink represents a link between two Entries.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.EntryLink} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.EntryLink) + com.google.cloud.dataplex.v1.EntryLinkOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.EntryLink.class, + com.google.cloud.dataplex.v1.EntryLink.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.EntryLink.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCreateTimeFieldBuilder(); + getUpdateTimeFieldBuilder(); + getEntryReferencesFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + entryLinkType_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + if (entryReferencesBuilder_ == null) { + entryReferences_ = java.util.Collections.emptyList(); + } else { + entryReferences_ = null; + entryReferencesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000010); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_EntryLink_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink build() { + com.google.cloud.dataplex.v1.EntryLink result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink buildPartial() { + com.google.cloud.dataplex.v1.EntryLink result = + new com.google.cloud.dataplex.v1.EntryLink(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields(com.google.cloud.dataplex.v1.EntryLink result) { + if (entryReferencesBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0)) { + entryReferences_ = java.util.Collections.unmodifiableList(entryReferences_); + bitField0_ = (bitField0_ & ~0x00000010); + } + result.entryReferences_ = entryReferences_; + } else { + result.entryReferences_ = entryReferencesBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.dataplex.v1.EntryLink result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.entryLinkType_ = entryLinkType_; + } + 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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.EntryLink) { + return mergeFrom((com.google.cloud.dataplex.v1.EntryLink) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.EntryLink other) { + if (other == com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (!other.getEntryLinkType().isEmpty()) { + entryLinkType_ = other.entryLinkType_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + if (entryReferencesBuilder_ == null) { + if (!other.entryReferences_.isEmpty()) { + if (entryReferences_.isEmpty()) { + entryReferences_ = other.entryReferences_; + bitField0_ = (bitField0_ & ~0x00000010); + } else { + ensureEntryReferencesIsMutable(); + entryReferences_.addAll(other.entryReferences_); + } + onChanged(); + } + } else { + if (!other.entryReferences_.isEmpty()) { + if (entryReferencesBuilder_.isEmpty()) { + entryReferencesBuilder_.dispose(); + entryReferencesBuilder_ = null; + entryReferences_ = other.entryReferences_; + bitField0_ = (bitField0_ & ~0x00000010); + entryReferencesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getEntryReferencesFieldBuilder() + : null; + } else { + entryReferencesBuilder_.addAllMessages(other.entryReferences_); + } + } + } + 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: + { + entryLinkType_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 82: + { + com.google.cloud.dataplex.v1.EntryLink.EntryReference m = + input.readMessage( + com.google.cloud.dataplex.v1.EntryLink.EntryReference.parser(), + extensionRegistry); + if (entryReferencesBuilder_ == null) { + ensureEntryReferencesIsMutable(); + entryReferences_.add(m); + } else { + entryReferencesBuilder_.addMessage(m); + } + break; + } // case 82 + 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_ = ""; + + /** + * + * + *
        +     * Output only. Immutable. Identifier. The relative resource name of the Entry
        +     * Link, of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.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; + } + } + + /** + * + * + *
        +     * Output only. Immutable. Identifier. The relative resource name of the Entry
        +     * Link, of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.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; + } + } + + /** + * + * + *
        +     * Output only. Immutable. Identifier. The relative resource name of the Entry
        +     * Link, of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.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; + } + + /** + * + * + *
        +     * Output only. Immutable. Identifier. The relative resource name of the Entry
        +     * Link, of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Immutable. Identifier. The relative resource name of the Entry
        +     * Link, of the form:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.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 entryLinkType_ = ""; + + /** + * + * + *
        +     * Required. Immutable. Relative resource name of the Entry Link Type used to
        +     * create this Entry Link. For example:
        +     *
        +     * - Entry link between synonym terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +     * - Entry link between related terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +     * - Entry link between glossary terms and data assets:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +     * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The entryLinkType. + */ + public java.lang.String getEntryLinkType() { + java.lang.Object ref = entryLinkType_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + entryLinkType_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +     * Required. Immutable. Relative resource name of the Entry Link Type used to
        +     * create this Entry Link. For example:
        +     *
        +     * - Entry link between synonym terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +     * - Entry link between related terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +     * - Entry link between glossary terms and data assets:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +     * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The bytes for entryLinkType. + */ + public com.google.protobuf.ByteString getEntryLinkTypeBytes() { + java.lang.Object ref = entryLinkType_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + entryLinkType_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +     * Required. Immutable. Relative resource name of the Entry Link Type used to
        +     * create this Entry Link. For example:
        +     *
        +     * - Entry link between synonym terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +     * - Entry link between related terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +     * - Entry link between glossary terms and data assets:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +     * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @param value The entryLinkType to set. + * @return This builder for chaining. + */ + public Builder setEntryLinkType(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + entryLinkType_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Immutable. Relative resource name of the Entry Link Type used to
        +     * create this Entry Link. For example:
        +     *
        +     * - Entry link between synonym terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +     * - Entry link between related terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +     * - Entry link between glossary terms and data assets:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +     * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return This builder for chaining. + */ + public Builder clearEntryLinkType() { + entryLinkType_ = getDefaultInstance().getEntryLinkType(); + bitField0_ = (bitField0_ & ~0x00000002); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. Immutable. Relative resource name of the Entry Link Type used to
        +     * create this Entry Link. For example:
        +     *
        +     * - Entry link between synonym terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +     * - Entry link between related terms in a glossary:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +     * - Entry link between glossary terms and data assets:
        +     * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +     * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @param value The bytes for entryLinkType to set. + * @return This builder for chaining. + */ + public Builder setEntryLinkTypeBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + entryLinkType_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + private com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 getCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time when the Entry Link 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 when the Entry Link was created.
        +     * 
        + * + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 when the Entry Link 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 getUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time when the Entry Link 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 when the Entry Link was last updated.
        +     * 
        + * + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getUpdateTime(), getParentForChildren(), isClean()); + updateTime_ = null; + } + return updateTimeBuilder_; + } + + private java.util.List entryReferences_ = + java.util.Collections.emptyList(); + + private void ensureEntryReferencesIsMutable() { + if (!((bitField0_ & 0x00000010) != 0)) { + entryReferences_ = + new java.util.ArrayList( + entryReferences_); + bitField0_ |= 0x00000010; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink.EntryReference, + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder, + com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder> + entryReferencesBuilder_; + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getEntryReferencesList() { + if (entryReferencesBuilder_ == null) { + return java.util.Collections.unmodifiableList(entryReferences_); + } else { + return entryReferencesBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public int getEntryReferencesCount() { + if (entryReferencesBuilder_ == null) { + return entryReferences_.size(); + } else { + return entryReferencesBuilder_.getCount(); + } + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLink.EntryReference getEntryReferences(int index) { + if (entryReferencesBuilder_ == null) { + return entryReferences_.get(index); + } else { + return entryReferencesBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setEntryReferences( + int index, com.google.cloud.dataplex.v1.EntryLink.EntryReference value) { + if (entryReferencesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEntryReferencesIsMutable(); + entryReferences_.set(index, value); + onChanged(); + } else { + entryReferencesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setEntryReferences( + int index, com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder builderForValue) { + if (entryReferencesBuilder_ == null) { + ensureEntryReferencesIsMutable(); + entryReferences_.set(index, builderForValue.build()); + onChanged(); + } else { + entryReferencesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEntryReferences(com.google.cloud.dataplex.v1.EntryLink.EntryReference value) { + if (entryReferencesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEntryReferencesIsMutable(); + entryReferences_.add(value); + onChanged(); + } else { + entryReferencesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEntryReferences( + int index, com.google.cloud.dataplex.v1.EntryLink.EntryReference value) { + if (entryReferencesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureEntryReferencesIsMutable(); + entryReferences_.add(index, value); + onChanged(); + } else { + entryReferencesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEntryReferences( + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder builderForValue) { + if (entryReferencesBuilder_ == null) { + ensureEntryReferencesIsMutable(); + entryReferences_.add(builderForValue.build()); + onChanged(); + } else { + entryReferencesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addEntryReferences( + int index, com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder builderForValue) { + if (entryReferencesBuilder_ == null) { + ensureEntryReferencesIsMutable(); + entryReferences_.add(index, builderForValue.build()); + onChanged(); + } else { + entryReferencesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder addAllEntryReferences( + java.lang.Iterable + values) { + if (entryReferencesBuilder_ == null) { + ensureEntryReferencesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, entryReferences_); + onChanged(); + } else { + entryReferencesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearEntryReferences() { + if (entryReferencesBuilder_ == null) { + entryReferences_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + onChanged(); + } else { + entryReferencesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder removeEntryReferences(int index) { + if (entryReferencesBuilder_ == null) { + ensureEntryReferencesIsMutable(); + entryReferences_.remove(index); + onChanged(); + } else { + entryReferencesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder getEntryReferencesBuilder( + int index) { + return getEntryReferencesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder + getEntryReferencesOrBuilder(int index) { + if (entryReferencesBuilder_ == null) { + return entryReferences_.get(index); + } else { + return entryReferencesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getEntryReferencesOrBuilderList() { + if (entryReferencesBuilder_ != null) { + return entryReferencesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(entryReferences_); + } + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder + addEntryReferencesBuilder() { + return getEntryReferencesFieldBuilder() + .addBuilder(com.google.cloud.dataplex.v1.EntryLink.EntryReference.getDefaultInstance()); + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder addEntryReferencesBuilder( + int index) { + return getEntryReferencesFieldBuilder() + .addBuilder( + index, com.google.cloud.dataplex.v1.EntryLink.EntryReference.getDefaultInstance()); + } + + /** + * + * + *
        +     * Required. Specifies the Entries referenced in the Entry Link. There should
        +     * be exactly two entry references.
        +     * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public java.util.List + getEntryReferencesBuilderList() { + return getEntryReferencesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink.EntryReference, + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder, + com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder> + getEntryReferencesFieldBuilder() { + if (entryReferencesBuilder_ == null) { + entryReferencesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink.EntryReference, + com.google.cloud.dataplex.v1.EntryLink.EntryReference.Builder, + com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder>( + entryReferences_, + ((bitField0_ & 0x00000010) != 0), + getParentForChildren(), + isClean()); + entryReferences_ = null; + } + return entryReferencesBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.EntryLink) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.EntryLink) + private static final com.google.cloud.dataplex.v1.EntryLink DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.EntryLink(); + } + + public static com.google.cloud.dataplex.v1.EntryLink getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EntryLink 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.dataplex.v1.EntryLink getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLinkName.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLinkName.java new file mode 100644 index 000000000000..971eb35f1fc2 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLinkName.java @@ -0,0 +1,269 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class EntryLinkName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_ENTRY_GROUP_ENTRY_LINK = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/entryGroups/{entry_group}/entryLinks/{entry_link}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String entryGroup; + private final String entryLink; + + @Deprecated + protected EntryLinkName() { + project = null; + location = null; + entryGroup = null; + entryLink = null; + } + + private EntryLinkName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + entryGroup = Preconditions.checkNotNull(builder.getEntryGroup()); + entryLink = Preconditions.checkNotNull(builder.getEntryLink()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getEntryGroup() { + return entryGroup; + } + + public String getEntryLink() { + return entryLink; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static EntryLinkName of( + String project, String location, String entryGroup, String entryLink) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setEntryGroup(entryGroup) + .setEntryLink(entryLink) + .build(); + } + + public static String format( + String project, String location, String entryGroup, String entryLink) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setEntryGroup(entryGroup) + .setEntryLink(entryLink) + .build() + .toString(); + } + + public static EntryLinkName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_ENTRY_GROUP_ENTRY_LINK.validatedMatch( + formattedString, "EntryLinkName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("entry_group"), + matchMap.get("entry_link")); + } + + 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 values) { + List list = new ArrayList<>(values.size()); + for (EntryLinkName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_ENTRY_GROUP_ENTRY_LINK.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 (entryGroup != null) { + fieldMapBuilder.put("entry_group", entryGroup); + } + if (entryLink != null) { + fieldMapBuilder.put("entry_link", entryLink); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_ENTRY_GROUP_ENTRY_LINK.instantiate( + "project", + project, + "location", + location, + "entry_group", + entryGroup, + "entry_link", + entryLink); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + EntryLinkName that = ((EntryLinkName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.entryGroup, that.entryGroup) + && Objects.equals(this.entryLink, that.entryLink); + } + 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(entryGroup); + h *= 1000003; + h ^= Objects.hashCode(entryLink); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/entryGroups/{entry_group}/entryLinks/{entry_link}. + */ + public static class Builder { + private String project; + private String location; + private String entryGroup; + private String entryLink; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getEntryGroup() { + return entryGroup; + } + + public String getEntryLink() { + return entryLink; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setEntryGroup(String entryGroup) { + this.entryGroup = entryGroup; + return this; + } + + public Builder setEntryLink(String entryLink) { + this.entryLink = entryLink; + return this; + } + + private Builder(EntryLinkName entryLinkName) { + this.project = entryLinkName.project; + this.location = entryLinkName.location; + this.entryGroup = entryLinkName.entryGroup; + this.entryLink = entryLinkName.entryLink; + } + + public EntryLinkName build() { + return new EntryLinkName(this); + } + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLinkOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLinkOrBuilder.java new file mode 100644 index 000000000000..c632ed39af59 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryLinkOrBuilder.java @@ -0,0 +1,258 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface EntryLinkOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.EntryLink) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Output only. Immutable. Identifier. The relative resource name of the Entry
        +   * Link, of the form:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Output only. Immutable. Identifier. The relative resource name of the Entry
        +   * Link, of the form:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = IDENTIFIER, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * Required. Immutable. Relative resource name of the Entry Link Type used to
        +   * create this Entry Link. For example:
        +   *
        +   * - Entry link between synonym terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +   * - Entry link between related terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +   * - Entry link between glossary terms and data assets:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +   * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The entryLinkType. + */ + java.lang.String getEntryLinkType(); + + /** + * + * + *
        +   * Required. Immutable. Relative resource name of the Entry Link Type used to
        +   * create this Entry Link. For example:
        +   *
        +   * - Entry link between synonym terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/synonym`
        +   * - Entry link between related terms in a glossary:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/related`
        +   * - Entry link between glossary terms and data assets:
        +   * `projects/dataplex-types/locations/global/entryLinkTypes/definition`
        +   * 
        + * + * + * string entry_link_type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * + * + * @return The bytes for entryLinkType. + */ + com.google.protobuf.ByteString getEntryLinkTypeBytes(); + + /** + * + * + *
        +   * Output only. The time when the Entry Link 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 when the Entry Link 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 when the Entry Link was created.
        +   * 
        + * + * .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
        +   * Output only. The time when the Entry Link 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 when the Entry Link 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 when the Entry Link was last updated.
        +   * 
        + * + * .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List getEntryReferencesList(); + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.EntryLink.EntryReference getEntryReferences(int index); + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + int getEntryReferencesCount(); + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + java.util.List + getEntryReferencesOrBuilderList(); + + /** + * + * + *
        +   * Required. Specifies the Entries referenced in the Entry Link. There should
        +   * be exactly two entry references.
        +   * 
        + * + * + * repeated .google.cloud.dataplex.v1.EntryLink.EntryReference entry_references = 10 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.EntryLink.EntryReferenceOrBuilder getEntryReferencesOrBuilder( + int index); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryOrBuilder.java index 04801aa10d4f..7203323be7e8 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryOrBuilder.java @@ -90,7 +90,8 @@ public interface EntryOrBuilder * * *
        -   * Output only. The time when the entry was created in Dataplex.
        +   * Output only. The time when the entry was created in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -104,7 +105,8 @@ public interface EntryOrBuilder * * *
        -   * Output only. The time when the entry was created in Dataplex.
        +   * Output only. The time when the entry was created in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -118,7 +120,8 @@ public interface EntryOrBuilder * * *
        -   * Output only. The time when the entry was created in Dataplex.
        +   * Output only. The time when the entry was created in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -130,7 +133,8 @@ public interface EntryOrBuilder * * *
        -   * Output only. The time when the entry was last updated in Dataplex.
        +   * Output only. The time when the entry was last updated in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -144,7 +148,8 @@ public interface EntryOrBuilder * * *
        -   * Output only. The time when the entry was last updated in Dataplex.
        +   * Output only. The time when the entry was last updated in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; @@ -158,7 +163,8 @@ public interface EntryOrBuilder * * *
        -   * Output only. The time when the entry was last updated in Dataplex.
        +   * Output only. The time when the entry was last updated in Dataplex Universal
        +   * Catalog.
            * 
        * * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryType.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryType.java index a58778548369..4c4002bab119 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryType.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/EntryType.java @@ -730,8 +730,8 @@ public interface AuthorizationOrBuilder * *
              * Immutable. The IAM permission grantable on the Entry Group to allow
        -     * access to instantiate Entries of Dataplex owned Entry Types, only
        -     * settable for Dataplex owned Types.
        +     * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +     * Types, only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -745,8 +745,8 @@ public interface AuthorizationOrBuilder * *
              * Immutable. The IAM permission grantable on the Entry Group to allow
        -     * access to instantiate Entries of Dataplex owned Entry Types, only
        -     * settable for Dataplex owned Types.
        +     * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +     * Types, only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -811,8 +811,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * *
              * Immutable. The IAM permission grantable on the Entry Group to allow
        -     * access to instantiate Entries of Dataplex owned Entry Types, only
        -     * settable for Dataplex owned Types.
        +     * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +     * Types, only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -837,8 +837,8 @@ public java.lang.String getAlternateUsePermission() { * *
              * Immutable. The IAM permission grantable on the Entry Group to allow
        -     * access to instantiate Entries of Dataplex owned Entry Types, only
        -     * settable for Dataplex owned Types.
        +     * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +     * Types, only settable for Dataplex Universal Catalog owned Types.
              * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1214,8 +1214,8 @@ public Builder mergeFrom( * *
                * Immutable. The IAM permission grantable on the Entry Group to allow
        -       * access to instantiate Entries of Dataplex owned Entry Types, only
        -       * settable for Dataplex owned Types.
        +       * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +       * Types, only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1240,8 +1240,8 @@ public java.lang.String getAlternateUsePermission() { * *
                * Immutable. The IAM permission grantable on the Entry Group to allow
        -       * access to instantiate Entries of Dataplex owned Entry Types, only
        -       * settable for Dataplex owned Types.
        +       * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +       * Types, only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1266,8 +1266,8 @@ public com.google.protobuf.ByteString getAlternateUsePermissionBytes() { * *
                * Immutable. The IAM permission grantable on the Entry Group to allow
        -       * access to instantiate Entries of Dataplex owned Entry Types, only
        -       * settable for Dataplex owned Types.
        +       * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +       * Types, only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1291,8 +1291,8 @@ public Builder setAlternateUsePermission(java.lang.String value) { * *
                * Immutable. The IAM permission grantable on the Entry Group to allow
        -       * access to instantiate Entries of Dataplex owned Entry Types, only
        -       * settable for Dataplex owned Types.
        +       * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +       * Types, only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1312,8 +1312,8 @@ public Builder clearAlternateUsePermission() { * *
                * Immutable. The IAM permission grantable on the Entry Group to allow
        -       * access to instantiate Entries of Dataplex owned Entry Types, only
        -       * settable for Dataplex owned Types.
        +       * access to instantiate Entries of Dataplex Universal Catalog owned Entry
        +       * Types, only settable for Dataplex Universal Catalog owned Types.
                * 
        * * string alternate_use_permission = 1 [(.google.api.field_behavior) = IMMUTABLE]; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Environment.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Environment.java index 9076086dcf41..27a690a7d68e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Environment.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Environment.java @@ -1045,7 +1045,7 @@ public interface OsImageRuntimeOrBuilder * * *
        -       * Required. Dataplex Image version.
        +       * Required. Dataplex Universal Catalog Image version.
                * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1058,7 +1058,7 @@ public interface OsImageRuntimeOrBuilder * * *
        -       * Required. Dataplex Image version.
        +       * Required. Dataplex Universal Catalog Image version.
                * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1344,7 +1344,7 @@ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldRefl * * *
        -       * Required. Dataplex Image version.
        +       * Required. Dataplex Universal Catalog Image version.
                * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -1368,7 +1368,7 @@ public java.lang.String getImageVersion() { * * *
        -       * Required. Dataplex Image version.
        +       * Required. Dataplex Universal Catalog Image version.
                * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -2176,7 +2176,7 @@ public Builder mergeFrom( * * *
        -         * Required. Dataplex Image version.
        +         * Required. Dataplex Universal Catalog Image version.
                  * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -2199,7 +2199,7 @@ public java.lang.String getImageVersion() { * * *
        -         * Required. Dataplex Image version.
        +         * Required. Dataplex Universal Catalog Image version.
                  * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -2222,7 +2222,7 @@ public com.google.protobuf.ByteString getImageVersionBytes() { * * *
        -         * Required. Dataplex Image version.
        +         * Required. Dataplex Universal Catalog Image version.
                  * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -2244,7 +2244,7 @@ public Builder setImageVersion(java.lang.String value) { * * *
        -         * Required. Dataplex Image version.
        +         * Required. Dataplex Universal Catalog Image version.
                  * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; @@ -2262,7 +2262,7 @@ public Builder clearImageVersion() { * * *
        -         * Required. Dataplex Image version.
        +         * Required. Dataplex Universal Catalog Image version.
                  * 
        * * string image_version = 1 [(.google.api.field_behavior) = REQUIRED]; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponse.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponse.java index d512ca8a9a17..ea0aad664d1d 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponse.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponse.java @@ -74,8 +74,8 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -89,8 +89,8 @@ public java.util.List getRuleList( * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -105,8 +105,8 @@ public java.util.List getRuleList( * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -120,8 +120,8 @@ public int getRuleCount() { * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -135,8 +135,8 @@ public com.google.cloud.dataplex.v1.DataQualityRule getRule(int index) { * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -561,8 +561,8 @@ private void ensureRuleIsMutable() { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -579,8 +579,8 @@ public java.util.List getRuleList( * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -597,8 +597,8 @@ public int getRuleCount() { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -615,8 +615,8 @@ public com.google.cloud.dataplex.v1.DataQualityRule getRule(int index) { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -639,8 +639,8 @@ public Builder setRule(int index, com.google.cloud.dataplex.v1.DataQualityRule v * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -661,8 +661,8 @@ public Builder setRule( * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -685,8 +685,8 @@ public Builder addRule(com.google.cloud.dataplex.v1.DataQualityRule value) { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -709,8 +709,8 @@ public Builder addRule(int index, com.google.cloud.dataplex.v1.DataQualityRule v * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -730,8 +730,8 @@ public Builder addRule(com.google.cloud.dataplex.v1.DataQualityRule.Builder buil * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -752,8 +752,8 @@ public Builder addRule( * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -774,8 +774,8 @@ public Builder addAllRule( * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -795,8 +795,8 @@ public Builder clearRule() { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -816,8 +816,8 @@ public Builder removeRule(int index) { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -830,8 +830,8 @@ public com.google.cloud.dataplex.v1.DataQualityRule.Builder getRuleBuilder(int i * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -848,8 +848,8 @@ public com.google.cloud.dataplex.v1.DataQualityRuleOrBuilder getRuleOrBuilder(in * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -867,8 +867,8 @@ public com.google.cloud.dataplex.v1.DataQualityRuleOrBuilder getRuleOrBuilder(in * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -882,8 +882,8 @@ public com.google.cloud.dataplex.v1.DataQualityRule.Builder addRuleBuilder() { * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -897,8 +897,8 @@ public com.google.cloud.dataplex.v1.DataQualityRule.Builder addRuleBuilder(int i * * *
        -     * The data quality rules that Dataplex generates based on the results
        -     * of a data profiling scan.
        +     * The data quality rules that Dataplex Universal Catalog generates based on
        +     * the results of a data profiling scan.
              * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponseOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponseOrBuilder.java index b26308045fc1..a48bd22156cd 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponseOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GenerateDataQualityRulesResponseOrBuilder.java @@ -28,8 +28,8 @@ public interface GenerateDataQualityRulesResponseOrBuilder * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -40,8 +40,8 @@ public interface GenerateDataQualityRulesResponseOrBuilder * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -52,8 +52,8 @@ public interface GenerateDataQualityRulesResponseOrBuilder * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -64,8 +64,8 @@ public interface GenerateDataQualityRulesResponseOrBuilder * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; @@ -77,8 +77,8 @@ public interface GenerateDataQualityRulesResponseOrBuilder * * *
        -   * The data quality rules that Dataplex generates based on the results
        -   * of a data profiling scan.
        +   * The data quality rules that Dataplex Universal Catalog generates based on
        +   * the results of a data profiling scan.
            * 
        * * repeated .google.cloud.dataplex.v1.DataQualityRule rule = 1; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequest.java index 063162069354..99a8e34f953e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequest.java @@ -240,7 +240,7 @@ private DataScanJobView(int value) { * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -269,7 +269,7 @@ public java.lang.String getName() { * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -714,7 +714,7 @@ public Builder mergeFrom( * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -742,7 +742,7 @@ public java.lang.String getName() { * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -770,7 +770,7 @@ public com.google.protobuf.ByteString getNameBytes() { * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -797,7 +797,7 @@ public Builder setName(java.lang.String value) { * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -820,7 +820,7 @@ public Builder clearName() { * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequestOrBuilder.java index cabe18dfc46e..916c33301a5f 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanJobRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface GetDataScanJobRequestOrBuilder * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface GetDataScanJobRequestOrBuilder * Required. The resource name of the DataScanJob: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequest.java index 87771b406cd2..c9fe7afdb99e 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequest.java @@ -236,7 +236,7 @@ private DataScanView(int value) { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -265,7 +265,7 @@ public java.lang.String getName() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -708,7 +708,7 @@ public Builder mergeFrom( * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -736,7 +736,7 @@ public java.lang.String getName() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -764,7 +764,7 @@ public com.google.protobuf.ByteString getNameBytes() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -791,7 +791,7 @@ public Builder setName(java.lang.String value) { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -814,7 +814,7 @@ public Builder clearName() { * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequestOrBuilder.java index 2abb2604521e..2e01bd4adc98 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetDataScanRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface GetDataScanRequestOrBuilder * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface GetDataScanRequestOrBuilder * Required. The resource name of the dataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetEntryLinkRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetEntryLinkRequest.java new file mode 100644 index 000000000000..1907ee84a303 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetEntryLinkRequest.java @@ -0,0 +1,655 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Request message for GetEntryLink.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetEntryLinkRequest} + */ +public final class GetEntryLinkRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.GetEntryLinkRequest) + GetEntryLinkRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use GetEntryLinkRequest.newBuilder() to construct. + private GetEntryLinkRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetEntryLinkRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetEntryLinkRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetEntryLinkRequest.class, + com.google.cloud.dataplex.v1.GetEntryLinkRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The resource name of the Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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 Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetEntryLinkRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.GetEntryLinkRequest other = + (com.google.cloud.dataplex.v1.GetEntryLinkRequest) 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.dataplex.v1.GetEntryLinkRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest 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.dataplex.v1.GetEntryLinkRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest 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.dataplex.v1.GetEntryLinkRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetEntryLinkRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Request message for GetEntryLink.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetEntryLinkRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.GetEntryLinkRequest) + com.google.cloud.dataplex.v1.GetEntryLinkRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetEntryLinkRequest.class, + com.google.cloud.dataplex.v1.GetEntryLinkRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.GetEntryLinkRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_GetEntryLinkRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetEntryLinkRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.GetEntryLinkRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetEntryLinkRequest build() { + com.google.cloud.dataplex.v1.GetEntryLinkRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetEntryLinkRequest buildPartial() { + com.google.cloud.dataplex.v1.GetEntryLinkRequest result = + new com.google.cloud.dataplex.v1.GetEntryLinkRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.GetEntryLinkRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.GetEntryLinkRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.GetEntryLinkRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.GetEntryLinkRequest other) { + if (other == com.google.cloud.dataplex.v1.GetEntryLinkRequest.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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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 Entry Link:
        +     * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.GetEntryLinkRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.GetEntryLinkRequest) + private static final com.google.cloud.dataplex.v1.GetEntryLinkRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.GetEntryLinkRequest(); + } + + public static com.google.cloud.dataplex.v1.GetEntryLinkRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetEntryLinkRequest 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.dataplex.v1.GetEntryLinkRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetEntryLinkRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetEntryLinkRequestOrBuilder.java new file mode 100644 index 000000000000..83ed20395287 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetEntryLinkRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/catalog.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GetEntryLinkRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.GetEntryLinkRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The resource name of the Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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 Entry Link:
        +   * `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`.
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryCategoryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryCategoryRequest.java new file mode 100644 index 000000000000..79a5c701411a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryCategoryRequest.java @@ -0,0 +1,663 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Get GlossaryCategory Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetGlossaryCategoryRequest} + */ +public final class GetGlossaryCategoryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.GetGlossaryCategoryRequest) + GetGlossaryCategoryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use GetGlossaryCategoryRequest.newBuilder() to construct. + private GetGlossaryCategoryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetGlossaryCategoryRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetGlossaryCategoryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The name of the GlossaryCategory to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * 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 GlossaryCategory to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetGlossaryCategoryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest other = + (com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest) 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.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest 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.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest 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.dataplex.v1.GetGlossaryCategoryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetGlossaryCategoryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Get GlossaryCategory Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetGlossaryCategoryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.GetGlossaryCategoryRequest) + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest build() { + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest buildPartial() { + com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest result = + new com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest other) { + if (other == com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest.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 GlossaryCategory to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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 GlossaryCategory to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.GetGlossaryCategoryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.GetGlossaryCategoryRequest) + private static final com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest(); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetGlossaryCategoryRequest 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.dataplex.v1.GetGlossaryCategoryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryCategoryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryCategoryRequestOrBuilder.java new file mode 100644 index 000000000000..29f1203f3b1a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryCategoryRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GetGlossaryCategoryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.GetGlossaryCategoryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The name of the GlossaryCategory to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Required. The name of the GlossaryCategory to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryRequest.java new file mode 100644 index 000000000000..b478ad13767f --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryRequest.java @@ -0,0 +1,662 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Get Glossary Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetGlossaryRequest} + */ +public final class GetGlossaryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.GetGlossaryRequest) + GetGlossaryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use GetGlossaryRequest.newBuilder() to construct. + private GetGlossaryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetGlossaryRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetGlossaryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetGlossaryRequest.class, + com.google.cloud.dataplex.v1.GetGlossaryRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The name of the Glossary to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * 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 Glossary to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetGlossaryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.GetGlossaryRequest other = + (com.google.cloud.dataplex.v1.GetGlossaryRequest) 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.dataplex.v1.GetGlossaryRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest 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.dataplex.v1.GetGlossaryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest 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.dataplex.v1.GetGlossaryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetGlossaryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Get Glossary Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetGlossaryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.GetGlossaryRequest) + com.google.cloud.dataplex.v1.GetGlossaryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetGlossaryRequest.class, + com.google.cloud.dataplex.v1.GetGlossaryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.GetGlossaryRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.GetGlossaryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryRequest build() { + com.google.cloud.dataplex.v1.GetGlossaryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryRequest buildPartial() { + com.google.cloud.dataplex.v1.GetGlossaryRequest result = + new com.google.cloud.dataplex.v1.GetGlossaryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.GetGlossaryRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.GetGlossaryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.GetGlossaryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.GetGlossaryRequest other) { + if (other == com.google.cloud.dataplex.v1.GetGlossaryRequest.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 Glossary to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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 Glossary to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.GetGlossaryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.GetGlossaryRequest) + private static final com.google.cloud.dataplex.v1.GetGlossaryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.GetGlossaryRequest(); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetGlossaryRequest 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.dataplex.v1.GetGlossaryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryRequestOrBuilder.java new file mode 100644 index 000000000000..57f38568a858 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GetGlossaryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.GetGlossaryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The name of the Glossary to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Required. The name of the Glossary to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryTermRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryTermRequest.java new file mode 100644 index 000000000000..bbdcd7c1f27a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryTermRequest.java @@ -0,0 +1,662 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Get GlossaryTerm Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetGlossaryTermRequest} + */ +public final class GetGlossaryTermRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.GetGlossaryTermRequest) + GetGlossaryTermRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use GetGlossaryTermRequest.newBuilder() to construct. + private GetGlossaryTermRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetGlossaryTermRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetGlossaryTermRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.GetGlossaryTermRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The name of the GlossaryTerm to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * 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 GlossaryTerm to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetGlossaryTermRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.GetGlossaryTermRequest other = + (com.google.cloud.dataplex.v1.GetGlossaryTermRequest) 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.dataplex.v1.GetGlossaryTermRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest 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.dataplex.v1.GetGlossaryTermRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest 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.dataplex.v1.GetGlossaryTermRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GetGlossaryTermRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Get GlossaryTerm Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GetGlossaryTermRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.GetGlossaryTermRequest) + com.google.cloud.dataplex.v1.GetGlossaryTermRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GetGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.GetGlossaryTermRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.GetGlossaryTermRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GetGlossaryTermRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryTermRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.GetGlossaryTermRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryTermRequest build() { + com.google.cloud.dataplex.v1.GetGlossaryTermRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GetGlossaryTermRequest buildPartial() { + com.google.cloud.dataplex.v1.GetGlossaryTermRequest result = + new com.google.cloud.dataplex.v1.GetGlossaryTermRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.GetGlossaryTermRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.GetGlossaryTermRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.GetGlossaryTermRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.GetGlossaryTermRequest other) { + if (other == com.google.cloud.dataplex.v1.GetGlossaryTermRequest.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 GlossaryTerm to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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 GlossaryTerm to retrieve.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.GetGlossaryTermRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.GetGlossaryTermRequest) + private static final com.google.cloud.dataplex.v1.GetGlossaryTermRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.GetGlossaryTermRequest(); + } + + public static com.google.cloud.dataplex.v1.GetGlossaryTermRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetGlossaryTermRequest 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.dataplex.v1.GetGlossaryTermRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryTermRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryTermRequestOrBuilder.java new file mode 100644 index 000000000000..c02d1330292a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GetGlossaryTermRequestOrBuilder.java @@ -0,0 +1,60 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GetGlossaryTermRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.GetGlossaryTermRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The name of the GlossaryTerm to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Required. The name of the GlossaryTerm to retrieve.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Glossary.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Glossary.java new file mode 100644 index 000000000000..bd383675a092 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Glossary.java @@ -0,0 +1,2623 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * A Glossary represents a collection of GlossaryCategories and GlossaryTerms
        + * defined by the user. Glossary is a top level resource and is the Google Cloud
        + * parent resource of all the GlossaryCategories and GlossaryTerms within it.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.Glossary} + */ +public final class Glossary extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.Glossary) + GlossaryOrBuilder { + private static final long serialVersionUID = 0L; + + // Use Glossary.newBuilder() to construct. + private Glossary(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Glossary() { + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + etag_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Glossary(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_Glossary_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.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_Glossary_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.Glossary.class, + com.google.cloud.dataplex.v1.Glossary.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the Glossary.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the Glossary.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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. System generated unique id for the Glossary. This ID will be
        +   * different if the Glossary is deleted and re-created with the
        +   * same name.
        +   * 
        + * + * + * 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. System generated unique id for the Glossary. This ID will be
        +   * different if the Glossary is deleted and re-created with the
        +   * same name.
        +   * 
        + * + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +   * This will be same as the GlossaryId, if not specified.
        +   * 
        + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +   * This will be same as the GlossaryId, if not specified.
        +   * 
        + * + * 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. The user-mutable description of the Glossary.
        +   * 
        + * + * 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. The user-mutable description of the Glossary.
        +   * 
        + * + * 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 CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
        +   * Output only. The time at which the Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 LABELS_FIELD_NUMBER = 7; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_Glossary_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. User-defined labels for the Glossary.
        +   * 
        + * + * 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. User-defined labels for the Glossary.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
        +   * Optional. User-defined labels for the Glossary.
        +   * 
        + * + * 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. User-defined labels for the Glossary.
        +   * 
        + * + * 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 TERM_COUNT_FIELD_NUMBER = 8; + private int termCount_ = 0; + + /** + * + * + *
        +   * Output only. The number of GlossaryTerms in the Glossary.
        +   * 
        + * + * int32 term_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The termCount. + */ + @java.lang.Override + public int getTermCount() { + return termCount_; + } + + public static final int CATEGORY_COUNT_FIELD_NUMBER = 9; + private int categoryCount_ = 0; + + /** + * + * + *
        +   * Output only. The number of GlossaryCategories in the Glossary.
        +   * 
        + * + * int32 category_count = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The categoryCount. + */ + @java.lang.Override + public int getCategoryCount() { + return categoryCount_; + } + + public static final int ETAG_FIELD_NUMBER = 10; + + @SuppressWarnings("serial") + private volatile java.lang.Object etag_ = ""; + + /** + * + * + *
        +   * Optional. Needed for resource freshness validation.
        +   * This checksum is computed by the server based on the value of other
        +   * fields, and may be sent on update and delete requests to ensure the
        +   * client has an up-to-date value before proceeding.
        +   * 
        + * + * string etag = 10 [(.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. Needed for resource freshness validation.
        +   * This checksum is computed by the server based on the value of other
        +   * fields, and may be sent on update and delete requests to ensure the
        +   * client has an up-to-date value before proceeding.
        +   * 
        + * + * string etag = 10 [(.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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, displayName_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getUpdateTime()); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 7); + if (termCount_ != 0) { + output.writeInt32(8, termCount_); + } + if (categoryCount_ != 0) { + output.writeInt32(9, categoryCount_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 10, etag_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, displayName_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, 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(7, labels__); + } + if (termCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(8, termCount_); + } + if (categoryCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(9, categoryCount_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, 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.dataplex.v1.Glossary)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.Glossary other = (com.google.cloud.dataplex.v1.Glossary) 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 (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 (getTermCount() != other.getTermCount()) return false; + if (getCategoryCount() != other.getCategoryCount()) 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) + 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(); + 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) + TERM_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getTermCount(); + hash = (37 * hash) + CATEGORY_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getCategoryCount(); + 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.dataplex.v1.Glossary parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.Glossary 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.dataplex.v1.Glossary parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.Glossary 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.dataplex.v1.Glossary parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.Glossary parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.Glossary parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.Glossary parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.Glossary parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.Glossary parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.Glossary parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.Glossary parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.Glossary 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * A Glossary represents a collection of GlossaryCategories and GlossaryTerms
        +   * defined by the user. Glossary is a top level resource and is the Google Cloud
        +   * parent resource of all the GlossaryCategories and GlossaryTerms within it.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.Glossary} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.Glossary) + com.google.cloud.dataplex.v1.GlossaryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_Glossary_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.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_Glossary_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.Glossary.class, + com.google.cloud.dataplex.v1.Glossary.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.Glossary.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCreateTimeFieldBuilder(); + getUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + internalGetMutableLabels().clear(); + termCount_ = 0; + categoryCount_ = 0; + etag_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_Glossary_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.Glossary getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.Glossary.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.Glossary build() { + com.google.cloud.dataplex.v1.Glossary result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.Glossary buildPartial() { + com.google.cloud.dataplex.v1.Glossary result = + new com.google.cloud.dataplex.v1.Glossary(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.Glossary 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_; + } + 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.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.termCount_ = termCount_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.categoryCount_ = categoryCount_; + } + if (((from_bitField0_ & 0x00000200) != 0)) { + result.etag_ = etag_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.Glossary) { + return mergeFrom((com.google.cloud.dataplex.v1.Glossary) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.Glossary other) { + if (other == com.google.cloud.dataplex.v1.Glossary.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.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + bitField0_ |= 0x00000040; + if (other.getTermCount() != 0) { + setTermCount(other.getTermCount()); + } + if (other.getCategoryCount() != 0) { + setCategoryCount(other.getCategoryCount()); + } + if (!other.getEtag().isEmpty()) { + etag_ = other.etag_; + bitField0_ |= 0x00000200; + 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: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + 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: + { + termCount_ = input.readInt32(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 72: + { + categoryCount_ = input.readInt32(); + bitField0_ |= 0x00000100; + break; + } // case 72 + case 82: + { + etag_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000200; + break; + } // case 82 + 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_ = ""; + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the Glossary.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the Glossary.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the Glossary.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the Glossary.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the Glossary.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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. System generated unique id for the Glossary. This ID will be
        +     * different if the Glossary is deleted and re-created with the
        +     * same name.
        +     * 
        + * + * + * 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. System generated unique id for the Glossary. This ID will be
        +     * different if the Glossary is deleted and re-created with the
        +     * same name.
        +     * 
        + * + * + * 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. System generated unique id for the Glossary. This ID will be
        +     * different if the Glossary is deleted and re-created with the
        +     * same name.
        +     * 
        + * + * + * 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. System generated unique id for the Glossary. This ID will be
        +     * different if the Glossary is deleted and re-created with the
        +     * same name.
        +     * 
        + * + * + * 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. System generated unique id for the Glossary. This ID will be
        +     * different if the Glossary is deleted and re-created with the
        +     * same name.
        +     * 
        + * + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +     * This will be same as the GlossaryId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +     * This will be same as the GlossaryId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +     * This will be same as the GlossaryId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +     * This will be same as the GlossaryId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the Glossary. This is user-mutable.
        +     * This will be same as the GlossaryId, if not specified.
        +     * 
        + * + * 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. The user-mutable description of the Glossary.
        +     * 
        + * + * 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. The user-mutable description of the Glossary.
        +     * 
        + * + * 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. The user-mutable description of the Glossary.
        +     * 
        + * + * 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. The user-mutable description of the Glossary.
        +     * 
        + * + * 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. The user-mutable description of the Glossary.
        +     * 
        + * + * 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 com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time at which the Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 getCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time at which the Glossary 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 Glossary was created.
        +     * 
        + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time at which the Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 getUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time at which the Glossary 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 Glossary was last updated.
        +     * 
        + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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_ |= 0x00000040; + onChanged(); + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
        +     * Optional. User-defined labels for the Glossary.
        +     * 
        + * + * 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. User-defined labels for the Glossary.
        +     * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
        +     * Optional. User-defined labels for the Glossary.
        +     * 
        + * + * 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. User-defined labels for the Glossary.
        +     * 
        + * + * 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. User-defined labels for the Glossary.
        +     * 
        + * + * 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. User-defined labels for the Glossary.
        +     * 
        + * + * 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. User-defined labels for the Glossary.
        +     * 
        + * + * 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 termCount_; + + /** + * + * + *
        +     * Output only. The number of GlossaryTerms in the Glossary.
        +     * 
        + * + * int32 term_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The termCount. + */ + @java.lang.Override + public int getTermCount() { + return termCount_; + } + + /** + * + * + *
        +     * Output only. The number of GlossaryTerms in the Glossary.
        +     * 
        + * + * int32 term_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The termCount to set. + * @return This builder for chaining. + */ + public Builder setTermCount(int value) { + + termCount_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. The number of GlossaryTerms in the Glossary.
        +     * 
        + * + * int32 term_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearTermCount() { + bitField0_ = (bitField0_ & ~0x00000080); + termCount_ = 0; + onChanged(); + return this; + } + + private int categoryCount_; + + /** + * + * + *
        +     * Output only. The number of GlossaryCategories in the Glossary.
        +     * 
        + * + * int32 category_count = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The categoryCount. + */ + @java.lang.Override + public int getCategoryCount() { + return categoryCount_; + } + + /** + * + * + *
        +     * Output only. The number of GlossaryCategories in the Glossary.
        +     * 
        + * + * int32 category_count = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The categoryCount to set. + * @return This builder for chaining. + */ + public Builder setCategoryCount(int value) { + + categoryCount_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. The number of GlossaryCategories in the Glossary.
        +     * 
        + * + * int32 category_count = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearCategoryCount() { + bitField0_ = (bitField0_ & ~0x00000100); + categoryCount_ = 0; + onChanged(); + return this; + } + + private java.lang.Object etag_ = ""; + + /** + * + * + *
        +     * Optional. Needed for resource freshness validation.
        +     * This checksum is computed by the server based on the value of other
        +     * fields, and may be sent on update and delete requests to ensure the
        +     * client has an up-to-date value before proceeding.
        +     * 
        + * + * string etag = 10 [(.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. Needed for resource freshness validation.
        +     * This checksum is computed by the server based on the value of other
        +     * fields, and may be sent on update and delete requests to ensure the
        +     * client has an up-to-date value before proceeding.
        +     * 
        + * + * string etag = 10 [(.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. Needed for resource freshness validation.
        +     * This checksum is computed by the server based on the value of other
        +     * fields, and may be sent on update and delete requests to ensure the
        +     * client has an up-to-date value before proceeding.
        +     * 
        + * + * string etag = 10 [(.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_ |= 0x00000200; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. Needed for resource freshness validation.
        +     * This checksum is computed by the server based on the value of other
        +     * fields, and may be sent on update and delete requests to ensure the
        +     * client has an up-to-date value before proceeding.
        +     * 
        + * + * string etag = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearEtag() { + etag_ = getDefaultInstance().getEtag(); + bitField0_ = (bitField0_ & ~0x00000200); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. Needed for resource freshness validation.
        +     * This checksum is computed by the server based on the value of other
        +     * fields, and may be sent on update and delete requests to ensure the
        +     * client has an up-to-date value before proceeding.
        +     * 
        + * + * string etag = 10 [(.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_ |= 0x00000200; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.Glossary) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.Glossary) + private static final com.google.cloud.dataplex.v1.Glossary DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.Glossary(); + } + + public static com.google.cloud.dataplex.v1.Glossary getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Glossary 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.dataplex.v1.Glossary getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategory.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategory.java new file mode 100644 index 000000000000..9a69967d83d1 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategory.java @@ -0,0 +1,2450 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * A GlossaryCategory represents a collection of GlossaryCategories and
        + * GlossaryTerms within a Glossary that are related to each other.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GlossaryCategory} + */ +public final class GlossaryCategory extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.GlossaryCategory) + GlossaryCategoryOrBuilder { + private static final long serialVersionUID = 0L; + + // Use GlossaryCategory.newBuilder() to construct. + private GlossaryCategory(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GlossaryCategory() { + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + parent_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GlossaryCategory(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryCategory_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.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryCategory_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GlossaryCategory.class, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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. System generated unique id for the GlossaryCategory. This ID
        +   * will be different if the GlossaryCategory is deleted and re-created with
        +   * the same name.
        +   * 
        + * + * + * 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. System generated unique id for the GlossaryCategory. This ID
        +   * will be different if the GlossaryCategory is deleted and re-created with
        +   * the same name.
        +   * 
        + * + * + * 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. User friendly display name of the GlossaryCategory. This is
        +   * user-mutable. This will be same as the GlossaryCategoryId, if not
        +   * specified.
        +   * 
        + * + * 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. User friendly display name of the GlossaryCategory. This is
        +   * user-mutable. This will be same as the GlossaryCategoryId, if not
        +   * specified.
        +   * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +   * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +   * 
        + * + * 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 CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
        +   * Output only. The time at which the GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 LABELS_FIELD_NUMBER = 7; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryCategory_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. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * 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 PARENT_FIELD_NUMBER = 8; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
        +   * Required. The immediate parent of the GlossaryCategory in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @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 immediate parent of the GlossaryCategory in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, displayName_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getUpdateTime()); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 7); + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 8, parent_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, displayName_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, 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(7, labels__); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, parent_); + } + 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.dataplex.v1.GlossaryCategory)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.GlossaryCategory other = + (com.google.cloud.dataplex.v1.GlossaryCategory) 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 (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 (!getParent().equals(other.getParent())) 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(); + 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) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory 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.dataplex.v1.GlossaryCategory parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory 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.dataplex.v1.GlossaryCategory parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GlossaryCategory 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * A GlossaryCategory represents a collection of GlossaryCategories and
        +   * GlossaryTerms within a Glossary that are related to each other.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GlossaryCategory} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.GlossaryCategory) + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryCategory_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.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryCategory_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GlossaryCategory.class, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.GlossaryCategory.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCreateTimeFieldBuilder(); + getUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + internalGetMutableLabels().clear(); + parent_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryCategory_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategory getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategory build() { + com.google.cloud.dataplex.v1.GlossaryCategory result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategory buildPartial() { + com.google.cloud.dataplex.v1.GlossaryCategory result = + new com.google.cloud.dataplex.v1.GlossaryCategory(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.GlossaryCategory 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_; + } + 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.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.parent_ = parent_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.GlossaryCategory) { + return mergeFrom((com.google.cloud.dataplex.v1.GlossaryCategory) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.GlossaryCategory other) { + if (other == com.google.cloud.dataplex.v1.GlossaryCategory.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.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + bitField0_ |= 0x00000040; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000080; + 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: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + 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 66: + { + parent_ = input.readStringRequireUtf8(); + 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 java.lang.Object name_ = ""; + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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. System generated unique id for the GlossaryCategory. This ID
        +     * will be different if the GlossaryCategory is deleted and re-created with
        +     * the same name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryCategory. This ID
        +     * will be different if the GlossaryCategory is deleted and re-created with
        +     * the same name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryCategory. This ID
        +     * will be different if the GlossaryCategory is deleted and re-created with
        +     * the same name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryCategory. This ID
        +     * will be different if the GlossaryCategory is deleted and re-created with
        +     * the same name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryCategory. This ID
        +     * will be different if the GlossaryCategory is deleted and re-created with
        +     * the same name.
        +     * 
        + * + * + * 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. User friendly display name of the GlossaryCategory. This is
        +     * user-mutable. This will be same as the GlossaryCategoryId, if not
        +     * specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryCategory. This is
        +     * user-mutable. This will be same as the GlossaryCategoryId, if not
        +     * specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryCategory. This is
        +     * user-mutable. This will be same as the GlossaryCategoryId, if not
        +     * specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryCategory. This is
        +     * user-mutable. This will be same as the GlossaryCategoryId, if not
        +     * specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryCategory. This is
        +     * user-mutable. This will be same as the GlossaryCategoryId, if not
        +     * specified.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryCategory.
        +     * 
        + * + * 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 com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time at which the GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 getCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time at which the GlossaryCategory 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 GlossaryCategory was created.
        +     * 
        + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time at which the GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 getUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time at which the GlossaryCategory 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 GlossaryCategory was last updated.
        +     * 
        + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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_ |= 0x00000040; + onChanged(); + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
        +     * Optional. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
        +     * Optional. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +     * 
        + * + * 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 java.lang.Object parent_ = ""; + + /** + * + * + *
        +     * Required. The immediate parent of the GlossaryCategory in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @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 immediate parent of the GlossaryCategory in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @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 immediate parent of the GlossaryCategory in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @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_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The immediate parent of the GlossaryCategory in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The immediate parent of the GlossaryCategory in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @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_ |= 0x00000080; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.GlossaryCategory) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.GlossaryCategory) + private static final com.google.cloud.dataplex.v1.GlossaryCategory DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.GlossaryCategory(); + } + + public static com.google.cloud.dataplex.v1.GlossaryCategory getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GlossaryCategory 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.dataplex.v1.GlossaryCategory getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategoryName.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategoryName.java new file mode 100644 index 000000000000..76022aab145e --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategoryName.java @@ -0,0 +1,269 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class GlossaryCategoryName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_GLOSSARY_GLOSSARY_CATEGORY = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/glossaries/{glossary}/categories/{glossary_category}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String glossary; + private final String glossaryCategory; + + @Deprecated + protected GlossaryCategoryName() { + project = null; + location = null; + glossary = null; + glossaryCategory = null; + } + + private GlossaryCategoryName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + glossary = Preconditions.checkNotNull(builder.getGlossary()); + glossaryCategory = Preconditions.checkNotNull(builder.getGlossaryCategory()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getGlossary() { + return glossary; + } + + public String getGlossaryCategory() { + return glossaryCategory; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static GlossaryCategoryName of( + String project, String location, String glossary, String glossaryCategory) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setGlossary(glossary) + .setGlossaryCategory(glossaryCategory) + .build(); + } + + public static String format( + String project, String location, String glossary, String glossaryCategory) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setGlossary(glossary) + .setGlossaryCategory(glossaryCategory) + .build() + .toString(); + } + + public static GlossaryCategoryName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_GLOSSARY_GLOSSARY_CATEGORY.validatedMatch( + formattedString, "GlossaryCategoryName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("glossary"), + matchMap.get("glossary_category")); + } + + 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 values) { + List list = new ArrayList<>(values.size()); + for (GlossaryCategoryName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_GLOSSARY_GLOSSARY_CATEGORY.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 (glossary != null) { + fieldMapBuilder.put("glossary", glossary); + } + if (glossaryCategory != null) { + fieldMapBuilder.put("glossary_category", glossaryCategory); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_GLOSSARY_GLOSSARY_CATEGORY.instantiate( + "project", + project, + "location", + location, + "glossary", + glossary, + "glossary_category", + glossaryCategory); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + GlossaryCategoryName that = ((GlossaryCategoryName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.glossary, that.glossary) + && Objects.equals(this.glossaryCategory, that.glossaryCategory); + } + 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(glossary); + h *= 1000003; + h ^= Objects.hashCode(glossaryCategory); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/glossaries/{glossary}/categories/{glossary_category}. + */ + public static class Builder { + private String project; + private String location; + private String glossary; + private String glossaryCategory; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getGlossary() { + return glossary; + } + + public String getGlossaryCategory() { + return glossaryCategory; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setGlossary(String glossary) { + this.glossary = glossary; + return this; + } + + public Builder setGlossaryCategory(String glossaryCategory) { + this.glossaryCategory = glossaryCategory; + return this; + } + + private Builder(GlossaryCategoryName glossaryCategoryName) { + this.project = glossaryCategoryName.project; + this.location = glossaryCategoryName.location; + this.glossary = glossaryCategoryName.glossary; + this.glossaryCategory = glossaryCategoryName.glossaryCategory; + } + + public GlossaryCategoryName build() { + return new GlossaryCategoryName(this); + } + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategoryOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategoryOrBuilder.java new file mode 100644 index 000000000000..5e95dcb7c684 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryCategoryOrBuilder.java @@ -0,0 +1,329 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GlossaryCategoryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.GlossaryCategory) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * Output only. System generated unique id for the GlossaryCategory. This ID
        +   * will be different if the GlossaryCategory is deleted and re-created with
        +   * the same name.
        +   * 
        + * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
        +   * Output only. System generated unique id for the GlossaryCategory. This ID
        +   * will be different if the GlossaryCategory is deleted and re-created with
        +   * the same name.
        +   * 
        + * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
        +   * Optional. User friendly display name of the GlossaryCategory. This is
        +   * user-mutable. This will be same as the GlossaryCategoryId, if not
        +   * specified.
        +   * 
        + * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
        +   * Optional. User friendly display name of the GlossaryCategory. This is
        +   * user-mutable. This will be same as the GlossaryCategoryId, if not
        +   * specified.
        +   * 
        + * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
        +   * Optional. The user-mutable description of the GlossaryCategory.
        +   * 
        + * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
        +   * Optional. The user-mutable description of the GlossaryCategory.
        +   * 
        + * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
        +   * Output only. The time at which the GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory 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 GlossaryCategory was last updated.
        +   * 
        + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getLabelsCount(); + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getLabelsMap(); + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * 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. User-defined labels for the GlossaryCategory.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + /** + * + * + *
        +   * Required. The immediate parent of the GlossaryCategory in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
        +   * Required. The immediate parent of the GlossaryCategory in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryName.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryName.java new file mode 100644 index 000000000000..414a00152c37 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryName.java @@ -0,0 +1,223 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class GlossaryName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_GLOSSARY = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/glossaries/{glossary}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String glossary; + + @Deprecated + protected GlossaryName() { + project = null; + location = null; + glossary = null; + } + + private GlossaryName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + glossary = Preconditions.checkNotNull(builder.getGlossary()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getGlossary() { + return glossary; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static GlossaryName of(String project, String location, String glossary) { + return newBuilder().setProject(project).setLocation(location).setGlossary(glossary).build(); + } + + public static String format(String project, String location, String glossary) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setGlossary(glossary) + .build() + .toString(); + } + + public static GlossaryName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_GLOSSARY.validatedMatch( + formattedString, "GlossaryName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("glossary")); + } + + 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 values) { + List list = new ArrayList<>(values.size()); + for (GlossaryName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_GLOSSARY.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 (glossary != null) { + fieldMapBuilder.put("glossary", glossary); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_GLOSSARY.instantiate( + "project", project, "location", location, "glossary", glossary); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + GlossaryName that = ((GlossaryName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.glossary, that.glossary); + } + 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(glossary); + return h; + } + + /** Builder for projects/{project}/locations/{location}/glossaries/{glossary}. */ + public static class Builder { + private String project; + private String location; + private String glossary; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getGlossary() { + return glossary; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setGlossary(String glossary) { + this.glossary = glossary; + return this; + } + + private Builder(GlossaryName glossaryName) { + this.project = glossaryName.project; + this.location = glossaryName.location; + this.glossary = glossaryName.glossary; + } + + public GlossaryName build() { + return new GlossaryName(this); + } + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryOrBuilder.java new file mode 100644 index 000000000000..49a9cf3e2503 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryOrBuilder.java @@ -0,0 +1,349 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GlossaryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.Glossary) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the Glossary.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the Glossary.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * Output only. System generated unique id for the Glossary. This ID will be
        +   * different if the Glossary is deleted and re-created with the
        +   * same name.
        +   * 
        + * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
        +   * Output only. System generated unique id for the Glossary. This ID will be
        +   * different if the Glossary is deleted and re-created with the
        +   * same name.
        +   * 
        + * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
        +   * Optional. User friendly display name of the Glossary. This is user-mutable.
        +   * This will be same as the GlossaryId, if not specified.
        +   * 
        + * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
        +   * Optional. User friendly display name of the Glossary. This is user-mutable.
        +   * This will be same as the GlossaryId, if not specified.
        +   * 
        + * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
        +   * Optional. The user-mutable description of the Glossary.
        +   * 
        + * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
        +   * Optional. The user-mutable description of the Glossary.
        +   * 
        + * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
        +   * Output only. The time at which the Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary 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 Glossary was last updated.
        +   * 
        + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
        +   * Optional. User-defined labels for the Glossary.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getLabelsCount(); + + /** + * + * + *
        +   * Optional. User-defined labels for the Glossary.
        +   * 
        + * + * 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. User-defined labels for the Glossary.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getLabelsMap(); + + /** + * + * + *
        +   * Optional. User-defined labels for the Glossary.
        +   * 
        + * + * 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. User-defined labels for the Glossary.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + /** + * + * + *
        +   * Output only. The number of GlossaryTerms in the Glossary.
        +   * 
        + * + * int32 term_count = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The termCount. + */ + int getTermCount(); + + /** + * + * + *
        +   * Output only. The number of GlossaryCategories in the Glossary.
        +   * 
        + * + * int32 category_count = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The categoryCount. + */ + int getCategoryCount(); + + /** + * + * + *
        +   * Optional. Needed for resource freshness validation.
        +   * This checksum is computed by the server based on the value of other
        +   * fields, and may be sent on update and delete requests to ensure the
        +   * client has an up-to-date value before proceeding.
        +   * 
        + * + * string etag = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The etag. + */ + java.lang.String getEtag(); + + /** + * + * + *
        +   * Optional. Needed for resource freshness validation.
        +   * This checksum is computed by the server based on the value of other
        +   * fields, and may be sent on update and delete requests to ensure the
        +   * client has an up-to-date value before proceeding.
        +   * 
        + * + * string etag = 10 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for etag. + */ + com.google.protobuf.ByteString getEtagBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTerm.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTerm.java new file mode 100644 index 000000000000..889a8248bdcc --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTerm.java @@ -0,0 +1,2459 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * GlossaryTerms are the core of Glossary.
        + * A GlossaryTerm holds a rich text description that can be attached to Entries
        + * or specific columns to enrich them.
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GlossaryTerm} + */ +public final class GlossaryTerm extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.GlossaryTerm) + GlossaryTermOrBuilder { + private static final long serialVersionUID = 0L; + + // Use GlossaryTerm.newBuilder() to construct. + private GlossaryTerm(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GlossaryTerm() { + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + parent_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GlossaryTerm(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryTerm_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.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryTerm_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GlossaryTerm.class, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryTerm.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryTerm.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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. System generated unique id for the GlossaryTerm. This ID will
        +   * be different if the GlossaryTerm is deleted and re-created with the same
        +   * name.
        +   * 
        + * + * + * 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. System generated unique id for the GlossaryTerm. This ID will
        +   * be different if the GlossaryTerm is deleted and re-created with the same
        +   * name.
        +   * 
        + * + * + * 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. User friendly display name of the GlossaryTerm. This is
        +   * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +   * 
        + * + * 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. User friendly display name of the GlossaryTerm. This is
        +   * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +   * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +   * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +   * 
        + * + * 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 CREATE_TIME_FIELD_NUMBER = 5; + private com.google.protobuf.Timestamp createTime_; + + /** + * + * + *
        +   * Output only. The time at which the GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 LABELS_FIELD_NUMBER = 7; + + private static final class LabelsDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryTerm_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. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * 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 PARENT_FIELD_NUMBER = 8; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
        +   * Required. The immediate parent of the GlossaryTerm in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string parent = 8 [(.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 immediate parent of the GlossaryTerm in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string parent = 8 [(.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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, displayName_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(6, getUpdateTime()); + } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetLabels(), LabelsDefaultEntryHolder.defaultEntry, 7); + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 8, parent_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, uid_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, displayName_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, description_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, 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(7, labels__); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, parent_); + } + 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.dataplex.v1.GlossaryTerm)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.GlossaryTerm other = + (com.google.cloud.dataplex.v1.GlossaryTerm) 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 (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 (!getParent().equals(other.getParent())) 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(); + 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) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm 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.dataplex.v1.GlossaryTerm parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm 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.dataplex.v1.GlossaryTerm parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.GlossaryTerm 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * GlossaryTerms are the core of Glossary.
        +   * A GlossaryTerm holds a rich text description that can be attached to Entries
        +   * or specific columns to enrich them.
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.GlossaryTerm} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.GlossaryTerm) + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryTerm_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.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryTerm_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.GlossaryTerm.class, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.GlossaryTerm.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCreateTimeFieldBuilder(); + getUpdateTimeFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + uid_ = ""; + displayName_ = ""; + description_ = ""; + createTime_ = null; + if (createTimeBuilder_ != null) { + createTimeBuilder_.dispose(); + createTimeBuilder_ = null; + } + updateTime_ = null; + if (updateTimeBuilder_ != null) { + updateTimeBuilder_.dispose(); + updateTimeBuilder_ = null; + } + internalGetMutableLabels().clear(); + parent_ = ""; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_GlossaryTerm_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTerm getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTerm build() { + com.google.cloud.dataplex.v1.GlossaryTerm result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTerm buildPartial() { + com.google.cloud.dataplex.v1.GlossaryTerm result = + new com.google.cloud.dataplex.v1.GlossaryTerm(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.GlossaryTerm 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_; + } + 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.labels_ = internalGetLabels(); + result.labels_.makeImmutable(); + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.parent_ = parent_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.GlossaryTerm) { + return mergeFrom((com.google.cloud.dataplex.v1.GlossaryTerm) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.GlossaryTerm other) { + if (other == com.google.cloud.dataplex.v1.GlossaryTerm.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.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + internalGetMutableLabels().mergeFrom(other.internalGetLabels()); + bitField0_ |= 0x00000040; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + bitField0_ |= 0x00000080; + 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: + { + displayName_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000004; + break; + } // case 26 + case 34: + { + description_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000008; + break; + } // case 34 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000020; + break; + } // case 50 + 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 66: + { + parent_ = input.readStringRequireUtf8(); + 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 java.lang.Object name_ = ""; + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryTerm.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryTerm.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryTerm.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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; + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryTerm.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Output only. Identifier. The resource name of the GlossaryTerm.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.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. System generated unique id for the GlossaryTerm. This ID will
        +     * be different if the GlossaryTerm is deleted and re-created with the same
        +     * name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryTerm. This ID will
        +     * be different if the GlossaryTerm is deleted and re-created with the same
        +     * name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryTerm. This ID will
        +     * be different if the GlossaryTerm is deleted and re-created with the same
        +     * name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryTerm. This ID will
        +     * be different if the GlossaryTerm is deleted and re-created with the same
        +     * name.
        +     * 
        + * + * + * 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. System generated unique id for the GlossaryTerm. This ID will
        +     * be different if the GlossaryTerm is deleted and re-created with the same
        +     * name.
        +     * 
        + * + * + * 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. User friendly display name of the GlossaryTerm. This is
        +     * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryTerm. This is
        +     * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryTerm. This is
        +     * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryTerm. This is
        +     * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +     * 
        + * + * 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. User friendly display name of the GlossaryTerm. This is
        +     * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +     * 
        + * + * 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. The user-mutable description of the GlossaryTerm.
        +     * 
        + * + * 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 com.google.protobuf.Timestamp createTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + createTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time at which the GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 getCreateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time at which the GlossaryTerm 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 GlossaryTerm was created.
        +     * 
        + * + * + * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getCreateTimeFieldBuilder() { + if (createTimeBuilder_ == null) { + createTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + updateTimeBuilder_; + + /** + * + * + *
        +     * Output only. The time at which the GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 getUpdateTimeFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Output only. The time at which the GlossaryTerm 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 GlossaryTerm was last updated.
        +     * 
        + * + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getUpdateTimeFieldBuilder() { + if (updateTimeBuilder_ == null) { + updateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + 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_ |= 0x00000040; + onChanged(); + return labels_; + } + + public int getLabelsCount() { + return internalGetLabels().getMap().size(); + } + + /** + * + * + *
        +     * Optional. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + @java.lang.Override + public java.util.Map getLabelsMap() { + return internalGetLabels().getMap(); + } + + /** + * + * + *
        +     * Optional. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +     * 
        + * + * 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 java.lang.Object parent_ = ""; + + /** + * + * + *
        +     * Required. The immediate parent of the GlossaryTerm in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string parent = 8 [(.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 immediate parent of the GlossaryTerm in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string parent = 8 [(.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 immediate parent of the GlossaryTerm in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string parent = 8 [(.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_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The immediate parent of the GlossaryTerm in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + parent_ = getDefaultInstance().getParent(); + bitField0_ = (bitField0_ & ~0x00000080); + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The immediate parent of the GlossaryTerm in the
        +     * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * OR
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * string parent = 8 [(.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_ |= 0x00000080; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.GlossaryTerm) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.GlossaryTerm) + private static final com.google.cloud.dataplex.v1.GlossaryTerm DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.GlossaryTerm(); + } + + public static com.google.cloud.dataplex.v1.GlossaryTerm getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GlossaryTerm 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.dataplex.v1.GlossaryTerm getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTermName.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTermName.java new file mode 100644 index 000000000000..6711fbe6746d --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTermName.java @@ -0,0 +1,269 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.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; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +@Generated("by gapic-generator-java") +public class GlossaryTermName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_GLOSSARY_GLOSSARY_TERM = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/glossaries/{glossary}/terms/{glossary_term}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String glossary; + private final String glossaryTerm; + + @Deprecated + protected GlossaryTermName() { + project = null; + location = null; + glossary = null; + glossaryTerm = null; + } + + private GlossaryTermName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + glossary = Preconditions.checkNotNull(builder.getGlossary()); + glossaryTerm = Preconditions.checkNotNull(builder.getGlossaryTerm()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getGlossary() { + return glossary; + } + + public String getGlossaryTerm() { + return glossaryTerm; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static GlossaryTermName of( + String project, String location, String glossary, String glossaryTerm) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setGlossary(glossary) + .setGlossaryTerm(glossaryTerm) + .build(); + } + + public static String format( + String project, String location, String glossary, String glossaryTerm) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setGlossary(glossary) + .setGlossaryTerm(glossaryTerm) + .build() + .toString(); + } + + public static GlossaryTermName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_GLOSSARY_GLOSSARY_TERM.validatedMatch( + formattedString, "GlossaryTermName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("glossary"), + matchMap.get("glossary_term")); + } + + 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 values) { + List list = new ArrayList<>(values.size()); + for (GlossaryTermName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_GLOSSARY_GLOSSARY_TERM.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 (glossary != null) { + fieldMapBuilder.put("glossary", glossary); + } + if (glossaryTerm != null) { + fieldMapBuilder.put("glossary_term", glossaryTerm); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_GLOSSARY_GLOSSARY_TERM.instantiate( + "project", + project, + "location", + location, + "glossary", + glossary, + "glossary_term", + glossaryTerm); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null && getClass() == o.getClass()) { + GlossaryTermName that = ((GlossaryTermName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.glossary, that.glossary) + && Objects.equals(this.glossaryTerm, that.glossaryTerm); + } + 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(glossary); + h *= 1000003; + h ^= Objects.hashCode(glossaryTerm); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/glossaries/{glossary}/terms/{glossary_term}. + */ + public static class Builder { + private String project; + private String location; + private String glossary; + private String glossaryTerm; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getGlossary() { + return glossary; + } + + public String getGlossaryTerm() { + return glossaryTerm; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setGlossary(String glossary) { + this.glossary = glossary; + return this; + } + + public Builder setGlossaryTerm(String glossaryTerm) { + this.glossaryTerm = glossaryTerm; + return this; + } + + private Builder(GlossaryTermName glossaryTermName) { + this.project = glossaryTermName.project; + this.location = glossaryTermName.location; + this.glossary = glossaryTermName.glossary; + this.glossaryTerm = glossaryTermName.glossaryTerm; + } + + public GlossaryTermName build() { + return new GlossaryTermName(this); + } + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTermOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTermOrBuilder.java new file mode 100644 index 000000000000..7145494c8a67 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/GlossaryTermOrBuilder.java @@ -0,0 +1,331 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface GlossaryTermOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.GlossaryTerm) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryTerm.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * Output only. Identifier. The resource name of the GlossaryTerm.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * Output only. System generated unique id for the GlossaryTerm. This ID will
        +   * be different if the GlossaryTerm is deleted and re-created with the same
        +   * name.
        +   * 
        + * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The uid. + */ + java.lang.String getUid(); + + /** + * + * + *
        +   * Output only. System generated unique id for the GlossaryTerm. This ID will
        +   * be different if the GlossaryTerm is deleted and re-created with the same
        +   * name.
        +   * 
        + * + * + * string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_info) = { ... } + * + * + * @return The bytes for uid. + */ + com.google.protobuf.ByteString getUidBytes(); + + /** + * + * + *
        +   * Optional. User friendly display name of the GlossaryTerm. This is
        +   * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +   * 
        + * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + + /** + * + * + *
        +   * Optional. User friendly display name of the GlossaryTerm. This is
        +   * user-mutable. This will be same as the GlossaryTermId, if not specified.
        +   * 
        + * + * string display_name = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
        +   * Optional. The user-mutable description of the GlossaryTerm.
        +   * 
        + * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The description. + */ + java.lang.String getDescription(); + + /** + * + * + *
        +   * Optional. The user-mutable description of the GlossaryTerm.
        +   * 
        + * + * string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
        +   * Output only. The time at which the GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm 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 GlossaryTerm was last updated.
        +   * 
        + * + * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + int getLabelsCount(); + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.util.Map getLabelsMap(); + + /** + * + * + *
        +   * Optional. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * 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. User-defined labels for the GlossaryTerm.
        +   * 
        + * + * map<string, string> labels = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + java.lang.String getLabelsOrThrow(java.lang.String key); + + /** + * + * + *
        +   * Required. The immediate parent of the GlossaryTerm in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
        +   * Required. The immediate parent of the GlossaryTerm in the
        +   * resource-hierarchy. It can either be a Glossary or a GlossaryCategory.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * OR
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * string parent = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItem.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItem.java index 676d61ca8d62..9b74c4831ad5 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItem.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItem.java @@ -121,6 +121,65 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { return entry_ == null ? com.google.cloud.dataplex.v1.Entry.getDefaultInstance() : entry_; } + public static final int ENTRY_LINK_FIELD_NUMBER = 4; + private com.google.cloud.dataplex.v1.EntryLink entryLink_; + + /** + * + * + *
        +   * Information about the entry link. User should provide either one of the
        +   * entry or entry_link. While providing entry_link, user should not
        +   * provide update_mask and aspect_keys.
        +   * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + * + * @return Whether the entryLink field is set. + */ + @java.lang.Override + public boolean hasEntryLink() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +   * Information about the entry link. User should provide either one of the
        +   * entry or entry_link. While providing entry_link, user should not
        +   * provide update_mask and aspect_keys.
        +   * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + * + * @return The entryLink. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLink getEntryLink() { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } + + /** + * + * + *
        +   * Information about the entry link. User should provide either one of the
        +   * entry or entry_link. While providing entry_link, user should not
        +   * provide update_mask and aspect_keys.
        +   * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.EntryLinkOrBuilder getEntryLinkOrBuilder() { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } + public static final int UPDATE_MASK_FIELD_NUMBER = 2; private com.google.protobuf.FieldMask updateMask_; @@ -131,12 +190,12 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -144,10 +203,10 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -157,7 +216,7 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { */ @java.lang.Override public boolean hasUpdateMask() { - return ((bitField0_ & 0x00000002) != 0); + return ((bitField0_ & 0x00000004) != 0); } /** @@ -167,12 +226,12 @@ public boolean hasUpdateMask() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -180,10 +239,10 @@ public boolean hasUpdateMask() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -203,12 +262,12 @@ public com.google.protobuf.FieldMask getUpdateMask() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -216,10 +275,10 @@ public com.google.protobuf.FieldMask getUpdateMask() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -256,8 +315,8 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -288,8 +347,8 @@ public com.google.protobuf.ProtocolStringList getAspectKeysList() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -320,8 +379,8 @@ public int getAspectKeysCount() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -353,8 +412,8 @@ public java.lang.String getAspectKeys(int index) { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -383,12 +442,15 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(1, getEntry()); } - if (((bitField0_ & 0x00000002) != 0)) { + if (((bitField0_ & 0x00000004) != 0)) { output.writeMessage(2, getUpdateMask()); } for (int i = 0; i < aspectKeys_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, aspectKeys_.getRaw(i)); } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(4, getEntryLink()); + } getUnknownFields().writeTo(output); } @@ -401,7 +463,7 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getEntry()); } - if (((bitField0_ & 0x00000002) != 0)) { + if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); } { @@ -412,6 +474,9 @@ public int getSerializedSize() { size += dataSize; size += 1 * getAspectKeysList().size(); } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getEntryLink()); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -431,6 +496,10 @@ public boolean equals(final java.lang.Object obj) { if (hasEntry()) { if (!getEntry().equals(other.getEntry())) return false; } + if (hasEntryLink() != other.hasEntryLink()) return false; + if (hasEntryLink()) { + if (!getEntryLink().equals(other.getEntryLink())) return false; + } if (hasUpdateMask() != other.hasUpdateMask()) return false; if (hasUpdateMask()) { if (!getUpdateMask().equals(other.getUpdateMask())) return false; @@ -451,6 +520,10 @@ public int hashCode() { hash = (37 * hash) + ENTRY_FIELD_NUMBER; hash = (53 * hash) + getEntry().hashCode(); } + if (hasEntryLink()) { + hash = (37 * hash) + ENTRY_LINK_FIELD_NUMBER; + hash = (53 * hash) + getEntryLink().hashCode(); + } if (hasUpdateMask()) { hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; hash = (53 * hash) + getUpdateMask().hashCode(); @@ -608,6 +681,7 @@ private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getEntryFieldBuilder(); + getEntryLinkFieldBuilder(); getUpdateMaskFieldBuilder(); } } @@ -621,6 +695,11 @@ public Builder clear() { entryBuilder_.dispose(); entryBuilder_ = null; } + entryLink_ = null; + if (entryLinkBuilder_ != null) { + entryLinkBuilder_.dispose(); + entryLinkBuilder_ = null; + } updateMask_ = null; if (updateMaskBuilder_ != null) { updateMaskBuilder_.dispose(); @@ -669,10 +748,14 @@ private void buildPartial0(com.google.cloud.dataplex.v1.ImportItem result) { to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000002) != 0)) { - result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + result.entryLink_ = entryLinkBuilder_ == null ? entryLink_ : entryLinkBuilder_.build(); to_bitField0_ |= 0x00000002; } if (((from_bitField0_ & 0x00000004) != 0)) { + result.updateMask_ = updateMaskBuilder_ == null ? updateMask_ : updateMaskBuilder_.build(); + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { aspectKeys_.makeImmutable(); result.aspectKeys_ = aspectKeys_; } @@ -727,13 +810,16 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.ImportItem other) { if (other.hasEntry()) { mergeEntry(other.getEntry()); } + if (other.hasEntryLink()) { + mergeEntryLink(other.getEntryLink()); + } if (other.hasUpdateMask()) { mergeUpdateMask(other.getUpdateMask()); } if (!other.aspectKeys_.isEmpty()) { if (aspectKeys_.isEmpty()) { aspectKeys_ = other.aspectKeys_; - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; } else { ensureAspectKeysIsMutable(); aspectKeys_.addAll(other.aspectKeys_); @@ -775,7 +861,7 @@ public Builder mergeFrom( case 18: { input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; break; } // case 18 case 26: @@ -785,6 +871,12 @@ public Builder mergeFrom( aspectKeys_.add(s); break; } // case 26 + case 34: + { + input.readMessage(getEntryLinkFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 34 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -994,6 +1086,218 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { return entryBuilder_; } + private com.google.cloud.dataplex.v1.EntryLink entryLink_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink, + com.google.cloud.dataplex.v1.EntryLink.Builder, + com.google.cloud.dataplex.v1.EntryLinkOrBuilder> + entryLinkBuilder_; + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + * + * @return Whether the entryLink field is set. + */ + public boolean hasEntryLink() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + * + * @return The entryLink. + */ + public com.google.cloud.dataplex.v1.EntryLink getEntryLink() { + if (entryLinkBuilder_ == null) { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } else { + return entryLinkBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + public Builder setEntryLink(com.google.cloud.dataplex.v1.EntryLink value) { + if (entryLinkBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + entryLink_ = value; + } else { + entryLinkBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + public Builder setEntryLink(com.google.cloud.dataplex.v1.EntryLink.Builder builderForValue) { + if (entryLinkBuilder_ == null) { + entryLink_ = builderForValue.build(); + } else { + entryLinkBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + public Builder mergeEntryLink(com.google.cloud.dataplex.v1.EntryLink value) { + if (entryLinkBuilder_ == null) { + if (((bitField0_ & 0x00000002) != 0) + && entryLink_ != null + && entryLink_ != com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance()) { + getEntryLinkBuilder().mergeFrom(value); + } else { + entryLink_ = value; + } + } else { + entryLinkBuilder_.mergeFrom(value); + } + if (entryLink_ != null) { + bitField0_ |= 0x00000002; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + public Builder clearEntryLink() { + bitField0_ = (bitField0_ & ~0x00000002); + entryLink_ = null; + if (entryLinkBuilder_ != null) { + entryLinkBuilder_.dispose(); + entryLinkBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + public com.google.cloud.dataplex.v1.EntryLink.Builder getEntryLinkBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return getEntryLinkFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + public com.google.cloud.dataplex.v1.EntryLinkOrBuilder getEntryLinkOrBuilder() { + if (entryLinkBuilder_ != null) { + return entryLinkBuilder_.getMessageOrBuilder(); + } else { + return entryLink_ == null + ? com.google.cloud.dataplex.v1.EntryLink.getDefaultInstance() + : entryLink_; + } + } + + /** + * + * + *
        +     * Information about the entry link. User should provide either one of the
        +     * entry or entry_link. While providing entry_link, user should not
        +     * provide update_mask and aspect_keys.
        +     * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink, + com.google.cloud.dataplex.v1.EntryLink.Builder, + com.google.cloud.dataplex.v1.EntryLinkOrBuilder> + getEntryLinkFieldBuilder() { + if (entryLinkBuilder_ == null) { + entryLinkBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.EntryLink, + com.google.cloud.dataplex.v1.EntryLink.Builder, + com.google.cloud.dataplex.v1.EntryLinkOrBuilder>( + getEntryLink(), getParentForChildren(), isClean()); + entryLink_ = null; + } + return entryLinkBuilder_; + } + private com.google.protobuf.FieldMask updateMask_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.FieldMask, @@ -1008,12 +1312,12 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1021,10 +1325,10 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1033,7 +1337,7 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder() { * @return Whether the updateMask field is set. */ public boolean hasUpdateMask() { - return ((bitField0_ & 0x00000002) != 0); + return ((bitField0_ & 0x00000004) != 0); } /** @@ -1043,12 +1347,12 @@ public boolean hasUpdateMask() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1056,10 +1360,10 @@ public boolean hasUpdateMask() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1084,12 +1388,12 @@ public com.google.protobuf.FieldMask getUpdateMask() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1097,10 +1401,10 @@ public com.google.protobuf.FieldMask getUpdateMask() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1115,7 +1419,7 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) { } else { updateMaskBuilder_.setMessage(value); } - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return this; } @@ -1127,12 +1431,12 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1140,10 +1444,10 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask value) { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1155,7 +1459,7 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForVal } else { updateMaskBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return this; } @@ -1167,12 +1471,12 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForVal * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1180,10 +1484,10 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForVal * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1191,7 +1495,7 @@ public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForVal */ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { if (updateMaskBuilder_ == null) { - if (((bitField0_ & 0x00000002) != 0) + if (((bitField0_ & 0x00000004) != 0) && updateMask_ != null && updateMask_ != com.google.protobuf.FieldMask.getDefaultInstance()) { getUpdateMaskBuilder().mergeFrom(value); @@ -1202,7 +1506,7 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { updateMaskBuilder_.mergeFrom(value); } if (updateMask_ != null) { - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); } return this; @@ -1215,12 +1519,12 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1228,17 +1532,17 @@ public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * * .google.protobuf.FieldMask update_mask = 2; */ public Builder clearUpdateMask() { - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000004); updateMask_ = null; if (updateMaskBuilder_ != null) { updateMaskBuilder_.dispose(); @@ -1255,12 +1559,12 @@ public Builder clearUpdateMask() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1268,17 +1572,17 @@ public Builder clearUpdateMask() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * * .google.protobuf.FieldMask update_mask = 2; */ public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { - bitField0_ |= 0x00000002; + bitField0_ |= 0x00000004; onChanged(); return getUpdateMaskFieldBuilder().getBuilder(); } @@ -1290,12 +1594,12 @@ public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1303,10 +1607,10 @@ public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1329,12 +1633,12 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -1342,10 +1646,10 @@ public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -1375,7 +1679,7 @@ private void ensureAspectKeysIsMutable() { if (!aspectKeys_.isModifiable()) { aspectKeys_ = new com.google.protobuf.LazyStringArrayList(aspectKeys_); } - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; } /** @@ -1398,8 +1702,8 @@ private void ensureAspectKeysIsMutable() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1431,8 +1735,8 @@ public com.google.protobuf.ProtocolStringList getAspectKeysList() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1463,8 +1767,8 @@ public int getAspectKeysCount() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1496,8 +1800,8 @@ public java.lang.String getAspectKeys(int index) { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1529,8 +1833,8 @@ public com.google.protobuf.ByteString getAspectKeysBytes(int index) { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1545,7 +1849,7 @@ public Builder setAspectKeys(int index, java.lang.String value) { } ensureAspectKeysIsMutable(); aspectKeys_.set(index, value); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return this; } @@ -1570,8 +1874,8 @@ public Builder setAspectKeys(int index, java.lang.String value) { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1585,7 +1889,7 @@ public Builder addAspectKeys(java.lang.String value) { } ensureAspectKeysIsMutable(); aspectKeys_.add(value); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return this; } @@ -1610,8 +1914,8 @@ public Builder addAspectKeys(java.lang.String value) { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1622,7 +1926,7 @@ public Builder addAspectKeys(java.lang.String value) { public Builder addAllAspectKeys(java.lang.Iterable values) { ensureAspectKeysIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, aspectKeys_); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return this; } @@ -1647,8 +1951,8 @@ public Builder addAllAspectKeys(java.lang.Iterable values) { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1657,7 +1961,7 @@ public Builder addAllAspectKeys(java.lang.Iterable values) { */ public Builder clearAspectKeys() { aspectKeys_ = com.google.protobuf.LazyStringArrayList.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); + bitField0_ = (bitField0_ & ~0x00000008); ; onChanged(); return this; @@ -1683,8 +1987,8 @@ public Builder clearAspectKeys() { * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -1699,7 +2003,7 @@ public Builder addAspectKeysBytes(com.google.protobuf.ByteString value) { checkByteStringIsUtf8(value); ensureAspectKeysIsMutable(); aspectKeys_.add(value); - bitField0_ |= 0x00000004; + bitField0_ |= 0x00000008; onChanged(); return this; } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItemOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItemOrBuilder.java index 63c192b5f0d9..24276af4fe05 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItemOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ImportItemOrBuilder.java @@ -61,6 +61,49 @@ public interface ImportItemOrBuilder */ com.google.cloud.dataplex.v1.EntryOrBuilder getEntryOrBuilder(); + /** + * + * + *
        +   * Information about the entry link. User should provide either one of the
        +   * entry or entry_link. While providing entry_link, user should not
        +   * provide update_mask and aspect_keys.
        +   * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + * + * @return Whether the entryLink field is set. + */ + boolean hasEntryLink(); + + /** + * + * + *
        +   * Information about the entry link. User should provide either one of the
        +   * entry or entry_link. While providing entry_link, user should not
        +   * provide update_mask and aspect_keys.
        +   * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + * + * @return The entryLink. + */ + com.google.cloud.dataplex.v1.EntryLink getEntryLink(); + + /** + * + * + *
        +   * Information about the entry link. User should provide either one of the
        +   * entry or entry_link. While providing entry_link, user should not
        +   * provide update_mask and aspect_keys.
        +   * 
        + * + * .google.cloud.dataplex.v1.EntryLink entry_link = 4; + */ + com.google.cloud.dataplex.v1.EntryLinkOrBuilder getEntryLinkOrBuilder(); + /** * * @@ -68,12 +111,12 @@ public interface ImportItemOrBuilder * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -81,10 +124,10 @@ public interface ImportItemOrBuilder * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -101,12 +144,12 @@ public interface ImportItemOrBuilder * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -114,10 +157,10 @@ public interface ImportItemOrBuilder * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -134,12 +177,12 @@ public interface ImportItemOrBuilder * The fields to update, in paths that are relative to the `Entry` resource. * Separate each field with a comma. * - * In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - * for an entry that can be modified, including aspects. This means that - * Dataplex replaces the existing entry with the entry in the metadata import - * file. All modifiable fields are updated, regardless of the fields that are - * listed in the update mask, and regardless of whether a field is present - * in the `entry` object. + * In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + * all of the fields for an entry that can be modified, including aspects. + * This means that Dataplex Universal Catalog replaces the existing entry with + * the entry in the metadata import file. All modifiable fields are updated, + * regardless of the fields that are listed in the update mask, and regardless + * of whether a field is present in the `entry` object. * * The `update_mask` field is ignored when an entry is created or re-created. * @@ -147,10 +190,10 @@ public interface ImportItemOrBuilder * value to `aspects`. * * - * Dataplex also determines which entries and aspects to modify by comparing - * the values and timestamps that you provide in the metadata import file with - * the values and timestamps that exist in your project. For more information, - * see [Comparison + * Dataplex Universal Catalog also determines which entries and aspects to + * modify by comparing the values and timestamps that you provide in the + * metadata import file with the values and timestamps that exist in your + * project. For more information, see [Comparison * logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). * * @@ -178,8 +221,8 @@ public interface ImportItemOrBuilder * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -208,8 +251,8 @@ public interface ImportItemOrBuilder * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -238,8 +281,8 @@ public interface ImportItemOrBuilder * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; @@ -269,8 +312,8 @@ public interface ImportItemOrBuilder * * In `FULL` entry sync mode, if you leave this field empty, it is treated as * specifying exactly those aspects that are present within the specified - * entry. Dataplex implicitly adds the keys for all of the required aspects of - * an entry. + * entry. Dataplex Universal Catalog implicitly adds the keys for all of the + * required aspects of an entry. * * * repeated string aspect_keys = 3; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Job.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Job.java index 20e0521c7b44..0dd7e5966b3b 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Job.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Job.java @@ -275,7 +275,7 @@ public enum State implements com.google.protobuf.ProtocolMessageEnum { * * *
        -     * The job was cancelled outside of Dataplex.
        +     * The job was cancelled outside of Dataplex Universal Catalog.
              * 
        * * ABORTED = 6; @@ -354,7 +354,7 @@ public enum State implements com.google.protobuf.ProtocolMessageEnum { * * *
        -     * The job was cancelled outside of Dataplex.
        +     * The job was cancelled outside of Dataplex Universal Catalog.
              * 
        * * ABORTED = 6; @@ -476,8 +476,8 @@ public enum Trigger implements com.google.protobuf.ProtocolMessageEnum { * * *
        -     * The job was triggered by Dataplex based on trigger spec from task
        -     * definition.
        +     * The job was triggered by Dataplex Universal Catalog based on trigger spec
        +     * from task definition.
              * 
        * * TASK_CONFIG = 1; @@ -511,8 +511,8 @@ public enum Trigger implements com.google.protobuf.ProtocolMessageEnum { * * *
        -     * The job was triggered by Dataplex based on trigger spec from task
        -     * definition.
        +     * The job was triggered by Dataplex Universal Catalog based on trigger spec
        +     * from task definition.
              * 
        * * TASK_CONFIG = 1; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/JobEvent.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/JobEvent.java index 6fa11614e83c..018d15b7d140 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/JobEvent.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/JobEvent.java @@ -595,8 +595,8 @@ public enum ExecutionTrigger implements com.google.protobuf.ProtocolMessageEnum * * *
        -     * The job was triggered by Dataplex based on trigger spec from task
        -     * definition.
        +     * The job was triggered by Dataplex Universal Catalog based on trigger spec
        +     * from task definition.
              * 
        * * TASK_CONFIG = 1; @@ -630,8 +630,8 @@ public enum ExecutionTrigger implements com.google.protobuf.ProtocolMessageEnum * * *
        -     * The job was triggered by Dataplex based on trigger spec from task
        -     * definition.
        +     * The job was triggered by Dataplex Universal Catalog based on trigger spec
        +     * from task definition.
              * 
        * * TASK_CONFIG = 1; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequest.java index 95ca79cda86c..3119da11e440 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequest.java @@ -78,7 +78,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -107,7 +107,7 @@ public java.lang.String getParent() { * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -717,7 +717,7 @@ public Builder mergeFrom( * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -745,7 +745,7 @@ public java.lang.String getParent() { * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -773,7 +773,7 @@ public com.google.protobuf.ByteString getParentBytes() { * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -800,7 +800,7 @@ public Builder setParent(java.lang.String value) { * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -823,7 +823,7 @@ public Builder clearParent() { * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequestOrBuilder.java index feebeff5e1e4..ff38c6b8080c 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScanJobsRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface ListDataScanJobsRequestOrBuilder * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface ListDataScanJobsRequestOrBuilder * Required. The resource name of the parent environment: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequest.java index 1e7edf0f0cc4..7c9026deae2d 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequest.java @@ -79,7 +79,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -108,7 +108,7 @@ public java.lang.String getParent() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -764,7 +764,7 @@ public Builder mergeFrom( * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -792,7 +792,7 @@ public java.lang.String getParent() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -820,7 +820,7 @@ public com.google.protobuf.ByteString getParentBytes() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -847,7 +847,7 @@ public Builder setParent(java.lang.String value) { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -870,7 +870,7 @@ public Builder clearParent() { * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequestOrBuilder.java index 2f007560a3ae..e36f0a7f3ca4 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataScansRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface ListDataScansRequestOrBuilder * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * @@ -49,7 +49,7 @@ public interface ListDataScansRequestOrBuilder * Required. The resource name of the parent location: * `projects/{project}/locations/{location_id}` * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequest.java index 491ac2ed2fc5..1c7b45d98940 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequest.java @@ -78,7 +78,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
            * Required. The resource name of the DataTaxonomy location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -106,7 +106,7 @@ public java.lang.String getParent() { *
            * Required. The resource name of the DataTaxonomy location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -761,7 +761,7 @@ public Builder mergeFrom( *
              * Required. The resource name of the DataTaxonomy location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -788,7 +788,7 @@ public java.lang.String getParent() { *
              * Required. The resource name of the DataTaxonomy location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -815,7 +815,7 @@ public com.google.protobuf.ByteString getParentBytes() { *
              * Required. The resource name of the DataTaxonomy location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -841,7 +841,7 @@ public Builder setParent(java.lang.String value) { *
              * Required. The resource name of the DataTaxonomy location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -863,7 +863,7 @@ public Builder clearParent() { *
              * Required. The resource name of the DataTaxonomy location, of the form:
              * projects/{project_number}/locations/{location_id}
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequestOrBuilder.java index ec73c5b4fce5..161b28bcaedf 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListDataTaxonomiesRequestOrBuilder.java @@ -30,7 +30,7 @@ public interface ListDataTaxonomiesRequestOrBuilder *
            * Required. The resource name of the DataTaxonomy location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -47,7 +47,7 @@ public interface ListDataTaxonomiesRequestOrBuilder *
            * Required. The resource name of the DataTaxonomy location, of the form:
            * projects/{project_number}/locations/{location_id}
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesRequest.java new file mode 100644 index 000000000000..c5cf8ba263f6 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesRequest.java @@ -0,0 +1,1408 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * List Glossaries Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossariesRequest} + */ +public final class ListGlossariesRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.ListGlossariesRequest) + ListGlossariesRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ListGlossariesRequest.newBuilder() to construct. + private ListGlossariesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListGlossariesRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListGlossariesRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossariesRequest.class, + com.google.cloud.dataplex.v1.ListGlossariesRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
        +   * Required. The parent, which has this collection of Glossaries.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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, which has this collection of Glossaries.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 Glossaries to return. The service may
        +   * return fewer than this value. If unspecified, at most 50 Glossaries 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 page token, received from a previous `ListGlossaries` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaries` 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 `ListGlossaries` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaries` 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_ = ""; + + /** + * + * + *
        +   * Optional. Filter expression that filters Glossaries listed in the response.
        +   * Filters on proto fields of Glossary are supported.
        +   * Examples of using a filter are:
        +   *   - `display_name="my-glossary"`
        +   *   - `categoryCount=1`
        +   *   - `termCount=0`
        +   * 
        + * + * 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 that filters Glossaries listed in the response.
        +   * Filters on proto fields of Glossary are supported.
        +   * Examples of using a filter are:
        +   *   - `display_name="my-glossary"`
        +   *   - `categoryCount=1`
        +   *   - `termCount=0`
        +   * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossariesRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.ListGlossariesRequest other = + (com.google.cloud.dataplex.v1.ListGlossariesRequest) 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.dataplex.v1.ListGlossariesRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest 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.dataplex.v1.ListGlossariesRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest 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.dataplex.v1.ListGlossariesRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossariesRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * List Glossaries Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossariesRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.ListGlossariesRequest) + com.google.cloud.dataplex.v1.ListGlossariesRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossariesRequest.class, + com.google.cloud.dataplex.v1.ListGlossariesRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.ListGlossariesRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossariesRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.ListGlossariesRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossariesRequest build() { + com.google.cloud.dataplex.v1.ListGlossariesRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossariesRequest buildPartial() { + com.google.cloud.dataplex.v1.ListGlossariesRequest result = + new com.google.cloud.dataplex.v1.ListGlossariesRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.ListGlossariesRequest 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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.ListGlossariesRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.ListGlossariesRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.ListGlossariesRequest other) { + if (other == com.google.cloud.dataplex.v1.ListGlossariesRequest.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, which has this collection of Glossaries.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of Glossaries.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of Glossaries.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of Glossaries.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of Glossaries.
        +     * Format: projects/{project_id_or_number}/locations/{location_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 Glossaries to return. The service may
        +     * return fewer than this value. If unspecified, at most 50 Glossaries 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. The maximum number of Glossaries to return. The service may
        +     * return fewer than this value. If unspecified, at most 50 Glossaries 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. The maximum number of Glossaries to return. The service may
        +     * return fewer than this value. If unspecified, at most 50 Glossaries 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 page token, received from a previous `ListGlossaries` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaries` 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 `ListGlossaries` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaries` 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 `ListGlossaries` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaries` 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 `ListGlossaries` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaries` 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 `ListGlossaries` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaries` 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_ = ""; + + /** + * + * + *
        +     * Optional. Filter expression that filters Glossaries listed in the response.
        +     * Filters on proto fields of Glossary are supported.
        +     * Examples of using a filter are:
        +     *   - `display_name="my-glossary"`
        +     *   - `categoryCount=1`
        +     *   - `termCount=0`
        +     * 
        + * + * 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 that filters Glossaries listed in the response.
        +     * Filters on proto fields of Glossary are supported.
        +     * Examples of using a filter are:
        +     *   - `display_name="my-glossary"`
        +     *   - `categoryCount=1`
        +     *   - `termCount=0`
        +     * 
        + * + * 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 that filters Glossaries listed in the response.
        +     * Filters on proto fields of Glossary are supported.
        +     * Examples of using a filter are:
        +     *   - `display_name="my-glossary"`
        +     *   - `categoryCount=1`
        +     *   - `termCount=0`
        +     * 
        + * + * 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 that filters Glossaries listed in the response.
        +     * Filters on proto fields of Glossary are supported.
        +     * Examples of using a filter are:
        +     *   - `display_name="my-glossary"`
        +     *   - `categoryCount=1`
        +     *   - `termCount=0`
        +     * 
        + * + * 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 that filters Glossaries listed in the response.
        +     * Filters on proto fields of Glossary are supported.
        +     * Examples of using a filter are:
        +     *   - `display_name="my-glossary"`
        +     *   - `categoryCount=1`
        +     *   - `termCount=0`
        +     * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders Glossaries listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.ListGlossariesRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.ListGlossariesRequest) + private static final com.google.cloud.dataplex.v1.ListGlossariesRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.ListGlossariesRequest(); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGlossariesRequest 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.dataplex.v1.ListGlossariesRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesRequestOrBuilder.java new file mode 100644 index 000000000000..1c350fa0c310 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesRequestOrBuilder.java @@ -0,0 +1,174 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface ListGlossariesRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.ListGlossariesRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The parent, which has this collection of Glossaries.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
        +   * Required. The parent, which has this collection of Glossaries.
        +   * Format: projects/{project_id_or_number}/locations/{location_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 Glossaries to return. The service may
        +   * return fewer than this value. If unspecified, at most 50 Glossaries 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 page token, received from a previous `ListGlossaries` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaries` 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 `ListGlossaries` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaries` 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(); + + /** + * + * + *
        +   * Optional. Filter expression that filters Glossaries listed in the response.
        +   * Filters on proto fields of Glossary are supported.
        +   * Examples of using a filter are:
        +   *   - `display_name="my-glossary"`
        +   *   - `categoryCount=1`
        +   *   - `termCount=0`
        +   * 
        + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
        +   * Optional. Filter expression that filters Glossaries listed in the response.
        +   * Filters on proto fields of Glossary are supported.
        +   * Examples of using a filter are:
        +   *   - `display_name="my-glossary"`
        +   *   - `categoryCount=1`
        +   *   - `termCount=0`
        +   * 
        + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
        +   * Optional. Order by expression that orders Glossaries listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
        +   * Optional. Order by expression that orders Glossaries listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesResponse.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesResponse.java new file mode 100644 index 000000000000..3971b7849495 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesResponse.java @@ -0,0 +1,1447 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * List Glossaries Response
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossariesResponse} + */ +public final class ListGlossariesResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.ListGlossariesResponse) + ListGlossariesResponseOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ListGlossariesResponse.newBuilder() to construct. + private ListGlossariesResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListGlossariesResponse() { + glossaries_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListGlossariesResponse(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossariesResponse.class, + com.google.cloud.dataplex.v1.ListGlossariesResponse.Builder.class); + } + + public static final int GLOSSARIES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List glossaries_; + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + @java.lang.Override + public java.util.List getGlossariesList() { + return glossaries_; + } + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + @java.lang.Override + public java.util.List + getGlossariesOrBuilderList() { + return glossaries_; + } + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + @java.lang.Override + public int getGlossariesCount() { + return glossaries_.size(); + } + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.Glossary getGlossaries(int index) { + return glossaries_.get(index); + } + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossariesOrBuilder(int index) { + return glossaries_.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 UNREACHABLE_LOCATIONS_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachableLocations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + public com.google.protobuf.ProtocolStringList getUnreachableLocationsList() { + return unreachableLocations_; + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + public int getUnreachableLocationsCount() { + return unreachableLocations_.size(); + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + public java.lang.String getUnreachableLocations(int index) { + return unreachableLocations_.get(index); + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + public com.google.protobuf.ByteString getUnreachableLocationsBytes(int index) { + return unreachableLocations_.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 < glossaries_.size(); i++) { + output.writeMessage(1, glossaries_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachableLocations_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString( + output, 3, unreachableLocations_.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 < glossaries_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, glossaries_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachableLocations_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachableLocations_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableLocationsList().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.dataplex.v1.ListGlossariesResponse)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.ListGlossariesResponse other = + (com.google.cloud.dataplex.v1.ListGlossariesResponse) obj; + + if (!getGlossariesList().equals(other.getGlossariesList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableLocationsList().equals(other.getUnreachableLocationsList())) 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 (getGlossariesCount() > 0) { + hash = (37 * hash) + GLOSSARIES_FIELD_NUMBER; + hash = (53 * hash) + getGlossariesList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableLocationsCount() > 0) { + hash = (37 * hash) + UNREACHABLE_LOCATIONS_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableLocationsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse 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.dataplex.v1.ListGlossariesResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse 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.dataplex.v1.ListGlossariesResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossariesResponse 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * List Glossaries Response
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossariesResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.ListGlossariesResponse) + com.google.cloud.dataplex.v1.ListGlossariesResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossariesResponse.class, + com.google.cloud.dataplex.v1.ListGlossariesResponse.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.ListGlossariesResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (glossariesBuilder_ == null) { + glossaries_ = java.util.Collections.emptyList(); + } else { + glossaries_ = null; + glossariesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossariesResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossariesResponse getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.ListGlossariesResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossariesResponse build() { + com.google.cloud.dataplex.v1.ListGlossariesResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossariesResponse buildPartial() { + com.google.cloud.dataplex.v1.ListGlossariesResponse result = + new com.google.cloud.dataplex.v1.ListGlossariesResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.dataplex.v1.ListGlossariesResponse result) { + if (glossariesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + glossaries_ = java.util.Collections.unmodifiableList(glossaries_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.glossaries_ = glossaries_; + } else { + result.glossaries_ = glossariesBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.dataplex.v1.ListGlossariesResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachableLocations_.makeImmutable(); + result.unreachableLocations_ = unreachableLocations_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.ListGlossariesResponse) { + return mergeFrom((com.google.cloud.dataplex.v1.ListGlossariesResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.ListGlossariesResponse other) { + if (other == com.google.cloud.dataplex.v1.ListGlossariesResponse.getDefaultInstance()) + return this; + if (glossariesBuilder_ == null) { + if (!other.glossaries_.isEmpty()) { + if (glossaries_.isEmpty()) { + glossaries_ = other.glossaries_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureGlossariesIsMutable(); + glossaries_.addAll(other.glossaries_); + } + onChanged(); + } + } else { + if (!other.glossaries_.isEmpty()) { + if (glossariesBuilder_.isEmpty()) { + glossariesBuilder_.dispose(); + glossariesBuilder_ = null; + glossaries_ = other.glossaries_; + bitField0_ = (bitField0_ & ~0x00000001); + glossariesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getGlossariesFieldBuilder() + : null; + } else { + glossariesBuilder_.addAllMessages(other.glossaries_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachableLocations_.isEmpty()) { + if (unreachableLocations_.isEmpty()) { + unreachableLocations_ = other.unreachableLocations_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.addAll(other.unreachableLocations_); + } + 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.dataplex.v1.Glossary m = + input.readMessage( + com.google.cloud.dataplex.v1.Glossary.parser(), extensionRegistry); + if (glossariesBuilder_ == null) { + ensureGlossariesIsMutable(); + glossaries_.add(m); + } else { + glossariesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.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 glossaries_ = + java.util.Collections.emptyList(); + + private void ensureGlossariesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + glossaries_ = new java.util.ArrayList(glossaries_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder> + glossariesBuilder_; + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public java.util.List getGlossariesList() { + if (glossariesBuilder_ == null) { + return java.util.Collections.unmodifiableList(glossaries_); + } else { + return glossariesBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public int getGlossariesCount() { + if (glossariesBuilder_ == null) { + return glossaries_.size(); + } else { + return glossariesBuilder_.getCount(); + } + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public com.google.cloud.dataplex.v1.Glossary getGlossaries(int index) { + if (glossariesBuilder_ == null) { + return glossaries_.get(index); + } else { + return glossariesBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder setGlossaries(int index, com.google.cloud.dataplex.v1.Glossary value) { + if (glossariesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGlossariesIsMutable(); + glossaries_.set(index, value); + onChanged(); + } else { + glossariesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder setGlossaries( + int index, com.google.cloud.dataplex.v1.Glossary.Builder builderForValue) { + if (glossariesBuilder_ == null) { + ensureGlossariesIsMutable(); + glossaries_.set(index, builderForValue.build()); + onChanged(); + } else { + glossariesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder addGlossaries(com.google.cloud.dataplex.v1.Glossary value) { + if (glossariesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGlossariesIsMutable(); + glossaries_.add(value); + onChanged(); + } else { + glossariesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder addGlossaries(int index, com.google.cloud.dataplex.v1.Glossary value) { + if (glossariesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureGlossariesIsMutable(); + glossaries_.add(index, value); + onChanged(); + } else { + glossariesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder addGlossaries(com.google.cloud.dataplex.v1.Glossary.Builder builderForValue) { + if (glossariesBuilder_ == null) { + ensureGlossariesIsMutable(); + glossaries_.add(builderForValue.build()); + onChanged(); + } else { + glossariesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder addGlossaries( + int index, com.google.cloud.dataplex.v1.Glossary.Builder builderForValue) { + if (glossariesBuilder_ == null) { + ensureGlossariesIsMutable(); + glossaries_.add(index, builderForValue.build()); + onChanged(); + } else { + glossariesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder addAllGlossaries( + java.lang.Iterable values) { + if (glossariesBuilder_ == null) { + ensureGlossariesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, glossaries_); + onChanged(); + } else { + glossariesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder clearGlossaries() { + if (glossariesBuilder_ == null) { + glossaries_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + glossariesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public Builder removeGlossaries(int index) { + if (glossariesBuilder_ == null) { + ensureGlossariesIsMutable(); + glossaries_.remove(index); + onChanged(); + } else { + glossariesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public com.google.cloud.dataplex.v1.Glossary.Builder getGlossariesBuilder(int index) { + return getGlossariesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossariesOrBuilder(int index) { + if (glossariesBuilder_ == null) { + return glossaries_.get(index); + } else { + return glossariesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public java.util.List + getGlossariesOrBuilderList() { + if (glossariesBuilder_ != null) { + return glossariesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(glossaries_); + } + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public com.google.cloud.dataplex.v1.Glossary.Builder addGlossariesBuilder() { + return getGlossariesFieldBuilder() + .addBuilder(com.google.cloud.dataplex.v1.Glossary.getDefaultInstance()); + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public com.google.cloud.dataplex.v1.Glossary.Builder addGlossariesBuilder(int index) { + return getGlossariesFieldBuilder() + .addBuilder(index, com.google.cloud.dataplex.v1.Glossary.getDefaultInstance()); + } + + /** + * + * + *
        +     * Lists the Glossaries in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + public java.util.List + getGlossariesBuilderList() { + return getGlossariesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder> + getGlossariesFieldBuilder() { + if (glossariesBuilder_ == null) { + glossariesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder>( + glossaries_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + glossaries_ = null; + } + return glossariesBuilder_; + } + + 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 com.google.protobuf.LazyStringArrayList unreachableLocations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableLocationsIsMutable() { + if (!unreachableLocations_.isModifiable()) { + unreachableLocations_ = new com.google.protobuf.LazyStringArrayList(unreachableLocations_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + public com.google.protobuf.ProtocolStringList getUnreachableLocationsList() { + unreachableLocations_.makeImmutable(); + return unreachableLocations_; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + public int getUnreachableLocationsCount() { + return unreachableLocations_.size(); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + public java.lang.String getUnreachableLocations(int index) { + return unreachableLocations_.get(index); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + public com.google.protobuf.ByteString getUnreachableLocationsBytes(int index) { + return unreachableLocations_.getByteString(index); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index to set the value at. + * @param value The unreachableLocations to set. + * @return This builder for chaining. + */ + public Builder setUnreachableLocations(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param value The unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addUnreachableLocations(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param values The unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachableLocations(java.lang.Iterable values) { + ensureUnreachableLocationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachableLocations_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachableLocations() { + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param value The bytes of the unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addUnreachableLocationsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.ListGlossariesResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.ListGlossariesResponse) + private static final com.google.cloud.dataplex.v1.ListGlossariesResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.ListGlossariesResponse(); + } + + public static com.google.cloud.dataplex.v1.ListGlossariesResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGlossariesResponse 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.dataplex.v1.ListGlossariesResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesResponseOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesResponseOrBuilder.java new file mode 100644 index 000000000000..088e6b5c1de4 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossariesResponseOrBuilder.java @@ -0,0 +1,164 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface ListGlossariesResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.ListGlossariesResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + java.util.List getGlossariesList(); + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + com.google.cloud.dataplex.v1.Glossary getGlossaries(int index); + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + int getGlossariesCount(); + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + java.util.List + getGlossariesOrBuilderList(); + + /** + * + * + *
        +   * Lists the Glossaries in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.Glossary glossaries = 1; + */ + com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossariesOrBuilder(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(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + java.util.List getUnreachableLocationsList(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + int getUnreachableLocationsCount(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + java.lang.String getUnreachableLocations(int index); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + com.google.protobuf.ByteString getUnreachableLocationsBytes(int index); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesRequest.java new file mode 100644 index 000000000000..e9ef77eba3b9 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesRequest.java @@ -0,0 +1,1458 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * List GlossaryCategories Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryCategoriesRequest} + */ +public final class ListGlossaryCategoriesRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) + ListGlossaryCategoriesRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ListGlossaryCategoriesRequest.newBuilder() to construct. + private ListGlossaryCategoriesRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListGlossaryCategoriesRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListGlossaryCategoriesRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.class, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
        +   * Required. The parent, which has this collection of GlossaryCategories.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * Location is the Google Cloud region.
        +   * 
        + * + * + * 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, which has this collection of GlossaryCategories.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * Location is the Google Cloud region.
        +   * 
        + * + * + * 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 GlossaryCategories to return. The service
        +   * may return fewer than this value. If unspecified, at most 50
        +   * GlossaryCategories 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 page token, received from a previous `ListGlossaryCategories`
        +   * call. Provide this to retrieve the subsequent page. When paginating, all
        +   * other parameters provided to `ListGlossaryCategories` 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 `ListGlossaryCategories`
        +   * call. Provide this to retrieve the subsequent page. When paginating, all
        +   * other parameters provided to `ListGlossaryCategories` 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_ = ""; + + /** + * + * + *
        +   * Optional. Filter expression that filters GlossaryCategories listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryCategories that are directly nested
        +   * under the specified parent.
        +   * 
        + * + * 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 that filters GlossaryCategories listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryCategories that are directly nested
        +   * under the specified parent.
        +   * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossaryCategoriesRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest other = + (com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) 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.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest 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.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest 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.dataplex.v1.ListGlossaryCategoriesRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossaryCategoriesRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * List GlossaryCategories Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryCategoriesRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.class, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest build() { + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest buildPartial() { + com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest result = + new com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest 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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest other) { + if (other == com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest.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, which has this collection of GlossaryCategories.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * Location is the Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryCategories.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * Location is the Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryCategories.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * Location is the Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryCategories.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * Location is the Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryCategories.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * Location is the Google Cloud region.
        +     * 
        + * + * + * 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 GlossaryCategories to return. The service
        +     * may return fewer than this value. If unspecified, at most 50
        +     * GlossaryCategories 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. The maximum number of GlossaryCategories to return. The service
        +     * may return fewer than this value. If unspecified, at most 50
        +     * GlossaryCategories 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. The maximum number of GlossaryCategories to return. The service
        +     * may return fewer than this value. If unspecified, at most 50
        +     * GlossaryCategories 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 page token, received from a previous `ListGlossaryCategories`
        +     * call. Provide this to retrieve the subsequent page. When paginating, all
        +     * other parameters provided to `ListGlossaryCategories` 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 `ListGlossaryCategories`
        +     * call. Provide this to retrieve the subsequent page. When paginating, all
        +     * other parameters provided to `ListGlossaryCategories` 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 `ListGlossaryCategories`
        +     * call. Provide this to retrieve the subsequent page. When paginating, all
        +     * other parameters provided to `ListGlossaryCategories` 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 `ListGlossaryCategories`
        +     * call. Provide this to retrieve the subsequent page. When paginating, all
        +     * other parameters provided to `ListGlossaryCategories` 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 `ListGlossaryCategories`
        +     * call. Provide this to retrieve the subsequent page. When paginating, all
        +     * other parameters provided to `ListGlossaryCategories` 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_ = ""; + + /** + * + * + *
        +     * Optional. Filter expression that filters GlossaryCategories listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryCategories that are directly nested
        +     * under the specified parent.
        +     * 
        + * + * 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 that filters GlossaryCategories listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryCategories that are directly nested
        +     * under the specified parent.
        +     * 
        + * + * 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 that filters GlossaryCategories listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryCategories that are directly nested
        +     * under the specified parent.
        +     * 
        + * + * 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 that filters GlossaryCategories listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryCategories that are directly nested
        +     * under the specified parent.
        +     * 
        + * + * 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 that filters GlossaryCategories listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryCategories that are directly nested
        +     * under the specified parent.
        +     * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryCategories listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) + private static final com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest(); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGlossaryCategoriesRequest 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.dataplex.v1.ListGlossaryCategoriesRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesRequestOrBuilder.java new file mode 100644 index 000000000000..7bf1235a0e9a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesRequestOrBuilder.java @@ -0,0 +1,188 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface ListGlossaryCategoriesRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.ListGlossaryCategoriesRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The parent, which has this collection of GlossaryCategories.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * Location is the Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
        +   * Required. The parent, which has this collection of GlossaryCategories.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * Location is the Google Cloud region.
        +   * 
        + * + * + * 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 GlossaryCategories to return. The service
        +   * may return fewer than this value. If unspecified, at most 50
        +   * GlossaryCategories 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 page token, received from a previous `ListGlossaryCategories`
        +   * call. Provide this to retrieve the subsequent page. When paginating, all
        +   * other parameters provided to `ListGlossaryCategories` 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 `ListGlossaryCategories`
        +   * call. Provide this to retrieve the subsequent page. When paginating, all
        +   * other parameters provided to `ListGlossaryCategories` 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(); + + /** + * + * + *
        +   * Optional. Filter expression that filters GlossaryCategories listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryCategories that are directly nested
        +   * under the specified parent.
        +   * 
        + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
        +   * Optional. Filter expression that filters GlossaryCategories listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryCategories that are directly nested
        +   * under the specified parent.
        +   * 
        + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
        +   * Optional. Order by expression that orders GlossaryCategories listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
        +   * Optional. Order by expression that orders GlossaryCategories listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesResponse.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesResponse.java new file mode 100644 index 000000000000..0287155d30f3 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesResponse.java @@ -0,0 +1,1452 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * List GlossaryCategories Response
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryCategoriesResponse} + */ +public final class ListGlossaryCategoriesResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) + ListGlossaryCategoriesResponseOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ListGlossaryCategoriesResponse.newBuilder() to construct. + private ListGlossaryCategoriesResponse( + com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListGlossaryCategoriesResponse() { + categories_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListGlossaryCategoriesResponse(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.class, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.Builder.class); + } + + public static final int CATEGORIES_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List categories_; + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + @java.lang.Override + public java.util.List getCategoriesList() { + return categories_; + } + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + @java.lang.Override + public java.util.List + getCategoriesOrBuilderList() { + return categories_; + } + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + @java.lang.Override + public int getCategoriesCount() { + return categories_.size(); + } + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategory getCategories(int index) { + return categories_.get(index); + } + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoriesOrBuilder(int index) { + return categories_.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 UNREACHABLE_LOCATIONS_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachableLocations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + public com.google.protobuf.ProtocolStringList getUnreachableLocationsList() { + return unreachableLocations_; + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + public int getUnreachableLocationsCount() { + return unreachableLocations_.size(); + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + public java.lang.String getUnreachableLocations(int index) { + return unreachableLocations_.get(index); + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + public com.google.protobuf.ByteString getUnreachableLocationsBytes(int index) { + return unreachableLocations_.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 < categories_.size(); i++) { + output.writeMessage(1, categories_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachableLocations_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString( + output, 3, unreachableLocations_.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 < categories_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, categories_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachableLocations_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachableLocations_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableLocationsList().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.dataplex.v1.ListGlossaryCategoriesResponse)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse other = + (com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) obj; + + if (!getCategoriesList().equals(other.getCategoriesList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableLocationsList().equals(other.getUnreachableLocationsList())) 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 (getCategoriesCount() > 0) { + hash = (37 * hash) + CATEGORIES_FIELD_NUMBER; + hash = (53 * hash) + getCategoriesList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableLocationsCount() > 0) { + hash = (37 * hash) + UNREACHABLE_LOCATIONS_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableLocationsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse 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.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse 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.dataplex.v1.ListGlossaryCategoriesResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossaryCategoriesResponse 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * List GlossaryCategories Response
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryCategoriesResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.class, + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (categoriesBuilder_ == null) { + categories_ = java.util.Collections.emptyList(); + } else { + categories_ = null; + categoriesBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryCategoriesResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse build() { + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse buildPartial() { + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse result = + new com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse result) { + if (categoriesBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + categories_ = java.util.Collections.unmodifiableList(categories_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.categories_ = categories_; + } else { + result.categories_ = categoriesBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachableLocations_.makeImmutable(); + result.unreachableLocations_ = unreachableLocations_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) { + return mergeFrom((com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse other) { + if (other == com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse.getDefaultInstance()) + return this; + if (categoriesBuilder_ == null) { + if (!other.categories_.isEmpty()) { + if (categories_.isEmpty()) { + categories_ = other.categories_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureCategoriesIsMutable(); + categories_.addAll(other.categories_); + } + onChanged(); + } + } else { + if (!other.categories_.isEmpty()) { + if (categoriesBuilder_.isEmpty()) { + categoriesBuilder_.dispose(); + categoriesBuilder_ = null; + categories_ = other.categories_; + bitField0_ = (bitField0_ & ~0x00000001); + categoriesBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getCategoriesFieldBuilder() + : null; + } else { + categoriesBuilder_.addAllMessages(other.categories_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachableLocations_.isEmpty()) { + if (unreachableLocations_.isEmpty()) { + unreachableLocations_ = other.unreachableLocations_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.addAll(other.unreachableLocations_); + } + 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.dataplex.v1.GlossaryCategory m = + input.readMessage( + com.google.cloud.dataplex.v1.GlossaryCategory.parser(), extensionRegistry); + if (categoriesBuilder_ == null) { + ensureCategoriesIsMutable(); + categories_.add(m); + } else { + categoriesBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.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 categories_ = + java.util.Collections.emptyList(); + + private void ensureCategoriesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + categories_ = + new java.util.ArrayList(categories_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder> + categoriesBuilder_; + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public java.util.List getCategoriesList() { + if (categoriesBuilder_ == null) { + return java.util.Collections.unmodifiableList(categories_); + } else { + return categoriesBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public int getCategoriesCount() { + if (categoriesBuilder_ == null) { + return categories_.size(); + } else { + return categoriesBuilder_.getCount(); + } + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryCategory getCategories(int index) { + if (categoriesBuilder_ == null) { + return categories_.get(index); + } else { + return categoriesBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder setCategories(int index, com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoriesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCategoriesIsMutable(); + categories_.set(index, value); + onChanged(); + } else { + categoriesBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder setCategories( + int index, com.google.cloud.dataplex.v1.GlossaryCategory.Builder builderForValue) { + if (categoriesBuilder_ == null) { + ensureCategoriesIsMutable(); + categories_.set(index, builderForValue.build()); + onChanged(); + } else { + categoriesBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder addCategories(com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoriesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCategoriesIsMutable(); + categories_.add(value); + onChanged(); + } else { + categoriesBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder addCategories(int index, com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoriesBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCategoriesIsMutable(); + categories_.add(index, value); + onChanged(); + } else { + categoriesBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder addCategories( + com.google.cloud.dataplex.v1.GlossaryCategory.Builder builderForValue) { + if (categoriesBuilder_ == null) { + ensureCategoriesIsMutable(); + categories_.add(builderForValue.build()); + onChanged(); + } else { + categoriesBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder addCategories( + int index, com.google.cloud.dataplex.v1.GlossaryCategory.Builder builderForValue) { + if (categoriesBuilder_ == null) { + ensureCategoriesIsMutable(); + categories_.add(index, builderForValue.build()); + onChanged(); + } else { + categoriesBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder addAllCategories( + java.lang.Iterable values) { + if (categoriesBuilder_ == null) { + ensureCategoriesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, categories_); + onChanged(); + } else { + categoriesBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder clearCategories() { + if (categoriesBuilder_ == null) { + categories_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + categoriesBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public Builder removeCategories(int index) { + if (categoriesBuilder_ == null) { + ensureCategoriesIsMutable(); + categories_.remove(index); + onChanged(); + } else { + categoriesBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryCategory.Builder getCategoriesBuilder(int index) { + return getCategoriesFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoriesOrBuilder( + int index) { + if (categoriesBuilder_ == null) { + return categories_.get(index); + } else { + return categoriesBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public java.util.List + getCategoriesOrBuilderList() { + if (categoriesBuilder_ != null) { + return categoriesBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(categories_); + } + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryCategory.Builder addCategoriesBuilder() { + return getCategoriesFieldBuilder() + .addBuilder(com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance()); + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryCategory.Builder addCategoriesBuilder(int index) { + return getCategoriesFieldBuilder() + .addBuilder(index, com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance()); + } + + /** + * + * + *
        +     * Lists the GlossaryCategories in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + public java.util.List + getCategoriesBuilderList() { + return getCategoriesFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder> + getCategoriesFieldBuilder() { + if (categoriesBuilder_ == null) { + categoriesBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder>( + categories_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + categories_ = null; + } + return categoriesBuilder_; + } + + 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 com.google.protobuf.LazyStringArrayList unreachableLocations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableLocationsIsMutable() { + if (!unreachableLocations_.isModifiable()) { + unreachableLocations_ = new com.google.protobuf.LazyStringArrayList(unreachableLocations_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + public com.google.protobuf.ProtocolStringList getUnreachableLocationsList() { + unreachableLocations_.makeImmutable(); + return unreachableLocations_; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + public int getUnreachableLocationsCount() { + return unreachableLocations_.size(); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + public java.lang.String getUnreachableLocations(int index) { + return unreachableLocations_.get(index); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + public com.google.protobuf.ByteString getUnreachableLocationsBytes(int index) { + return unreachableLocations_.getByteString(index); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index to set the value at. + * @param value The unreachableLocations to set. + * @return This builder for chaining. + */ + public Builder setUnreachableLocations(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param value The unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addUnreachableLocations(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param values The unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachableLocations(java.lang.Iterable values) { + ensureUnreachableLocationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachableLocations_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachableLocations() { + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param value The bytes of the unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addUnreachableLocationsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) + private static final com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse(); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGlossaryCategoriesResponse 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.dataplex.v1.ListGlossaryCategoriesResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesResponseOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesResponseOrBuilder.java new file mode 100644 index 000000000000..dc339e26ee8a --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryCategoriesResponseOrBuilder.java @@ -0,0 +1,164 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface ListGlossaryCategoriesResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.ListGlossaryCategoriesResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + java.util.List getCategoriesList(); + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + com.google.cloud.dataplex.v1.GlossaryCategory getCategories(int index); + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + int getCategoriesCount(); + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + java.util.List + getCategoriesOrBuilderList(); + + /** + * + * + *
        +   * Lists the GlossaryCategories in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryCategory categories = 1; + */ + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoriesOrBuilder(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(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + java.util.List getUnreachableLocationsList(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + int getUnreachableLocationsCount(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + java.lang.String getUnreachableLocations(int index); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + com.google.protobuf.ByteString getUnreachableLocationsBytes(int index); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsRequest.java new file mode 100644 index 000000000000..c7472fe84b8b --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsRequest.java @@ -0,0 +1,1458 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * List GlossaryTerms Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryTermsRequest} + */ +public final class ListGlossaryTermsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.ListGlossaryTermsRequest) + ListGlossaryTermsRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ListGlossaryTermsRequest.newBuilder() to construct. + private ListGlossaryTermsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListGlossaryTermsRequest() { + parent_ = ""; + pageToken_ = ""; + filter_ = ""; + orderBy_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListGlossaryTermsRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.class, + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object parent_ = ""; + + /** + * + * + *
        +   * Required. The parent, which has this collection of GlossaryTerms.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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, which has this collection of GlossaryTerms.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 GlossaryTerms to return. The service may
        +   * return fewer than this value. If unspecified, at most 50 GlossaryTerms 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 page token, received from a previous `ListGlossaryTerms` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaryTerms` 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 `ListGlossaryTerms` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaryTerms` 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_ = ""; + + /** + * + * + *
        +   * Optional. Filter expression that filters GlossaryTerms listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryTerms that are directly nested under the
        +   * specified parent.
        +   * 
        + * + * 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 that filters GlossaryTerms listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryTerms that are directly nested under the
        +   * specified parent.
        +   * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * 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.GeneratedMessageV3.isStringEmpty(parent_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, filter_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + com.google.protobuf.GeneratedMessageV3.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.GeneratedMessageV3.isStringEmpty(parent_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, filter_); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(orderBy_)) { + size += com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossaryTermsRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest other = + (com.google.cloud.dataplex.v1.ListGlossaryTermsRequest) 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.dataplex.v1.ListGlossaryTermsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest 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.dataplex.v1.ListGlossaryTermsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest 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.dataplex.v1.ListGlossaryTermsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossaryTermsRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * List GlossaryTerms Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryTermsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.ListGlossaryTermsRequest) + com.google.cloud.dataplex.v1.ListGlossaryTermsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.class, + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryTermsRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryTermsRequest build() { + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryTermsRequest buildPartial() { + com.google.cloud.dataplex.v1.ListGlossaryTermsRequest result = + new com.google.cloud.dataplex.v1.ListGlossaryTermsRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.ListGlossaryTermsRequest 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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.ListGlossaryTermsRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.ListGlossaryTermsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.ListGlossaryTermsRequest other) { + if (other == com.google.cloud.dataplex.v1.ListGlossaryTermsRequest.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, which has this collection of GlossaryTerms.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryTerms.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryTerms.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryTerms.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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, which has this collection of GlossaryTerms.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * where `location_id` refers to a Google Cloud region.
        +     * 
        + * + * + * 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 GlossaryTerms to return. The service may
        +     * return fewer than this value. If unspecified, at most 50 GlossaryTerms 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. The maximum number of GlossaryTerms to return. The service may
        +     * return fewer than this value. If unspecified, at most 50 GlossaryTerms 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. The maximum number of GlossaryTerms to return. The service may
        +     * return fewer than this value. If unspecified, at most 50 GlossaryTerms 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 page token, received from a previous `ListGlossaryTerms` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaryTerms` 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 `ListGlossaryTerms` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaryTerms` 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 `ListGlossaryTerms` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaryTerms` 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 `ListGlossaryTerms` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaryTerms` 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 `ListGlossaryTerms` call.
        +     * Provide this to retrieve the subsequent page.
        +     * When paginating, all other parameters provided to `ListGlossaryTerms` 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_ = ""; + + /** + * + * + *
        +     * Optional. Filter expression that filters GlossaryTerms listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryTerms that are directly nested under the
        +     * specified parent.
        +     * 
        + * + * 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 that filters GlossaryTerms listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryTerms that are directly nested under the
        +     * specified parent.
        +     * 
        + * + * 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 that filters GlossaryTerms listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryTerms that are directly nested under the
        +     * specified parent.
        +     * 
        + * + * 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 that filters GlossaryTerms listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryTerms that are directly nested under the
        +     * specified parent.
        +     * 
        + * + * 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 that filters GlossaryTerms listed in the
        +     * response. Filters are supported on the following fields:
        +     *   - immediate_parent
        +     *
        +     * Examples of using a filter are:
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +     *   -
        +     *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +     *
        +     * This will only return the GlossaryTerms that are directly nested under the
        +     * specified parent.
        +     * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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. Order by expression that orders GlossaryTerms listed in the
        +     * response. Order by fields are: `name` or `create_time` for the result. If
        +     * not specified, the ordering is undefined.
        +     * 
        + * + * 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; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.ListGlossaryTermsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.ListGlossaryTermsRequest) + private static final com.google.cloud.dataplex.v1.ListGlossaryTermsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.ListGlossaryTermsRequest(); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGlossaryTermsRequest 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.dataplex.v1.ListGlossaryTermsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsRequestOrBuilder.java new file mode 100644 index 000000000000..e24bf6150473 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsRequestOrBuilder.java @@ -0,0 +1,188 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface ListGlossaryTermsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.ListGlossaryTermsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The parent, which has this collection of GlossaryTerms.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + + /** + * + * + *
        +   * Required. The parent, which has this collection of GlossaryTerms.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * where `location_id` refers to a Google Cloud region.
        +   * 
        + * + * + * 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 GlossaryTerms to return. The service may
        +   * return fewer than this value. If unspecified, at most 50 GlossaryTerms 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 page token, received from a previous `ListGlossaryTerms` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaryTerms` 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 `ListGlossaryTerms` call.
        +   * Provide this to retrieve the subsequent page.
        +   * When paginating, all other parameters provided to `ListGlossaryTerms` 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(); + + /** + * + * + *
        +   * Optional. Filter expression that filters GlossaryTerms listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryTerms that are directly nested under the
        +   * specified parent.
        +   * 
        + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The filter. + */ + java.lang.String getFilter(); + + /** + * + * + *
        +   * Optional. Filter expression that filters GlossaryTerms listed in the
        +   * response. Filters are supported on the following fields:
        +   *   - immediate_parent
        +   *
        +   * Examples of using a filter are:
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"`
        +   *   -
        +   *   `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"`
        +   *
        +   * This will only return the GlossaryTerms that are directly nested under the
        +   * specified parent.
        +   * 
        + * + * string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for filter. + */ + com.google.protobuf.ByteString getFilterBytes(); + + /** + * + * + *
        +   * Optional. Order by expression that orders GlossaryTerms listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The orderBy. + */ + java.lang.String getOrderBy(); + + /** + * + * + *
        +   * Optional. Order by expression that orders GlossaryTerms listed in the
        +   * response. Order by fields are: `name` or `create_time` for the result. If
        +   * not specified, the ordering is undefined.
        +   * 
        + * + * string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for orderBy. + */ + com.google.protobuf.ByteString getOrderByBytes(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsResponse.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsResponse.java new file mode 100644 index 000000000000..21a732a01e04 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsResponse.java @@ -0,0 +1,1447 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * List GlossaryTerms Response
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryTermsResponse} + */ +public final class ListGlossaryTermsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.ListGlossaryTermsResponse) + ListGlossaryTermsResponseOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ListGlossaryTermsResponse.newBuilder() to construct. + private ListGlossaryTermsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListGlossaryTermsResponse() { + terms_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListGlossaryTermsResponse(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.class, + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.Builder.class); + } + + public static final int TERMS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private java.util.List terms_; + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + @java.lang.Override + public java.util.List getTermsList() { + return terms_; + } + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + @java.lang.Override + public java.util.List + getTermsOrBuilderList() { + return terms_; + } + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + @java.lang.Override + public int getTermsCount() { + return terms_.size(); + } + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTerm getTerms(int index) { + return terms_.get(index); + } + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermsOrBuilder(int index) { + return terms_.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 UNREACHABLE_LOCATIONS_FIELD_NUMBER = 3; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList unreachableLocations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + public com.google.protobuf.ProtocolStringList getUnreachableLocationsList() { + return unreachableLocations_; + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + public int getUnreachableLocationsCount() { + return unreachableLocations_.size(); + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + public java.lang.String getUnreachableLocations(int index) { + return unreachableLocations_.get(index); + } + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + public com.google.protobuf.ByteString getUnreachableLocationsBytes(int index) { + return unreachableLocations_.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 < terms_.size(); i++) { + output.writeMessage(1, terms_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + for (int i = 0; i < unreachableLocations_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString( + output, 3, unreachableLocations_.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 < terms_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, terms_.get(i)); + } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + { + int dataSize = 0; + for (int i = 0; i < unreachableLocations_.size(); i++) { + dataSize += computeStringSizeNoTag(unreachableLocations_.getRaw(i)); + } + size += dataSize; + size += 1 * getUnreachableLocationsList().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.dataplex.v1.ListGlossaryTermsResponse)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse other = + (com.google.cloud.dataplex.v1.ListGlossaryTermsResponse) obj; + + if (!getTermsList().equals(other.getTermsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!getUnreachableLocationsList().equals(other.getUnreachableLocationsList())) 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 (getTermsCount() > 0) { + hash = (37 * hash) + TERMS_FIELD_NUMBER; + hash = (53 * hash) + getTermsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + if (getUnreachableLocationsCount() > 0) { + hash = (37 * hash) + UNREACHABLE_LOCATIONS_FIELD_NUMBER; + hash = (53 * hash) + getUnreachableLocationsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse 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.dataplex.v1.ListGlossaryTermsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse 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.dataplex.v1.ListGlossaryTermsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.ListGlossaryTermsResponse 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * List GlossaryTerms Response
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.ListGlossaryTermsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.ListGlossaryTermsResponse) + com.google.cloud.dataplex.v1.ListGlossaryTermsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.class, + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + if (termsBuilder_ == null) { + terms_ = java.util.Collections.emptyList(); + } else { + terms_ = null; + termsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + nextPageToken_ = ""; + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_ListGlossaryTermsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryTermsResponse getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryTermsResponse build() { + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.ListGlossaryTermsResponse buildPartial() { + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse result = + new com.google.cloud.dataplex.v1.ListGlossaryTermsResponse(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.dataplex.v1.ListGlossaryTermsResponse result) { + if (termsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + terms_ = java.util.Collections.unmodifiableList(terms_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.terms_ = terms_; + } else { + result.terms_ = termsBuilder_.build(); + } + } + + private void buildPartial0(com.google.cloud.dataplex.v1.ListGlossaryTermsResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000002) != 0)) { + result.nextPageToken_ = nextPageToken_; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + unreachableLocations_.makeImmutable(); + result.unreachableLocations_ = unreachableLocations_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.ListGlossaryTermsResponse) { + return mergeFrom((com.google.cloud.dataplex.v1.ListGlossaryTermsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.ListGlossaryTermsResponse other) { + if (other == com.google.cloud.dataplex.v1.ListGlossaryTermsResponse.getDefaultInstance()) + return this; + if (termsBuilder_ == null) { + if (!other.terms_.isEmpty()) { + if (terms_.isEmpty()) { + terms_ = other.terms_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureTermsIsMutable(); + terms_.addAll(other.terms_); + } + onChanged(); + } + } else { + if (!other.terms_.isEmpty()) { + if (termsBuilder_.isEmpty()) { + termsBuilder_.dispose(); + termsBuilder_ = null; + terms_ = other.terms_; + bitField0_ = (bitField0_ & ~0x00000001); + termsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getTermsFieldBuilder() + : null; + } else { + termsBuilder_.addAllMessages(other.terms_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + bitField0_ |= 0x00000002; + onChanged(); + } + if (!other.unreachableLocations_.isEmpty()) { + if (unreachableLocations_.isEmpty()) { + unreachableLocations_ = other.unreachableLocations_; + bitField0_ |= 0x00000004; + } else { + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.addAll(other.unreachableLocations_); + } + 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.dataplex.v1.GlossaryTerm m = + input.readMessage( + com.google.cloud.dataplex.v1.GlossaryTerm.parser(), extensionRegistry); + if (termsBuilder_ == null) { + ensureTermsIsMutable(); + terms_.add(m); + } else { + termsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.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 terms_ = + java.util.Collections.emptyList(); + + private void ensureTermsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + terms_ = new java.util.ArrayList(terms_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder> + termsBuilder_; + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public java.util.List getTermsList() { + if (termsBuilder_ == null) { + return java.util.Collections.unmodifiableList(terms_); + } else { + return termsBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public int getTermsCount() { + if (termsBuilder_ == null) { + return terms_.size(); + } else { + return termsBuilder_.getCount(); + } + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryTerm getTerms(int index) { + if (termsBuilder_ == null) { + return terms_.get(index); + } else { + return termsBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder setTerms(int index, com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTermsIsMutable(); + terms_.set(index, value); + onChanged(); + } else { + termsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder setTerms( + int index, com.google.cloud.dataplex.v1.GlossaryTerm.Builder builderForValue) { + if (termsBuilder_ == null) { + ensureTermsIsMutable(); + terms_.set(index, builderForValue.build()); + onChanged(); + } else { + termsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder addTerms(com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTermsIsMutable(); + terms_.add(value); + onChanged(); + } else { + termsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder addTerms(int index, com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureTermsIsMutable(); + terms_.add(index, value); + onChanged(); + } else { + termsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder addTerms(com.google.cloud.dataplex.v1.GlossaryTerm.Builder builderForValue) { + if (termsBuilder_ == null) { + ensureTermsIsMutable(); + terms_.add(builderForValue.build()); + onChanged(); + } else { + termsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder addTerms( + int index, com.google.cloud.dataplex.v1.GlossaryTerm.Builder builderForValue) { + if (termsBuilder_ == null) { + ensureTermsIsMutable(); + terms_.add(index, builderForValue.build()); + onChanged(); + } else { + termsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder addAllTerms( + java.lang.Iterable values) { + if (termsBuilder_ == null) { + ensureTermsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, terms_); + onChanged(); + } else { + termsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder clearTerms() { + if (termsBuilder_ == null) { + terms_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + termsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public Builder removeTerms(int index) { + if (termsBuilder_ == null) { + ensureTermsIsMutable(); + terms_.remove(index); + onChanged(); + } else { + termsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryTerm.Builder getTermsBuilder(int index) { + return getTermsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermsOrBuilder(int index) { + if (termsBuilder_ == null) { + return terms_.get(index); + } else { + return termsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public java.util.List + getTermsOrBuilderList() { + if (termsBuilder_ != null) { + return termsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(terms_); + } + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryTerm.Builder addTermsBuilder() { + return getTermsFieldBuilder() + .addBuilder(com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance()); + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public com.google.cloud.dataplex.v1.GlossaryTerm.Builder addTermsBuilder(int index) { + return getTermsFieldBuilder() + .addBuilder(index, com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance()); + } + + /** + * + * + *
        +     * Lists the GlossaryTerms in the specified parent.
        +     * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + public java.util.List getTermsBuilderList() { + return getTermsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder> + getTermsFieldBuilder() { + if (termsBuilder_ == null) { + termsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder>( + terms_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + terms_ = null; + } + return termsBuilder_; + } + + 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 com.google.protobuf.LazyStringArrayList unreachableLocations_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureUnreachableLocationsIsMutable() { + if (!unreachableLocations_.isModifiable()) { + unreachableLocations_ = new com.google.protobuf.LazyStringArrayList(unreachableLocations_); + } + bitField0_ |= 0x00000004; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + public com.google.protobuf.ProtocolStringList getUnreachableLocationsList() { + unreachableLocations_.makeImmutable(); + return unreachableLocations_; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + public int getUnreachableLocationsCount() { + return unreachableLocations_.size(); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + public java.lang.String getUnreachableLocations(int index) { + return unreachableLocations_.get(index); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + public com.google.protobuf.ByteString getUnreachableLocationsBytes(int index) { + return unreachableLocations_.getByteString(index); + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index to set the value at. + * @param value The unreachableLocations to set. + * @return This builder for chaining. + */ + public Builder setUnreachableLocations(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.set(index, value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param value The unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addUnreachableLocations(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param values The unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addAllUnreachableLocations(java.lang.Iterable values) { + ensureUnreachableLocationsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, unreachableLocations_); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @return This builder for chaining. + */ + public Builder clearUnreachableLocations() { + unreachableLocations_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000004); + ; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Locations that the service couldn't reach.
        +     * 
        + * + * repeated string unreachable_locations = 3; + * + * @param value The bytes of the unreachableLocations to add. + * @return This builder for chaining. + */ + public Builder addUnreachableLocationsBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureUnreachableLocationsIsMutable(); + unreachableLocations_.add(value); + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.ListGlossaryTermsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.ListGlossaryTermsResponse) + private static final com.google.cloud.dataplex.v1.ListGlossaryTermsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.ListGlossaryTermsResponse(); + } + + public static com.google.cloud.dataplex.v1.ListGlossaryTermsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListGlossaryTermsResponse 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.dataplex.v1.ListGlossaryTermsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsResponseOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsResponseOrBuilder.java new file mode 100644 index 000000000000..d5ec033b8add --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListGlossaryTermsResponseOrBuilder.java @@ -0,0 +1,164 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface ListGlossaryTermsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.ListGlossaryTermsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + java.util.List getTermsList(); + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + com.google.cloud.dataplex.v1.GlossaryTerm getTerms(int index); + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + int getTermsCount(); + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + java.util.List + getTermsOrBuilderList(); + + /** + * + * + *
        +   * Lists the GlossaryTerms in the specified parent.
        +   * 
        + * + * repeated .google.cloud.dataplex.v1.GlossaryTerm terms = 1; + */ + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermsOrBuilder(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(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return A list containing the unreachableLocations. + */ + java.util.List getUnreachableLocationsList(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @return The count of unreachableLocations. + */ + int getUnreachableLocationsCount(); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the element to return. + * @return The unreachableLocations at the given index. + */ + java.lang.String getUnreachableLocations(int index); + + /** + * + * + *
        +   * Locations that the service couldn't reach.
        +   * 
        + * + * repeated string unreachable_locations = 3; + * + * @param index The index of the value to return. + * @return The bytes of the unreachableLocations at the given index. + */ + com.google.protobuf.ByteString getUnreachableLocationsBytes(int index); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequest.java index 2521d351cf3f..146782cb58f6 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequest.java @@ -78,7 +78,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { *
            * Required. The resource name of the lake location, of the form:
            * `projects/{project_number}/locations/{location_id}`
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -106,7 +106,7 @@ public java.lang.String getParent() { *
            * Required. The resource name of the lake location, of the form:
            * `projects/{project_number}/locations/{location_id}`
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -756,7 +756,7 @@ public Builder mergeFrom( *
              * Required. The resource name of the lake location, of the form:
              * `projects/{project_number}/locations/{location_id}`
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -783,7 +783,7 @@ public java.lang.String getParent() { *
              * Required. The resource name of the lake location, of the form:
              * `projects/{project_number}/locations/{location_id}`
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -810,7 +810,7 @@ public com.google.protobuf.ByteString getParentBytes() { *
              * Required. The resource name of the lake location, of the form:
              * `projects/{project_number}/locations/{location_id}`
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -836,7 +836,7 @@ public Builder setParent(java.lang.String value) { *
              * Required. The resource name of the lake location, of the form:
              * `projects/{project_number}/locations/{location_id}`
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * @@ -858,7 +858,7 @@ public Builder clearParent() { *
              * Required. The resource name of the lake location, of the form:
              * `projects/{project_number}/locations/{location_id}`
        -     * where `location_id` refers to a GCP region.
        +     * where `location_id` refers to a Google Cloud region.
              * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequestOrBuilder.java index 5cdb5a95b299..4d1508703013 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ListLakesRequestOrBuilder.java @@ -30,7 +30,7 @@ public interface ListLakesRequestOrBuilder *
            * Required. The resource name of the lake location, of the form:
            * `projects/{project_number}/locations/{location_id}`
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * @@ -47,7 +47,7 @@ public interface ListLakesRequestOrBuilder *
            * Required. The resource name of the lake location, of the form:
            * `projects/{project_number}/locations/{location_id}`
        -   * where `location_id` refers to a GCP region.
        +   * where `location_id` refers to a Google Cloud region.
            * 
        * * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java index ce1ba5e9392f..56312cc97541 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/LogsProto.java @@ -141,7 +141,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "#google/cloud/dataplex/v1/logs.proto\022\030g" + "oogle.cloud.dataplex.v1\032\037google/api/fiel" + "d_behavior.proto\032\031google/api/resource.pr" - + "oto\032\036google/protobuf/duration.proto\032\037google/protobuf/timestamp.proto\"\235\014\n" + + "oto\032/google/cloud/dataplex/v1/datascans_" + + "common.proto\032\036google/protobuf/duration.p" + + "roto\032\037google/protobuf/timestamp.proto\"\235\014\n" + "\016DiscoveryEvent\022\017\n" + "\007message\030\001 \001(\t\022\017\n" + "\007lake_id\030\002 \001(\t\022\017\n" @@ -151,19 +153,19 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013datascan_id\030\006 \001(\t\022@\n" + "\004type\030\n" + " \001(\01622.google.cloud.dataplex.v1.DiscoveryEvent.EventType\022H\n" - + "\006config\030\024 \001" - + "(\01326.google.cloud.dataplex.v1.DiscoveryEvent.ConfigDetailsH\000\022H\n" - + "\006entity\030\025 \001(\01326.g" - + "oogle.cloud.dataplex.v1.DiscoveryEvent.EntityDetailsH\000\022N\n" - + "\tpartition\030\026 \001(\01329.goog" - + "le.cloud.dataplex.v1.DiscoveryEvent.PartitionDetailsH\000\022H\n" - + "\006action\030\027 \001(\01326.google." - + "cloud.dataplex.v1.DiscoveryEvent.ActionDetailsH\000\022F\n" - + "\005table\030\030 \001(\01325.google.cloud.d" - + "ataplex.v1.DiscoveryEvent.TableDetailsH\000\032\236\001\n\r" + + "\006config\030\024" + + " \001(\01326.google.cloud.dataplex.v1.DiscoveryEvent.ConfigDetailsH\000\022H\n" + + "\006entity\030\025" + + " \001(\01326.google.cloud.dataplex.v1.DiscoveryEvent.EntityDetailsH\000\022N\n" + + "\tpartition\030\026 \001" + + "(\01329.google.cloud.dataplex.v1.DiscoveryEvent.PartitionDetailsH\000\022H\n" + + "\006action\030\027 \001(\0132" + + "6.google.cloud.dataplex.v1.DiscoveryEvent.ActionDetailsH\000\022F\n" + + "\005table\030\030 \001(\01325.googl" + + "e.cloud.dataplex.v1.DiscoveryEvent.TableDetailsH\000\032\236\001\n\r" + "ConfigDetails\022Z\n\n" - + "parameters\030\001 \003(\0132F" - + ".google.cloud.dataplex.v1.DiscoveryEvent.ConfigDetails.ParametersEntry\0321\n" + + "parameters\030\001 \003(\0132F.google.cloud.dataplex.v1.Disco" + + "veryEvent.ConfigDetails.ParametersEntry\0321\n" + "\017ParametersEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\t:\0028\001\032b\n\r" @@ -172,13 +174,13 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004type\030\002 \001(\01623.google.cloud.dataplex.v1.DiscoveryEvent.EntityType\032_\n" + "\014TableDetails\022\r\n" + "\005table\030\001 \001(\t\022@\n" - + "\004type\030\002 \001(\01622.google.clou" - + "d.dataplex.v1.DiscoveryEvent.TableType\032\230\001\n" + + "\004type\030\002 \001(\01622.go" + + "ogle.cloud.dataplex.v1.DiscoveryEvent.TableType\032\230\001\n" + "\020PartitionDetails\022\021\n" + "\tpartition\030\001 \001(\t\022\016\n" + "\006entity\030\002 \001(\t\022A\n" - + "\004type\030\003 \001(\01623.google.cl" - + "oud.dataplex.v1.DiscoveryEvent.EntityType\022\036\n" + + "\004type\030\003 \001(\01623." + + "google.cloud.dataplex.v1.DiscoveryEvent.EntityType\022\036\n" + "\026sampled_data_locations\030\004 \003(\t\032,\n\r" + "ActionDetails\022\014\n" + "\004type\030\001 \001(\t\022\r\n" @@ -204,7 +206,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\007FILESET\020\002\"`\n" + "\tTableType\022\032\n" + "\026TABLE_TYPE_UNSPECIFIED\020\000\022\022\n" - + "\016EXTERNAL_TABLE\020\001\022\021\n\r" + + "\016EXTERNAL_TABLE\020\001\022\021\n" + + "\r" + "BIGLAKE_TABLE\020\002\022\020\n" + "\014OBJECT_TABLE\020\003B\t\n" + "\007details\"\305\005\n" @@ -242,16 +245,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\007user_id\030\002 \001(\t\022\022\n\n" + "session_id\030\003 \001(\t\022>\n" + "\004type\030\004 \001(\01620.google.cloud.dataplex.v1.SessionEvent.EventType\022C\n" - + "\005query\030\005" - + " \001(\01322.google.cloud.dataplex.v1.SessionEvent.QueryDetailH\000\022\027\n" + + "\005query\030\005 \001(\01322.google.clo" + + "ud.dataplex.v1.SessionEvent.QueryDetailH\000\022\027\n" + "\017event_succeeded\030\006 \001(\010\022\034\n" + "\024fast_startup_enabled\030\007 \001(\010\0226\n" + "\023unassigned_duration\030\010 \001(\0132\031.google.protobuf.Duration\032\243\002\n" + "\013QueryDetail\022\020\n" + "\010query_id\030\001 \001(\t\022\022\n\n" + "query_text\030\002 \001(\t\022I\n" - + "\006engine\030\003" - + " \001(\01629.google.cloud.dataplex.v1.SessionEvent.QueryDetail.Engine\022+\n" + + "\006engine\030\003 \001(\01629.google.cloud.da" + + "taplex.v1.SessionEvent.QueryDetail.Engine\022+\n" + "\010duration\030\004 \001(\0132\031.google.protobuf.Duration\022\031\n" + "\021result_size_bytes\030\005 \001(\003\022\034\n" + "\024data_processed_bytes\030\006 \001(\003\"=\n" @@ -268,15 +271,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006detail\"\272\007\n" + "\017GovernanceEvent\022\017\n" + "\007message\030\001 \001(\t\022G\n\n" - + "event_type\030\002 \001(\01623.google.c" - + "loud.dataplex.v1.GovernanceEvent.EventType\022E\n" - + "\006entity\030\003" - + " \001(\01320.google.cloud.dataplex.v1.GovernanceEvent.EntityH\000\210\001\001\032\322\001\n" + + "event_type\030\002 \001(\01623" + + ".google.cloud.dataplex.v1.GovernanceEvent.EventType\022E\n" + + "\006entity\030\003 \001(\01320.google.clo" + + "ud.dataplex.v1.GovernanceEvent.EntityH\000\210\001\001\032\322\001\n" + "\006Entity\0223\n" + "\006entity\030\001 \001(\tB#\372A \n" + "\036dataplex.googleapis.com/Entity\022P\n" - + "\013entity_type\030\002 \001(\0162;" - + ".google.cloud.dataplex.v1.GovernanceEvent.Entity.EntityType\"A\n\n" + + "\013entity_type\030\002" + + " \001(\0162;.google.cloud.dataplex.v1.GovernanceEvent.Entity.EntityType\"A\n\n" + "EntityType\022\033\n" + "\027ENTITY_TYPE_UNSPECIFIED\020\000\022\t\n" + "\005TABLE\020\001\022\013\n" @@ -301,7 +304,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "$GOVERNANCE_RULE_SEARCH_LIMIT_EXCEEDS\020\020\022\032\n" + "\026GOVERNANCE_RULE_ERRORS\020\021\022\036\n" + "\032GOVERNANCE_RULE_PROCESSING\020\022B\t\n" - + "\007_entity\"\207\023\n\r" + + "\007_entity\"\345\023\n\r" + "DataScanEvent\022\023\n" + "\013data_source\030\001 \001(\t\022\016\n" + "\006job_id\030\002 \001(\t\022/\n" @@ -315,28 +318,30 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\007trigger\030\t \001(\0162/.google.cloud.dataplex.v1.DataScanEvent.Trigger\022<\n" + "\005scope\030\n" + " \001(\0162-.google.cloud.dataplex.v1.DataScanEvent.Scope\022Q\n" - + "\014data_profile\030e \001" - + "(\01329.google.cloud.dataplex.v1.DataScanEvent.DataProfileResultH\000\022Q\n" + + "\014data_profile\030e" + + " \001(\01329.google.cloud.dataplex.v1.DataScanEvent.DataProfileResultH\000\022Q\n" + "\014data_quality\030f" + " \001(\01329.google.cloud.dataplex.v1.DataScanEvent.DataQualityResultH\000\022b\n" - + "\024data_profile_configs\030\311\001 \001(\0132A.google.cloud.dataple" - + "x.v1.DataScanEvent.DataProfileAppliedConfigsH\001\022b\n" - + "\024data_quality_configs\030\312\001 \001(\0132A." - + "google.cloud.dataplex.v1.DataScanEvent.DataQualityAppliedConfigsH\001\022_\n" - + "\030post_scan_actions_result\030\013 \001(\0132=.google.cloud.data" - + "plex.v1.DataScanEvent.PostScanActionsResult\032&\n" + + "\024data_profile_configs\030\311\001 \001(\0132A.google.clou" + + "d.dataplex.v1.DataScanEvent.DataProfileAppliedConfigsH\001\022b\n" + + "\024data_quality_configs\030\312\001" + + " \001(\0132A.google.cloud.dataplex.v1.DataScanEvent.DataQualityAppliedConfigsH\001\022_\n" + + "\030post_scan_actions_result\030\013 \001(\0132=.google.c" + + "loud.dataplex.v1.DataScanEvent.PostScanActionsResult\022\\\n" + + "\031catalog_publishing_status\030\r" + + " \001(\01329.google.cloud.dataplex.v1.DataScanCatalogPublishingStatus\032&\n" + "\021DataProfileResult\022\021\n" + "\trow_count\030\001 \001(\003\032\234\004\n" + "\021DataQualityResult\022\021\n" + "\trow_count\030\001 \001(\003\022\016\n" + "\006passed\030\002 \001(\010\022h\n" - + "\020dimension_passed\030\003 \003(\0132N.google.cloud.dataplex.v1.DataSc" - + "anEvent.DataQualityResult.DimensionPassedEntry\022\r\n" + + "\020dimension_passed\030\003 \003(\0132N.google.c" + + "loud.dataplex.v1.DataScanEvent.DataQualityResult.DimensionPassedEntry\022\r\n" + "\005score\030\004 \001(\002\022f\n" - + "\017dimension_score\030\005 \003(\0132M.google.cloud.dataplex.v1.DataSc" - + "anEvent.DataQualityResult.DimensionScoreEntry\022`\n" - + "\014column_score\030\006 \003(\0132J.google.clo" - + "ud.dataplex.v1.DataScanEvent.DataQualityResult.ColumnScoreEntry\0326\n" + + "\017dimension_score\030\005 \003(\0132M.google.c" + + "loud.dataplex.v1.DataScanEvent.DataQualityResult.DimensionScoreEntry\022`\n" + + "\014column_score\030\006 \003(\0132J.google.cloud.dataplex.v1.Da" + + "taScanEvent.DataQualityResult.ColumnScoreEntry\0326\n" + "\024DimensionPassedEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" + "\005value\030\002 \001(\010:\0028\001\0325\n" @@ -354,11 +359,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020sampling_percent\030\001 \001(\002\022\032\n" + "\022row_filter_applied\030\002 \001(\010\032\346\002\n" + "\025PostScanActionsResult\022r\n" - + "\026bigquery_export_result\030\001 \001(\0132R.google.cloud.dataplex.v1.DataScanEve" - + "nt.PostScanActionsResult.BigQueryExportResult\032\330\001\n" + + "\026bigquery_export_result\030\001 \001(\0132R.google.cloud." + + "dataplex.v1.DataScanEvent.PostScanActionsResult.BigQueryExportResult\032\330\001\n" + "\024BigQueryExportResult\022g\n" - + "\005state\030\001 \001(\0162X.google.cloud.dataplex.v1.DataSca" - + "nEvent.PostScanActionsResult.BigQueryExportResult.State\022\017\n" + + "\005state\030\001 \001(\0162X.google.cloud.dataplex.v1.DataScanEvent.PostScanAc" + + "tionsResult.BigQueryExportResult.State\022\017\n" + "\007message\030\002 \001(\t\"F\n" + "\005State\022\025\n" + "\021STATE_UNSPECIFIED\020\000\022\r\n" @@ -378,7 +383,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tCANCELLED\020\004\022\013\n" + "\007CREATED\020\005\"?\n" + "\007Trigger\022\027\n" - + "\023TRIGGER_UNSPECIFIED\020\000\022\r\n" + + "\023TRIGGER_UNSPECIFIED\020\000\022\r" + + "\n" + "\tON_DEMAND\020\001\022\014\n" + "\010SCHEDULE\020\002\"9\n" + "\005Scope\022\025\n" @@ -392,14 +398,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013data_source\030\002 \001(\t\022\016\n" + "\006column\030\003 \001(\t\022\021\n" + "\trule_name\030\004 \001(\t\022O\n" - + "\trule_type\030\005" - + " \001(\0162<.google.cloud.dataplex.v1.DataQualityScanRuleResult.RuleType\022Z\n" - + "\016evalution_type\030\006 \001(\0162B.google.cloud.datapl" - + "ex.v1.DataQualityScanRuleResult.EvaluationType\022\026\n" + + "\trule_type\030\005 \001(\0162<.go" + + "ogle.cloud.dataplex.v1.DataQualityScanRuleResult.RuleType\022Z\n" + + "\016evalution_type\030\006 \001(" + + "\0162B.google.cloud.dataplex.v1.DataQualityScanRuleResult.EvaluationType\022\026\n" + "\016rule_dimension\030\007 \001(\t\022\031\n" + "\021threshold_percent\030\010 \001(\001\022J\n" - + "\006result\030\t \001(\0162:.goog" - + "le.cloud.dataplex.v1.DataQualityScanRuleResult.Result\022\033\n" + + "\006result\030\t" + + " \001(\0162:.google.cloud.dataplex.v1.DataQualityScanRuleResult.Result\022\033\n" + "\023evaluated_row_count\030\n" + " \001(\003\022\030\n" + "\020passed_row_count\030\013 \001(\003\022\026\n" @@ -427,8 +433,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006FAILED\020\002\"\232\003\n" + "\025BusinessGlossaryEvent\022\017\n" + "\007message\030\001 \001(\t\022M\n\n" - + "event_type\030\002 \001(\01629" - + ".google.cloud.dataplex.v1.BusinessGlossaryEvent.EventType\022\020\n" + + "event_type\030\002 \001(\01629.google.cloud.dat" + + "aplex.v1.BusinessGlossaryEvent.EventType\022\020\n" + "\010resource\030\003 \001(\t\"\216\002\n" + "\tEventType\022\032\n" + "\026EVENT_TYPE_UNSPECIFIED\020\000\022\023\n" @@ -443,15 +449,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\024GLOSSARY_TERM_DELETE\020\t\"\322\001\n" + "\016EntryLinkEvent\022\017\n" + "\007message\030\001 \001(\t\022F\n\n" - + "event_type\030\002" - + " \001(\01622.google.cloud.dataplex.v1.EntryLinkEvent.EventType\022\020\n" + + "event_type\030\002 \001(\01622.google.clo" + + "ud.dataplex.v1.EntryLinkEvent.EventType\022\020\n" + "\010resource\030\003 \001(\t\"U\n" + "\tEventType\022\032\n" + "\026EVENT_TYPE_UNSPECIFIED\020\000\022\025\n" + "\021ENTRY_LINK_CREATE\020\001\022\025\n" + "\021ENTRY_LINK_DELETE\020\002Be\n" - + "\034com.google.cloud.dataplex.v1B\tLogsProtoP\001Z8cloud.google.com/go/dataplex/api" - + "v1/dataplexpb;dataplexpbb\006proto3" + + "\034com.google.cloud.dataplex.v1B\tLogsProtoP\001Z8cloud.goo" + + "gle.com/go/dataplex/apiv1/dataplexpb;dataplexpbb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -459,6 +465,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.cloud.dataplex.v1.DataScansCommonProto.getDescriptor(), com.google.protobuf.DurationProto.getDescriptor(), com.google.protobuf.TimestampProto.getDescriptor(), }); @@ -611,6 +618,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "DataProfileConfigs", "DataQualityConfigs", "PostScanActionsResult", + "CatalogPublishingStatus", "Result", "AppliedConfigs", }); @@ -737,6 +745,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { descriptor, registry); com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); + com.google.cloud.dataplex.v1.DataScansCommonProto.getDescriptor(); com.google.protobuf.DurationProto.getDescriptor(); com.google.protobuf.TimestampProto.getDescriptor(); } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/MetadataJob.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/MetadataJob.java index fcb76d68f709..b707ba41b448 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/MetadataJob.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/MetadataJob.java @@ -349,6 +349,47 @@ public interface ImportJobResultOrBuilder * */ com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + /** + * + * + *
        +     * Output only. The total number of entry links that were successfully
        +     * deleted.
        +     * 
        + * + * int64 deleted_entry_links = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The deletedEntryLinks. + */ + long getDeletedEntryLinks(); + + /** + * + * + *
        +     * Output only. The total number of entry links that were successfully
        +     * created.
        +     * 
        + * + * int64 created_entry_links = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The createdEntryLinks. + */ + long getCreatedEntryLinks(); + + /** + * + * + *
        +     * Output only. The total number of entry links that were left unchanged.
        +     * 
        + * + * int64 unchanged_entry_links = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The unchangedEntryLinks. + */ + long getUnchangedEntryLinks(); } /** @@ -545,6 +586,65 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; } + public static final int DELETED_ENTRY_LINKS_FIELD_NUMBER = 7; + private long deletedEntryLinks_ = 0L; + + /** + * + * + *
        +     * Output only. The total number of entry links that were successfully
        +     * deleted.
        +     * 
        + * + * int64 deleted_entry_links = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The deletedEntryLinks. + */ + @java.lang.Override + public long getDeletedEntryLinks() { + return deletedEntryLinks_; + } + + public static final int CREATED_ENTRY_LINKS_FIELD_NUMBER = 8; + private long createdEntryLinks_ = 0L; + + /** + * + * + *
        +     * Output only. The total number of entry links that were successfully
        +     * created.
        +     * 
        + * + * int64 created_entry_links = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The createdEntryLinks. + */ + @java.lang.Override + public long getCreatedEntryLinks() { + return createdEntryLinks_; + } + + public static final int UNCHANGED_ENTRY_LINKS_FIELD_NUMBER = 9; + private long unchangedEntryLinks_ = 0L; + + /** + * + * + *
        +     * Output only. The total number of entry links that were left unchanged.
        +     * 
        + * + * int64 unchanged_entry_links = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The unchangedEntryLinks. + */ + @java.lang.Override + public long getUnchangedEntryLinks() { + return unchangedEntryLinks_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -577,6 +677,15 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (recreatedEntries_ != 0L) { output.writeInt64(6, recreatedEntries_); } + if (deletedEntryLinks_ != 0L) { + output.writeInt64(7, deletedEntryLinks_); + } + if (createdEntryLinks_ != 0L) { + output.writeInt64(8, createdEntryLinks_); + } + if (unchangedEntryLinks_ != 0L) { + output.writeInt64(9, unchangedEntryLinks_); + } getUnknownFields().writeTo(output); } @@ -604,6 +713,15 @@ public int getSerializedSize() { if (recreatedEntries_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(6, recreatedEntries_); } + if (deletedEntryLinks_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(7, deletedEntryLinks_); + } + if (createdEntryLinks_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(8, createdEntryLinks_); + } + if (unchangedEntryLinks_ != 0L) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(9, unchangedEntryLinks_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -629,6 +747,9 @@ public boolean equals(final java.lang.Object obj) { if (hasUpdateTime()) { if (!getUpdateTime().equals(other.getUpdateTime())) return false; } + if (getDeletedEntryLinks() != other.getDeletedEntryLinks()) return false; + if (getCreatedEntryLinks() != other.getCreatedEntryLinks()) return false; + if (getUnchangedEntryLinks() != other.getUnchangedEntryLinks()) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -654,6 +775,12 @@ public int hashCode() { hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; hash = (53 * hash) + getUpdateTime().hashCode(); } + hash = (37 * hash) + DELETED_ENTRY_LINKS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDeletedEntryLinks()); + hash = (37 * hash) + CREATED_ENTRY_LINKS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getCreatedEntryLinks()); + hash = (37 * hash) + UNCHANGED_ENTRY_LINKS_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getUnchangedEntryLinks()); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -816,6 +943,9 @@ public Builder clear() { updateTimeBuilder_.dispose(); updateTimeBuilder_ = null; } + deletedEntryLinks_ = 0L; + createdEntryLinks_ = 0L; + unchangedEntryLinks_ = 0L; return this; } @@ -873,6 +1003,15 @@ private void buildPartial0(com.google.cloud.dataplex.v1.MetadataJob.ImportJobRes updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build(); to_bitField0_ |= 0x00000001; } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.deletedEntryLinks_ = deletedEntryLinks_; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.createdEntryLinks_ = createdEntryLinks_; + } + if (((from_bitField0_ & 0x00000100) != 0)) { + result.unchangedEntryLinks_ = unchangedEntryLinks_; + } result.bitField0_ |= to_bitField0_; } @@ -942,6 +1081,15 @@ public Builder mergeFrom(com.google.cloud.dataplex.v1.MetadataJob.ImportJobResul if (other.hasUpdateTime()) { mergeUpdateTime(other.getUpdateTime()); } + if (other.getDeletedEntryLinks() != 0L) { + setDeletedEntryLinks(other.getDeletedEntryLinks()); + } + if (other.getCreatedEntryLinks() != 0L) { + setCreatedEntryLinks(other.getCreatedEntryLinks()); + } + if (other.getUnchangedEntryLinks() != 0L) { + setUnchangedEntryLinks(other.getUnchangedEntryLinks()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1004,6 +1152,24 @@ public Builder mergeFrom( bitField0_ |= 0x00000010; break; } // case 48 + case 56: + { + deletedEntryLinks_ = input.readInt64(); + bitField0_ |= 0x00000040; + break; + } // case 56 + case 64: + { + createdEntryLinks_ = input.readInt64(); + bitField0_ |= 0x00000080; + break; + } // case 64 + case 72: + { + unchangedEntryLinks_ = input.readInt64(); + bitField0_ |= 0x00000100; + break; + } // case 72 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -1515,6 +1681,180 @@ public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { return updateTimeBuilder_; } + private long deletedEntryLinks_; + + /** + * + * + *
        +       * Output only. The total number of entry links that were successfully
        +       * deleted.
        +       * 
        + * + * int64 deleted_entry_links = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The deletedEntryLinks. + */ + @java.lang.Override + public long getDeletedEntryLinks() { + return deletedEntryLinks_; + } + + /** + * + * + *
        +       * Output only. The total number of entry links that were successfully
        +       * deleted.
        +       * 
        + * + * int64 deleted_entry_links = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The deletedEntryLinks to set. + * @return This builder for chaining. + */ + public Builder setDeletedEntryLinks(long value) { + + deletedEntryLinks_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
        +       * Output only. The total number of entry links that were successfully
        +       * deleted.
        +       * 
        + * + * int64 deleted_entry_links = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearDeletedEntryLinks() { + bitField0_ = (bitField0_ & ~0x00000040); + deletedEntryLinks_ = 0L; + onChanged(); + return this; + } + + private long createdEntryLinks_; + + /** + * + * + *
        +       * Output only. The total number of entry links that were successfully
        +       * created.
        +       * 
        + * + * int64 created_entry_links = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The createdEntryLinks. + */ + @java.lang.Override + public long getCreatedEntryLinks() { + return createdEntryLinks_; + } + + /** + * + * + *
        +       * Output only. The total number of entry links that were successfully
        +       * created.
        +       * 
        + * + * int64 created_entry_links = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The createdEntryLinks to set. + * @return This builder for chaining. + */ + public Builder setCreatedEntryLinks(long value) { + + createdEntryLinks_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +       * Output only. The total number of entry links that were successfully
        +       * created.
        +       * 
        + * + * int64 created_entry_links = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearCreatedEntryLinks() { + bitField0_ = (bitField0_ & ~0x00000080); + createdEntryLinks_ = 0L; + onChanged(); + return this; + } + + private long unchangedEntryLinks_; + + /** + * + * + *
        +       * Output only. The total number of entry links that were left unchanged.
        +       * 
        + * + * int64 unchanged_entry_links = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return The unchangedEntryLinks. + */ + @java.lang.Override + public long getUnchangedEntryLinks() { + return unchangedEntryLinks_; + } + + /** + * + * + *
        +       * Output only. The total number of entry links that were left unchanged.
        +       * 
        + * + * int64 unchanged_entry_links = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @param value The unchangedEntryLinks to set. + * @return This builder for chaining. + */ + public Builder setUnchangedEntryLinks(long value) { + + unchangedEntryLinks_ = value; + bitField0_ |= 0x00000100; + onChanged(); + return this; + } + + /** + * + * + *
        +       * Output only. The total number of entry links that were left unchanged.
        +       * 
        + * + * int64 unchanged_entry_links = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * @return This builder for chaining. + */ + public Builder clearUnchangedEntryLinks() { + bitField0_ = (bitField0_ & ~0x00000100); + unchangedEntryLinks_ = 0L; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { @@ -2695,9 +3035,9 @@ public enum SyncMode implements com.google.protobuf.ProtocolMessageEnum { * *
                * All resources in the job's scope are modified. If a resource exists in
        -       * Dataplex but isn't included in the metadata import file, the resource
        -       * is deleted when you run the metadata job. Use this mode to perform a
        -       * full sync of the set of entries in the job scope.
        +       * Dataplex Universal Catalog but isn't included in the metadata import
        +       * file, the resource is deleted when you run the metadata job. Use this
        +       * mode to perform a full sync of the set of entries in the job scope.
                *
                * This sync mode is supported for entries.
                * 
        @@ -2752,9 +3092,9 @@ public enum SyncMode implements com.google.protobuf.ProtocolMessageEnum { * *
                * All resources in the job's scope are modified. If a resource exists in
        -       * Dataplex but isn't included in the metadata import file, the resource
        -       * is deleted when you run the metadata job. Use this mode to perform a
        -       * full sync of the set of entries in the job scope.
        +       * Dataplex Universal Catalog but isn't included in the metadata import
        +       * file, the resource is deleted when you run the metadata job. Use this
        +       * mode to perform a full sync of the set of entries in the job scope.
                *
                * This sync mode is supported for entries.
                * 
        @@ -3373,69 +3713,362 @@ public interface ImportJobScopeOrBuilder * @return The bytes of the aspectTypes at the given index. */ com.google.protobuf.ByteString getAspectTypesBytes(int index); - } - - /** - * - * - *
        -     * A boundary on the scope of impact that the metadata import job can have.
        -     * 
        - * - * Protobuf type {@code google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope} - */ - public static final class ImportJobScope extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope) - ImportJobScopeOrBuilder { - private static final long serialVersionUID = 0L; - - // Use ImportJobScope.newBuilder() to construct. - private ImportJobScope(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ImportJobScope() { - entryGroups_ = com.google.protobuf.LazyStringArrayList.emptyList(); - entryTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); - aspectTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ImportJobScope(); - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.dataplex.v1.CatalogProto - .internal_static_google_cloud_dataplex_v1_MetadataJob_ImportJobSpec_ImportJobScope_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.dataplex.v1.CatalogProto - .internal_static_google_cloud_dataplex_v1_MetadataJob_ImportJobSpec_ImportJobScope_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope.class, - com.google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope.Builder - .class); - } - - public static final int ENTRY_GROUPS_FIELD_NUMBER = 1; - - @SuppressWarnings("serial") - private com.google.protobuf.LazyStringArrayList entryGroups_ = - com.google.protobuf.LazyStringArrayList.emptyList(); /** * * *
        -       * Required. The entry group that is in scope for the import job,
        -       * specified as a relative resource name in the format
        -       * `projects/{project_number_or_id}/locations/{location_id}/entryGroups/{entry_group_id}`.
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the glossaries. + */ + java.util.List getGlossariesList(); + + /** + * + * + *
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of glossaries. + */ + int getGlossariesCount(); + + /** + * + * + *
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The glossaries at the given index. + */ + java.lang.String getGlossaries(int index); + + /** + * + * + *
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the glossaries at the given index. + */ + com.google.protobuf.ByteString getGlossariesBytes(int index); + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the entryLinkTypes. + */ + java.util.List getEntryLinkTypesList(); + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of entryLinkTypes. + */ + int getEntryLinkTypesCount(); + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The entryLinkTypes at the given index. + */ + java.lang.String getEntryLinkTypes(int index); + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the entryLinkTypes at the given index. + */ + com.google.protobuf.ByteString getEntryLinkTypesBytes(int index); + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the referencedEntryScopes. + */ + java.util.List getReferencedEntryScopesList(); + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of referencedEntryScopes. + */ + int getReferencedEntryScopesCount(); + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The referencedEntryScopes at the given index. + */ + java.lang.String getReferencedEntryScopes(int index); + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the referencedEntryScopes at the given index. + */ + com.google.protobuf.ByteString getReferencedEntryScopesBytes(int index); + } + + /** + * + * + *
        +     * A boundary on the scope of impact that the metadata import job can have.
        +     * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope} + */ + public static final class ImportJobScope extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope) + ImportJobScopeOrBuilder { + private static final long serialVersionUID = 0L; + + // Use ImportJobScope.newBuilder() to construct. + private ImportJobScope(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ImportJobScope() { + entryGroups_ = com.google.protobuf.LazyStringArrayList.emptyList(); + entryTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + aspectTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + glossaries_ = com.google.protobuf.LazyStringArrayList.emptyList(); + entryLinkTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + referencedEntryScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ImportJobScope(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_MetadataJob_ImportJobSpec_ImportJobScope_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.CatalogProto + .internal_static_google_cloud_dataplex_v1_MetadataJob_ImportJobSpec_ImportJobScope_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope.class, + com.google.cloud.dataplex.v1.MetadataJob.ImportJobSpec.ImportJobScope.Builder + .class); + } + + public static final int ENTRY_GROUPS_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList entryGroups_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
        +       * Required. The entry group that is in scope for the import job,
        +       * specified as a relative resource name in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryGroups/{entry_group_id}`.
                * Only entries and aspects that belong to the specified entry group are
                * affected by the job.
                *
        @@ -3771,31 +4404,373 @@ public com.google.protobuf.ByteString getAspectTypesBytes(int index) {
                 return aspectTypes_.getByteString(index);
               }
         
        -      private byte memoizedIsInitialized = -1;
        +      public static final int GLOSSARIES_FIELD_NUMBER = 4;
         
        -      @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 glossaries_ =
        +          com.google.protobuf.LazyStringArrayList.emptyList();
         
        -        memoizedIsInitialized = 1;
        -        return true;
        +      /**
        +       *
        +       *
        +       * 
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the glossaries. + */ + public com.google.protobuf.ProtocolStringList getGlossariesList() { + return glossaries_; } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < entryGroups_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, entryGroups_.getRaw(i)); - } - for (int i = 0; i < entryTypes_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, entryTypes_.getRaw(i)); - } - for (int i = 0; i < aspectTypes_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, aspectTypes_.getRaw(i)); - } - getUnknownFields().writeTo(output); - } + /** + * + * + *
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of glossaries. + */ + public int getGlossariesCount() { + return glossaries_.size(); + } + + /** + * + * + *
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The glossaries at the given index. + */ + public java.lang.String getGlossaries(int index) { + return glossaries_.get(index); + } + + /** + * + * + *
        +       * Optional. The glossaries that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +       *
        +       * While importing Business Glossary entries, the user must
        +       * provide glossaries. While importing entries, the user does not have to
        +       * provide glossaries. If the metadata import file attempts to modify
        +       * Business Glossary entries whose glossary isn't included in this list,
        +       * the import job will skip those entries.
        +       *
        +       * The location of a glossary must either match the location of the
        +       * job, or the glossary must be global.
        +       * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the glossaries at the given index. + */ + public com.google.protobuf.ByteString getGlossariesBytes(int index) { + return glossaries_.getByteString(index); + } + + public static final int ENTRY_LINK_TYPES_FIELD_NUMBER = 5; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList entryLinkTypes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the entryLinkTypes. + */ + public com.google.protobuf.ProtocolStringList getEntryLinkTypesList() { + return entryLinkTypes_; + } + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of entryLinkTypes. + */ + public int getEntryLinkTypesCount() { + return entryLinkTypes_.size(); + } + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The entryLinkTypes at the given index. + */ + public java.lang.String getEntryLinkTypes(int index) { + return entryLinkTypes_.get(index); + } + + /** + * + * + *
        +       * Optional. The entry link types that are in scope for the import job,
        +       * specified as relative resource names in the format
        +       * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +       * The job modifies only the entryLinks that belong to these entry link
        +       * types.
        +       *
        +       * If the metadata import file attempts to create or delete an entry link
        +       * whose entry link type isn't included in this list, the import job will
        +       * skip those entry links.
        +       * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the entryLinkTypes at the given index. + */ + public com.google.protobuf.ByteString getEntryLinkTypesBytes(int index) { + return entryLinkTypes_.getByteString(index); + } + + public static final int REFERENCED_ENTRY_SCOPES_FIELD_NUMBER = 6; + + @SuppressWarnings("serial") + private com.google.protobuf.LazyStringArrayList referencedEntryScopes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the referencedEntryScopes. + */ + public com.google.protobuf.ProtocolStringList getReferencedEntryScopesList() { + return referencedEntryScopes_; + } + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of referencedEntryScopes. + */ + public int getReferencedEntryScopesCount() { + return referencedEntryScopes_.size(); + } + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The referencedEntryScopes at the given index. + */ + public java.lang.String getReferencedEntryScopes(int index) { + return referencedEntryScopes_.get(index); + } + + /** + * + * + *
        +       * Optional. Defines the scope of entries that can be referenced in the
        +       * entry links.
        +       *
        +       * Currently, projects are supported as valid scopes.
        +       * Format: `projects/{project_number_or_id}`
        +       *
        +       * If the metadata import file attempts to create an entry link
        +       * which references an entry that is not in the scope, the import job will
        +       * skip that entry link.
        +       * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the referencedEntryScopes at the given index. + */ + public com.google.protobuf.ByteString getReferencedEntryScopesBytes(int index) { + return referencedEntryScopes_.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 < entryGroups_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, entryGroups_.getRaw(i)); + } + for (int i = 0; i < entryTypes_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, entryTypes_.getRaw(i)); + } + for (int i = 0; i < aspectTypes_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, aspectTypes_.getRaw(i)); + } + for (int i = 0; i < glossaries_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 4, glossaries_.getRaw(i)); + } + for (int i = 0; i < entryLinkTypes_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 5, entryLinkTypes_.getRaw(i)); + } + for (int i = 0; i < referencedEntryScopes_.size(); i++) { + com.google.protobuf.GeneratedMessageV3.writeString( + output, 6, referencedEntryScopes_.getRaw(i)); + } + getUnknownFields().writeTo(output); + } @java.lang.Override public int getSerializedSize() { @@ -3827,6 +4802,30 @@ public int getSerializedSize() { size += dataSize; size += 1 * getAspectTypesList().size(); } + { + int dataSize = 0; + for (int i = 0; i < glossaries_.size(); i++) { + dataSize += computeStringSizeNoTag(glossaries_.getRaw(i)); + } + size += dataSize; + size += 1 * getGlossariesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < entryLinkTypes_.size(); i++) { + dataSize += computeStringSizeNoTag(entryLinkTypes_.getRaw(i)); + } + size += dataSize; + size += 1 * getEntryLinkTypesList().size(); + } + { + int dataSize = 0; + for (int i = 0; i < referencedEntryScopes_.size(); i++) { + dataSize += computeStringSizeNoTag(referencedEntryScopes_.getRaw(i)); + } + size += dataSize; + size += 1 * getReferencedEntryScopesList().size(); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -3847,6 +4846,10 @@ public boolean equals(final java.lang.Object obj) { if (!getEntryGroupsList().equals(other.getEntryGroupsList())) return false; if (!getEntryTypesList().equals(other.getEntryTypesList())) return false; if (!getAspectTypesList().equals(other.getAspectTypesList())) return false; + if (!getGlossariesList().equals(other.getGlossariesList())) return false; + if (!getEntryLinkTypesList().equals(other.getEntryLinkTypesList())) return false; + if (!getReferencedEntryScopesList().equals(other.getReferencedEntryScopesList())) + return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -3870,6 +4873,18 @@ public int hashCode() { hash = (37 * hash) + ASPECT_TYPES_FIELD_NUMBER; hash = (53 * hash) + getAspectTypesList().hashCode(); } + if (getGlossariesCount() > 0) { + hash = (37 * hash) + GLOSSARIES_FIELD_NUMBER; + hash = (53 * hash) + getGlossariesList().hashCode(); + } + if (getEntryLinkTypesCount() > 0) { + hash = (37 * hash) + ENTRY_LINK_TYPES_FIELD_NUMBER; + hash = (53 * hash) + getEntryLinkTypesList().hashCode(); + } + if (getReferencedEntryScopesCount() > 0) { + hash = (37 * hash) + REFERENCED_ENTRY_SCOPES_FIELD_NUMBER; + hash = (53 * hash) + getReferencedEntryScopesList().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -4020,6 +5035,9 @@ public Builder clear() { entryGroups_ = com.google.protobuf.LazyStringArrayList.emptyList(); entryTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); aspectTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + glossaries_ = com.google.protobuf.LazyStringArrayList.emptyList(); + entryLinkTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + referencedEntryScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); return this; } @@ -4073,6 +5091,18 @@ private void buildPartial0( aspectTypes_.makeImmutable(); result.aspectTypes_ = aspectTypes_; } + if (((from_bitField0_ & 0x00000008) != 0)) { + glossaries_.makeImmutable(); + result.glossaries_ = glossaries_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + entryLinkTypes_.makeImmutable(); + result.entryLinkTypes_ = entryLinkTypes_; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + referencedEntryScopes_.makeImmutable(); + result.referencedEntryScopes_ = referencedEntryScopes_; + } } @java.lang.Override @@ -4157,6 +5187,36 @@ public Builder mergeFrom( } onChanged(); } + if (!other.glossaries_.isEmpty()) { + if (glossaries_.isEmpty()) { + glossaries_ = other.glossaries_; + bitField0_ |= 0x00000008; + } else { + ensureGlossariesIsMutable(); + glossaries_.addAll(other.glossaries_); + } + onChanged(); + } + if (!other.entryLinkTypes_.isEmpty()) { + if (entryLinkTypes_.isEmpty()) { + entryLinkTypes_ = other.entryLinkTypes_; + bitField0_ |= 0x00000010; + } else { + ensureEntryLinkTypesIsMutable(); + entryLinkTypes_.addAll(other.entryLinkTypes_); + } + onChanged(); + } + if (!other.referencedEntryScopes_.isEmpty()) { + if (referencedEntryScopes_.isEmpty()) { + referencedEntryScopes_ = other.referencedEntryScopes_; + bitField0_ |= 0x00000020; + } else { + ensureReferencedEntryScopesIsMutable(); + referencedEntryScopes_.addAll(other.referencedEntryScopes_); + } + onChanged(); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -4204,6 +5264,27 @@ public Builder mergeFrom( aspectTypes_.add(s); break; } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureGlossariesIsMutable(); + glossaries_.add(s); + break; + } // case 34 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureEntryLinkTypesIsMutable(); + entryLinkTypes_.add(s); + break; + } // case 42 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureReferencedEntryScopesIsMutable(); + referencedEntryScopes_.add(s); + break; + } // case 50 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -5096,6 +6177,844 @@ public Builder addAspectTypesBytes(com.google.protobuf.ByteString value) { return this; } + private com.google.protobuf.LazyStringArrayList glossaries_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureGlossariesIsMutable() { + if (!glossaries_.isModifiable()) { + glossaries_ = new com.google.protobuf.LazyStringArrayList(glossaries_); + } + bitField0_ |= 0x00000008; + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return A list containing the glossaries. + */ + public com.google.protobuf.ProtocolStringList getGlossariesList() { + glossaries_.makeImmutable(); + return glossaries_; + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return The count of glossaries. + */ + public int getGlossariesCount() { + return glossaries_.size(); + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the element to return. + * @return The glossaries at the given index. + */ + public java.lang.String getGlossaries(int index) { + return glossaries_.get(index); + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index of the value to return. + * @return The bytes of the glossaries at the given index. + */ + public com.google.protobuf.ByteString getGlossariesBytes(int index) { + return glossaries_.getByteString(index); + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param index The index to set the value at. + * @param value The glossaries to set. + * @return This builder for chaining. + */ + public Builder setGlossaries(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureGlossariesIsMutable(); + glossaries_.set(index, value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The glossaries to add. + * @return This builder for chaining. + */ + public Builder addGlossaries(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureGlossariesIsMutable(); + glossaries_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param values The glossaries to add. + * @return This builder for chaining. + */ + public Builder addAllGlossaries(java.lang.Iterable values) { + ensureGlossariesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, glossaries_); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearGlossaries() { + glossaries_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000008); + ; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The glossaries that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`.
        +         *
        +         * While importing Business Glossary entries, the user must
        +         * provide glossaries. While importing entries, the user does not have to
        +         * provide glossaries. If the metadata import file attempts to modify
        +         * Business Glossary entries whose glossary isn't included in this list,
        +         * the import job will skip those entries.
        +         *
        +         * The location of a glossary must either match the location of the
        +         * job, or the glossary must be global.
        +         * 
        + * + * + * repeated string glossaries = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes of the glossaries to add. + * @return This builder for chaining. + */ + public Builder addGlossariesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureGlossariesIsMutable(); + glossaries_.add(value); + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList entryLinkTypes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureEntryLinkTypesIsMutable() { + if (!entryLinkTypes_.isModifiable()) { + entryLinkTypes_ = new com.google.protobuf.LazyStringArrayList(entryLinkTypes_); + } + bitField0_ |= 0x00000010; + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the entryLinkTypes. + */ + public com.google.protobuf.ProtocolStringList getEntryLinkTypesList() { + entryLinkTypes_.makeImmutable(); + return entryLinkTypes_; + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of entryLinkTypes. + */ + public int getEntryLinkTypesCount() { + return entryLinkTypes_.size(); + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The entryLinkTypes at the given index. + */ + public java.lang.String getEntryLinkTypes(int index) { + return entryLinkTypes_.get(index); + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the entryLinkTypes at the given index. + */ + public com.google.protobuf.ByteString getEntryLinkTypesBytes(int index) { + return entryLinkTypes_.getByteString(index); + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The entryLinkTypes to set. + * @return This builder for chaining. + */ + public Builder setEntryLinkTypes(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureEntryLinkTypesIsMutable(); + entryLinkTypes_.set(index, value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The entryLinkTypes to add. + * @return This builder for chaining. + */ + public Builder addEntryLinkTypes(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureEntryLinkTypesIsMutable(); + entryLinkTypes_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The entryLinkTypes to add. + * @return This builder for chaining. + */ + public Builder addAllEntryLinkTypes(java.lang.Iterable values) { + ensureEntryLinkTypesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, entryLinkTypes_); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearEntryLinkTypes() { + entryLinkTypes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000010); + ; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. The entry link types that are in scope for the import job,
        +         * specified as relative resource names in the format
        +         * `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`.
        +         * The job modifies only the entryLinks that belong to these entry link
        +         * types.
        +         *
        +         * If the metadata import file attempts to create or delete an entry link
        +         * whose entry link type isn't included in this list, the import job will
        +         * skip those entry links.
        +         * 
        + * + * repeated string entry_link_types = 5 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the entryLinkTypes to add. + * @return This builder for chaining. + */ + public Builder addEntryLinkTypesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureEntryLinkTypesIsMutable(); + entryLinkTypes_.add(value); + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + private com.google.protobuf.LazyStringArrayList referencedEntryScopes_ = + com.google.protobuf.LazyStringArrayList.emptyList(); + + private void ensureReferencedEntryScopesIsMutable() { + if (!referencedEntryScopes_.isModifiable()) { + referencedEntryScopes_ = + new com.google.protobuf.LazyStringArrayList(referencedEntryScopes_); + } + bitField0_ |= 0x00000020; + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return A list containing the referencedEntryScopes. + */ + public com.google.protobuf.ProtocolStringList getReferencedEntryScopesList() { + referencedEntryScopes_.makeImmutable(); + return referencedEntryScopes_; + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The count of referencedEntryScopes. + */ + public int getReferencedEntryScopesCount() { + return referencedEntryScopes_.size(); + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the element to return. + * @return The referencedEntryScopes at the given index. + */ + public java.lang.String getReferencedEntryScopes(int index) { + return referencedEntryScopes_.get(index); + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index of the value to return. + * @return The bytes of the referencedEntryScopes at the given index. + */ + public com.google.protobuf.ByteString getReferencedEntryScopesBytes(int index) { + return referencedEntryScopes_.getByteString(index); + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param index The index to set the value at. + * @param value The referencedEntryScopes to set. + * @return This builder for chaining. + */ + public Builder setReferencedEntryScopes(int index, java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedEntryScopesIsMutable(); + referencedEntryScopes_.set(index, value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The referencedEntryScopes to add. + * @return This builder for chaining. + */ + public Builder addReferencedEntryScopes(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + ensureReferencedEntryScopesIsMutable(); + referencedEntryScopes_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param values The referencedEntryScopes to add. + * @return This builder for chaining. + */ + public Builder addAllReferencedEntryScopes(java.lang.Iterable values) { + ensureReferencedEntryScopesIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, referencedEntryScopes_); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearReferencedEntryScopes() { + referencedEntryScopes_ = com.google.protobuf.LazyStringArrayList.emptyList(); + bitField0_ = (bitField0_ & ~0x00000020); + ; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Optional. Defines the scope of entries that can be referenced in the
        +         * entry links.
        +         *
        +         * Currently, projects are supported as valid scopes.
        +         * Format: `projects/{project_number_or_id}`
        +         *
        +         * If the metadata import file attempts to create an entry link
        +         * which references an entry that is not in the scope, the import job will
        +         * skip that entry link.
        +         * 
        + * + * + * repeated string referenced_entry_scopes = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The bytes of the referencedEntryScopes to add. + * @return This builder for chaining. + */ + public Builder addReferencedEntryScopesBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + ensureReferencedEntryScopesIsMutable(); + referencedEntryScopes_.add(value); + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { @@ -7175,9 +9094,9 @@ public interface ExportJobSpecOrBuilder * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. *
        @@ -7196,9 +9115,9 @@ public interface ExportJobSpecOrBuilder * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -9766,9 +11685,9 @@ public com.google.cloud.dataplex.v1.MetadataJob.ExportJobSpec.ExportJobScope get * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -9798,9 +11717,9 @@ public java.lang.String getOutputPath() { * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -10445,9 +12364,9 @@ public Builder clearScope() { * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -10476,9 +12395,9 @@ public java.lang.String getOutputPath() { * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -10507,9 +12426,9 @@ public com.google.protobuf.ByteString getOutputPathBytes() { * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -10537,9 +12456,9 @@ public Builder setOutputPath(java.lang.String value) { * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * @@ -10563,9 +12482,9 @@ public Builder clearOutputPath() { * metadata to, in the format `gs://{bucket}/`. You can optionally specify a * custom prefix after the bucket name, in the format * `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - * characters. Dataplex constructs the object path for the exported files by - * using the bucket name and prefix that you provide, followed by a - * system-generated path. + * characters. Dataplex Universal Catalog constructs the object path for the + * exported files by using the bucket name and prefix that you provide, + * followed by a system-generated path. * * The bucket must be in the same VPC Service Controls perimeter as the job. * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ProcessingProto.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ProcessingProto.java index ff239f7d8c17..56e7012a2759 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ProcessingProto.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ProcessingProto.java @@ -76,17 +76,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006entity\030d \001(\tB&\340A\005\372A \n" + "\036dataplex.googleapis.com/EntityH\000\022\027\n" + "\010resource\030e \001(\tB\003\340A\005H\000B\010\n" - + "\006source\"\257\001\n" + + "\006source\"\276\001\n" + "\013ScannedData\022S\n" + "\021incremental_field\030\001 \001(\01326.google" - + ".cloud.dataplex.v1.ScannedData.IncrementalFieldH\000\032=\n" - + "\020IncrementalField\022\r\n" - + "\005field\030\001 \001(\t\022\r\n" - + "\005start\030\002 \001(\t\022\013\n" - + "\003end\030\003 \001(\tB\014\n\n" + + ".cloud.dataplex.v1.ScannedData.IncrementalFieldH\000\032L\n" + + "\020IncrementalField\022\022\n" + + "\005field\030\001 \001(\tB\003\340A\003\022\022\n" + + "\005start\030\002 \001(\tB\003\340A\003\022\020\n" + + "\003end\030\003 \001(\tB\003\340A\003B\014\n\n" + "data_rangeBk\n" - + "\034com.google.cloud.dataplex.v1B\017ProcessingProtoP\001Z8cloud.google.com/go/d" - + "ataplex/apiv1/dataplexpb;dataplexpbb\006proto3" + + "\034com.google.cloud.dataplex.v1B\017ProcessingProtoP\001Z8cloud." + + "google.com/go/dataplex/apiv1/dataplexpb;dataplexpbb\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequest.java index 7f72c1f0a8fe..70302ddd2833 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequest.java @@ -76,7 +76,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -107,7 +107,7 @@ public java.lang.String getName() { * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -483,7 +483,7 @@ public Builder mergeFrom( * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -513,7 +513,7 @@ public java.lang.String getName() { * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -543,7 +543,7 @@ public com.google.protobuf.ByteString getNameBytes() { * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -572,7 +572,7 @@ public Builder setName(java.lang.String value) { * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -597,7 +597,7 @@ public Builder clearName() { * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequestOrBuilder.java index 356e5fcf26f0..a98eea9d6a82 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/RunDataScanRequestOrBuilder.java @@ -31,7 +31,7 @@ public interface RunDataScanRequestOrBuilder * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * @@ -51,7 +51,7 @@ public interface RunDataScanRequestOrBuilder * Required. The resource name of the DataScan: * `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. * where `project` refers to a *project_id* or *project_number* and - * `location_id` refers to a GCP region. + * `location_id` refers to a Google Cloud region. * * Only **OnDemand** data scans are allowed. * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ScannedData.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ScannedData.java index 513f7e3d7c0b..f52da623dd10 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ScannedData.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/ScannedData.java @@ -71,11 +71,11 @@ public interface IncrementalFieldOrBuilder * * *
        -     * The field that contains values which monotonically increases over time
        -     * (e.g. a timestamp column).
        +     * Output only. The field that contains values which monotonically increases
        +     * over time (e.g. a timestamp column).
              * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The field. */ @@ -85,11 +85,11 @@ public interface IncrementalFieldOrBuilder * * *
        -     * The field that contains values which monotonically increases over time
        -     * (e.g. a timestamp column).
        +     * Output only. The field that contains values which monotonically increases
        +     * over time (e.g. a timestamp column).
              * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for field. */ @@ -99,10 +99,10 @@ public interface IncrementalFieldOrBuilder * * *
        -     * Value that marks the start of the range.
        +     * Output only. Value that marks the start of the range.
              * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The start. */ @@ -112,10 +112,10 @@ public interface IncrementalFieldOrBuilder * * *
        -     * Value that marks the start of the range.
        +     * Output only. Value that marks the start of the range.
              * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for start. */ @@ -125,10 +125,10 @@ public interface IncrementalFieldOrBuilder * * *
        -     * Value that marks the end of the range.
        +     * Output only. Value that marks the end of the range.
              * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The end. */ @@ -138,10 +138,10 @@ public interface IncrementalFieldOrBuilder * * *
        -     * Value that marks the end of the range.
        +     * Output only. Value that marks the end of the range.
              * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for end. */ @@ -204,11 +204,11 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * * *
        -     * The field that contains values which monotonically increases over time
        -     * (e.g. a timestamp column).
        +     * Output only. The field that contains values which monotonically increases
        +     * over time (e.g. a timestamp column).
              * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The field. */ @@ -229,11 +229,11 @@ public java.lang.String getField() { * * *
        -     * The field that contains values which monotonically increases over time
        -     * (e.g. a timestamp column).
        +     * Output only. The field that contains values which monotonically increases
        +     * over time (e.g. a timestamp column).
              * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for field. */ @@ -259,10 +259,10 @@ public com.google.protobuf.ByteString getFieldBytes() { * * *
        -     * Value that marks the start of the range.
        +     * Output only. Value that marks the start of the range.
              * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The start. */ @@ -283,10 +283,10 @@ public java.lang.String getStart() { * * *
        -     * Value that marks the start of the range.
        +     * Output only. Value that marks the start of the range.
              * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for start. */ @@ -312,10 +312,10 @@ public com.google.protobuf.ByteString getStartBytes() { * * *
        -     * Value that marks the end of the range.
        +     * Output only. Value that marks the end of the range.
              * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The end. */ @@ -336,10 +336,10 @@ public java.lang.String getEnd() { * * *
        -     * Value that marks the end of the range.
        +     * Output only. Value that marks the end of the range.
              * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for end. */ @@ -758,11 +758,11 @@ public Builder mergeFrom( * * *
        -       * The field that contains values which monotonically increases over time
        -       * (e.g. a timestamp column).
        +       * Output only. The field that contains values which monotonically increases
        +       * over time (e.g. a timestamp column).
                * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The field. */ @@ -782,11 +782,11 @@ public java.lang.String getField() { * * *
        -       * The field that contains values which monotonically increases over time
        -       * (e.g. a timestamp column).
        +       * Output only. The field that contains values which monotonically increases
        +       * over time (e.g. a timestamp column).
                * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for field. */ @@ -806,11 +806,11 @@ public com.google.protobuf.ByteString getFieldBytes() { * * *
        -       * The field that contains values which monotonically increases over time
        -       * (e.g. a timestamp column).
        +       * Output only. The field that contains values which monotonically increases
        +       * over time (e.g. a timestamp column).
                * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The field to set. * @return This builder for chaining. @@ -829,11 +829,11 @@ public Builder setField(java.lang.String value) { * * *
        -       * The field that contains values which monotonically increases over time
        -       * (e.g. a timestamp column).
        +       * Output only. The field that contains values which monotonically increases
        +       * over time (e.g. a timestamp column).
                * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -848,11 +848,11 @@ public Builder clearField() { * * *
        -       * The field that contains values which monotonically increases over time
        -       * (e.g. a timestamp column).
        +       * Output only. The field that contains values which monotonically increases
        +       * over time (e.g. a timestamp column).
                * 
        * - * string field = 1; + * string field = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for field to set. * @return This builder for chaining. @@ -874,10 +874,10 @@ public Builder setFieldBytes(com.google.protobuf.ByteString value) { * * *
        -       * Value that marks the start of the range.
        +       * Output only. Value that marks the start of the range.
                * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The start. */ @@ -897,10 +897,10 @@ public java.lang.String getStart() { * * *
        -       * Value that marks the start of the range.
        +       * Output only. Value that marks the start of the range.
                * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for start. */ @@ -920,10 +920,10 @@ public com.google.protobuf.ByteString getStartBytes() { * * *
        -       * Value that marks the start of the range.
        +       * Output only. Value that marks the start of the range.
                * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The start to set. * @return This builder for chaining. @@ -942,10 +942,10 @@ public Builder setStart(java.lang.String value) { * * *
        -       * Value that marks the start of the range.
        +       * Output only. Value that marks the start of the range.
                * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -960,10 +960,10 @@ public Builder clearStart() { * * *
        -       * Value that marks the start of the range.
        +       * Output only. Value that marks the start of the range.
                * 
        * - * string start = 2; + * string start = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for start to set. * @return This builder for chaining. @@ -985,10 +985,10 @@ public Builder setStartBytes(com.google.protobuf.ByteString value) { * * *
        -       * Value that marks the end of the range.
        +       * Output only. Value that marks the end of the range.
                * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The end. */ @@ -1008,10 +1008,10 @@ public java.lang.String getEnd() { * * *
        -       * Value that marks the end of the range.
        +       * Output only. Value that marks the end of the range.
                * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return The bytes for end. */ @@ -1031,10 +1031,10 @@ public com.google.protobuf.ByteString getEndBytes() { * * *
        -       * Value that marks the end of the range.
        +       * Output only. Value that marks the end of the range.
                * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The end to set. * @return This builder for chaining. @@ -1053,10 +1053,10 @@ public Builder setEnd(java.lang.String value) { * * *
        -       * Value that marks the end of the range.
        +       * Output only. Value that marks the end of the range.
                * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @return This builder for chaining. */ @@ -1071,10 +1071,10 @@ public Builder clearEnd() { * * *
        -       * Value that marks the end of the range.
        +       * Output only. Value that marks the end of the range.
                * 
        * - * string end = 3; + * string end = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; * * @param value The bytes for end to set. * @return This builder for chaining. diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Schema.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Schema.java index 1f290d4fe55a..b8496cf778ec 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Schema.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/Schema.java @@ -3654,18 +3654,20 @@ public com.google.cloud.dataplex.v1.Schema.PartitionField getDefaultInstanceForT * * *
        -   * Required. Set to `true` if user-managed or `false` if managed by Dataplex.
        -   * The default is `false` (managed by Dataplex).
        +   * Required. Set to `true` if user-managed or `false` if managed by Dataplex
        +   * Universal Catalog. The default is `false` (managed by Dataplex Universal
        +   * Catalog).
            *
        -   * - Set to `false`to enable Dataplex discovery to update the schema.
        +   * - Set to `false`to enable Dataplex Universal Catalog discovery to update
        +   * the schema.
            *   including new data discovery, schema inference, and schema evolution.
        -   *   Users retain the ability to input and edit the schema. Dataplex
        -   *   treats schema input by the user as though produced
        -   *   by a previous Dataplex discovery operation, and it will
        -   *   evolve the schema and take action based on that treatment.
        +   *   Users retain the ability to input and edit the schema. Dataplex Universal
        +   *   Catalog treats schema input by the user as though produced by a previous
        +   *   Dataplex Universal Catalog discovery operation, and it will evolve the
        +   *   schema and take action based on that treatment.
            *
            * - Set to `true` to fully manage the entity
        -   *   schema. This setting guarantees that Dataplex will not
        +   *   schema. This setting guarantees that Dataplex Universal Catalog will not
            *   change schema fields.
            * 
        * @@ -4416,18 +4418,20 @@ public Builder mergeFrom( * * *
        -     * Required. Set to `true` if user-managed or `false` if managed by Dataplex.
        -     * The default is `false` (managed by Dataplex).
        +     * Required. Set to `true` if user-managed or `false` if managed by Dataplex
        +     * Universal Catalog. The default is `false` (managed by Dataplex Universal
        +     * Catalog).
              *
        -     * - Set to `false`to enable Dataplex discovery to update the schema.
        +     * - Set to `false`to enable Dataplex Universal Catalog discovery to update
        +     * the schema.
              *   including new data discovery, schema inference, and schema evolution.
        -     *   Users retain the ability to input and edit the schema. Dataplex
        -     *   treats schema input by the user as though produced
        -     *   by a previous Dataplex discovery operation, and it will
        -     *   evolve the schema and take action based on that treatment.
        +     *   Users retain the ability to input and edit the schema. Dataplex Universal
        +     *   Catalog treats schema input by the user as though produced by a previous
        +     *   Dataplex Universal Catalog discovery operation, and it will evolve the
        +     *   schema and take action based on that treatment.
              *
              * - Set to `true` to fully manage the entity
        -     *   schema. This setting guarantees that Dataplex will not
        +     *   schema. This setting guarantees that Dataplex Universal Catalog will not
              *   change schema fields.
              * 
        * @@ -4444,18 +4448,20 @@ public boolean getUserManaged() { * * *
        -     * Required. Set to `true` if user-managed or `false` if managed by Dataplex.
        -     * The default is `false` (managed by Dataplex).
        +     * Required. Set to `true` if user-managed or `false` if managed by Dataplex
        +     * Universal Catalog. The default is `false` (managed by Dataplex Universal
        +     * Catalog).
              *
        -     * - Set to `false`to enable Dataplex discovery to update the schema.
        +     * - Set to `false`to enable Dataplex Universal Catalog discovery to update
        +     * the schema.
              *   including new data discovery, schema inference, and schema evolution.
        -     *   Users retain the ability to input and edit the schema. Dataplex
        -     *   treats schema input by the user as though produced
        -     *   by a previous Dataplex discovery operation, and it will
        -     *   evolve the schema and take action based on that treatment.
        +     *   Users retain the ability to input and edit the schema. Dataplex Universal
        +     *   Catalog treats schema input by the user as though produced by a previous
        +     *   Dataplex Universal Catalog discovery operation, and it will evolve the
        +     *   schema and take action based on that treatment.
              *
              * - Set to `true` to fully manage the entity
        -     *   schema. This setting guarantees that Dataplex will not
        +     *   schema. This setting guarantees that Dataplex Universal Catalog will not
              *   change schema fields.
              * 
        * @@ -4476,18 +4482,20 @@ public Builder setUserManaged(boolean value) { * * *
        -     * Required. Set to `true` if user-managed or `false` if managed by Dataplex.
        -     * The default is `false` (managed by Dataplex).
        +     * Required. Set to `true` if user-managed or `false` if managed by Dataplex
        +     * Universal Catalog. The default is `false` (managed by Dataplex Universal
        +     * Catalog).
              *
        -     * - Set to `false`to enable Dataplex discovery to update the schema.
        +     * - Set to `false`to enable Dataplex Universal Catalog discovery to update
        +     * the schema.
              *   including new data discovery, schema inference, and schema evolution.
        -     *   Users retain the ability to input and edit the schema. Dataplex
        -     *   treats schema input by the user as though produced
        -     *   by a previous Dataplex discovery operation, and it will
        -     *   evolve the schema and take action based on that treatment.
        +     *   Users retain the ability to input and edit the schema. Dataplex Universal
        +     *   Catalog treats schema input by the user as though produced by a previous
        +     *   Dataplex Universal Catalog discovery operation, and it will evolve the
        +     *   schema and take action based on that treatment.
              *
              * - Set to `true` to fully manage the entity
        -     *   schema. This setting guarantees that Dataplex will not
        +     *   schema. This setting guarantees that Dataplex Universal Catalog will not
              *   change schema fields.
              * 
        * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SchemaOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SchemaOrBuilder.java index 61609e9303ef..90e0c0b5937c 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SchemaOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SchemaOrBuilder.java @@ -28,18 +28,20 @@ public interface SchemaOrBuilder * * *
        -   * Required. Set to `true` if user-managed or `false` if managed by Dataplex.
        -   * The default is `false` (managed by Dataplex).
        +   * Required. Set to `true` if user-managed or `false` if managed by Dataplex
        +   * Universal Catalog. The default is `false` (managed by Dataplex Universal
        +   * Catalog).
            *
        -   * - Set to `false`to enable Dataplex discovery to update the schema.
        +   * - Set to `false`to enable Dataplex Universal Catalog discovery to update
        +   * the schema.
            *   including new data discovery, schema inference, and schema evolution.
        -   *   Users retain the ability to input and edit the schema. Dataplex
        -   *   treats schema input by the user as though produced
        -   *   by a previous Dataplex discovery operation, and it will
        -   *   evolve the schema and take action based on that treatment.
        +   *   Users retain the ability to input and edit the schema. Dataplex Universal
        +   *   Catalog treats schema input by the user as though produced by a previous
        +   *   Dataplex Universal Catalog discovery operation, and it will evolve the
        +   *   schema and take action based on that treatment.
            *
            * - Set to `true` to fully manage the entity
        -   *   schema. This setting guarantees that Dataplex will not
        +   *   schema. This setting guarantees that Dataplex Universal Catalog will not
            *   change schema fields.
            * 
        * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequest.java index dda4779fe264..55f1f12f1de8 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequest.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequest.java @@ -70,7 +70,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * *
            * Required. The project to which the request should be attributed in the
        -   * following form: `projects/{project}/locations/{location}`.
        +   * following form: `projects/{project}/locations/global`.
            * 
        * * @@ -97,7 +97,7 @@ public java.lang.String getName() { * *
            * Required. The project to which the request should be attributed in the
        -   * following form: `projects/{project}/locations/{location}`.
        +   * following form: `projects/{project}/locations/global`.
            * 
        * * @@ -129,7 +129,7 @@ public com.google.protobuf.ByteString getNameBytes() { * *
            * Required. The query against which entries in scope should be matched.
        -   * The query syntax is defined in [Search syntax for Dataplex
        +   * The query syntax is defined in [Search syntax for Dataplex Universal
            * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
            * 
        * @@ -155,7 +155,7 @@ public java.lang.String getQuery() { * *
            * Required. The query against which entries in scope should be matched.
        -   * The query syntax is defined in [Search syntax for Dataplex
        +   * The query syntax is defined in [Search syntax for Dataplex Universal
            * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
            * 
        * @@ -264,7 +264,7 @@ public com.google.protobuf.ByteString getPageTokenBytes() { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -293,7 +293,7 @@ public java.lang.String getOrderBy() { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -876,7 +876,7 @@ public Builder mergeFrom( * *
              * Required. The project to which the request should be attributed in the
        -     * following form: `projects/{project}/locations/{location}`.
        +     * following form: `projects/{project}/locations/global`.
              * 
        * * @@ -902,7 +902,7 @@ public java.lang.String getName() { * *
              * Required. The project to which the request should be attributed in the
        -     * following form: `projects/{project}/locations/{location}`.
        +     * following form: `projects/{project}/locations/global`.
              * 
        * * @@ -928,7 +928,7 @@ public com.google.protobuf.ByteString getNameBytes() { * *
              * Required. The project to which the request should be attributed in the
        -     * following form: `projects/{project}/locations/{location}`.
        +     * following form: `projects/{project}/locations/global`.
              * 
        * * @@ -953,7 +953,7 @@ public Builder setName(java.lang.String value) { * *
              * Required. The project to which the request should be attributed in the
        -     * following form: `projects/{project}/locations/{location}`.
        +     * following form: `projects/{project}/locations/global`.
              * 
        * * @@ -974,7 +974,7 @@ public Builder clearName() { * *
              * Required. The project to which the request should be attributed in the
        -     * following form: `projects/{project}/locations/{location}`.
        +     * following form: `projects/{project}/locations/global`.
              * 
        * * @@ -1002,7 +1002,7 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * *
              * Required. The query against which entries in scope should be matched.
        -     * The query syntax is defined in [Search syntax for Dataplex
        +     * The query syntax is defined in [Search syntax for Dataplex Universal
              * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
              * 
        * @@ -1027,7 +1027,7 @@ public java.lang.String getQuery() { * *
              * Required. The query against which entries in scope should be matched.
        -     * The query syntax is defined in [Search syntax for Dataplex
        +     * The query syntax is defined in [Search syntax for Dataplex Universal
              * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
              * 
        * @@ -1052,7 +1052,7 @@ public com.google.protobuf.ByteString getQueryBytes() { * *
              * Required. The query against which entries in scope should be matched.
        -     * The query syntax is defined in [Search syntax for Dataplex
        +     * The query syntax is defined in [Search syntax for Dataplex Universal
              * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
              * 
        * @@ -1076,7 +1076,7 @@ public Builder setQuery(java.lang.String value) { * *
              * Required. The query against which entries in scope should be matched.
        -     * The query syntax is defined in [Search syntax for Dataplex
        +     * The query syntax is defined in [Search syntax for Dataplex Universal
              * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
              * 
        * @@ -1096,7 +1096,7 @@ public Builder clearQuery() { * *
              * Required. The query against which entries in scope should be matched.
        -     * The query syntax is defined in [Search syntax for Dataplex
        +     * The query syntax is defined in [Search syntax for Dataplex Universal
              * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
              * 
        * @@ -1303,7 +1303,7 @@ public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -1331,7 +1331,7 @@ public java.lang.String getOrderBy() { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -1359,7 +1359,7 @@ public com.google.protobuf.ByteString getOrderByBytes() { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -1386,7 +1386,7 @@ public Builder setOrderBy(java.lang.String value) { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -1409,7 +1409,7 @@ public Builder clearOrderBy() { * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequestOrBuilder.java index b3de51516464..b72a326c79e5 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequestOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesRequestOrBuilder.java @@ -29,7 +29,7 @@ public interface SearchEntriesRequestOrBuilder * *
            * Required. The project to which the request should be attributed in the
        -   * following form: `projects/{project}/locations/{location}`.
        +   * following form: `projects/{project}/locations/global`.
            * 
        * * @@ -45,7 +45,7 @@ public interface SearchEntriesRequestOrBuilder * *
            * Required. The project to which the request should be attributed in the
        -   * following form: `projects/{project}/locations/{location}`.
        +   * following form: `projects/{project}/locations/global`.
            * 
        * * @@ -61,7 +61,7 @@ public interface SearchEntriesRequestOrBuilder * *
            * Required. The query against which entries in scope should be matched.
        -   * The query syntax is defined in [Search syntax for Dataplex
        +   * The query syntax is defined in [Search syntax for Dataplex Universal
            * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
            * 
        * @@ -76,7 +76,7 @@ public interface SearchEntriesRequestOrBuilder * *
            * Required. The query against which entries in scope should be matched.
        -   * The query syntax is defined in [Search syntax for Dataplex
        +   * The query syntax is defined in [Search syntax for Dataplex Universal
            * Catalog](https://cloud.google.com/dataplex/docs/search-syntax).
            * 
        * @@ -136,7 +136,7 @@ public interface SearchEntriesRequestOrBuilder * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * @@ -154,7 +154,7 @@ public interface SearchEntriesRequestOrBuilder * Optional. Specifies the ordering of results. * Supported values are: * - * * `relevance` (default) + * * `relevance` * * `last_modified_timestamp` * * `last_modified_timestamp asc` * diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResult.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResult.java index 47554b029b2d..0b776c856f4d 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResult.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResult.java @@ -80,7 +80,7 @@ public interface SnippetsOrBuilder * .google.cloud.dataplex.v1.Entry dataplex_entry = 1 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.Snippets.dataplex_entry is - * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1389 + * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1418 * @return Whether the dataplexEntry field is set. */ @java.lang.Deprecated @@ -96,7 +96,7 @@ public interface SnippetsOrBuilder * .google.cloud.dataplex.v1.Entry dataplex_entry = 1 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.Snippets.dataplex_entry is - * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1389 + * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1418 * @return The dataplexEntry. */ @java.lang.Deprecated @@ -174,7 +174,7 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * .google.cloud.dataplex.v1.Entry dataplex_entry = 1 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.Snippets.dataplex_entry is - * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1389 + * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1418 * @return Whether the dataplexEntry field is set. */ @java.lang.Override @@ -193,7 +193,7 @@ public boolean hasDataplexEntry() { * .google.cloud.dataplex.v1.Entry dataplex_entry = 1 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.Snippets.dataplex_entry is - * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1389 + * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1418 * @return The dataplexEntry. */ @java.lang.Override @@ -607,7 +607,7 @@ public Builder mergeFrom( * .google.cloud.dataplex.v1.Entry dataplex_entry = 1 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.Snippets.dataplex_entry is - * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1389 + * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1418 * @return Whether the dataplexEntry field is set. */ @java.lang.Deprecated @@ -625,7 +625,7 @@ public boolean hasDataplexEntry() { * .google.cloud.dataplex.v1.Entry dataplex_entry = 1 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.Snippets.dataplex_entry is - * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1389 + * deprecated. See google/cloud/dataplex/v1/catalog.proto;l=1418 * @return The dataplexEntry. */ @java.lang.Deprecated @@ -876,7 +876,7 @@ public com.google.cloud.dataplex.v1.SearchEntriesResult.Snippets getDefaultInsta * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return The linkedResource. */ @java.lang.Override @@ -903,7 +903,7 @@ public java.lang.String getLinkedResource() { * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return The bytes for linkedResource. */ @java.lang.Override @@ -967,7 +967,7 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getDataplexEntryOrBuilder() { *
        * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.snippets is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1398 + * google/cloud/dataplex/v1/catalog.proto;l=1427 * @return Whether the snippets field is set. */ @java.lang.Override @@ -987,7 +987,7 @@ public boolean hasSnippets() { *
        * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.snippets is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1398 + * google/cloud/dataplex/v1/catalog.proto;l=1427 * @return The snippets. */ @java.lang.Override @@ -1448,7 +1448,7 @@ public Builder mergeFrom( * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return The linkedResource. */ @java.lang.Deprecated @@ -1474,7 +1474,7 @@ public java.lang.String getLinkedResource() { * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return The bytes for linkedResource. */ @java.lang.Deprecated @@ -1500,7 +1500,7 @@ public com.google.protobuf.ByteString getLinkedResourceBytes() { * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @param value The linkedResource to set. * @return This builder for chaining. */ @@ -1525,7 +1525,7 @@ public Builder setLinkedResource(java.lang.String value) { * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return This builder for chaining. */ @java.lang.Deprecated @@ -1546,7 +1546,7 @@ public Builder clearLinkedResource() { * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @param value The bytes for linkedResource to set. * @return This builder for chaining. */ @@ -1707,7 +1707,7 @@ public com.google.cloud.dataplex.v1.EntryOrBuilder getDataplexEntryOrBuilder() { *
        * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.snippets is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1398 + * google/cloud/dataplex/v1/catalog.proto;l=1427 * @return Whether the snippets field is set. */ @java.lang.Deprecated @@ -1727,7 +1727,7 @@ public boolean hasSnippets() { *
        * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.snippets is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1398 + * google/cloud/dataplex/v1/catalog.proto;l=1427 * @return The snippets. */ @java.lang.Deprecated diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResultOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResultOrBuilder.java index 2346873fa5ee..ae8f93093e0b 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResultOrBuilder.java +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/SearchEntriesResultOrBuilder.java @@ -34,7 +34,7 @@ public interface SearchEntriesResultOrBuilder * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return The linkedResource. */ @java.lang.Deprecated @@ -50,7 +50,7 @@ public interface SearchEntriesResultOrBuilder * string linked_resource = 8 [deprecated = true]; * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.linked_resource is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1393 + * google/cloud/dataplex/v1/catalog.proto;l=1422 * @return The bytes for linkedResource. */ @java.lang.Deprecated @@ -84,7 +84,7 @@ public interface SearchEntriesResultOrBuilder *
        * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.snippets is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1398 + * google/cloud/dataplex/v1/catalog.proto;l=1427 * @return Whether the snippets field is set. */ @java.lang.Deprecated @@ -101,7 +101,7 @@ public interface SearchEntriesResultOrBuilder *
        * * @deprecated google.cloud.dataplex.v1.SearchEntriesResult.snippets is deprecated. See - * google/cloud/dataplex/v1/catalog.proto;l=1398 + * google/cloud/dataplex/v1/catalog.proto;l=1427 * @return The snippets. */ @java.lang.Deprecated diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryCategoryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryCategoryRequest.java new file mode 100644 index 000000000000..b0ad0dc53a4e --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryCategoryRequest.java @@ -0,0 +1,1085 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Update GlossaryCategory Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest} + */ +public final class UpdateGlossaryCategoryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) + UpdateGlossaryCategoryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use UpdateGlossaryCategoryRequest.newBuilder() to construct. + private UpdateGlossaryCategoryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateGlossaryCategoryRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateGlossaryCategoryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.Builder.class); + } + + private int bitField0_; + public static final int CATEGORY_FIELD_NUMBER = 1; + private com.google.cloud.dataplex.v1.GlossaryCategory category_; + + /** + * + * + *
        +   * Required. The GlossaryCategory to update.
        +   * The GlossaryCategory's `name` field is used to identify the
        +   * GlossaryCategory to update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the category field is set. + */ + @java.lang.Override + public boolean hasCategory() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. The GlossaryCategory to update.
        +   * The GlossaryCategory's `name` field is used to identify the
        +   * GlossaryCategory to update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The category. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategory getCategory() { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } + + /** + * + * + *
        +   * Required. The GlossaryCategory to update.
        +   * The GlossaryCategory's `name` field is used to identify the
        +   * GlossaryCategory to update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoryOrBuilder() { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } + + 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, getCategory()); + } + 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, getCategory()); + } + 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.dataplex.v1.UpdateGlossaryCategoryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest other = + (com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) obj; + + if (hasCategory() != other.hasCategory()) return false; + if (hasCategory()) { + if (!getCategory().equals(other.getCategory())) 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 (hasCategory()) { + hash = (37 * hash) + CATEGORY_FIELD_NUMBER; + hash = (53 * hash) + getCategory().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.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest 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.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest 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.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.UpdateGlossaryCategoryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Update GlossaryCategory Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.class, + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCategoryFieldBuilder(); + getUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + category_ = null; + if (categoryBuilder_ != null) { + categoryBuilder_.dispose(); + categoryBuilder_ = 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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryCategoryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest build() { + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest buildPartial() { + com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest result = + new com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.category_ = categoryBuilder_ == null ? category_ : categoryBuilder_.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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest other) { + if (other == com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest.getDefaultInstance()) + return this; + if (other.hasCategory()) { + mergeCategory(other.getCategory()); + } + 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(getCategoryFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().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.dataplex.v1.GlossaryCategory category_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder> + categoryBuilder_; + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the category field is set. + */ + public boolean hasCategory() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The category. + */ + public com.google.cloud.dataplex.v1.GlossaryCategory getCategory() { + if (categoryBuilder_ == null) { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } else { + return categoryBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setCategory(com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + category_ = value; + } else { + categoryBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setCategory( + com.google.cloud.dataplex.v1.GlossaryCategory.Builder builderForValue) { + if (categoryBuilder_ == null) { + category_ = builderForValue.build(); + } else { + categoryBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeCategory(com.google.cloud.dataplex.v1.GlossaryCategory value) { + if (categoryBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && category_ != null + && category_ != com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance()) { + getCategoryBuilder().mergeFrom(value); + } else { + category_ = value; + } + } else { + categoryBuilder_.mergeFrom(value); + } + if (category_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearCategory() { + bitField0_ = (bitField0_ & ~0x00000001); + category_ = null; + if (categoryBuilder_ != null) { + categoryBuilder_.dispose(); + categoryBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryCategory.Builder getCategoryBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return getCategoryFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoryOrBuilder() { + if (categoryBuilder_ != null) { + return categoryBuilder_.getMessageOrBuilder(); + } else { + return category_ == null + ? com.google.cloud.dataplex.v1.GlossaryCategory.getDefaultInstance() + : category_; + } + } + + /** + * + * + *
        +     * Required. The GlossaryCategory to update.
        +     * The GlossaryCategory's `name` field is used to identify the
        +     * GlossaryCategory to update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder> + getCategoryFieldBuilder() { + if (categoryBuilder_ == null) { + categoryBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryCategory, + com.google.cloud.dataplex.v1.GlossaryCategory.Builder, + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder>( + getCategory(), getParentForChildren(), isClean()); + category_ = null; + } + return categoryBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + 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 getUpdateMaskFieldBuilder().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.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) + private static final com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest(); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateGlossaryCategoryRequest 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.dataplex.v1.UpdateGlossaryCategoryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryCategoryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryCategoryRequestOrBuilder.java new file mode 100644 index 000000000000..11efa65e02a6 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryCategoryRequestOrBuilder.java @@ -0,0 +1,118 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface UpdateGlossaryCategoryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The GlossaryCategory to update.
        +   * The GlossaryCategory's `name` field is used to identify the
        +   * GlossaryCategory to update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the category field is set. + */ + boolean hasCategory(); + + /** + * + * + *
        +   * Required. The GlossaryCategory to update.
        +   * The GlossaryCategory's `name` field is used to identify the
        +   * GlossaryCategory to update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The category. + */ + com.google.cloud.dataplex.v1.GlossaryCategory getCategory(); + + /** + * + * + *
        +   * Required. The GlossaryCategory to update.
        +   * The GlossaryCategory's `name` field is used to identify the
        +   * GlossaryCategory to update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryCategory category = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.GlossaryCategoryOrBuilder getCategoryOrBuilder(); + + /** + * + * + *
        +   * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryRequest.java new file mode 100644 index 000000000000..51722a306fcd --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryRequest.java @@ -0,0 +1,1184 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Update Glossary Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.UpdateGlossaryRequest} + */ +public final class UpdateGlossaryRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.UpdateGlossaryRequest) + UpdateGlossaryRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use UpdateGlossaryRequest.newBuilder() to construct. + private UpdateGlossaryRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateGlossaryRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateGlossaryRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest.class, + com.google.cloud.dataplex.v1.UpdateGlossaryRequest.Builder.class); + } + + private int bitField0_; + public static final int GLOSSARY_FIELD_NUMBER = 1; + private com.google.cloud.dataplex.v1.Glossary glossary_; + + /** + * + * + *
        +   * Required. The Glossary to update.
        +   * The Glossary's `name` field is used to identify the Glossary to update.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the glossary field is set. + */ + @java.lang.Override + public boolean hasGlossary() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. The Glossary to update.
        +   * The Glossary's `name` field is used to identify the Glossary to update.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The glossary. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.Glossary getGlossary() { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } + + /** + * + * + *
        +   * Required. The Glossary to update.
        +   * The Glossary's `name` field is used to identify the Glossary to update.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossaryOrBuilder() { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } + + 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_; + } + + public static final int VALIDATE_ONLY_FIELD_NUMBER = 3; + private boolean validateOnly_ = false; + + /** + * + * + *
        +   * Optional. Validates the request without actually updating the Glossary.
        +   * Default: false.
        +   * 
        + * + * bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + 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, getGlossary()); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeMessage(2, getUpdateMask()); + } + if (validateOnly_ != false) { + output.writeBool(3, validateOnly_); + } + 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, getGlossary()); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + if (validateOnly_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, validateOnly_); + } + 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.dataplex.v1.UpdateGlossaryRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.UpdateGlossaryRequest other = + (com.google.cloud.dataplex.v1.UpdateGlossaryRequest) obj; + + if (hasGlossary() != other.hasGlossary()) return false; + if (hasGlossary()) { + if (!getGlossary().equals(other.getGlossary())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (getValidateOnly() != other.getValidateOnly()) 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 (hasGlossary()) { + hash = (37 * hash) + GLOSSARY_FIELD_NUMBER; + hash = (53 * hash) + getGlossary().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest 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.dataplex.v1.UpdateGlossaryRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest 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.dataplex.v1.UpdateGlossaryRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.UpdateGlossaryRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Update Glossary Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.UpdateGlossaryRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.UpdateGlossaryRequest) + com.google.cloud.dataplex.v1.UpdateGlossaryRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.UpdateGlossaryRequest.class, + com.google.cloud.dataplex.v1.UpdateGlossaryRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.UpdateGlossaryRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getGlossaryFieldBuilder(); + getUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + glossary_ = null; + if (glossaryBuilder_ != null) { + glossaryBuilder_.dispose(); + glossaryBuilder_ = null; + } + updateMask_ = null; + if (updateMaskBuilder_ != null) { + updateMaskBuilder_.dispose(); + updateMaskBuilder_ = null; + } + validateOnly_ = false; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.UpdateGlossaryRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryRequest build() { + com.google.cloud.dataplex.v1.UpdateGlossaryRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryRequest buildPartial() { + com.google.cloud.dataplex.v1.UpdateGlossaryRequest result = + new com.google.cloud.dataplex.v1.UpdateGlossaryRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.UpdateGlossaryRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.glossary_ = glossaryBuilder_ == null ? glossary_ : glossaryBuilder_.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.validateOnly_ = validateOnly_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.UpdateGlossaryRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.UpdateGlossaryRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.UpdateGlossaryRequest other) { + if (other == com.google.cloud.dataplex.v1.UpdateGlossaryRequest.getDefaultInstance()) + return this; + if (other.hasGlossary()) { + mergeGlossary(other.getGlossary()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + if (other.getValidateOnly() != false) { + setValidateOnly(other.getValidateOnly()); + } + 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(getGlossaryFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + validateOnly_ = 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 com.google.cloud.dataplex.v1.Glossary glossary_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder> + glossaryBuilder_; + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the glossary field is set. + */ + public boolean hasGlossary() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The glossary. + */ + public com.google.cloud.dataplex.v1.Glossary getGlossary() { + if (glossaryBuilder_ == null) { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } else { + return glossaryBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGlossary(com.google.cloud.dataplex.v1.Glossary value) { + if (glossaryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + glossary_ = value; + } else { + glossaryBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setGlossary(com.google.cloud.dataplex.v1.Glossary.Builder builderForValue) { + if (glossaryBuilder_ == null) { + glossary_ = builderForValue.build(); + } else { + glossaryBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeGlossary(com.google.cloud.dataplex.v1.Glossary value) { + if (glossaryBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && glossary_ != null + && glossary_ != com.google.cloud.dataplex.v1.Glossary.getDefaultInstance()) { + getGlossaryBuilder().mergeFrom(value); + } else { + glossary_ = value; + } + } else { + glossaryBuilder_.mergeFrom(value); + } + if (glossary_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearGlossary() { + bitField0_ = (bitField0_ & ~0x00000001); + glossary_ = null; + if (glossaryBuilder_ != null) { + glossaryBuilder_.dispose(); + glossaryBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.Glossary.Builder getGlossaryBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return getGlossaryFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossaryOrBuilder() { + if (glossaryBuilder_ != null) { + return glossaryBuilder_.getMessageOrBuilder(); + } else { + return glossary_ == null + ? com.google.cloud.dataplex.v1.Glossary.getDefaultInstance() + : glossary_; + } + } + + /** + * + * + *
        +     * Required. The Glossary to update.
        +     * The Glossary's `name` field is used to identify the Glossary to update.
        +     * Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder> + getGlossaryFieldBuilder() { + if (glossaryBuilder_ == null) { + glossaryBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.Glossary, + com.google.cloud.dataplex.v1.Glossary.Builder, + com.google.cloud.dataplex.v1.GlossaryOrBuilder>( + getGlossary(), getParentForChildren(), isClean()); + glossary_ = null; + } + return glossaryBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + 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 getUpdateMaskFieldBuilder().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.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + private boolean validateOnly_; + + /** + * + * + *
        +     * Optional. Validates the request without actually updating the Glossary.
        +     * Default: false.
        +     * 
        + * + * bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The validateOnly. + */ + @java.lang.Override + public boolean getValidateOnly() { + return validateOnly_; + } + + /** + * + * + *
        +     * Optional. Validates the request without actually updating the Glossary.
        +     * Default: false.
        +     * 
        + * + * bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The validateOnly to set. + * @return This builder for chaining. + */ + public Builder setValidateOnly(boolean value) { + + validateOnly_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. Validates the request without actually updating the Glossary.
        +     * Default: false.
        +     * 
        + * + * bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearValidateOnly() { + bitField0_ = (bitField0_ & ~0x00000004); + validateOnly_ = false; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.UpdateGlossaryRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.UpdateGlossaryRequest) + private static final com.google.cloud.dataplex.v1.UpdateGlossaryRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.UpdateGlossaryRequest(); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateGlossaryRequest 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.dataplex.v1.UpdateGlossaryRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryRequestOrBuilder.java new file mode 100644 index 000000000000..d0e93c32d6fe --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryRequestOrBuilder.java @@ -0,0 +1,132 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface UpdateGlossaryRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.UpdateGlossaryRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The Glossary to update.
        +   * The Glossary's `name` field is used to identify the Glossary to update.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the glossary field is set. + */ + boolean hasGlossary(); + + /** + * + * + *
        +   * Required. The Glossary to update.
        +   * The Glossary's `name` field is used to identify the Glossary to update.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The glossary. + */ + com.google.cloud.dataplex.v1.Glossary getGlossary(); + + /** + * + * + *
        +   * Required. The Glossary to update.
        +   * The Glossary's `name` field is used to identify the Glossary to update.
        +   * Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.Glossary glossary = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.GlossaryOrBuilder getGlossaryOrBuilder(); + + /** + * + * + *
        +   * 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(); + + /** + * + * + *
        +   * Optional. Validates the request without actually updating the Glossary.
        +   * Default: false.
        +   * 
        + * + * bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The validateOnly. + */ + boolean getValidateOnly(); +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryTermRequest.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryTermRequest.java new file mode 100644 index 000000000000..14d46325d913 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryTermRequest.java @@ -0,0 +1,1080 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +/** + * + * + *
        + * Update GlossaryTerm Request
        + * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.UpdateGlossaryTermRequest} + */ +public final class UpdateGlossaryTermRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dataplex.v1.UpdateGlossaryTermRequest) + UpdateGlossaryTermRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use UpdateGlossaryTermRequest.newBuilder() to construct. + private UpdateGlossaryTermRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateGlossaryTermRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateGlossaryTermRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.Builder.class); + } + + private int bitField0_; + public static final int TERM_FIELD_NUMBER = 1; + private com.google.cloud.dataplex.v1.GlossaryTerm term_; + + /** + * + * + *
        +   * Required. The GlossaryTerm to update.
        +   * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +   * update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the term field is set. + */ + @java.lang.Override + public boolean hasTerm() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Required. The GlossaryTerm to update.
        +   * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +   * update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The term. + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTerm getTerm() { + return term_ == null ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() : term_; + } + + /** + * + * + *
        +   * Required. The GlossaryTerm to update.
        +   * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +   * update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermOrBuilder() { + return term_ == null ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() : term_; + } + + 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, getTerm()); + } + 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, getTerm()); + } + 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.dataplex.v1.UpdateGlossaryTermRequest)) { + return super.equals(obj); + } + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest other = + (com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest) obj; + + if (hasTerm() != other.hasTerm()) return false; + if (hasTerm()) { + if (!getTerm().equals(other.getTerm())) 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 (hasTerm()) { + hash = (37 * hash) + TERM_FIELD_NUMBER; + hash = (53 * hash) + getTerm().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.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest 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.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest 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.dataplex.v1.UpdateGlossaryTermRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.dataplex.v1.UpdateGlossaryTermRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Update GlossaryTerm Request
        +   * 
        + * + * Protobuf type {@code google.cloud.dataplex.v1.UpdateGlossaryTermRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dataplex.v1.UpdateGlossaryTermRequest) + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.class, + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.Builder.class); + } + + // Construct using com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getTermFieldBuilder(); + getUpdateMaskFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + term_ = null; + if (termBuilder_ != null) { + termBuilder_.dispose(); + termBuilder_ = 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.dataplex.v1.BusinessGlossaryProto + .internal_static_google_cloud_dataplex_v1_UpdateGlossaryTermRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest getDefaultInstanceForType() { + return com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest build() { + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest buildPartial() { + com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest result = + new com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.term_ = termBuilder_ == null ? term_ : termBuilder_.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 clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest) { + return mergeFrom((com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest other) { + if (other == com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest.getDefaultInstance()) + return this; + if (other.hasTerm()) { + mergeTerm(other.getTerm()); + } + 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(getTermFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000001; + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().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.dataplex.v1.GlossaryTerm term_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder> + termBuilder_; + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the term field is set. + */ + public boolean hasTerm() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The term. + */ + public com.google.cloud.dataplex.v1.GlossaryTerm getTerm() { + if (termBuilder_ == null) { + return term_ == null + ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() + : term_; + } else { + return termBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTerm(com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + term_ = value; + } else { + termBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setTerm(com.google.cloud.dataplex.v1.GlossaryTerm.Builder builderForValue) { + if (termBuilder_ == null) { + term_ = builderForValue.build(); + } else { + termBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeTerm(com.google.cloud.dataplex.v1.GlossaryTerm value) { + if (termBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0) + && term_ != null + && term_ != com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance()) { + getTermBuilder().mergeFrom(value); + } else { + term_ = value; + } + } else { + termBuilder_.mergeFrom(value); + } + if (term_ != null) { + bitField0_ |= 0x00000001; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearTerm() { + bitField0_ = (bitField0_ & ~0x00000001); + term_ = null; + if (termBuilder_ != null) { + termBuilder_.dispose(); + termBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryTerm.Builder getTermBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return getTermFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermOrBuilder() { + if (termBuilder_ != null) { + return termBuilder_.getMessageOrBuilder(); + } else { + return term_ == null + ? com.google.cloud.dataplex.v1.GlossaryTerm.getDefaultInstance() + : term_; + } + } + + /** + * + * + *
        +     * Required. The GlossaryTerm to update.
        +     * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +     * update. Format:
        +     * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +     * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder> + getTermFieldBuilder() { + if (termBuilder_ == null) { + termBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dataplex.v1.GlossaryTerm, + com.google.cloud.dataplex.v1.GlossaryTerm.Builder, + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder>( + getTerm(), getParentForChildren(), isClean()); + term_ = null; + } + return termBuilder_; + } + + private com.google.protobuf.FieldMask updateMask_; + private com.google.protobuf.SingleFieldBuilderV3< + 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 getUpdateMaskFieldBuilder().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.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder> + getUpdateMaskFieldBuilder() { + if (updateMaskBuilder_ == null) { + updateMaskBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.FieldMask, + com.google.protobuf.FieldMask.Builder, + com.google.protobuf.FieldMaskOrBuilder>( + getUpdateMask(), getParentForChildren(), isClean()); + updateMask_ = null; + } + return updateMaskBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.dataplex.v1.UpdateGlossaryTermRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dataplex.v1.UpdateGlossaryTermRequest) + private static final com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest(); + } + + public static com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateGlossaryTermRequest 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.dataplex.v1.UpdateGlossaryTermRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryTermRequestOrBuilder.java b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryTermRequestOrBuilder.java new file mode 100644 index 000000000000..dc9c01128b6d --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/java/com/google/cloud/dataplex/v1/UpdateGlossaryTermRequestOrBuilder.java @@ -0,0 +1,118 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/dataplex/v1/business_glossary.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.dataplex.v1; + +public interface UpdateGlossaryTermRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dataplex.v1.UpdateGlossaryTermRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The GlossaryTerm to update.
        +   * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +   * update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the term field is set. + */ + boolean hasTerm(); + + /** + * + * + *
        +   * Required. The GlossaryTerm to update.
        +   * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +   * update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The term. + */ + com.google.cloud.dataplex.v1.GlossaryTerm getTerm(); + + /** + * + * + *
        +   * Required. The GlossaryTerm to update.
        +   * The GlossaryTerm's `name` field is used to identify the GlossaryTerm to
        +   * update. Format:
        +   * projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id}
        +   * 
        + * + * + * .google.cloud.dataplex.v1.GlossaryTerm term = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dataplex.v1.GlossaryTermOrBuilder getTermOrBuilder(); + + /** + * + * + *
        +   * 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-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/analyze.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/analyze.proto index 4dbaa7b9e243..23abfdc2bf12 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/analyze.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/analyze.proto @@ -53,7 +53,7 @@ message Environment { // Software Runtime Configuration to run Analyze. message OsImageRuntime { - // Required. Dataplex Image version. + // Required. Dataplex Universal Catalog Image version. string image_version = 1 [(google.api.field_behavior) = REQUIRED]; // Optional. List of Java jars to be included in the runtime environment. diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/business_glossary.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/business_glossary.proto new file mode 100644 index 000000000000..2b0b4437cfe4 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/business_glossary.proto @@ -0,0 +1,724 @@ +// Copyright 2025 Google LLC +// +// Licensed under the Apache License, Version 2.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.dataplex.v1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/field_info.proto"; +import "google/api/resource.proto"; +import "google/cloud/dataplex/v1/service.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; +import "google/protobuf/timestamp.proto"; + +option go_package = "cloud.google.com/go/dataplex/apiv1/dataplexpb;dataplexpb"; +option java_multiple_files = true; +option java_outer_classname = "BusinessGlossaryProto"; +option java_package = "com.google.cloud.dataplex.v1"; + +// BusinessGlossaryService provides APIs for managing business glossary +// resources for enterprise customers. +// The resources currently supported in Business Glossary are: +// 1. Glossary +// 2. GlossaryCategory +// 3. GlossaryTerm +service BusinessGlossaryService { + option (google.api.default_host) = "dataplex.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform"; + + // Creates a new Glossary resource. + rpc CreateGlossary(CreateGlossaryRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*}/glossaries" + body: "glossary" + }; + option (google.api.method_signature) = "parent,glossary,glossary_id"; + option (google.longrunning.operation_info) = { + response_type: "Glossary" + metadata_type: "OperationMetadata" + }; + } + + // Updates a Glossary resource. + rpc UpdateGlossary(UpdateGlossaryRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + patch: "/v1/{glossary.name=projects/*/locations/*/glossaries/*}" + body: "glossary" + }; + option (google.api.method_signature) = "glossary,update_mask"; + option (google.longrunning.operation_info) = { + response_type: "Glossary" + metadata_type: "OperationMetadata" + }; + } + + // Deletes a Glossary resource. All the categories and terms within the + // Glossary must be deleted before the Glossary can be deleted. + rpc DeleteGlossary(DeleteGlossaryRequest) + returns (google.longrunning.Operation) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/glossaries/*}" + }; + option (google.api.method_signature) = "name"; + option (google.longrunning.operation_info) = { + response_type: "google.protobuf.Empty" + metadata_type: "OperationMetadata" + }; + } + + // Gets a Glossary resource. + rpc GetGlossary(GetGlossaryRequest) returns (Glossary) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/glossaries/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists Glossary resources in a project and location. + rpc ListGlossaries(ListGlossariesRequest) returns (ListGlossariesResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*}/glossaries" + }; + option (google.api.method_signature) = "parent"; + } + + // Creates a new GlossaryCategory resource. + rpc CreateGlossaryCategory(CreateGlossaryCategoryRequest) + returns (GlossaryCategory) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/glossaries/*}/categories" + body: "category" + }; + option (google.api.method_signature) = "parent,category,category_id"; + } + + // Updates a GlossaryCategory resource. + rpc UpdateGlossaryCategory(UpdateGlossaryCategoryRequest) + returns (GlossaryCategory) { + option (google.api.http) = { + patch: "/v1/{category.name=projects/*/locations/*/glossaries/*/categories/*}" + body: "category" + }; + option (google.api.method_signature) = "category,update_mask"; + } + + // Deletes a GlossaryCategory resource. All the GlossaryCategories and + // GlossaryTerms nested directly under the specified GlossaryCategory will be + // moved one level up to the parent in the hierarchy. + rpc DeleteGlossaryCategory(DeleteGlossaryCategoryRequest) + returns (google.protobuf.Empty) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/glossaries/*/categories/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Gets a GlossaryCategory resource. + rpc GetGlossaryCategory(GetGlossaryCategoryRequest) + returns (GlossaryCategory) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/glossaries/*/categories/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists GlossaryCategory resources in a Glossary. + rpc ListGlossaryCategories(ListGlossaryCategoriesRequest) + returns (ListGlossaryCategoriesResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/glossaries/*}/categories" + }; + option (google.api.method_signature) = "parent"; + } + + // Creates a new GlossaryTerm resource. + rpc CreateGlossaryTerm(CreateGlossaryTermRequest) returns (GlossaryTerm) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/glossaries/*}/terms" + body: "term" + }; + option (google.api.method_signature) = "parent,term,term_id"; + } + + // Updates a GlossaryTerm resource. + rpc UpdateGlossaryTerm(UpdateGlossaryTermRequest) returns (GlossaryTerm) { + option (google.api.http) = { + patch: "/v1/{term.name=projects/*/locations/*/glossaries/*/terms/*}" + body: "term" + }; + option (google.api.method_signature) = "term,update_mask"; + } + + // Deletes a GlossaryTerm resource. + rpc DeleteGlossaryTerm(DeleteGlossaryTermRequest) + returns (google.protobuf.Empty) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/glossaries/*/terms/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Gets a GlossaryTerm resource. + rpc GetGlossaryTerm(GetGlossaryTermRequest) returns (GlossaryTerm) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/glossaries/*/terms/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Lists GlossaryTerm resources in a Glossary. + rpc ListGlossaryTerms(ListGlossaryTermsRequest) + returns (ListGlossaryTermsResponse) { + option (google.api.http) = { + get: "/v1/{parent=projects/*/locations/*/glossaries/*}/terms" + }; + option (google.api.method_signature) = "parent"; + } +} + +// A Glossary represents a collection of GlossaryCategories and GlossaryTerms +// defined by the user. Glossary is a top level resource and is the Google Cloud +// parent resource of all the GlossaryCategories and GlossaryTerms within it. +message Glossary { + option (google.api.resource) = { + type: "dataplex.googleapis.com/Glossary" + pattern: "projects/{project}/locations/{location}/glossaries/{glossary}" + plural: "glossaries" + singular: "glossary" + }; + + // Output only. Identifier. The resource name of the Glossary. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + string name = 1 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.field_behavior) = IDENTIFIER + ]; + + // Output only. System generated unique id for the Glossary. This ID will be + // different if the Glossary is deleted and re-created with the + // same name. + string uid = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Optional. User friendly display name of the Glossary. This is user-mutable. + // This will be same as the GlossaryId, if not specified. + string display_name = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The user-mutable description of the Glossary. + string description = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The time at which the Glossary was created. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time at which the Glossary was last updated. + google.protobuf.Timestamp update_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. User-defined labels for the Glossary. + map labels = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The number of GlossaryTerms in the Glossary. + int32 term_count = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The number of GlossaryCategories in the Glossary. + int32 category_count = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. Needed for resource freshness validation. + // This checksum is computed by the server based on the value of other + // fields, and may be sent on update and delete requests to ensure the + // client has an up-to-date value before proceeding. + string etag = 10 [(google.api.field_behavior) = OPTIONAL]; +} + +// A GlossaryCategory represents a collection of GlossaryCategories and +// GlossaryTerms within a Glossary that are related to each other. +message GlossaryCategory { + option (google.api.resource) = { + type: "dataplex.googleapis.com/GlossaryCategory" + pattern: "projects/{project}/locations/{location}/glossaries/{glossary}/categories/{glossary_category}" + plural: "categories" + singular: "category" + }; + + // Output only. Identifier. The resource name of the GlossaryCategory. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + string name = 1 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.field_behavior) = IDENTIFIER + ]; + + // Output only. System generated unique id for the GlossaryCategory. This ID + // will be different if the GlossaryCategory is deleted and re-created with + // the same name. + string uid = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Optional. User friendly display name of the GlossaryCategory. This is + // user-mutable. This will be same as the GlossaryCategoryId, if not + // specified. + string display_name = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The user-mutable description of the GlossaryCategory. + string description = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The time at which the GlossaryCategory was created. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time at which the GlossaryCategory was last updated. + google.protobuf.Timestamp update_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. User-defined labels for the GlossaryCategory. + map labels = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Required. The immediate parent of the GlossaryCategory in the + // resource-hierarchy. It can either be a Glossary or a GlossaryCategory. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + // OR + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + string parent = 8 [(google.api.field_behavior) = REQUIRED]; +} + +// GlossaryTerms are the core of Glossary. +// A GlossaryTerm holds a rich text description that can be attached to Entries +// or specific columns to enrich them. +message GlossaryTerm { + option (google.api.resource) = { + type: "dataplex.googleapis.com/GlossaryTerm" + pattern: "projects/{project}/locations/{location}/glossaries/{glossary}/terms/{glossary_term}" + plural: "terms" + singular: "term" + }; + + // Output only. Identifier. The resource name of the GlossaryTerm. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + string name = 1 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.field_behavior) = IDENTIFIER + ]; + + // Output only. System generated unique id for the GlossaryTerm. This ID will + // be different if the GlossaryTerm is deleted and re-created with the same + // name. + string uid = 2 [ + (google.api.field_info).format = UUID4, + (google.api.field_behavior) = OUTPUT_ONLY + ]; + + // Optional. User friendly display name of the GlossaryTerm. This is + // user-mutable. This will be same as the GlossaryTermId, if not specified. + string display_name = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The user-mutable description of the GlossaryTerm. + string description = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Output only. The time at which the GlossaryTerm was created. + google.protobuf.Timestamp create_time = 5 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time at which the GlossaryTerm was last updated. + google.protobuf.Timestamp update_time = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Optional. User-defined labels for the GlossaryTerm. + map labels = 7 [(google.api.field_behavior) = OPTIONAL]; + + // Required. The immediate parent of the GlossaryTerm in the + // resource-hierarchy. It can either be a Glossary or a GlossaryCategory. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + // OR + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + string parent = 8 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; +} + +// Create Glossary Request +message CreateGlossaryRequest { + // Required. The parent resource where this Glossary will be created. + // Format: projects/{project_id_or_number}/locations/{location_id} + // where `location_id` refers to a Google Cloud region. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; + + // Required. Glossary ID: Glossary identifier. + string glossary_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The Glossary to create. + Glossary glossary = 3 [(google.api.field_behavior) = REQUIRED]; + + // Optional. Validates the request without actually creating the Glossary. + // Default: false. + bool validate_only = 4 [(google.api.field_behavior) = OPTIONAL]; +} + +// Update Glossary Request +message UpdateGlossaryRequest { + // Required. The Glossary to update. + // The Glossary's `name` field is used to identify the Glossary to update. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + Glossary glossary = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The list of fields to update. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = REQUIRED]; + + // Optional. Validates the request without actually updating the Glossary. + // Default: false. + bool validate_only = 3 [(google.api.field_behavior) = OPTIONAL]; +} + +// Delete Glossary Request +message DeleteGlossaryRequest { + // Required. The name of the Glossary to delete. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; + + // Optional. The etag of the Glossary. + // If this is provided, it must match the server's etag. + // If the etag is provided and does not match the server-computed etag, + // the request must fail with a ABORTED error code. + string etag = 2 [(google.api.field_behavior) = OPTIONAL]; +} + +// Get Glossary Request +message GetGlossaryRequest { + // Required. The name of the Glossary to retrieve. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; +} + +// List Glossaries Request +message ListGlossariesRequest { + // Required. The parent, which has this collection of Glossaries. + // Format: projects/{project_id_or_number}/locations/{location_id} + // where `location_id` refers to a Google Cloud region. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "locations.googleapis.com/Location" + } + ]; + + // Optional. The maximum number of Glossaries to return. The service may + // return fewer than this value. If unspecified, at most 50 Glossaries 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 page token, received from a previous `ListGlossaries` call. + // Provide this to retrieve the subsequent page. + // When paginating, all other parameters provided to `ListGlossaries` must + // match the call that provided the page token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filter expression that filters Glossaries listed in the response. + // Filters on proto fields of Glossary are supported. + // Examples of using a filter are: + // - `display_name="my-glossary"` + // - `categoryCount=1` + // - `termCount=0` + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Order by expression that orders Glossaries listed in the + // response. Order by fields are: `name` or `create_time` for the result. If + // not specified, the ordering is undefined. + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// List Glossaries Response +message ListGlossariesResponse { + // Lists the Glossaries in the specified parent. + repeated Glossary glossaries = 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; + + // Locations that the service couldn't reach. + repeated string unreachable_locations = 3; +} + +// Creates a new GlossaryCategory under the specified Glossary. +message CreateGlossaryCategoryRequest { + // Required. The parent resource where this GlossaryCategory will be created. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + // where `locationId` refers to a Google Cloud region. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; + + // Required. GlossaryCategory identifier. + string category_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The GlossaryCategory to create. + GlossaryCategory category = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// Update GlossaryCategory Request +message UpdateGlossaryCategoryRequest { + // Required. The GlossaryCategory to update. + // The GlossaryCategory's `name` field is used to identify the + // GlossaryCategory to update. Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + GlossaryCategory category = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The list of fields to update. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = REQUIRED]; +} + +// Delete GlossaryCategory Request +message DeleteGlossaryCategoryRequest { + // Required. The name of the GlossaryCategory to delete. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/GlossaryCategory" + } + ]; +} + +// Get GlossaryCategory Request +message GetGlossaryCategoryRequest { + // Required. The name of the GlossaryCategory to retrieve. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id} + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/GlossaryCategory" + } + ]; +} + +// List GlossaryCategories Request +message ListGlossaryCategoriesRequest { + // Required. The parent, which has this collection of GlossaryCategories. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + // Location is the Google Cloud region. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; + + // Optional. The maximum number of GlossaryCategories to return. The service + // may return fewer than this value. If unspecified, at most 50 + // GlossaryCategories 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 page token, received from a previous `ListGlossaryCategories` + // call. Provide this to retrieve the subsequent page. When paginating, all + // other parameters provided to `ListGlossaryCategories` must match the call + // that provided the page token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filter expression that filters GlossaryCategories listed in the + // response. Filters are supported on the following fields: + // - immediate_parent + // + // Examples of using a filter are: + // - + // `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"` + // - + // `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"` + // + // This will only return the GlossaryCategories that are directly nested + // under the specified parent. + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Order by expression that orders GlossaryCategories listed in the + // response. Order by fields are: `name` or `create_time` for the result. If + // not specified, the ordering is undefined. + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// List GlossaryCategories Response +message ListGlossaryCategoriesResponse { + // Lists the GlossaryCategories in the specified parent. + repeated GlossaryCategory categories = 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; + + // Locations that the service couldn't reach. + repeated string unreachable_locations = 3; +} + +// Creates a new GlossaryTerm under the specified Glossary. +message CreateGlossaryTermRequest { + // Required. The parent resource where the GlossaryTerm will be created. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + // where `location_id` refers to a Google Cloud region. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; + + // Required. GlossaryTerm identifier. + string term_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. The GlossaryTerm to create. + GlossaryTerm term = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// Update GlossaryTerm Request +message UpdateGlossaryTermRequest { + // Required. The GlossaryTerm to update. + // The GlossaryTerm's `name` field is used to identify the GlossaryTerm to + // update. Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + GlossaryTerm term = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The list of fields to update. + google.protobuf.FieldMask update_mask = 2 + [(google.api.field_behavior) = REQUIRED]; +} + +// Delete GlossaryTerm Request +message DeleteGlossaryTermRequest { + // Required. The name of the GlossaryTerm to delete. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/GlossaryTerm" + } + ]; +} + +// Get GlossaryTerm Request +message GetGlossaryTermRequest { + // Required. The name of the GlossaryTerm to retrieve. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/terms/{term_id} + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/GlossaryTerm" + } + ]; +} + +// List GlossaryTerms Request +message ListGlossaryTermsRequest { + // Required. The parent, which has this collection of GlossaryTerms. + // Format: + // projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id} + // where `location_id` refers to a Google Cloud region. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; + + // Optional. The maximum number of GlossaryTerms to return. The service may + // return fewer than this value. If unspecified, at most 50 GlossaryTerms 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 page token, received from a previous `ListGlossaryTerms` call. + // Provide this to retrieve the subsequent page. + // When paginating, all other parameters provided to `ListGlossaryTerms` must + // match the call that provided the page token. + string page_token = 3 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Filter expression that filters GlossaryTerms listed in the + // response. Filters are supported on the following fields: + // - immediate_parent + // + // Examples of using a filter are: + // - + // `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}"` + // - + // `immediate_parent="projects/{project_id_or_number}/locations/{location_id}/glossaries/{glossary_id}/categories/{category_id}"` + // + // This will only return the GlossaryTerms that are directly nested under the + // specified parent. + string filter = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Order by expression that orders GlossaryTerms listed in the + // response. Order by fields are: `name` or `create_time` for the result. If + // not specified, the ordering is undefined. + string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; +} + +// List GlossaryTerms Response +message ListGlossaryTermsResponse { + // Lists the GlossaryTerms in the specified parent. + repeated GlossaryTerm terms = 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; + + // Locations that the service couldn't reach. + repeated string unreachable_locations = 3; +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/catalog.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/catalog.proto index fd778155ca55..ed9d5c6eec5b 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/catalog.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/catalog.proto @@ -36,11 +36,13 @@ option java_package = "com.google.cloud.dataplex.v1"; option php_namespace = "Google\\Cloud\\Dataplex\\V1"; option ruby_package = "Google::Cloud::Dataplex::V1"; +// LINT: LEGACY_NAMES + // The primary resources offered by this service are EntryGroups, EntryTypes, -// AspectTypes, and Entries. They collectively let data administrators organize, -// manage, secure, and catalog data located across cloud projects in their -// organization in a variety of storage systems, including Cloud Storage and -// BigQuery. +// AspectTypes, Entries and EntryLinks. They collectively let data +// administrators organize, manage, secure, and catalog data located across +// cloud projects in their organization in a variety of storage systems, +// including Cloud Storage and BigQuery. service CatalogService { option (google.api.default_host) = "dataplex.googleapis.com"; option (google.api.oauth_scopes) = @@ -276,8 +278,8 @@ service CatalogService { option (google.api.method_signature) = "name,query"; } - // Creates a metadata job. For example, use a metadata job to import Dataplex - // Catalog entries and aspects from a third-party system into Dataplex. + // Creates a metadata job. For example, use a metadata job to import metadata + // from a third-party system into Dataplex Universal Catalog. rpc CreateMetadataJob(CreateMetadataJobRequest) returns (google.longrunning.Operation) { option (google.api.http) = { @@ -323,6 +325,31 @@ service CatalogService { }; option (google.api.method_signature) = "name"; } + + // Creates an Entry Link. + rpc CreateEntryLink(CreateEntryLinkRequest) returns (EntryLink) { + option (google.api.http) = { + post: "/v1/{parent=projects/*/locations/*/entryGroups/*}/entryLinks" + body: "entry_link" + }; + option (google.api.method_signature) = "parent,entry_link,entry_link_id"; + } + + // Deletes an Entry Link. + rpc DeleteEntryLink(DeleteEntryLinkRequest) returns (EntryLink) { + option (google.api.http) = { + delete: "/v1/{name=projects/*/locations/*/entryGroups/*/entryLinks/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Gets an Entry Link. + rpc GetEntryLink(GetEntryLinkRequest) returns (EntryLink) { + option (google.api.http) = { + get: "/v1/{name=projects/*/locations/*/entryGroups/*/entryLinks/*}" + }; + option (google.api.method_signature) = "name"; + } } // AspectType is a template for creating Aspects, and represents the @@ -335,11 +362,11 @@ message AspectType { singular: "aspectType" }; - // Autorization for an AspectType. + // Authorization for an AspectType. message Authorization { // Immutable. The IAM permission grantable on the EntryGroup to allow access - // to instantiate Aspects of Dataplex owned AspectTypes, only settable for - // Dataplex owned Types. + // to instantiate Aspects of Dataplex Universal Catalog owned AspectTypes, + // only settable for Dataplex Universal Catalog owned Types. string alternate_use_permission = 1 [(google.api.field_behavior) = IMMUTABLE]; } @@ -412,8 +439,8 @@ message AspectType { // Primitive types: // // * string - // * integer - // * boolean + // * int + // * bool // * double // * datetime. Must be of the format RFC3339 UTC "Zulu" (Examples: // "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z"). @@ -585,8 +612,8 @@ message EntryType { // Authorization for an Entry Type. message Authorization { // Immutable. The IAM permission grantable on the Entry Group to allow - // access to instantiate Entries of Dataplex owned Entry Types, only - // settable for Dataplex owned Types. + // access to instantiate Entries of Dataplex Universal Catalog owned Entry + // Types, only settable for Dataplex Universal Catalog owned Types. string alternate_use_permission = 1 [(google.api.field_behavior) = IMMUTABLE]; } @@ -705,11 +732,13 @@ message Entry { (google.api.field_behavior) = IMMUTABLE ]; - // Output only. The time when the entry was created in Dataplex. + // Output only. The time when the entry was created in Dataplex Universal + // Catalog. google.protobuf.Timestamp create_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Output only. The time when the entry was last updated in Dataplex. + // Output only. The time when the entry was last updated in Dataplex Universal + // Catalog. google.protobuf.Timestamp update_time = 6 [(google.api.field_behavior) = OUTPUT_ONLY]; @@ -802,7 +831,7 @@ message EntrySource { message CreateEntryGroupRequest { // Required. The resource name of the entryGroup, of the form: // projects/{project_number}/locations/{location_id} - // where `location_id` refers to a GCP region. + // where `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -945,7 +974,7 @@ message UpdateEntryTypeRequest { bool validate_only = 3 [(google.api.field_behavior) = OPTIONAL]; } -// Delele EntryType Request. +// Delete EntryType Request. message DeleteEntryTypeRequest { // Required. The resource name of the EntryType: // `projects/{project_number}/locations/{location_id}/entryTypes/{entry_type_id}`. @@ -1062,7 +1091,7 @@ message UpdateAspectTypeRequest { bool validate_only = 3 [(google.api.field_behavior) = OPTIONAL]; } -// Delele AspectType Request. +// Delete AspectType Request. message DeleteAspectTypeRequest { // Required. The resource name of the AspectType: // `projects/{project_number}/locations/{location_id}/aspectTypes/{aspect_type_id}`. @@ -1338,7 +1367,7 @@ message LookupEntryRequest { message SearchEntriesRequest { // Required. The project to which the request should be attributed in the - // following form: `projects/{project}/locations/{location}`. + // following form: `projects/{project}/locations/global`. string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -1347,7 +1376,7 @@ message SearchEntriesRequest { ]; // Required. The query against which entries in scope should be matched. - // The query syntax is defined in [Search syntax for Dataplex + // The query syntax is defined in [Search syntax for Dataplex Universal // Catalog](https://cloud.google.com/dataplex/docs/search-syntax). string query = 2 [(google.api.field_behavior) = REQUIRED]; @@ -1363,7 +1392,7 @@ message SearchEntriesRequest { // Optional. Specifies the ordering of results. // Supported values are: // - // * `relevance` (default) + // * `relevance` // * `last_modified_timestamp` // * `last_modified_timestamp asc` string order_by = 5 [(google.api.field_behavior) = OPTIONAL]; @@ -1428,15 +1457,20 @@ message ImportItem { // Information about an entry and its attached aspects. Entry entry = 1; + // Information about the entry link. User should provide either one of the + // entry or entry_link. While providing entry_link, user should not + // provide update_mask and aspect_keys. + EntryLink entry_link = 4; + // The fields to update, in paths that are relative to the `Entry` resource. // Separate each field with a comma. // - // In `FULL` entry sync mode, Dataplex includes the paths of all of the fields - // for an entry that can be modified, including aspects. This means that - // Dataplex replaces the existing entry with the entry in the metadata import - // file. All modifiable fields are updated, regardless of the fields that are - // listed in the update mask, and regardless of whether a field is present - // in the `entry` object. + // In `FULL` entry sync mode, Dataplex Universal Catalog includes the paths of + // all of the fields for an entry that can be modified, including aspects. + // This means that Dataplex Universal Catalog replaces the existing entry with + // the entry in the metadata import file. All modifiable fields are updated, + // regardless of the fields that are listed in the update mask, and regardless + // of whether a field is present in the `entry` object. // // The `update_mask` field is ignored when an entry is created or re-created. // @@ -1444,10 +1478,10 @@ message ImportItem { // value to `aspects`. // // - // Dataplex also determines which entries and aspects to modify by comparing - // the values and timestamps that you provide in the metadata import file with - // the values and timestamps that exist in your project. For more information, - // see [Comparison + // Dataplex Universal Catalog also determines which entries and aspects to + // modify by comparing the values and timestamps that you provide in the + // metadata import file with the values and timestamps that exist in your + // project. For more information, see [Comparison // logic](https://cloud.google.com/dataplex/docs/import-metadata#data-modification-logic). google.protobuf.FieldMask update_mask = 2; @@ -1467,8 +1501,8 @@ message ImportItem { // // In `FULL` entry sync mode, if you leave this field empty, it is treated as // specifying exactly those aspects that are present within the specified - // entry. Dataplex implicitly adds the keys for all of the required aspects of - // an entry. + // entry. Dataplex Universal Catalog implicitly adds the keys for all of the + // required aspects of an entry. repeated string aspect_keys = 3; } @@ -1597,6 +1631,17 @@ message MetadataJob { // Output only. The time when the status was updated. google.protobuf.Timestamp update_time = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The total number of entry links that were successfully + // deleted. + int64 deleted_entry_links = 7 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The total number of entry links that were successfully + // created. + int64 created_entry_links = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The total number of entry links that were left unchanged. + int64 unchanged_entry_links = 9 [(google.api.field_behavior) = OUTPUT_ONLY]; } // Summary results from a metadata export job. The results are a snapshot of @@ -1629,9 +1674,9 @@ message MetadataJob { SYNC_MODE_UNSPECIFIED = 0; // All resources in the job's scope are modified. If a resource exists in - // Dataplex but isn't included in the metadata import file, the resource - // is deleted when you run the metadata job. Use this mode to perform a - // full sync of the set of entries in the job scope. + // Dataplex Universal Catalog but isn't included in the metadata import + // file, the resource is deleted when you run the metadata job. Use this + // mode to perform a full sync of the set of entries in the job scope. // // This sync mode is supported for entries. FULL = 1; @@ -1729,6 +1774,49 @@ message MetadataJob { type: "dataplex.googleapis.com/AspectType" } ]; + + // Optional. The glossaries that are in scope for the import job, + // specified as relative resource names in the format + // `projects/{project_number_or_id}/locations/{location_id}/glossaries/{glossary_id}`. + // + // While importing Business Glossary entries, the user must + // provide glossaries. While importing entries, the user does not have to + // provide glossaries. If the metadata import file attempts to modify + // Business Glossary entries whose glossary isn't included in this list, + // the import job will skip those entries. + // + // The location of a glossary must either match the location of the + // job, or the glossary must be global. + repeated string glossaries = 4 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/Glossary" + } + ]; + + // Optional. The entry link types that are in scope for the import job, + // specified as relative resource names in the format + // `projects/{project_number_or_id}/locations/{location_id}/entryLinkTypes/{entry_link_type_id}`. + // The job modifies only the entryLinks that belong to these entry link + // types. + // + // If the metadata import file attempts to create or delete an entry link + // whose entry link type isn't included in this list, the import job will + // skip those entry links. + repeated string entry_link_types = 5 + [(google.api.field_behavior) = OPTIONAL]; + + // Optional. Defines the scope of entries that can be referenced in the + // entry links. + // + // Currently, projects are supported as valid scopes. + // Format: `projects/{project_number_or_id}` + // + // If the metadata import file attempts to create an entry link + // which references an entry that is not in the scope, the import job will + // skip that entry link. + repeated string referenced_entry_scopes = 6 + [(google.api.field_behavior) = OPTIONAL]; } // Optional. The URI of a Cloud Storage bucket or folder (beginning with @@ -1849,9 +1937,9 @@ message MetadataJob { // metadata to, in the format `gs://{bucket}/`. You can optionally specify a // custom prefix after the bucket name, in the format // `gs://{bucket}/{prefix}/`. The maximum length of the custom prefix is 128 - // characters. Dataplex constructs the object path for the exported files by - // using the bucket name and prefix that you provide, followed by a - // system-generated path. + // characters. Dataplex Universal Catalog constructs the object path for the + // exported files by using the bucket name and prefix that you provide, + // followed by a system-generated path. // // The bucket must be in the same VPC Service Controls perimeter as the job. string output_path = 3 [(google.api.field_behavior) = REQUIRED]; @@ -2001,3 +2089,134 @@ enum TransferStatus { // resource can only be updated from Dataplex API. TRANSFER_STATUS_TRANSFERRED = 2; } + +// EntryLink represents a link between two Entries. +message EntryLink { + option (google.api.resource) = { + type: "dataplex.googleapis.com/EntryLink" + pattern: "projects/{project}/locations/{location}/entryGroups/{entry_group}/entryLinks/{entry_link}" + plural: "entryLinks" + singular: "entryLink" + }; + + // Reference to the Entry that is linked through the Entry Link. + message EntryReference { + // Reference type of the Entry. + enum Type { + // Unspecified reference type. Implies that the Entry is referenced + // in a non-directional Entry Link. + UNSPECIFIED = 0; + + // The Entry is referenced as the source of the directional Entry Link. + SOURCE = 2; + + // The Entry is referenced as the target of the directional Entry Link. + TARGET = 3; + } + + // Required. Immutable. The relative resource name of the referenced Entry, + // of the form: + // `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entries/{entry_id}` + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE + ]; + + // Immutable. The path in the Entry that is referenced in the Entry Link. + // Empty path denotes that the Entry itself is referenced in the Entry + // Link. + string path = 2 [(google.api.field_behavior) = IMMUTABLE]; + + // Required. Immutable. The reference type of the Entry. + Type type = 3 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE + ]; + } + + // Output only. Immutable. Identifier. The relative resource name of the Entry + // Link, of the form: + // `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}` + string name = 1 [ + (google.api.field_behavior) = OUTPUT_ONLY, + (google.api.field_behavior) = IMMUTABLE, + (google.api.field_behavior) = IDENTIFIER, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/EntryLink" + } + ]; + + // Required. Immutable. Relative resource name of the Entry Link Type used to + // create this Entry Link. For example: + // + // - Entry link between synonym terms in a glossary: + // `projects/dataplex-types/locations/global/entryLinkTypes/synonym` + // - Entry link between related terms in a glossary: + // `projects/dataplex-types/locations/global/entryLinkTypes/related` + // - Entry link between glossary terms and data assets: + // `projects/dataplex-types/locations/global/entryLinkTypes/definition` + string entry_link_type = 2 [ + (google.api.field_behavior) = REQUIRED, + (google.api.field_behavior) = IMMUTABLE + ]; + + // Output only. The time when the Entry Link was created. + google.protobuf.Timestamp create_time = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The time when the Entry Link was last updated. + google.protobuf.Timestamp update_time = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Required. Specifies the Entries referenced in the Entry Link. There should + // be exactly two entry references. + repeated EntryReference entry_references = 10 + [(google.api.field_behavior) = REQUIRED]; +} + +// Request message for CreateEntryLink. +message CreateEntryLinkRequest { + // Required. The resource name of the parent Entry Group: + // `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/EntryGroup" + } + ]; + + // Required. Entry Link identifier + // * Must contain only lowercase letters, numbers and hyphens. + // * Must start with a letter. + // * Must be between 1-63 characters. + // * Must end with a number or a letter. + // * Must be unique within the EntryGroup. + string entry_link_id = 2 [(google.api.field_behavior) = REQUIRED]; + + // Required. Entry Link resource. + EntryLink entry_link = 3 [(google.api.field_behavior) = REQUIRED]; +} + +// Request message for DeleteEntryLink. +message DeleteEntryLinkRequest { + // Required. The resource name of the Entry Link: + // `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/EntryLink" + } + ]; +} + +// Request message for GetEntryLink. +message GetEntryLinkRequest { + // Required. The resource name of the Entry Link: + // `projects/{project_id_or_number}/locations/{location_id}/entryGroups/{entry_group_id}/entryLinks/{entry_link_id}`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dataplex.googleapis.com/EntryLink" + } + ]; +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/cmek.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/cmek.proto index 997f583648ee..62b8a03b263d 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/cmek.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/cmek.proto @@ -38,7 +38,7 @@ option (google.api.resource_definition) = { pattern: "organizations/{organization}/locations/{location}" }; -// Dataplex Cmek Service +// Dataplex Universal Catalog Customer Managed Encryption Keys (CMEK) Service service CmekService { option (google.api.default_host) = "dataplex.googleapis.com"; option (google.api.oauth_scopes) = diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/content.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/content.proto index b51cc4f2a901..49a23981e31a 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/content.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/content.proto @@ -31,7 +31,8 @@ option java_multiple_files = true; option java_outer_classname = "ContentProto"; option java_package = "com.google.cloud.dataplex.v1"; -// ContentService manages Notebook and SQL Scripts for Dataplex. +// ContentService manages Notebook and SQL Scripts for Dataplex Universal +// Catalog. service ContentService { option (google.api.default_host) = "dataplex.googleapis.com"; option (google.api.oauth_scopes) = diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_discovery.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_discovery.proto index f9b9f493f8f2..dc9a9e6d913c 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_discovery.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_discovery.proto @@ -88,6 +88,17 @@ message DataDiscoverySpec { // For supported values, refer to // https://cloud.google.com/bigquery/docs/locations#supported_locations. string location = 4 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. The project of the BigQuery dataset to publish BigLake external + // or non-BigLake external tables to. If not specified, the project of the + // Cloud Storage bucket will be used. The format is + // "projects/{project_id_or_number}". + string project = 5 [ + (google.api.field_behavior) = OPTIONAL, + (google.api.resource_reference) = { + type: "cloudresourcemanager.googleapis.com/Project" + } + ]; } // Configurations related to Cloud Storage as the data source. diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_profile.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_profile.proto index ce59a1a77b0c..09143b9bcf15 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_profile.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_profile.proto @@ -33,8 +33,6 @@ message DataProfileSpec { // Optional. The BigQuery table to export DataProfileScan results to. // Format: // //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID - // or - // projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID string results_table = 1 [(google.api.field_behavior) = OPTIONAL]; } @@ -65,10 +63,8 @@ message DataProfileSpec { float sampling_percent = 2 [(google.api.field_behavior) = OPTIONAL]; // Optional. A filter applied to all rows in a single DataScan job. - // The filter needs to be a valid SQL expression for a [WHERE clause in - // GoogleSQL - // syntax](https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax#where_clause). - // + // The filter needs to be a valid SQL expression for a WHERE clause in + // BigQuery standard SQL syntax. // Example: col1 >= 0 AND col2 < 10 string row_filter = 3 [(google.api.field_behavior) = OPTIONAL]; @@ -100,108 +96,116 @@ message DataProfileResult { message ProfileInfo { // The profile information for a string type field. message StringFieldInfo { - // Minimum length of non-null values in the scanned data. - int64 min_length = 1; + // Output only. Minimum length of non-null values in the scanned data. + int64 min_length = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Maximum length of non-null values in the scanned data. - int64 max_length = 2; + // Output only. Maximum length of non-null values in the scanned data. + int64 max_length = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Average length of non-null values in the scanned data. - double average_length = 3; + // Output only. Average length of non-null values in the scanned data. + double average_length = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; } // The profile information for an integer type field. message IntegerFieldInfo { - // Average of non-null values in the scanned data. NaN, if the field - // has a NaN. - double average = 1; - - // Standard deviation of non-null values in the scanned data. NaN, if - // the field has a NaN. - double standard_deviation = 3; - - // Minimum of non-null values in the scanned data. NaN, if the field - // has a NaN. - int64 min = 4; - - // A quartile divides the number of data points into four parts, or - // quarters, of more-or-less equal size. Three main quartiles used - // are: The first quartile (Q1) splits off the lowest 25% of data from - // the highest 75%. It is also known as the lower or 25th empirical - // quartile, as 25% of the data is below this point. The second - // quartile (Q2) is the median of a data set. So, 50% of the data lies - // below this point. The third quartile (Q3) splits off the highest - // 25% of data from the lowest 75%. It is known as the upper or 75th - // empirical quartile, as 75% of the data lies below this point. - // Here, the quartiles is provided as an ordered list of approximate - // quartile values for the scanned data, occurring in order Q1, - // median, Q3. - repeated int64 quartiles = 6; - - // Maximum of non-null values in the scanned data. NaN, if the field - // has a NaN. - int64 max = 5; + // Output only. Average of non-null values in the scanned data. NaN, + // if the field has a NaN. + double average = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Standard deviation of non-null values in the scanned + // data. NaN, if the field has a NaN. + double standard_deviation = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Minimum of non-null values in the scanned data. NaN, + // if the field has a NaN. + int64 min = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. A quartile divides the number of data points into four + // parts, or quarters, of more-or-less equal size. Three main + // quartiles used are: The first quartile (Q1) splits off the lowest + // 25% of data from the highest 75%. It is also known as the lower or + // 25th empirical quartile, as 25% of the data is below this point. + // The second quartile (Q2) is the median of a data set. So, 50% of + // the data lies below this point. The third quartile (Q3) splits off + // the highest 25% of data from the lowest 75%. It is known as the + // upper or 75th empirical quartile, as 75% of the data lies below + // this point. Here, the quartiles is provided as an ordered list of + // approximate quartile values for the scanned data, occurring in + // order Q1, median, Q3. + repeated int64 quartiles = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Maximum of non-null values in the scanned data. NaN, + // if the field has a NaN. + int64 max = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; } // The profile information for a double type field. message DoubleFieldInfo { - // Average of non-null values in the scanned data. NaN, if the field - // has a NaN. - double average = 1; - - // Standard deviation of non-null values in the scanned data. NaN, if - // the field has a NaN. - double standard_deviation = 3; - - // Minimum of non-null values in the scanned data. NaN, if the field - // has a NaN. - double min = 4; - - // A quartile divides the number of data points into four parts, or - // quarters, of more-or-less equal size. Three main quartiles used - // are: The first quartile (Q1) splits off the lowest 25% of data from - // the highest 75%. It is also known as the lower or 25th empirical - // quartile, as 25% of the data is below this point. The second - // quartile (Q2) is the median of a data set. So, 50% of the data lies - // below this point. The third quartile (Q3) splits off the highest - // 25% of data from the lowest 75%. It is known as the upper or 75th - // empirical quartile, as 75% of the data lies below this point. - // Here, the quartiles is provided as an ordered list of quartile - // values for the scanned data, occurring in order Q1, median, Q3. - repeated double quartiles = 6; - - // Maximum of non-null values in the scanned data. NaN, if the field - // has a NaN. - double max = 5; + // Output only. Average of non-null values in the scanned data. NaN, + // if the field has a NaN. + double average = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Standard deviation of non-null values in the scanned + // data. NaN, if the field has a NaN. + double standard_deviation = 3 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Minimum of non-null values in the scanned data. NaN, + // if the field has a NaN. + double min = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. A quartile divides the number of data points into four + // parts, or quarters, of more-or-less equal size. Three main + // quartiles used are: The first quartile (Q1) splits off the lowest + // 25% of data from the highest 75%. It is also known as the lower or + // 25th empirical quartile, as 25% of the data is below this point. + // The second quartile (Q2) is the median of a data set. So, 50% of + // the data lies below this point. The third quartile (Q3) splits off + // the highest 25% of data from the lowest 75%. It is known as the + // upper or 75th empirical quartile, as 75% of the data lies below + // this point. Here, the quartiles is provided as an ordered list of + // quartile values for the scanned data, occurring in order Q1, + // median, Q3. + repeated double quartiles = 6 + [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Maximum of non-null values in the scanned data. NaN, + // if the field has a NaN. + double max = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; } // Top N non-null values in the scanned data. message TopNValue { - // String value of a top N non-null value. - string value = 1; + // Output only. String value of a top N non-null value. + string value = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Count of the corresponding value in the scanned data. - int64 count = 2; + // Output only. Count of the corresponding value in the scanned data. + int64 count = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Ratio of the corresponding value in the field against the total - // number of rows in the scanned data. - double ratio = 3; + // Output only. Ratio of the corresponding value in the field against + // the total number of rows in the scanned data. + double ratio = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; } - // Ratio of rows with null value against total scanned rows. - double null_ratio = 2; + // Output only. Ratio of rows with null value against total scanned + // rows. + double null_ratio = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Ratio of rows with distinct values against total scanned rows. - // Not available for complex non-groupable field type, including RECORD, - // ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode. - double distinct_ratio = 3; + // Output only. Ratio of rows with distinct values against total scanned + // rows. Not available for complex non-groupable field type, including + // RECORD, ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE + // mode. + double distinct_ratio = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; - // The list of top N non-null values, frequency and ratio with which - // they occur in the scanned data. N is 10 or equal to the number of - // distinct values in the field, whichever is smaller. Not available for - // complex non-groupable field type, including RECORD, ARRAY, GEOGRAPHY, - // and JSON, as well as fields with REPEATABLE mode. - repeated TopNValue top_n_values = 4; + // Output only. The list of top N non-null values, frequency and ratio + // with which they occur in the scanned data. N is 10 or equal to the + // number of distinct values in the field, whichever is smaller. Not + // available for complex non-groupable field type, including RECORD, + // ARRAY, GEOGRAPHY, and JSON, as well as fields with REPEATABLE mode. + repeated TopNValue top_n_values = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; // Structural and profile information for specific field type. Not // available, if mode is REPEATABLE. @@ -217,29 +221,31 @@ message DataProfileResult { } } - // The name of the field. - string name = 1; + // Output only. The name of the field. + string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - // The data type retrieved from the schema of the data source. For - // instance, for a BigQuery native table, it is the [BigQuery Table + // Output only. The data type retrieved from the schema of the data + // source. For instance, for a BigQuery native table, it is the [BigQuery + // Table // Schema](https://cloud.google.com/bigquery/docs/reference/rest/v2/tables#tablefieldschema). - // For a Dataplex Entity, it is the [Entity + // For a Dataplex Universal Catalog Entity, it is the [Entity // Schema](https://cloud.google.com/dataplex/docs/reference/rpc/google.cloud.dataplex.v1#type_3). - string type = 2; + string type = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - // The mode of the field. Possible values include: + // Output only. The mode of the field. Possible values include: // // * REQUIRED, if it is a required field. // * NULLABLE, if it is an optional field. // * REPEATED, if it is a repeated field. - string mode = 3; + string mode = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Profile information for the corresponding field. - ProfileInfo profile = 4; + // Output only. Profile information for the corresponding field. + ProfileInfo profile = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; } - // List of fields with structural and profile information for each field. - repeated Field fields = 2; + // Output only. List of fields with structural and profile information for + // each field. + repeated Field fields = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; } // The result of post scan actions of DataProfileScan job. @@ -274,14 +280,14 @@ message DataProfileResult { [(google.api.field_behavior) = OUTPUT_ONLY]; } - // The count of rows scanned. - int64 row_count = 3; + // Output only. The count of rows scanned. + int64 row_count = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; - // The profile information per field. - Profile profile = 4; + // Output only. The profile information per field. + Profile profile = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; - // The data scanned for this result. - ScannedData scanned_data = 5; + // Output only. The data scanned for this result. + ScannedData scanned_data = 5 [(google.api.field_behavior) = OUTPUT_ONLY]; // Output only. The result of post scan actions. PostScanActionsResult post_scan_actions_result = 6 diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_quality.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_quality.proto index 1ab34efedaaa..4efccaefeeaf 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_quality.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_quality.proto @@ -18,6 +18,7 @@ package google.cloud.dataplex.v1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/cloud/dataplex/v1/datascans_common.proto"; import "google/cloud/dataplex/v1/processing.proto"; option go_package = "cloud.google.com/go/dataplex/apiv1/dataplexpb;dataplexpb"; @@ -118,6 +119,10 @@ message DataQualitySpec { // Optional. Actions to take upon job completion. PostScanActions post_scan_actions = 6 [(google.api.field_behavior) = OPTIONAL]; + + // Optional. If set, the latest DataScan job result will be published as + // Dataplex Universal Catalog metadata. + bool catalog_publishing_enabled = 8 [(google.api.field_behavior) = OPTIONAL]; } // The output of a DataQualityScan. @@ -189,6 +194,11 @@ message DataQualityResult { // Output only. The result of post scan actions. PostScanActionsResult post_scan_actions_result = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The status of publishing the data scan as Dataplex Universal + // Catalog metadata. + DataScanCatalogPublishingStatus catalog_publishing_status = 11 + [(google.api.field_behavior) = OUTPUT_ONLY]; } // DataQualityRuleResult provides a more detailed, per-rule view of the results. @@ -261,9 +271,9 @@ message DataQualityDimensionResult { // A dimension captures data quality intent about a defined subset of the rules // specified. message DataQualityDimension { - // Optional. The dimension name a rule belongs to. Custom dimension name is + // Output only. The dimension name a rule belongs to. Custom dimension name is // supported with all uppercase letters and maximum length of 30 characters. - string name = 1 [(google.api.field_behavior) = OPTIONAL]; + string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; } // A rule captures data quality intent about a data source. @@ -453,9 +463,8 @@ message DataQualityRule { bool ignore_null = 501 [(google.api.field_behavior) = OPTIONAL]; // Required. The dimension a rule belongs to. Results are also aggregated at - // the dimension level. Supported dimensions are **["COMPLETENESS", - // "ACCURACY", "CONSISTENCY", "VALIDITY", "UNIQUENESS", "FRESHNESS", - // "VOLUME"]** + // the dimension level. Custom dimension name is supported with all uppercase + // letters and maximum length of 30 characters. string dimension = 502 [(google.api.field_behavior) = REQUIRED]; // Optional. The minimum ratio of **passing_rows / total_rows** required to @@ -497,4 +506,11 @@ message DataQualityColumnResult { // The score ranges between between [0, 100] (up to two decimal // points). optional float score = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. Whether the column passed or failed. + bool passed = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // Output only. The dimension-level results for this column. + repeated DataQualityDimensionResult dimensions = 4 + [(google.api.field_behavior) = OUTPUT_ONLY]; } diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_taxonomy.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_taxonomy.proto index 2bf329f3e6e3..97f96d279ef1 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_taxonomy.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/data_taxonomy.proto @@ -524,7 +524,7 @@ message GetDataTaxonomyRequest { message ListDataTaxonomiesRequest { // Required. The resource name of the DataTaxonomy location, of the form: // projects/{project_number}/locations/{location_id} - // where `location_id` refers to a GCP region. + // where `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans.proto index 3e493e9edfad..9c67f8261bc2 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans.proto @@ -151,7 +151,7 @@ message CreateDataScanRequest { // Required. The resource name of the parent location: // `projects/{project}/locations/{location_id}` // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -197,7 +197,7 @@ message DeleteDataScanRequest { // Required. The resource name of the dataScan: // `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -228,7 +228,7 @@ message GetDataScanRequest { // Required. The resource name of the dataScan: // `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -245,7 +245,7 @@ message ListDataScansRequest { // Required. The resource name of the parent location: // `projects/{project}/locations/{location_id}` // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -290,7 +290,7 @@ message RunDataScanRequest { // Required. The resource name of the DataScan: // `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}`. // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. // // Only **OnDemand** data scans are allowed. string name = 1 [ @@ -324,7 +324,7 @@ message GetDataScanJobRequest { // Required. The resource name of the DataScanJob: // `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}/jobs/{data_scan_job_id}` // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string name = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -341,7 +341,7 @@ message ListDataScanJobsRequest { // Required. The resource name of the parent environment: // `projects/{project}/locations/{location_id}/dataScans/{data_scan_id}` // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -404,8 +404,8 @@ message GenerateDataQualityRulesRequest { // Response details for data quality rule recommendations. message GenerateDataQualityRulesResponse { - // The data quality rules that Dataplex generates based on the results - // of a data profiling scan. + // The data quality rules that Dataplex Universal Catalog generates based on + // the results of a data profiling scan. repeated DataQualityRule rule = 1; } @@ -471,7 +471,7 @@ message DataScan { // Output only. Identifier. The relative resource name of the scan, of the // form: `projects/{project}/locations/{location_id}/dataScans/{datascan_id}`, // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string name = 1 [ (google.api.field_behavior) = OUTPUT_ONLY, (google.api.field_behavior) = IDENTIFIER @@ -589,7 +589,7 @@ message DataScanJob { // the form: // `projects/{project}/locations/{location_id}/dataScans/{datascan_id}/jobs/{job_id}`, // where `project` refers to a *project_id* or *project_number* and - // `location_id` refers to a GCP region. + // `location_id` refers to a Google Cloud region. string name = 1 [ (google.api.field_behavior) = OUTPUT_ONLY, (google.api.field_behavior) = IDENTIFIER diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans_common.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans_common.proto new file mode 100644 index 000000000000..56456d160c94 --- /dev/null +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/datascans_common.proto @@ -0,0 +1,43 @@ +// Copyright 2025 Google LLC +// +// Licensed under the Apache License, Version 2.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.dataplex.v1; + +import "google/api/field_behavior.proto"; + +option go_package = "cloud.google.com/go/dataplex/apiv1/dataplexpb;dataplexpb"; +option java_multiple_files = true; +option java_outer_classname = "DataScansCommonProto"; +option java_package = "com.google.cloud.dataplex.v1"; + +// The status of publishing the data scan result as Dataplex Universal Catalog +// metadata. +message DataScanCatalogPublishingStatus { + // Execution state for the publishing. + enum State { + // The publishing state is unspecified. + STATE_UNSPECIFIED = 0; + + // Publish to catalog completed successfully. + SUCCEEDED = 1; + + // Publish to catalog failed. + FAILED = 2; + } + + // Output only. Execution state for catalog publishing. + State state = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; +} diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto index 977e45b92613..468e026d0fd8 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/logs.proto @@ -18,6 +18,7 @@ package google.cloud.dataplex.v1; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; +import "google/cloud/dataplex/v1/datascans_common.proto"; import "google/protobuf/duration.proto"; import "google/protobuf/timestamp.proto"; @@ -237,8 +238,8 @@ message JobEvent { // The job execution trigger is unspecified. EXECUTION_TRIGGER_UNSPECIFIED = 0; - // The job was triggered by Dataplex based on trigger spec from task - // definition. + // The job was triggered by Dataplex Universal Catalog based on trigger spec + // from task definition. TASK_CONFIG = 1; // The job was triggered by the explicit call of Task API. @@ -488,7 +489,7 @@ message DataScanEvent { // Data scan job was cancelled. CANCELLED = 4; - // Data scan job was createed. + // Data scan job was created. CREATED = 5; } @@ -671,6 +672,10 @@ message DataScanEvent { // The result of post scan actions. PostScanActionsResult post_scan_actions_result = 11; + + // The status of publishing the data scan as Dataplex Universal Catalog + // metadata. + DataScanCatalogPublishingStatus catalog_publishing_status = 13; } // Information about the result of a data quality rule for data quality scan. diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/metadata.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/metadata.proto index c1c1e97fca1b..0b6daee9deae 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/metadata.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/metadata.proto @@ -632,18 +632,20 @@ message Schema { HIVE_COMPATIBLE = 1; } - // Required. Set to `true` if user-managed or `false` if managed by Dataplex. - // The default is `false` (managed by Dataplex). + // Required. Set to `true` if user-managed or `false` if managed by Dataplex + // Universal Catalog. The default is `false` (managed by Dataplex Universal + // Catalog). // - // - Set to `false`to enable Dataplex discovery to update the schema. + // - Set to `false`to enable Dataplex Universal Catalog discovery to update + // the schema. // including new data discovery, schema inference, and schema evolution. - // Users retain the ability to input and edit the schema. Dataplex - // treats schema input by the user as though produced - // by a previous Dataplex discovery operation, and it will - // evolve the schema and take action based on that treatment. + // Users retain the ability to input and edit the schema. Dataplex Universal + // Catalog treats schema input by the user as though produced by a previous + // Dataplex Universal Catalog discovery operation, and it will evolve the + // schema and take action based on that treatment. // // - Set to `true` to fully manage the entity - // schema. This setting guarantees that Dataplex will not + // schema. This setting guarantees that Dataplex Universal Catalog will not // change schema fields. bool user_managed = 1 [(google.api.field_behavior) = REQUIRED]; diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/processing.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/processing.proto index f31850cd2bb9..37bf3c47bbcf 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/processing.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/processing.proto @@ -63,8 +63,8 @@ message DataSource { // The source is required and immutable. Once it is set, it cannot be change // to others. oneof source { - // Immutable. The Dataplex entity that represents the data source (e.g. - // BigQuery table) for DataScan, of the form: + // Immutable. The Dataplex Universal Catalog entity that represents the data + // source (e.g. BigQuery table) for DataScan, of the form: // `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/entities/{entity_id}`. string entity = 100 [ (google.api.field_behavior) = IMMUTABLE, @@ -74,8 +74,12 @@ message DataSource { ]; // Immutable. The service-qualified full resource name of the cloud resource - // for a DataScan job to scan against. The field could be: BigQuery table of - // type "TABLE" for DataProfileScan/DataQualityScan Format: + // for a DataScan job to scan against. The field could either be: Cloud + // Storage bucket for DataDiscoveryScan Format: + // //storage.googleapis.com/projects/PROJECT_ID/buckets/BUCKET_ID + // or + // BigQuery table of type "TABLE" for DataProfileScan/DataQualityScan + // Format: // //bigquery.googleapis.com/projects/PROJECT_ID/datasets/DATASET_ID/tables/TABLE_ID string resource = 101 [(google.api.field_behavior) = IMMUTABLE]; } @@ -85,15 +89,15 @@ message DataSource { message ScannedData { // A data range denoted by a pair of start/end values of a field. message IncrementalField { - // The field that contains values which monotonically increases over time - // (e.g. a timestamp column). - string field = 1; + // Output only. The field that contains values which monotonically increases + // over time (e.g. a timestamp column). + string field = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Value that marks the start of the range. - string start = 2; + // Output only. Value that marks the start of the range. + string start = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - // Value that marks the end of the range. - string end = 3; + // Output only. Value that marks the end of the range. + string end = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; } // The range of scanned data diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/service.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/service.proto index 1c902fb55af5..d4e8e0bdbec1 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/service.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/service.proto @@ -392,7 +392,7 @@ service DataplexService { message CreateLakeRequest { // Required. The resource name of the lake location, of the form: // projects/{project_number}/locations/{location_id} - // where `location_id` refers to a GCP region. + // where `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -447,7 +447,7 @@ message DeleteLakeRequest { message ListLakesRequest { // Required. The resource name of the lake location, of the form: // `projects/{project_number}/locations/{location_id}` - // where `location_id` refers to a GCP region. + // where `location_id` refers to a Google Cloud region. string parent = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { diff --git a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/tasks.proto b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/tasks.proto index 5ff0e89f86ff..78e57132829d 100644 --- a/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/tasks.proto +++ b/java-dataplex/proto-google-cloud-dataplex-v1/src/main/proto/google/cloud/dataplex/v1/tasks.proto @@ -358,7 +358,7 @@ message Job { // The job is no longer running due to an error. FAILED = 5; - // The job was cancelled outside of Dataplex. + // The job was cancelled outside of Dataplex Universal Catalog. ABORTED = 6; } @@ -367,8 +367,8 @@ message Job { // The trigger is unspecified. TRIGGER_UNSPECIFIED = 0; - // The job was triggered by Dataplex based on trigger spec from task - // definition. + // The job was triggered by Dataplex Universal Catalog based on trigger spec + // from task definition. TASK_CONFIG = 1; // The job was triggered by the explicit call of Task API. diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateSetCredentialsProvider.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateSetCredentialsProvider.java new file mode 100644 index 000000000000..8fb0e364d926 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateSetCredentialsProvider.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_Create_SetCredentialsProvider_sync] +import com.google.api.gax.core.FixedCredentialsProvider; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceSettings; +import com.google.cloud.dataplex.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 + BusinessGlossaryServiceSettings businessGlossaryServiceSettings = + BusinessGlossaryServiceSettings.newBuilder() + .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials)) + .build(); + BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create(businessGlossaryServiceSettings); + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_Create_SetCredentialsProvider_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateSetEndpoint.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateSetEndpoint.java new file mode 100644 index 000000000000..394be57d1640 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateSetEndpoint.java @@ -0,0 +1,42 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_Create_SetEndpoint_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceSettings; +import com.google.cloud.dataplex.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 + BusinessGlossaryServiceSettings businessGlossaryServiceSettings = + BusinessGlossaryServiceSettings.newBuilder().setEndpoint(myEndpoint).build(); + BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create(businessGlossaryServiceSettings); + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_Create_SetEndpoint_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateUseHttpJsonTransport.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateUseHttpJsonTransport.java new file mode 100644 index 000000000000..74e937389aec --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/create/SyncCreateUseHttpJsonTransport.java @@ -0,0 +1,41 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_Create_UseHttpJsonTransport_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceSettings; + +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 + BusinessGlossaryServiceSettings businessGlossaryServiceSettings = + BusinessGlossaryServiceSettings.newHttpJsonBuilder().build(); + BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create(businessGlossaryServiceSettings); + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_Create_UseHttpJsonTransport_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/AsyncCreateGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/AsyncCreateGlossary.java new file mode 100644 index 000000000000..472ffd5aadcd --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/AsyncCreateGlossary.java @@ -0,0 +1,55 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; +import com.google.longrunning.Operation; + +public class AsyncCreateGlossary { + + public static void main(String[] args) throws Exception { + asyncCreateGlossary(); + } + + public static void asyncCreateGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryRequest request = + CreateGlossaryRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setGlossaryId("glossaryId1849967577") + .setGlossary(Glossary.newBuilder().build()) + .setValidateOnly(true) + .build(); + ApiFuture future = + businessGlossaryServiceClient.createGlossaryCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/AsyncCreateGlossaryLRO.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/AsyncCreateGlossaryLRO.java new file mode 100644 index 000000000000..1dcd644e302a --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/AsyncCreateGlossaryLRO.java @@ -0,0 +1,55 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; +import com.google.cloud.dataplex.v1.OperationMetadata; + +public class AsyncCreateGlossaryLRO { + + public static void main(String[] args) throws Exception { + asyncCreateGlossaryLRO(); + } + + public static void asyncCreateGlossaryLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryRequest request = + CreateGlossaryRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setGlossaryId("glossaryId1849967577") + .setGlossary(Glossary.newBuilder().build()) + .setValidateOnly(true) + .build(); + OperationFuture future = + businessGlossaryServiceClient.createGlossaryOperationCallable().futureCall(request); + // Do something. + Glossary response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_LRO_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossary.java new file mode 100644 index 000000000000..9d6109f9b692 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossary.java @@ -0,0 +1,50 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; + +public class SyncCreateGlossary { + + public static void main(String[] args) throws Exception { + syncCreateGlossary(); + } + + public static void syncCreateGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryRequest request = + CreateGlossaryRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setGlossaryId("glossaryId1849967577") + .setGlossary(Glossary.newBuilder().build()) + .setValidateOnly(true) + .build(); + Glossary response = businessGlossaryServiceClient.createGlossaryAsync(request).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossaryLocationnameGlossaryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossaryLocationnameGlossaryString.java new file mode 100644 index 000000000000..ba28063329cf --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossaryLocationnameGlossaryString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_LocationnameGlossaryString_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; + +public class SyncCreateGlossaryLocationnameGlossaryString { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryLocationnameGlossaryString(); + } + + public static void syncCreateGlossaryLocationnameGlossaryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + Glossary response = + businessGlossaryServiceClient.createGlossaryAsync(parent, glossary, glossaryId).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_LocationnameGlossaryString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossaryStringGlossaryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossaryStringGlossaryString.java new file mode 100644 index 000000000000..aebd84bb92ac --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossary/SyncCreateGlossaryStringGlossaryString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_StringGlossaryString_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; + +public class SyncCreateGlossaryStringGlossaryString { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryStringGlossaryString(); + } + + public static void syncCreateGlossaryStringGlossaryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + Glossary glossary = Glossary.newBuilder().build(); + String glossaryId = "glossaryId1849967577"; + Glossary response = + businessGlossaryServiceClient.createGlossaryAsync(parent, glossary, glossaryId).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossary_StringGlossaryString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/AsyncCreateGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/AsyncCreateGlossaryCategory.java new file mode 100644 index 000000000000..c67d23d86adb --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/AsyncCreateGlossaryCategory.java @@ -0,0 +1,53 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class AsyncCreateGlossaryCategory { + + public static void main(String[] args) throws Exception { + asyncCreateGlossaryCategory(); + } + + public static void asyncCreateGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryCategoryRequest request = + CreateGlossaryCategoryRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setCategoryId("categoryId1296531129") + .setCategory(GlossaryCategory.newBuilder().build()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.createGlossaryCategoryCallable().futureCall(request); + // Do something. + GlossaryCategory response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategory.java new file mode 100644 index 000000000000..beef23840ffb --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategory.java @@ -0,0 +1,49 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncCreateGlossaryCategory { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryCategory(); + } + + public static void syncCreateGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryCategoryRequest request = + CreateGlossaryCategoryRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setCategoryId("categoryId1296531129") + .setCategory(GlossaryCategory.newBuilder().build()) + .build(); + GlossaryCategory response = businessGlossaryServiceClient.createGlossaryCategory(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategoryGlossarynameGlossarycategoryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategoryGlossarynameGlossarycategoryString.java new file mode 100644 index 000000000000..6f203fdf9575 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategoryGlossarynameGlossarycategoryString.java @@ -0,0 +1,47 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_GlossarynameGlossarycategoryString_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncCreateGlossaryCategoryGlossarynameGlossarycategoryString { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryCategoryGlossarynameGlossarycategoryString(); + } + + public static void syncCreateGlossaryCategoryGlossarynameGlossarycategoryString() + throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + GlossaryCategory response = + businessGlossaryServiceClient.createGlossaryCategory(parent, category, categoryId); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_GlossarynameGlossarycategoryString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategoryStringGlossarycategoryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategoryStringGlossarycategoryString.java new file mode 100644 index 000000000000..53731f8c2040 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossarycategory/SyncCreateGlossaryCategoryStringGlossarycategoryString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_StringGlossarycategoryString_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncCreateGlossaryCategoryStringGlossarycategoryString { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryCategoryStringGlossarycategoryString(); + } + + public static void syncCreateGlossaryCategoryStringGlossarycategoryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString(); + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + String categoryId = "categoryId1296531129"; + GlossaryCategory response = + businessGlossaryServiceClient.createGlossaryCategory(parent, category, categoryId); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryCategory_StringGlossarycategoryString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/AsyncCreateGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/AsyncCreateGlossaryTerm.java new file mode 100644 index 000000000000..edea94bfe781 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/AsyncCreateGlossaryTerm.java @@ -0,0 +1,53 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; + +public class AsyncCreateGlossaryTerm { + + public static void main(String[] args) throws Exception { + asyncCreateGlossaryTerm(); + } + + public static void asyncCreateGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryTermRequest request = + CreateGlossaryTermRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setTermId("termId-877206873") + .setTerm(GlossaryTerm.newBuilder().build()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.createGlossaryTermCallable().futureCall(request); + // Do something. + GlossaryTerm response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTerm.java new file mode 100644 index 000000000000..0598e90a6977 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTerm.java @@ -0,0 +1,49 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.CreateGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; + +public class SyncCreateGlossaryTerm { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryTerm(); + } + + public static void syncCreateGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + CreateGlossaryTermRequest request = + CreateGlossaryTermRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setTermId("termId-877206873") + .setTerm(GlossaryTerm.newBuilder().build()) + .build(); + GlossaryTerm response = businessGlossaryServiceClient.createGlossaryTerm(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTermGlossarynameGlossarytermString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTermGlossarynameGlossarytermString.java new file mode 100644 index 000000000000..1ac9161dfc44 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTermGlossarynameGlossarytermString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_GlossarynameGlossarytermString_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; + +public class SyncCreateGlossaryTermGlossarynameGlossarytermString { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryTermGlossarynameGlossarytermString(); + } + + public static void syncCreateGlossaryTermGlossarynameGlossarytermString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + GlossaryTerm response = + businessGlossaryServiceClient.createGlossaryTerm(parent, term, termId); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_GlossarynameGlossarytermString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTermStringGlossarytermString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTermStringGlossarytermString.java new file mode 100644 index 000000000000..d2ea1f48e54e --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/createglossaryterm/SyncCreateGlossaryTermStringGlossarytermString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_StringGlossarytermString_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; + +public class SyncCreateGlossaryTermStringGlossarytermString { + + public static void main(String[] args) throws Exception { + syncCreateGlossaryTermStringGlossarytermString(); + } + + public static void syncCreateGlossaryTermStringGlossarytermString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString(); + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + String termId = "termId-877206873"; + GlossaryTerm response = + businessGlossaryServiceClient.createGlossaryTerm(parent, term, termId); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_CreateGlossaryTerm_StringGlossarytermString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/AsyncDeleteGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/AsyncDeleteGlossary.java new file mode 100644 index 000000000000..5bb8e788889c --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/AsyncDeleteGlossary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.longrunning.Operation; + +public class AsyncDeleteGlossary { + + public static void main(String[] args) throws Exception { + asyncDeleteGlossary(); + } + + public static void asyncDeleteGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryRequest request = + DeleteGlossaryRequest.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setEtag("etag3123477") + .build(); + ApiFuture future = + businessGlossaryServiceClient.deleteGlossaryCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/AsyncDeleteGlossaryLRO.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/AsyncDeleteGlossaryLRO.java new file mode 100644 index 000000000000..a2595ec51d1a --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/AsyncDeleteGlossaryLRO.java @@ -0,0 +1,53 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.OperationMetadata; +import com.google.protobuf.Empty; + +public class AsyncDeleteGlossaryLRO { + + public static void main(String[] args) throws Exception { + asyncDeleteGlossaryLRO(); + } + + public static void asyncDeleteGlossaryLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryRequest request = + DeleteGlossaryRequest.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setEtag("etag3123477") + .build(); + OperationFuture future = + businessGlossaryServiceClient.deleteGlossaryOperationCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_LRO_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossary.java new file mode 100644 index 000000000000..7b112e43b876 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossary.java @@ -0,0 +1,48 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryRequest; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossary { + + public static void main(String[] args) throws Exception { + syncDeleteGlossary(); + } + + public static void syncDeleteGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryRequest request = + DeleteGlossaryRequest.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setEtag("etag3123477") + .build(); + businessGlossaryServiceClient.deleteGlossaryAsync(request).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossaryGlossaryname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossaryGlossaryname.java new file mode 100644 index 000000000000..c7144ad5d4db --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossaryGlossaryname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_Glossaryname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryGlossaryname { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryGlossaryname(); + } + + public static void syncDeleteGlossaryGlossaryname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + businessGlossaryServiceClient.deleteGlossaryAsync(name).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_Glossaryname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossaryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossaryString.java new file mode 100644 index 000000000000..a05d55f997b7 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossary/SyncDeleteGlossaryString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryString { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryString(); + } + + public static void syncDeleteGlossaryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString(); + businessGlossaryServiceClient.deleteGlossaryAsync(name).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossary_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/AsyncDeleteGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/AsyncDeleteGlossaryCategory.java new file mode 100644 index 000000000000..7bfe12816668 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/AsyncDeleteGlossaryCategory.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; +import com.google.protobuf.Empty; + +public class AsyncDeleteGlossaryCategory { + + public static void main(String[] args) throws Exception { + asyncDeleteGlossaryCategory(); + } + + public static void asyncDeleteGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryCategoryRequest request = + DeleteGlossaryCategoryRequest.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.deleteGlossaryCategoryCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategory.java new file mode 100644 index 000000000000..f86aa09d42f6 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategory.java @@ -0,0 +1,50 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryCategory { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryCategory(); + } + + public static void syncDeleteGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryCategoryRequest request = + DeleteGlossaryCategoryRequest.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .build(); + businessGlossaryServiceClient.deleteGlossaryCategory(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategoryGlossarycategoryname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategoryGlossarycategoryname.java new file mode 100644 index 000000000000..95b5cf8c39aa --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategoryGlossarycategoryname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_Glossarycategoryname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryCategoryGlossarycategoryname { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryCategoryGlossarycategoryname(); + } + + public static void syncDeleteGlossaryCategoryGlossarycategoryname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + businessGlossaryServiceClient.deleteGlossaryCategory(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_Glossarycategoryname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategoryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategoryString.java new file mode 100644 index 000000000000..e8be73cb7645 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossarycategory/SyncDeleteGlossaryCategoryString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryCategoryString { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryCategoryString(); + } + + public static void syncDeleteGlossaryCategoryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString(); + businessGlossaryServiceClient.deleteGlossaryCategory(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryCategory_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/AsyncDeleteGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/AsyncDeleteGlossaryTerm.java new file mode 100644 index 000000000000..b1c8cf67c02c --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/AsyncDeleteGlossaryTerm.java @@ -0,0 +1,53 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GlossaryTermName; +import com.google.protobuf.Empty; + +public class AsyncDeleteGlossaryTerm { + + public static void main(String[] args) throws Exception { + asyncDeleteGlossaryTerm(); + } + + public static void asyncDeleteGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryTermRequest request = + DeleteGlossaryTermRequest.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.deleteGlossaryTermCallable().futureCall(request); + // Do something. + future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTerm.java new file mode 100644 index 000000000000..098cebe3e48e --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTerm.java @@ -0,0 +1,49 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.DeleteGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GlossaryTermName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryTerm { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryTerm(); + } + + public static void syncDeleteGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + DeleteGlossaryTermRequest request = + DeleteGlossaryTermRequest.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .build(); + businessGlossaryServiceClient.deleteGlossaryTerm(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTermGlossarytermname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTermGlossarytermname.java new file mode 100644 index 000000000000..ec02f9047bb2 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTermGlossarytermname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_Glossarytermname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTermName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryTermGlossarytermname { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryTermGlossarytermname(); + } + + public static void syncDeleteGlossaryTermGlossarytermname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + businessGlossaryServiceClient.deleteGlossaryTerm(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_Glossarytermname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTermString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTermString.java new file mode 100644 index 000000000000..cd8252ad0984 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/deleteglossaryterm/SyncDeleteGlossaryTermString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTermName; +import com.google.protobuf.Empty; + +public class SyncDeleteGlossaryTermString { + + public static void main(String[] args) throws Exception { + syncDeleteGlossaryTermString(); + } + + public static void syncDeleteGlossaryTermString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString(); + businessGlossaryServiceClient.deleteGlossaryTerm(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_DeleteGlossaryTerm_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/AsyncGetGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/AsyncGetGlossary.java new file mode 100644 index 000000000000..b9fe10eddb18 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/AsyncGetGlossary.java @@ -0,0 +1,51 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossary_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GetGlossaryRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class AsyncGetGlossary { + + public static void main(String[] args) throws Exception { + asyncGetGlossary(); + } + + public static void asyncGetGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetGlossaryRequest request = + GetGlossaryRequest.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.getGlossaryCallable().futureCall(request); + // Do something. + Glossary response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossary_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossary.java new file mode 100644 index 000000000000..e9c9d699fb70 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossary.java @@ -0,0 +1,47 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossary_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GetGlossaryRequest; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncGetGlossary { + + public static void main(String[] args) throws Exception { + syncGetGlossary(); + } + + public static void syncGetGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetGlossaryRequest request = + GetGlossaryRequest.newBuilder() + .setName(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .build(); + Glossary response = businessGlossaryServiceClient.getGlossary(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossaryGlossaryname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossaryGlossaryname.java new file mode 100644 index 000000000000..c5353102faa7 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossaryGlossaryname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossary_Glossaryname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncGetGlossaryGlossaryname { + + public static void main(String[] args) throws Exception { + syncGetGlossaryGlossaryname(); + } + + public static void syncGetGlossaryGlossaryname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryName name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + Glossary response = businessGlossaryServiceClient.getGlossary(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossary_Glossaryname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossaryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossaryString.java new file mode 100644 index 000000000000..3ff1f45bbd2a --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossary/SyncGetGlossaryString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossary_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncGetGlossaryString { + + public static void main(String[] args) throws Exception { + syncGetGlossaryString(); + } + + public static void syncGetGlossaryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String name = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString(); + Glossary response = businessGlossaryServiceClient.getGlossary(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossary_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/AsyncGetGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/AsyncGetGlossaryCategory.java new file mode 100644 index 000000000000..0ec57d8de06e --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/AsyncGetGlossaryCategory.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; + +public class AsyncGetGlossaryCategory { + + public static void main(String[] args) throws Exception { + asyncGetGlossaryCategory(); + } + + public static void asyncGetGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetGlossaryCategoryRequest request = + GetGlossaryCategoryRequest.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.getGlossaryCategoryCallable().futureCall(request); + // Do something. + GlossaryCategory response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategory.java new file mode 100644 index 000000000000..9093f45f0f7a --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategory.java @@ -0,0 +1,50 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GetGlossaryCategoryRequest; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; + +public class SyncGetGlossaryCategory { + + public static void main(String[] args) throws Exception { + syncGetGlossaryCategory(); + } + + public static void syncGetGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetGlossaryCategoryRequest request = + GetGlossaryCategoryRequest.newBuilder() + .setName( + GlossaryCategoryName.of( + "[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString()) + .build(); + GlossaryCategory response = businessGlossaryServiceClient.getGlossaryCategory(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategoryGlossarycategoryname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategoryGlossarycategoryname.java new file mode 100644 index 000000000000..645c93302662 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategoryGlossarycategoryname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_Glossarycategoryname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; + +public class SyncGetGlossaryCategoryGlossarycategoryname { + + public static void main(String[] args) throws Exception { + syncGetGlossaryCategoryGlossarycategoryname(); + } + + public static void syncGetGlossaryCategoryGlossarycategoryname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryCategoryName name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]"); + GlossaryCategory response = businessGlossaryServiceClient.getGlossaryCategory(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_Glossarycategoryname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategoryString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategoryString.java new file mode 100644 index 000000000000..9a54b1bc4d7d --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossarycategory/SyncGetGlossaryCategoryString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryCategoryName; + +public class SyncGetGlossaryCategoryString { + + public static void main(String[] args) throws Exception { + syncGetGlossaryCategoryString(); + } + + public static void syncGetGlossaryCategoryString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String name = + GlossaryCategoryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_CATEGORY]") + .toString(); + GlossaryCategory response = businessGlossaryServiceClient.getGlossaryCategory(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryCategory_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/AsyncGetGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/AsyncGetGlossaryTerm.java new file mode 100644 index 000000000000..7e4811626a50 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/AsyncGetGlossaryTerm.java @@ -0,0 +1,53 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GetGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.GlossaryTermName; + +public class AsyncGetGlossaryTerm { + + public static void main(String[] args) throws Exception { + asyncGetGlossaryTerm(); + } + + public static void asyncGetGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetGlossaryTermRequest request = + GetGlossaryTermRequest.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.getGlossaryTermCallable().futureCall(request); + // Do something. + GlossaryTerm response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTerm.java new file mode 100644 index 000000000000..d0499d62f8a5 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTerm.java @@ -0,0 +1,49 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GetGlossaryTermRequest; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.GlossaryTermName; + +public class SyncGetGlossaryTerm { + + public static void main(String[] args) throws Exception { + syncGetGlossaryTerm(); + } + + public static void syncGetGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetGlossaryTermRequest request = + GetGlossaryTermRequest.newBuilder() + .setName( + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString()) + .build(); + GlossaryTerm response = businessGlossaryServiceClient.getGlossaryTerm(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTermGlossarytermname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTermGlossarytermname.java new file mode 100644 index 000000000000..21925c01f8fb --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTermGlossarytermname.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_Glossarytermname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.GlossaryTermName; + +public class SyncGetGlossaryTermGlossarytermname { + + public static void main(String[] args) throws Exception { + syncGetGlossaryTermGlossarytermname(); + } + + public static void syncGetGlossaryTermGlossarytermname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryTermName name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]"); + GlossaryTerm response = businessGlossaryServiceClient.getGlossaryTerm(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_Glossarytermname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTermString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTermString.java new file mode 100644 index 000000000000..1f13da4a33e1 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getglossaryterm/SyncGetGlossaryTermString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.GlossaryTermName; + +public class SyncGetGlossaryTermString { + + public static void main(String[] args) throws Exception { + syncGetGlossaryTermString(); + } + + public static void syncGetGlossaryTermString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String name = + GlossaryTermName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]", "[GLOSSARY_TERM]") + .toString(); + GlossaryTerm response = businessGlossaryServiceClient.getGlossaryTerm(name); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetGlossaryTerm_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getlocation/AsyncGetLocation.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getlocation/AsyncGetLocation.java new file mode 100644 index 000000000000..ef6b492385e2 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getlocation/AsyncGetLocation.java @@ -0,0 +1,47 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetLocation_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +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 (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + ApiFuture future = + businessGlossaryServiceClient.getLocationCallable().futureCall(request); + // Do something. + Location response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetLocation_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getlocation/SyncGetLocation.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getlocation/SyncGetLocation.java new file mode 100644 index 000000000000..9f6807f32f96 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/getlocation/SyncGetLocation.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_GetLocation_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +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 (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GetLocationRequest request = GetLocationRequest.newBuilder().setName("name3373707").build(); + Location response = businessGlossaryServiceClient.getLocation(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_GetLocation_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/AsyncListGlossaries.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/AsyncListGlossaries.java new file mode 100644 index 000000000000..a22d21790a53 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/AsyncListGlossaries.java @@ -0,0 +1,57 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.LocationName; + +public class AsyncListGlossaries { + + public static void main(String[] args) throws Exception { + asyncListGlossaries(); + } + + public static void asyncListGlossaries() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossariesRequest request = + ListGlossariesRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + businessGlossaryServiceClient.listGlossariesPagedCallable().futureCall(request); + // Do something. + for (Glossary element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/AsyncListGlossariesPaged.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/AsyncListGlossariesPaged.java new file mode 100644 index 000000000000..fc35272d5187 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/AsyncListGlossariesPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_Paged_async] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.ListGlossariesResponse; +import com.google.cloud.dataplex.v1.LocationName; +import com.google.common.base.Strings; + +public class AsyncListGlossariesPaged { + + public static void main(String[] args) throws Exception { + asyncListGlossariesPaged(); + } + + public static void asyncListGlossariesPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossariesRequest request = + ListGlossariesRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListGlossariesResponse response = + businessGlossaryServiceClient.listGlossariesCallable().call(request); + for (Glossary element : response.getGlossariesList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_Paged_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossaries.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossaries.java new file mode 100644 index 000000000000..8df93e92c079 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossaries.java @@ -0,0 +1,53 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.ListGlossariesRequest; +import com.google.cloud.dataplex.v1.LocationName; + +public class SyncListGlossaries { + + public static void main(String[] args) throws Exception { + syncListGlossaries(); + } + + public static void syncListGlossaries() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossariesRequest request = + ListGlossariesRequest.newBuilder() + .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (Glossary element : businessGlossaryServiceClient.listGlossaries(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossariesLocationname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossariesLocationname.java new file mode 100644 index 000000000000..f7a3514c512d --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossariesLocationname.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_Locationname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; + +public class SyncListGlossariesLocationname { + + public static void main(String[] args) throws Exception { + syncListGlossariesLocationname(); + } + + public static void syncListGlossariesLocationname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + for (Glossary element : businessGlossaryServiceClient.listGlossaries(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_Locationname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossariesString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossariesString.java new file mode 100644 index 000000000000..bea3ecc483dd --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaries/SyncListGlossariesString.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.LocationName; + +public class SyncListGlossariesString { + + public static void main(String[] args) throws Exception { + syncListGlossariesString(); + } + + public static void syncListGlossariesString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString(); + for (Glossary element : businessGlossaryServiceClient.listGlossaries(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaries_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/AsyncListGlossaryCategories.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/AsyncListGlossaryCategories.java new file mode 100644 index 000000000000..23d2cafe9b69 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/AsyncListGlossaryCategories.java @@ -0,0 +1,57 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; + +public class AsyncListGlossaryCategories { + + public static void main(String[] args) throws Exception { + asyncListGlossaryCategories(); + } + + public static void asyncListGlossaryCategories() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossaryCategoriesRequest request = + ListGlossaryCategoriesRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + businessGlossaryServiceClient.listGlossaryCategoriesPagedCallable().futureCall(request); + // Do something. + for (GlossaryCategory element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/AsyncListGlossaryCategoriesPaged.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/AsyncListGlossaryCategoriesPaged.java new file mode 100644 index 000000000000..48e19c6a0fc2 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/AsyncListGlossaryCategoriesPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_Paged_async] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesResponse; +import com.google.common.base.Strings; + +public class AsyncListGlossaryCategoriesPaged { + + public static void main(String[] args) throws Exception { + asyncListGlossaryCategoriesPaged(); + } + + public static void asyncListGlossaryCategoriesPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossaryCategoriesRequest request = + ListGlossaryCategoriesRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListGlossaryCategoriesResponse response = + businessGlossaryServiceClient.listGlossaryCategoriesCallable().call(request); + for (GlossaryCategory element : response.getCategoriesList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_Paged_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategories.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategories.java new file mode 100644 index 000000000000..e8af05282ed6 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategories.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.ListGlossaryCategoriesRequest; + +public class SyncListGlossaryCategories { + + public static void main(String[] args) throws Exception { + syncListGlossaryCategories(); + } + + public static void syncListGlossaryCategories() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossaryCategoriesRequest request = + ListGlossaryCategoriesRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (GlossaryCategory element : + businessGlossaryServiceClient.listGlossaryCategories(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategoriesGlossaryname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategoriesGlossaryname.java new file mode 100644 index 000000000000..c21c1e0d82b7 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategoriesGlossaryname.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_Glossaryname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncListGlossaryCategoriesGlossaryname { + + public static void main(String[] args) throws Exception { + syncListGlossaryCategoriesGlossaryname(); + } + + public static void syncListGlossaryCategoriesGlossaryname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + for (GlossaryCategory element : + businessGlossaryServiceClient.listGlossaryCategories(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_Glossaryname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategoriesString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategoriesString.java new file mode 100644 index 000000000000..a0a8c7941d13 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossarycategories/SyncListGlossaryCategoriesString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.GlossaryName; + +public class SyncListGlossaryCategoriesString { + + public static void main(String[] args) throws Exception { + syncListGlossaryCategoriesString(); + } + + public static void syncListGlossaryCategoriesString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString(); + for (GlossaryCategory element : + businessGlossaryServiceClient.listGlossaryCategories(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryCategories_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/AsyncListGlossaryTerms.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/AsyncListGlossaryTerms.java new file mode 100644 index 000000000000..51658a663884 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/AsyncListGlossaryTerms.java @@ -0,0 +1,57 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; + +public class AsyncListGlossaryTerms { + + public static void main(String[] args) throws Exception { + asyncListGlossaryTerms(); + } + + public static void asyncListGlossaryTerms() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossaryTermsRequest request = + ListGlossaryTermsRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + ApiFuture future = + businessGlossaryServiceClient.listGlossaryTermsPagedCallable().futureCall(request); + // Do something. + for (GlossaryTerm element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/AsyncListGlossaryTermsPaged.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/AsyncListGlossaryTermsPaged.java new file mode 100644 index 000000000000..4e1a1a30d924 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/AsyncListGlossaryTermsPaged.java @@ -0,0 +1,65 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_Paged_async] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; +import com.google.cloud.dataplex.v1.ListGlossaryTermsResponse; +import com.google.common.base.Strings; + +public class AsyncListGlossaryTermsPaged { + + public static void main(String[] args) throws Exception { + asyncListGlossaryTermsPaged(); + } + + public static void asyncListGlossaryTermsPaged() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossaryTermsRequest request = + ListGlossaryTermsRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + while (true) { + ListGlossaryTermsResponse response = + businessGlossaryServiceClient.listGlossaryTermsCallable().call(request); + for (GlossaryTerm element : response.getTermsList()) { + // doThingsWith(element); + } + String nextPageToken = response.getNextPageToken(); + if (!Strings.isNullOrEmpty(nextPageToken)) { + request = request.toBuilder().setPageToken(nextPageToken).build(); + } else { + break; + } + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_Paged_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTerms.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTerms.java new file mode 100644 index 000000000000..129940687403 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTerms.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.ListGlossaryTermsRequest; + +public class SyncListGlossaryTerms { + + public static void main(String[] args) throws Exception { + syncListGlossaryTerms(); + } + + public static void syncListGlossaryTerms() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListGlossaryTermsRequest request = + ListGlossaryTermsRequest.newBuilder() + .setParent(GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString()) + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .setFilter("filter-1274492040") + .setOrderBy("orderBy-1207110587") + .build(); + for (GlossaryTerm element : + businessGlossaryServiceClient.listGlossaryTerms(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTermsGlossaryname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTermsGlossaryname.java new file mode 100644 index 000000000000..4da776c231be --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTermsGlossaryname.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_Glossaryname_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; + +public class SyncListGlossaryTermsGlossaryname { + + public static void main(String[] args) throws Exception { + syncListGlossaryTermsGlossaryname(); + } + + public static void syncListGlossaryTermsGlossaryname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryName parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]"); + for (GlossaryTerm element : + businessGlossaryServiceClient.listGlossaryTerms(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_Glossaryname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTermsString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTermsString.java new file mode 100644 index 000000000000..c1565e022679 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listglossaryterms/SyncListGlossaryTermsString.java @@ -0,0 +1,46 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_String_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryName; +import com.google.cloud.dataplex.v1.GlossaryTerm; + +public class SyncListGlossaryTermsString { + + public static void main(String[] args) throws Exception { + syncListGlossaryTermsString(); + } + + public static void syncListGlossaryTermsString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + String parent = GlossaryName.of("[PROJECT]", "[LOCATION]", "[GLOSSARY]").toString(); + for (GlossaryTerm element : + businessGlossaryServiceClient.listGlossaryTerms(parent).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListGlossaryTerms_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/AsyncListLocations.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/AsyncListLocations.java new file mode 100644 index 000000000000..bc24302887e5 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/AsyncListLocations.java @@ -0,0 +1,55 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListLocations_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +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 (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + ApiFuture future = + businessGlossaryServiceClient.listLocationsPagedCallable().futureCall(request); + // Do something. + for (Location element : future.get().iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListLocations_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/AsyncListLocationsPaged.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/AsyncListLocationsPaged.java new file mode 100644 index 000000000000..09f7c68ab764 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/AsyncListLocationsPaged.java @@ -0,0 +1,63 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListLocations_Paged_async] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +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 (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + while (true) { + ListLocationsResponse response = + businessGlossaryServiceClient.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 dataplex_v1_generated_BusinessGlossaryService_ListLocations_Paged_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/SyncListLocations.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/SyncListLocations.java new file mode 100644 index 000000000000..fcbda05f41ce --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/listlocations/SyncListLocations.java @@ -0,0 +1,51 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_ListLocations_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +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 (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + ListLocationsRequest request = + ListLocationsRequest.newBuilder() + .setName("name3373707") + .setFilter("filter-1274492040") + .setPageSize(883849137) + .setPageToken("pageToken873572522") + .build(); + for (Location element : businessGlossaryServiceClient.listLocations(request).iterateAll()) { + // doThingsWith(element); + } + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_ListLocations_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/AsyncUpdateGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/AsyncUpdateGlossary.java new file mode 100644 index 000000000000..43b7311777a5 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/AsyncUpdateGlossary.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.longrunning.Operation; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGlossary { + + public static void main(String[] args) throws Exception { + asyncUpdateGlossary(); + } + + public static void asyncUpdateGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryRequest request = + UpdateGlossaryRequest.newBuilder() + .setGlossary(Glossary.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setValidateOnly(true) + .build(); + ApiFuture future = + businessGlossaryServiceClient.updateGlossaryCallable().futureCall(request); + // Do something. + Operation response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/AsyncUpdateGlossaryLRO.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/AsyncUpdateGlossaryLRO.java new file mode 100644 index 000000000000..74ff742744b8 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/AsyncUpdateGlossaryLRO.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_LRO_async] +import com.google.api.gax.longrunning.OperationFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.OperationMetadata; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGlossaryLRO { + + public static void main(String[] args) throws Exception { + asyncUpdateGlossaryLRO(); + } + + public static void asyncUpdateGlossaryLRO() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryRequest request = + UpdateGlossaryRequest.newBuilder() + .setGlossary(Glossary.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setValidateOnly(true) + .build(); + OperationFuture future = + businessGlossaryServiceClient.updateGlossaryOperationCallable().futureCall(request); + // Do something. + Glossary response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_LRO_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/SyncUpdateGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/SyncUpdateGlossary.java new file mode 100644 index 000000000000..e590dc562b0c --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/SyncUpdateGlossary.java @@ -0,0 +1,49 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.cloud.dataplex.v1.UpdateGlossaryRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGlossary { + + public static void main(String[] args) throws Exception { + syncUpdateGlossary(); + } + + public static void syncUpdateGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryRequest request = + UpdateGlossaryRequest.newBuilder() + .setGlossary(Glossary.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .setValidateOnly(true) + .build(); + Glossary response = businessGlossaryServiceClient.updateGlossaryAsync(request).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/SyncUpdateGlossaryGlossaryFieldmask.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/SyncUpdateGlossaryGlossaryFieldmask.java new file mode 100644 index 000000000000..99612fe904d1 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossary/SyncUpdateGlossaryGlossaryFieldmask.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_GlossaryFieldmask_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.Glossary; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGlossaryGlossaryFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateGlossaryGlossaryFieldmask(); + } + + public static void syncUpdateGlossaryGlossaryFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + Glossary glossary = Glossary.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + Glossary response = + businessGlossaryServiceClient.updateGlossaryAsync(glossary, updateMask).get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossary_GlossaryFieldmask_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/AsyncUpdateGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/AsyncUpdateGlossaryCategory.java new file mode 100644 index 000000000000..14a493a7506d --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/AsyncUpdateGlossaryCategory.java @@ -0,0 +1,52 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryCategory_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGlossaryCategory { + + public static void main(String[] args) throws Exception { + asyncUpdateGlossaryCategory(); + } + + public static void asyncUpdateGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryCategoryRequest request = + UpdateGlossaryCategoryRequest.newBuilder() + .setCategory(GlossaryCategory.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.updateGlossaryCategoryCallable().futureCall(request); + // Do something. + GlossaryCategory response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryCategory_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/SyncUpdateGlossaryCategory.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/SyncUpdateGlossaryCategory.java new file mode 100644 index 000000000000..cf43bd0cf88b --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/SyncUpdateGlossaryCategory.java @@ -0,0 +1,48 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryCategory_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.cloud.dataplex.v1.UpdateGlossaryCategoryRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGlossaryCategory { + + public static void main(String[] args) throws Exception { + syncUpdateGlossaryCategory(); + } + + public static void syncUpdateGlossaryCategory() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryCategoryRequest request = + UpdateGlossaryCategoryRequest.newBuilder() + .setCategory(GlossaryCategory.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + GlossaryCategory response = businessGlossaryServiceClient.updateGlossaryCategory(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryCategory_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/SyncUpdateGlossaryCategoryGlossarycategoryFieldmask.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/SyncUpdateGlossaryCategoryGlossarycategoryFieldmask.java new file mode 100644 index 000000000000..a9ccf475d635 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossarycategory/SyncUpdateGlossaryCategoryGlossarycategoryFieldmask.java @@ -0,0 +1,45 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryCategory_GlossarycategoryFieldmask_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryCategory; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGlossaryCategoryGlossarycategoryFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateGlossaryCategoryGlossarycategoryFieldmask(); + } + + public static void syncUpdateGlossaryCategoryGlossarycategoryFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryCategory category = GlossaryCategory.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + GlossaryCategory response = + businessGlossaryServiceClient.updateGlossaryCategory(category, updateMask); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryCategory_GlossarycategoryFieldmask_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/AsyncUpdateGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/AsyncUpdateGlossaryTerm.java new file mode 100644 index 000000000000..e4ebcfd7956f --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/AsyncUpdateGlossaryTerm.java @@ -0,0 +1,52 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryTerm_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest; +import com.google.protobuf.FieldMask; + +public class AsyncUpdateGlossaryTerm { + + public static void main(String[] args) throws Exception { + asyncUpdateGlossaryTerm(); + } + + public static void asyncUpdateGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryTermRequest request = + UpdateGlossaryTermRequest.newBuilder() + .setTerm(GlossaryTerm.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + ApiFuture future = + businessGlossaryServiceClient.updateGlossaryTermCallable().futureCall(request); + // Do something. + GlossaryTerm response = future.get(); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryTerm_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/SyncUpdateGlossaryTerm.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/SyncUpdateGlossaryTerm.java new file mode 100644 index 000000000000..a3a47927927e --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/SyncUpdateGlossaryTerm.java @@ -0,0 +1,48 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryTerm_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.cloud.dataplex.v1.UpdateGlossaryTermRequest; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGlossaryTerm { + + public static void main(String[] args) throws Exception { + syncUpdateGlossaryTerm(); + } + + public static void syncUpdateGlossaryTerm() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + UpdateGlossaryTermRequest request = + UpdateGlossaryTermRequest.newBuilder() + .setTerm(GlossaryTerm.newBuilder().build()) + .setUpdateMask(FieldMask.newBuilder().build()) + .build(); + GlossaryTerm response = businessGlossaryServiceClient.updateGlossaryTerm(request); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryTerm_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/SyncUpdateGlossaryTermGlossarytermFieldmask.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/SyncUpdateGlossaryTermGlossarytermFieldmask.java new file mode 100644 index 000000000000..061366f93929 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservice/updateglossaryterm/SyncUpdateGlossaryTermGlossarytermFieldmask.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryTerm_GlossarytermFieldmask_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceClient; +import com.google.cloud.dataplex.v1.GlossaryTerm; +import com.google.protobuf.FieldMask; + +public class SyncUpdateGlossaryTermGlossarytermFieldmask { + + public static void main(String[] args) throws Exception { + syncUpdateGlossaryTermGlossarytermFieldmask(); + } + + public static void syncUpdateGlossaryTermGlossarytermFieldmask() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (BusinessGlossaryServiceClient businessGlossaryServiceClient = + BusinessGlossaryServiceClient.create()) { + GlossaryTerm term = GlossaryTerm.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + GlossaryTerm response = businessGlossaryServiceClient.updateGlossaryTerm(term, updateMask); + } + } +} +// [END dataplex_v1_generated_BusinessGlossaryService_UpdateGlossaryTerm_GlossarytermFieldmask_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservicesettings/createglossary/SyncCreateGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservicesettings/createglossary/SyncCreateGlossary.java new file mode 100644 index 000000000000..629760d55c86 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservicesettings/createglossary/SyncCreateGlossary.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryServiceSettings_CreateGlossary_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.dataplex.v1.BusinessGlossaryServiceSettings; +import java.time.Duration; + +public class SyncCreateGlossary { + + public static void main(String[] args) throws Exception { + syncCreateGlossary(); + } + + public static void syncCreateGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + BusinessGlossaryServiceSettings.Builder businessGlossaryServiceSettingsBuilder = + BusinessGlossaryServiceSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + businessGlossaryServiceSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END dataplex_v1_generated_BusinessGlossaryServiceSettings_CreateGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservicesettings/getglossary/SyncGetGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservicesettings/getglossary/SyncGetGlossary.java new file mode 100644 index 000000000000..35c179068ced --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/businessglossaryservicesettings/getglossary/SyncGetGlossary.java @@ -0,0 +1,57 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_BusinessGlossaryServiceSettings_GetGlossary_sync] +import com.google.cloud.dataplex.v1.BusinessGlossaryServiceSettings; +import java.time.Duration; + +public class SyncGetGlossary { + + public static void main(String[] args) throws Exception { + syncGetGlossary(); + } + + public static void syncGetGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + BusinessGlossaryServiceSettings.Builder businessGlossaryServiceSettingsBuilder = + BusinessGlossaryServiceSettings.newBuilder(); + businessGlossaryServiceSettingsBuilder + .getGlossarySettings() + .setRetrySettings( + businessGlossaryServiceSettingsBuilder + .getGlossarySettings() + .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()); + BusinessGlossaryServiceSettings businessGlossaryServiceSettings = + businessGlossaryServiceSettingsBuilder.build(); + } +} +// [END dataplex_v1_generated_BusinessGlossaryServiceSettings_GetGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/AsyncCreateEntryLink.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/AsyncCreateEntryLink.java new file mode 100644 index 000000000000..61dd320fd93b --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/AsyncCreateEntryLink.java @@ -0,0 +1,52 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_CreateEntryLink_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.CreateEntryLinkRequest; +import com.google.cloud.dataplex.v1.EntryGroupName; +import com.google.cloud.dataplex.v1.EntryLink; + +public class AsyncCreateEntryLink { + + public static void main(String[] args) throws Exception { + asyncCreateEntryLink(); + } + + public static void asyncCreateEntryLink() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + CreateEntryLinkRequest request = + CreateEntryLinkRequest.newBuilder() + .setParent(EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]").toString()) + .setEntryLinkId("entryLinkId-1349584441") + .setEntryLink(EntryLink.newBuilder().build()) + .build(); + ApiFuture future = + catalogServiceClient.createEntryLinkCallable().futureCall(request); + // Do something. + EntryLink response = future.get(); + } + } +} +// [END dataplex_v1_generated_CatalogService_CreateEntryLink_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLink.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLink.java new file mode 100644 index 000000000000..36118405ab35 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLink.java @@ -0,0 +1,48 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_CreateEntryLink_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.CreateEntryLinkRequest; +import com.google.cloud.dataplex.v1.EntryGroupName; +import com.google.cloud.dataplex.v1.EntryLink; + +public class SyncCreateEntryLink { + + public static void main(String[] args) throws Exception { + syncCreateEntryLink(); + } + + public static void syncCreateEntryLink() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + CreateEntryLinkRequest request = + CreateEntryLinkRequest.newBuilder() + .setParent(EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]").toString()) + .setEntryLinkId("entryLinkId-1349584441") + .setEntryLink(EntryLink.newBuilder().build()) + .build(); + EntryLink response = catalogServiceClient.createEntryLink(request); + } + } +} +// [END dataplex_v1_generated_CatalogService_CreateEntryLink_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLinkEntrygroupnameEntrylinkString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLinkEntrygroupnameEntrylinkString.java new file mode 100644 index 000000000000..cf4419594f32 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLinkEntrygroupnameEntrylinkString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_CreateEntryLink_EntrygroupnameEntrylinkString_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryGroupName; +import com.google.cloud.dataplex.v1.EntryLink; + +public class SyncCreateEntryLinkEntrygroupnameEntrylinkString { + + public static void main(String[] args) throws Exception { + syncCreateEntryLinkEntrygroupnameEntrylinkString(); + } + + public static void syncCreateEntryLinkEntrygroupnameEntrylinkString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + EntryGroupName parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]"); + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + EntryLink response = catalogServiceClient.createEntryLink(parent, entryLink, entryLinkId); + } + } +} +// [END dataplex_v1_generated_CatalogService_CreateEntryLink_EntrygroupnameEntrylinkString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLinkStringEntrylinkString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLinkStringEntrylinkString.java new file mode 100644 index 000000000000..61db3423418f --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/createentrylink/SyncCreateEntryLinkStringEntrylinkString.java @@ -0,0 +1,44 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_CreateEntryLink_StringEntrylinkString_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryGroupName; +import com.google.cloud.dataplex.v1.EntryLink; + +public class SyncCreateEntryLinkStringEntrylinkString { + + public static void main(String[] args) throws Exception { + syncCreateEntryLinkStringEntrylinkString(); + } + + public static void syncCreateEntryLinkStringEntrylinkString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + String parent = EntryGroupName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]").toString(); + EntryLink entryLink = EntryLink.newBuilder().build(); + String entryLinkId = "entryLinkId-1349584441"; + EntryLink response = catalogServiceClient.createEntryLink(parent, entryLink, entryLinkId); + } + } +} +// [END dataplex_v1_generated_CatalogService_CreateEntryLink_StringEntrylinkString_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/AsyncDeleteEntryLink.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/AsyncDeleteEntryLink.java new file mode 100644 index 000000000000..63801b9147c1 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/AsyncDeleteEntryLink.java @@ -0,0 +1,52 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_DeleteEntryLink_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.DeleteEntryLinkRequest; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; + +public class AsyncDeleteEntryLink { + + public static void main(String[] args) throws Exception { + asyncDeleteEntryLink(); + } + + public static void asyncDeleteEntryLink() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + DeleteEntryLinkRequest request = + DeleteEntryLinkRequest.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .build(); + ApiFuture future = + catalogServiceClient.deleteEntryLinkCallable().futureCall(request); + // Do something. + EntryLink response = future.get(); + } + } +} +// [END dataplex_v1_generated_CatalogService_DeleteEntryLink_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLink.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLink.java new file mode 100644 index 000000000000..bdbb42ab80cc --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLink.java @@ -0,0 +1,48 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_DeleteEntryLink_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.DeleteEntryLinkRequest; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; + +public class SyncDeleteEntryLink { + + public static void main(String[] args) throws Exception { + syncDeleteEntryLink(); + } + + public static void syncDeleteEntryLink() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + DeleteEntryLinkRequest request = + DeleteEntryLinkRequest.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .build(); + EntryLink response = catalogServiceClient.deleteEntryLink(request); + } + } +} +// [END dataplex_v1_generated_CatalogService_DeleteEntryLink_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLinkEntrylinkname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLinkEntrylinkname.java new file mode 100644 index 000000000000..405a4f8f2c10 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLinkEntrylinkname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_DeleteEntryLink_Entrylinkname_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; + +public class SyncDeleteEntryLinkEntrylinkname { + + public static void main(String[] args) throws Exception { + syncDeleteEntryLinkEntrylinkname(); + } + + public static void syncDeleteEntryLinkEntrylinkname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + EntryLink response = catalogServiceClient.deleteEntryLink(name); + } + } +} +// [END dataplex_v1_generated_CatalogService_DeleteEntryLink_Entrylinkname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLinkString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLinkString.java new file mode 100644 index 000000000000..3a4c81bc73a4 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/deleteentrylink/SyncDeleteEntryLinkString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_DeleteEntryLink_String_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; + +public class SyncDeleteEntryLinkString { + + public static void main(String[] args) throws Exception { + syncDeleteEntryLinkString(); + } + + public static void syncDeleteEntryLinkString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + String name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]").toString(); + EntryLink response = catalogServiceClient.deleteEntryLink(name); + } + } +} +// [END dataplex_v1_generated_CatalogService_DeleteEntryLink_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/AsyncGetEntryLink.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/AsyncGetEntryLink.java new file mode 100644 index 000000000000..650461f8bc0f --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/AsyncGetEntryLink.java @@ -0,0 +1,51 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_GetEntryLink_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; +import com.google.cloud.dataplex.v1.GetEntryLinkRequest; + +public class AsyncGetEntryLink { + + public static void main(String[] args) throws Exception { + asyncGetEntryLink(); + } + + public static void asyncGetEntryLink() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + GetEntryLinkRequest request = + GetEntryLinkRequest.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .build(); + ApiFuture future = catalogServiceClient.getEntryLinkCallable().futureCall(request); + // Do something. + EntryLink response = future.get(); + } + } +} +// [END dataplex_v1_generated_CatalogService_GetEntryLink_async] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLink.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLink.java new file mode 100644 index 000000000000..bfc576955b5f --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLink.java @@ -0,0 +1,48 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_GetEntryLink_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; +import com.google.cloud.dataplex.v1.GetEntryLinkRequest; + +public class SyncGetEntryLink { + + public static void main(String[] args) throws Exception { + syncGetEntryLink(); + } + + public static void syncGetEntryLink() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + GetEntryLinkRequest request = + GetEntryLinkRequest.newBuilder() + .setName( + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]") + .toString()) + .build(); + EntryLink response = catalogServiceClient.getEntryLink(request); + } + } +} +// [END dataplex_v1_generated_CatalogService_GetEntryLink_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLinkEntrylinkname.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLinkEntrylinkname.java new file mode 100644 index 000000000000..4500a2ebd6bc --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLinkEntrylinkname.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_GetEntryLink_Entrylinkname_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; + +public class SyncGetEntryLinkEntrylinkname { + + public static void main(String[] args) throws Exception { + syncGetEntryLinkEntrylinkname(); + } + + public static void syncGetEntryLinkEntrylinkname() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + EntryLinkName name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]"); + EntryLink response = catalogServiceClient.getEntryLink(name); + } + } +} +// [END dataplex_v1_generated_CatalogService_GetEntryLink_Entrylinkname_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLinkString.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLinkString.java new file mode 100644 index 000000000000..77cc171123db --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/catalogservice/getentrylink/SyncGetEntryLinkString.java @@ -0,0 +1,43 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.samples; + +// [START dataplex_v1_generated_CatalogService_GetEntryLink_String_sync] +import com.google.cloud.dataplex.v1.CatalogServiceClient; +import com.google.cloud.dataplex.v1.EntryLink; +import com.google.cloud.dataplex.v1.EntryLinkName; + +public class SyncGetEntryLinkString { + + public static void main(String[] args) throws Exception { + syncGetEntryLinkString(); + } + + public static void syncGetEntryLinkString() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (CatalogServiceClient catalogServiceClient = CatalogServiceClient.create()) { + String name = + EntryLinkName.of("[PROJECT]", "[LOCATION]", "[ENTRY_GROUP]", "[ENTRY_LINK]").toString(); + EntryLink response = catalogServiceClient.getEntryLink(name); + } + } +} +// [END dataplex_v1_generated_CatalogService_GetEntryLink_String_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/stub/businessglossaryservicestubsettings/createglossary/SyncCreateGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/stub/businessglossaryservicestubsettings/createglossary/SyncCreateGlossary.java new file mode 100644 index 000000000000..5d0cd3c4fe57 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/stub/businessglossaryservicestubsettings/createglossary/SyncCreateGlossary.java @@ -0,0 +1,54 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.stub.samples; + +// [START dataplex_v1_generated_BusinessGlossaryServiceStubSettings_CreateGlossary_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.dataplex.v1.stub.BusinessGlossaryServiceStubSettings; +import java.time.Duration; + +public class SyncCreateGlossary { + + public static void main(String[] args) throws Exception { + syncCreateGlossary(); + } + + public static void syncCreateGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + BusinessGlossaryServiceStubSettings.Builder businessGlossaryServiceSettingsBuilder = + BusinessGlossaryServiceStubSettings.newBuilder(); + TimedRetryAlgorithm timedRetryAlgorithm = + OperationalTimedPollAlgorithm.create( + RetrySettings.newBuilder() + .setInitialRetryDelayDuration(Duration.ofMillis(500)) + .setRetryDelayMultiplier(1.5) + .setMaxRetryDelayDuration(Duration.ofMillis(5000)) + .setTotalTimeoutDuration(Duration.ofHours(24)) + .build()); + businessGlossaryServiceSettingsBuilder + .createClusterOperationSettings() + .setPollingAlgorithm(timedRetryAlgorithm) + .build(); + } +} +// [END dataplex_v1_generated_BusinessGlossaryServiceStubSettings_CreateGlossary_sync] diff --git a/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/stub/businessglossaryservicestubsettings/getglossary/SyncGetGlossary.java b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/stub/businessglossaryservicestubsettings/getglossary/SyncGetGlossary.java new file mode 100644 index 000000000000..191037e8e3d8 --- /dev/null +++ b/java-dataplex/samples/snippets/generated/com/google/cloud/dataplex/v1/stub/businessglossaryservicestubsettings/getglossary/SyncGetGlossary.java @@ -0,0 +1,57 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dataplex.v1.stub.samples; + +// [START dataplex_v1_generated_BusinessGlossaryServiceStubSettings_GetGlossary_sync] +import com.google.cloud.dataplex.v1.stub.BusinessGlossaryServiceStubSettings; +import java.time.Duration; + +public class SyncGetGlossary { + + public static void main(String[] args) throws Exception { + syncGetGlossary(); + } + + public static void syncGetGlossary() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + BusinessGlossaryServiceStubSettings.Builder businessGlossaryServiceSettingsBuilder = + BusinessGlossaryServiceStubSettings.newBuilder(); + businessGlossaryServiceSettingsBuilder + .getGlossarySettings() + .setRetrySettings( + businessGlossaryServiceSettingsBuilder + .getGlossarySettings() + .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()); + BusinessGlossaryServiceStubSettings businessGlossaryServiceSettings = + businessGlossaryServiceSettingsBuilder.build(); + } +} +// [END dataplex_v1_generated_BusinessGlossaryServiceStubSettings_GetGlossary_sync] diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceClient.java b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceClient.java index e97b84446c8a..d49d15e7b5fb 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceClient.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceClient.java @@ -85,6 +85,7 @@ * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * for (SearchResponse.SearchResult element : searchServiceClient.search(request).iterateAll()) { * // doThingsWith(element); @@ -291,6 +292,7 @@ public SearchServiceStub getStub() { * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * for (SearchResponse.SearchResult element : searchServiceClient.search(request).iterateAll()) { * // doThingsWith(element); @@ -357,6 +359,7 @@ public final SearchPagedResponse search(SearchRequest request) { * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * ApiFuture future = * searchServiceClient.searchPagedCallable().futureCall(request); @@ -423,6 +426,7 @@ public final UnaryCallable searchPagedCallab * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * while (true) { * SearchResponse response = searchServiceClient.searchCallable().call(request); @@ -505,6 +509,7 @@ public final UnaryCallable searchCallable() { * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * for (SearchResponse.SearchResult element : * searchServiceClient.searchLite(request).iterateAll()) { @@ -582,6 +587,7 @@ public final SearchLitePagedResponse searchLite(SearchRequest request) { * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * ApiFuture future = * searchServiceClient.searchLitePagedCallable().futureCall(request); @@ -658,6 +664,7 @@ public final UnaryCallable searchLitePag * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * while (true) { * SearchResponse response = searchServiceClient.searchLiteCallable().call(request); diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/package-info.java b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/package-info.java index f887381ba269..9b35a4f62204 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/package-info.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/java/com/google/cloud/discoveryengine/v1/package-info.java @@ -409,6 +409,7 @@ * .toString()) * .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) * .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + * .setRankingExpression("rankingExpression2110320494") * .build(); * for (SearchResponse.SearchResult element : searchServiceClient.search(request).iterateAll()) { * // doThingsWith(element); 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 8e13febf5f8a..db0a99bcae9f 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 @@ -6974,6 +6974,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1.SearchRequest$RankingExpressionBackend", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1.SearchRequest$RelevanceScoreSpec", "queryAllDeclaredConstructors": true, @@ -7163,6 +7172,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1.SearchResponse$SearchResult$RankSignals", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1.SearchResponse$SearchResult$RankSignals$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1.SearchResponse$SearchResult$RankSignals$CustomSignal", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1.SearchResponse$SearchResult$RankSignals$CustomSignal$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1.SearchResponse$SessionInfo", "queryAllDeclaredConstructors": true, diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1alpha/reflect-config.json b/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1alpha/reflect-config.json index 24ee7b32563f..75ad2daff6fc 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1alpha/reflect-config.json +++ b/java-discoveryengine/google-cloud-discoveryengine/src/main/resources/META-INF/native-image/com.google.cloud.discoveryengine.v1alpha/reflect-config.json @@ -6515,6 +6515,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1alpha.SearchRequest$RankingExpressionBackend", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1alpha.SearchRequest$RelevanceThreshold", "queryAllDeclaredConstructors": true, @@ -6920,6 +6929,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1alpha.SearchResponse$SearchResult$RankSignals", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1alpha.SearchResponse$SearchResult$RankSignals$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1alpha.SearchResponse$SearchResult$RankSignals$CustomSignal", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1alpha.SearchResponse$SearchResult$RankSignals$CustomSignal$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1alpha.SearchResponse$SessionInfo", "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 aa11248d2a21..a6dff9e87e15 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 @@ -6596,6 +6596,15 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1beta.SearchRequest$RankingExpressionBackend", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1beta.SearchRequest$RelevanceThreshold", "queryAllDeclaredConstructors": true, @@ -7001,6 +7010,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.discoveryengine.v1beta.SearchResponse$SearchResult$RankSignals", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1beta.SearchResponse$SearchResult$RankSignals$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1beta.SearchResponse$SearchResult$RankSignals$CustomSignal", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.discoveryengine.v1beta.SearchResponse$SearchResult$RankSignals$CustomSignal$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.discoveryengine.v1beta.SearchResponse$SessionInfo", "queryAllDeclaredConstructors": true, diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientHttpJsonTest.java b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientHttpJsonTest.java index 1bc548dadd83..ae925cff023b 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientHttpJsonTest.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientHttpJsonTest.java @@ -128,6 +128,7 @@ public void searchTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); SearchPagedResponse pagedListResponse = client.search(request); @@ -200,6 +201,7 @@ public void searchExceptionTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); client.search(request); Assert.fail("No exception raised"); @@ -257,6 +259,7 @@ public void searchLiteTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); SearchLitePagedResponse pagedListResponse = client.searchLite(request); @@ -329,6 +332,7 @@ public void searchLiteExceptionTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); client.searchLite(request); Assert.fail("No exception raised"); diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientTest.java b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientTest.java index 7c4fb77bc8db..7c86e9c3f980 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientTest.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1/SearchServiceClientTest.java @@ -134,6 +134,7 @@ public void searchTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); SearchPagedResponse pagedListResponse = client.search(request); @@ -177,6 +178,9 @@ public void searchTest() throws Exception { Assert.assertEquals(request.getSessionSpec(), actualRequest.getSessionSpec()); Assert.assertEquals(request.getRelevanceThreshold(), actualRequest.getRelevanceThreshold()); Assert.assertEquals(request.getRelevanceScoreSpec(), actualRequest.getRelevanceScoreSpec()); + Assert.assertEquals(request.getRankingExpression(), actualRequest.getRankingExpression()); + Assert.assertEquals( + request.getRankingExpressionBackend(), actualRequest.getRankingExpressionBackend()); Assert.assertTrue( channelProvider.isHeaderSent( ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), @@ -228,6 +232,7 @@ public void searchExceptionTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); client.search(request); Assert.fail("No exception raised"); @@ -285,6 +290,7 @@ public void searchLiteTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); SearchLitePagedResponse pagedListResponse = client.searchLite(request); @@ -328,6 +334,9 @@ public void searchLiteTest() throws Exception { Assert.assertEquals(request.getSessionSpec(), actualRequest.getSessionSpec()); Assert.assertEquals(request.getRelevanceThreshold(), actualRequest.getRelevanceThreshold()); Assert.assertEquals(request.getRelevanceScoreSpec(), actualRequest.getRelevanceScoreSpec()); + Assert.assertEquals(request.getRankingExpression(), actualRequest.getRankingExpression()); + Assert.assertEquals( + request.getRankingExpressionBackend(), actualRequest.getRankingExpressionBackend()); Assert.assertTrue( channelProvider.isHeaderSent( ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), @@ -379,6 +388,7 @@ public void searchLiteExceptionTest() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); client.searchLite(request); Assert.fail("No exception raised"); diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceClientTest.java b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceClientTest.java index 7324860e59da..16da5c302ee3 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceClientTest.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceClientTest.java @@ -173,6 +173,8 @@ public void searchTest() throws Exception { Assert.assertEquals(request.getContentSearchSpec(), actualRequest.getContentSearchSpec()); Assert.assertEquals(request.getEmbeddingSpec(), actualRequest.getEmbeddingSpec()); Assert.assertEquals(request.getRankingExpression(), actualRequest.getRankingExpression()); + Assert.assertEquals( + request.getRankingExpressionBackend(), actualRequest.getRankingExpressionBackend()); Assert.assertEquals(request.getSafeSearch(), actualRequest.getSafeSearch()); Assert.assertEquals(request.getUserLabelsMap(), actualRequest.getUserLabelsMap()); Assert.assertEquals( diff --git a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1beta/SearchServiceClientTest.java b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1beta/SearchServiceClientTest.java index 8f80055414eb..5d1b670adc48 100644 --- a/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1beta/SearchServiceClientTest.java +++ b/java-discoveryengine/google-cloud-discoveryengine/src/test/java/com/google/cloud/discoveryengine/v1beta/SearchServiceClientTest.java @@ -176,6 +176,8 @@ public void searchTest() throws Exception { Assert.assertEquals(request.getContentSearchSpec(), actualRequest.getContentSearchSpec()); Assert.assertEquals(request.getEmbeddingSpec(), actualRequest.getEmbeddingSpec()); Assert.assertEquals(request.getRankingExpression(), actualRequest.getRankingExpression()); + Assert.assertEquals( + request.getRankingExpressionBackend(), actualRequest.getRankingExpressionBackend()); Assert.assertEquals(request.getSafeSearch(), actualRequest.getSafeSearch()); Assert.assertEquals(request.getUserLabelsMap(), actualRequest.getUserLabelsMap()); Assert.assertEquals( @@ -340,6 +342,8 @@ public void searchLiteTest() throws Exception { Assert.assertEquals(request.getContentSearchSpec(), actualRequest.getContentSearchSpec()); Assert.assertEquals(request.getEmbeddingSpec(), actualRequest.getEmbeddingSpec()); Assert.assertEquals(request.getRankingExpression(), actualRequest.getRankingExpression()); + Assert.assertEquals( + request.getRankingExpressionBackend(), actualRequest.getRankingExpressionBackend()); Assert.assertEquals(request.getSafeSearch(), actualRequest.getSafeSearch()); Assert.assertEquals(request.getUserLabelsMap(), actualRequest.getUserLabelsMap()); Assert.assertEquals( diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequest.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequest.java index f9d32a9308f3..8c7ed8c1a1cb 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequest.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequest.java @@ -55,6 +55,8 @@ private SearchRequest() { userPseudoId_ = ""; session_ = ""; relevanceThreshold_ = 0; + rankingExpression_ = ""; + rankingExpressionBackend_ = 0; } @java.lang.Override @@ -306,6 +308,172 @@ private RelevanceThreshold(int value) { // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1.SearchRequest.RelevanceThreshold) } + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * Protobuf enum {@code google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend} + */ + public enum RankingExpressionBackend implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
        +     * Default option for unspecified/unknown values.
        +     * 
        + * + * RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + */ + RANKING_EXPRESSION_BACKEND_UNSPECIFIED(0), + /** + * + * + *
        +     * Ranking by custom embedding model, the default way to evaluate the
        +     * ranking expression.
        +     * 
        + * + * RANK_BY_EMBEDDING = 3; + */ + RANK_BY_EMBEDDING(3), + /** + * + * + *
        +     * Ranking by custom formula.
        +     * 
        + * + * RANK_BY_FORMULA = 4; + */ + RANK_BY_FORMULA(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
        +     * Default option for unspecified/unknown values.
        +     * 
        + * + * RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + */ + public static final int RANKING_EXPRESSION_BACKEND_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
        +     * Ranking by custom embedding model, the default way to evaluate the
        +     * ranking expression.
        +     * 
        + * + * RANK_BY_EMBEDDING = 3; + */ + public static final int RANK_BY_EMBEDDING_VALUE = 3; + + /** + * + * + *
        +     * Ranking by custom formula.
        +     * 
        + * + * RANK_BY_FORMULA = 4; + */ + public static final int RANK_BY_FORMULA_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 RankingExpressionBackend 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 RankingExpressionBackend forNumber(int value) { + switch (value) { + case 0: + return RANKING_EXPRESSION_BACKEND_UNSPECIFIED; + case 3: + return RANK_BY_EMBEDDING; + case 4: + return RANK_BY_FORMULA; + 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 RankingExpressionBackend findValueByNumber(int number) { + return RankingExpressionBackend.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.SearchRequest.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final RankingExpressionBackend[] VALUES = values(); + + public static RankingExpressionBackend 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 RankingExpressionBackend(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend) + } + public interface ImageQueryOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1.SearchRequest.ImageQuery) @@ -30300,6 +30468,282 @@ public boolean hasRelevanceScoreSpec() { : relevanceScoreSpec_; } + public static final int RANKING_EXPRESSION_FIELD_NUMBER = 26; + + @SuppressWarnings("serial") + private volatile java.lang.Object rankingExpression_ = ""; + + /** + * + * + *
        +   * The ranking expression controls the customized ranking on retrieval
        +   * documents. This overrides
        +   * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +   * The syntax and supported features depend on the
        +   * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +   * provided, it defaults to `RANK_BY_EMBEDDING`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +   * function or multiple functions that are joined by "+".
        +   *
        +   *   * ranking_expression = function, { " + ", function };
        +   *
        +   * Supported functions:
        +   *
        +   *   * double * relevance_score
        +   *   * double * dotProduct(embedding_field_path)
        +   *
        +   * Function variables:
        +   *
        +   *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +   *   between query and document.
        +   *   * `embedding_field_path`: the document embedding field
        +   *   used with query embedding vector.
        +   *   * `dotProduct`: embedding function between `embedding_field_path` and
        +   *   query embedding vector.
        +   *
        +   *  Example ranking expression:
        +   *
        +   *    If document has an embedding field doc_embedding, the ranking expression
        +   *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is set to `RANK_BY_FORMULA`, the following expression types (and
        +   * combinations of those chained using + or
        +   * * operators) are supported:
        +   *
        +   *   * `double`
        +   *   * `signal`
        +   *   * `log(signal)`
        +   *   * `exp(signal)`
        +   *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +   *   argument being a denominator constant.
        +   *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +   *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +   *   signal2 | double, else returns signal1.
        +   *
        +   *   Here are a few examples of ranking formulas that use the supported
        +   *   ranking expression types:
        +   *
        +   *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +   *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +   *   `semantic_smilarity_score` adjustment.
        +   *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +   *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +   *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +   *   add constant 0.3 adjustment to the final score if
        +   *   `semantic_similarity_score` is NaN.
        +   *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +   *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +   *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +   *   of `semantic_smilarity_score`.
        +   *
        +   * The following signals are supported:
        +   *
        +   *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +   *   calculated using the embeddings generated by a proprietary Google model.
        +   *   This score determines how semantically similar a search query is to a
        +   *   document.
        +   *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +   *   Match 25 (BM25) ranking function. This score is calculated using a
        +   *   probabilistic model to estimate the probability that a document is
        +   *   relevant to a given query.
        +   *   * `relevance_score`: semantic relevance adjustment that uses a
        +   *   proprietary Google model to determine the meaning and intent behind a
        +   *   user's query in context with the content in the documents.
        +   *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +   *   predicted Click-through rate (pCTR) to gauge the relevance and
        +   *   attractiveness of a search result from a user's perspective. A higher
        +   *   pCTR suggests that the result is more likely to satisfy the user's query
        +   *   and intent, making it a valuable signal for ranking.
        +   *   * `freshness_rank`: freshness adjustment as a rank
        +   *   * `document_age`: The time in hours elapsed since the document was last
        +   *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +   *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +   *   Google model to determine the keyword-based overlap between the query and
        +   *   the document.
        +   *   * `base_rank`: the default rank of the result
        +   * 
        + * + * string ranking_expression = 26; + * + * @return The rankingExpression. + */ + @java.lang.Override + public java.lang.String getRankingExpression() { + java.lang.Object ref = rankingExpression_; + 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(); + rankingExpression_ = s; + return s; + } + } + + /** + * + * + *
        +   * The ranking expression controls the customized ranking on retrieval
        +   * documents. This overrides
        +   * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +   * The syntax and supported features depend on the
        +   * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +   * provided, it defaults to `RANK_BY_EMBEDDING`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +   * function or multiple functions that are joined by "+".
        +   *
        +   *   * ranking_expression = function, { " + ", function };
        +   *
        +   * Supported functions:
        +   *
        +   *   * double * relevance_score
        +   *   * double * dotProduct(embedding_field_path)
        +   *
        +   * Function variables:
        +   *
        +   *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +   *   between query and document.
        +   *   * `embedding_field_path`: the document embedding field
        +   *   used with query embedding vector.
        +   *   * `dotProduct`: embedding function between `embedding_field_path` and
        +   *   query embedding vector.
        +   *
        +   *  Example ranking expression:
        +   *
        +   *    If document has an embedding field doc_embedding, the ranking expression
        +   *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is set to `RANK_BY_FORMULA`, the following expression types (and
        +   * combinations of those chained using + or
        +   * * operators) are supported:
        +   *
        +   *   * `double`
        +   *   * `signal`
        +   *   * `log(signal)`
        +   *   * `exp(signal)`
        +   *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +   *   argument being a denominator constant.
        +   *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +   *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +   *   signal2 | double, else returns signal1.
        +   *
        +   *   Here are a few examples of ranking formulas that use the supported
        +   *   ranking expression types:
        +   *
        +   *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +   *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +   *   `semantic_smilarity_score` adjustment.
        +   *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +   *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +   *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +   *   add constant 0.3 adjustment to the final score if
        +   *   `semantic_similarity_score` is NaN.
        +   *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +   *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +   *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +   *   of `semantic_smilarity_score`.
        +   *
        +   * The following signals are supported:
        +   *
        +   *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +   *   calculated using the embeddings generated by a proprietary Google model.
        +   *   This score determines how semantically similar a search query is to a
        +   *   document.
        +   *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +   *   Match 25 (BM25) ranking function. This score is calculated using a
        +   *   probabilistic model to estimate the probability that a document is
        +   *   relevant to a given query.
        +   *   * `relevance_score`: semantic relevance adjustment that uses a
        +   *   proprietary Google model to determine the meaning and intent behind a
        +   *   user's query in context with the content in the documents.
        +   *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +   *   predicted Click-through rate (pCTR) to gauge the relevance and
        +   *   attractiveness of a search result from a user's perspective. A higher
        +   *   pCTR suggests that the result is more likely to satisfy the user's query
        +   *   and intent, making it a valuable signal for ranking.
        +   *   * `freshness_rank`: freshness adjustment as a rank
        +   *   * `document_age`: The time in hours elapsed since the document was last
        +   *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +   *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +   *   Google model to determine the keyword-based overlap between the query and
        +   *   the document.
        +   *   * `base_rank`: the default rank of the result
        +   * 
        + * + * string ranking_expression = 26; + * + * @return The bytes for rankingExpression. + */ + @java.lang.Override + public com.google.protobuf.ByteString getRankingExpressionBytes() { + java.lang.Object ref = rankingExpression_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + rankingExpression_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int RANKING_EXPRESSION_BACKEND_FIELD_NUMBER = 53; + private int rankingExpressionBackend_ = 0; + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + @java.lang.Override + public int getRankingExpressionBackendValue() { + return rankingExpressionBackend_; + } + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend() { + com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend result = + com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend.forNumber( + rankingExpressionBackend_); + return result == null + ? com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend.UNRECOGNIZED + : result; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -30369,6 +30813,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000020) != 0)) { output.writeMessage(24, getContentSearchSpec()); } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(rankingExpression_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 26, rankingExpression_); + } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(canonicalFilter_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 29, canonicalFilter_); } @@ -30402,6 +30849,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (((bitField0_ & 0x00000200) != 0)) { output.writeMessage(52, getRelevanceScoreSpec()); } + if (rankingExpressionBackend_ + != com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend + .RANKING_EXPRESSION_BACKEND_UNSPECIFIED + .getNumber()) { + output.writeEnum(53, rankingExpressionBackend_); + } getUnknownFields().writeTo(output); } @@ -30483,6 +30936,9 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000020) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(24, getContentSearchSpec()); } + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(rankingExpression_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(26, rankingExpression_); + } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(canonicalFilter_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(29, canonicalFilter_); } @@ -30517,6 +30973,12 @@ public int getSerializedSize() { if (((bitField0_ & 0x00000200) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(52, getRelevanceScoreSpec()); } + if (rankingExpressionBackend_ + != com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend + .RANKING_EXPRESSION_BACKEND_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(53, rankingExpressionBackend_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -30592,6 +31054,8 @@ public boolean equals(final java.lang.Object obj) { if (hasRelevanceScoreSpec()) { if (!getRelevanceScoreSpec().equals(other.getRelevanceScoreSpec())) return false; } + if (!getRankingExpression().equals(other.getRankingExpression())) return false; + if (rankingExpressionBackend_ != other.rankingExpressionBackend_) return false; if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -30689,6 +31153,10 @@ public int hashCode() { hash = (37 * hash) + RELEVANCE_SCORE_SPEC_FIELD_NUMBER; hash = (53 * hash) + getRelevanceScoreSpec().hashCode(); } + hash = (37 * hash) + RANKING_EXPRESSION_FIELD_NUMBER; + hash = (53 * hash) + getRankingExpression().hashCode(); + hash = (37 * hash) + RANKING_EXPRESSION_BACKEND_FIELD_NUMBER; + hash = (53 * hash) + rankingExpressionBackend_; hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -30958,6 +31426,8 @@ public Builder clear() { relevanceScoreSpecBuilder_.dispose(); relevanceScoreSpecBuilder_ = null; } + rankingExpression_ = ""; + rankingExpressionBackend_ = 0; return this; } @@ -31127,6 +31597,12 @@ private void buildPartial0(com.google.cloud.discoveryengine.v1.SearchRequest res : relevanceScoreSpecBuilder_.build(); to_bitField0_ |= 0x00000200; } + if (((from_bitField0_ & 0x20000000) != 0)) { + result.rankingExpression_ = rankingExpression_; + } + if (((from_bitField0_ & 0x40000000) != 0)) { + result.rankingExpressionBackend_ = rankingExpressionBackend_; + } result.bitField0_ |= to_bitField0_; } @@ -31329,6 +31805,14 @@ public Builder mergeFrom(com.google.cloud.discoveryengine.v1.SearchRequest other if (other.hasRelevanceScoreSpec()) { mergeRelevanceScoreSpec(other.getRelevanceScoreSpec()); } + if (!other.getRankingExpression().isEmpty()) { + rankingExpression_ = other.rankingExpression_; + bitField0_ |= 0x20000000; + onChanged(); + } + if (other.rankingExpressionBackend_ != 0) { + setRankingExpressionBackendValue(other.getRankingExpressionBackendValue()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -31492,6 +31976,12 @@ public Builder mergeFrom( bitField0_ |= 0x00100000; break; } // case 194 + case 210: + { + rankingExpression_ = input.readStringRequireUtf8(); + bitField0_ |= 0x20000000; + break; + } // case 210 case 234: { canonicalFilter_ = input.readStringRequireUtf8(); @@ -31562,6 +32052,12 @@ public Builder mergeFrom( bitField0_ |= 0x10000000; break; } // case 418 + case 424: + { + rankingExpressionBackend_ = input.readEnum(); + bitField0_ |= 0x40000000; + break; + } // case 424 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -37425,6 +37921,672 @@ public Builder clearRelevanceScoreSpec() { return relevanceScoreSpecBuilder_; } + private java.lang.Object rankingExpression_ = ""; + + /** + * + * + *
        +     * The ranking expression controls the customized ranking on retrieval
        +     * documents. This overrides
        +     * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +     * The syntax and supported features depend on the
        +     * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +     * provided, it defaults to `RANK_BY_EMBEDDING`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +     * function or multiple functions that are joined by "+".
        +     *
        +     *   * ranking_expression = function, { " + ", function };
        +     *
        +     * Supported functions:
        +     *
        +     *   * double * relevance_score
        +     *   * double * dotProduct(embedding_field_path)
        +     *
        +     * Function variables:
        +     *
        +     *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +     *   between query and document.
        +     *   * `embedding_field_path`: the document embedding field
        +     *   used with query embedding vector.
        +     *   * `dotProduct`: embedding function between `embedding_field_path` and
        +     *   query embedding vector.
        +     *
        +     *  Example ranking expression:
        +     *
        +     *    If document has an embedding field doc_embedding, the ranking expression
        +     *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is set to `RANK_BY_FORMULA`, the following expression types (and
        +     * combinations of those chained using + or
        +     * * operators) are supported:
        +     *
        +     *   * `double`
        +     *   * `signal`
        +     *   * `log(signal)`
        +     *   * `exp(signal)`
        +     *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +     *   argument being a denominator constant.
        +     *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +     *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +     *   signal2 | double, else returns signal1.
        +     *
        +     *   Here are a few examples of ranking formulas that use the supported
        +     *   ranking expression types:
        +     *
        +     *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +     *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +     *   `semantic_smilarity_score` adjustment.
        +     *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +     *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +     *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +     *   add constant 0.3 adjustment to the final score if
        +     *   `semantic_similarity_score` is NaN.
        +     *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +     *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +     *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +     *   of `semantic_smilarity_score`.
        +     *
        +     * The following signals are supported:
        +     *
        +     *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +     *   calculated using the embeddings generated by a proprietary Google model.
        +     *   This score determines how semantically similar a search query is to a
        +     *   document.
        +     *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +     *   Match 25 (BM25) ranking function. This score is calculated using a
        +     *   probabilistic model to estimate the probability that a document is
        +     *   relevant to a given query.
        +     *   * `relevance_score`: semantic relevance adjustment that uses a
        +     *   proprietary Google model to determine the meaning and intent behind a
        +     *   user's query in context with the content in the documents.
        +     *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +     *   predicted Click-through rate (pCTR) to gauge the relevance and
        +     *   attractiveness of a search result from a user's perspective. A higher
        +     *   pCTR suggests that the result is more likely to satisfy the user's query
        +     *   and intent, making it a valuable signal for ranking.
        +     *   * `freshness_rank`: freshness adjustment as a rank
        +     *   * `document_age`: The time in hours elapsed since the document was last
        +     *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +     *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +     *   Google model to determine the keyword-based overlap between the query and
        +     *   the document.
        +     *   * `base_rank`: the default rank of the result
        +     * 
        + * + * string ranking_expression = 26; + * + * @return The rankingExpression. + */ + public java.lang.String getRankingExpression() { + java.lang.Object ref = rankingExpression_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + rankingExpression_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + + /** + * + * + *
        +     * The ranking expression controls the customized ranking on retrieval
        +     * documents. This overrides
        +     * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +     * The syntax and supported features depend on the
        +     * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +     * provided, it defaults to `RANK_BY_EMBEDDING`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +     * function or multiple functions that are joined by "+".
        +     *
        +     *   * ranking_expression = function, { " + ", function };
        +     *
        +     * Supported functions:
        +     *
        +     *   * double * relevance_score
        +     *   * double * dotProduct(embedding_field_path)
        +     *
        +     * Function variables:
        +     *
        +     *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +     *   between query and document.
        +     *   * `embedding_field_path`: the document embedding field
        +     *   used with query embedding vector.
        +     *   * `dotProduct`: embedding function between `embedding_field_path` and
        +     *   query embedding vector.
        +     *
        +     *  Example ranking expression:
        +     *
        +     *    If document has an embedding field doc_embedding, the ranking expression
        +     *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is set to `RANK_BY_FORMULA`, the following expression types (and
        +     * combinations of those chained using + or
        +     * * operators) are supported:
        +     *
        +     *   * `double`
        +     *   * `signal`
        +     *   * `log(signal)`
        +     *   * `exp(signal)`
        +     *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +     *   argument being a denominator constant.
        +     *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +     *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +     *   signal2 | double, else returns signal1.
        +     *
        +     *   Here are a few examples of ranking formulas that use the supported
        +     *   ranking expression types:
        +     *
        +     *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +     *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +     *   `semantic_smilarity_score` adjustment.
        +     *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +     *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +     *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +     *   add constant 0.3 adjustment to the final score if
        +     *   `semantic_similarity_score` is NaN.
        +     *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +     *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +     *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +     *   of `semantic_smilarity_score`.
        +     *
        +     * The following signals are supported:
        +     *
        +     *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +     *   calculated using the embeddings generated by a proprietary Google model.
        +     *   This score determines how semantically similar a search query is to a
        +     *   document.
        +     *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +     *   Match 25 (BM25) ranking function. This score is calculated using a
        +     *   probabilistic model to estimate the probability that a document is
        +     *   relevant to a given query.
        +     *   * `relevance_score`: semantic relevance adjustment that uses a
        +     *   proprietary Google model to determine the meaning and intent behind a
        +     *   user's query in context with the content in the documents.
        +     *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +     *   predicted Click-through rate (pCTR) to gauge the relevance and
        +     *   attractiveness of a search result from a user's perspective. A higher
        +     *   pCTR suggests that the result is more likely to satisfy the user's query
        +     *   and intent, making it a valuable signal for ranking.
        +     *   * `freshness_rank`: freshness adjustment as a rank
        +     *   * `document_age`: The time in hours elapsed since the document was last
        +     *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +     *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +     *   Google model to determine the keyword-based overlap between the query and
        +     *   the document.
        +     *   * `base_rank`: the default rank of the result
        +     * 
        + * + * string ranking_expression = 26; + * + * @return The bytes for rankingExpression. + */ + public com.google.protobuf.ByteString getRankingExpressionBytes() { + java.lang.Object ref = rankingExpression_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + rankingExpression_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + /** + * + * + *
        +     * The ranking expression controls the customized ranking on retrieval
        +     * documents. This overrides
        +     * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +     * The syntax and supported features depend on the
        +     * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +     * provided, it defaults to `RANK_BY_EMBEDDING`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +     * function or multiple functions that are joined by "+".
        +     *
        +     *   * ranking_expression = function, { " + ", function };
        +     *
        +     * Supported functions:
        +     *
        +     *   * double * relevance_score
        +     *   * double * dotProduct(embedding_field_path)
        +     *
        +     * Function variables:
        +     *
        +     *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +     *   between query and document.
        +     *   * `embedding_field_path`: the document embedding field
        +     *   used with query embedding vector.
        +     *   * `dotProduct`: embedding function between `embedding_field_path` and
        +     *   query embedding vector.
        +     *
        +     *  Example ranking expression:
        +     *
        +     *    If document has an embedding field doc_embedding, the ranking expression
        +     *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is set to `RANK_BY_FORMULA`, the following expression types (and
        +     * combinations of those chained using + or
        +     * * operators) are supported:
        +     *
        +     *   * `double`
        +     *   * `signal`
        +     *   * `log(signal)`
        +     *   * `exp(signal)`
        +     *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +     *   argument being a denominator constant.
        +     *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +     *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +     *   signal2 | double, else returns signal1.
        +     *
        +     *   Here are a few examples of ranking formulas that use the supported
        +     *   ranking expression types:
        +     *
        +     *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +     *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +     *   `semantic_smilarity_score` adjustment.
        +     *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +     *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +     *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +     *   add constant 0.3 adjustment to the final score if
        +     *   `semantic_similarity_score` is NaN.
        +     *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +     *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +     *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +     *   of `semantic_smilarity_score`.
        +     *
        +     * The following signals are supported:
        +     *
        +     *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +     *   calculated using the embeddings generated by a proprietary Google model.
        +     *   This score determines how semantically similar a search query is to a
        +     *   document.
        +     *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +     *   Match 25 (BM25) ranking function. This score is calculated using a
        +     *   probabilistic model to estimate the probability that a document is
        +     *   relevant to a given query.
        +     *   * `relevance_score`: semantic relevance adjustment that uses a
        +     *   proprietary Google model to determine the meaning and intent behind a
        +     *   user's query in context with the content in the documents.
        +     *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +     *   predicted Click-through rate (pCTR) to gauge the relevance and
        +     *   attractiveness of a search result from a user's perspective. A higher
        +     *   pCTR suggests that the result is more likely to satisfy the user's query
        +     *   and intent, making it a valuable signal for ranking.
        +     *   * `freshness_rank`: freshness adjustment as a rank
        +     *   * `document_age`: The time in hours elapsed since the document was last
        +     *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +     *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +     *   Google model to determine the keyword-based overlap between the query and
        +     *   the document.
        +     *   * `base_rank`: the default rank of the result
        +     * 
        + * + * string ranking_expression = 26; + * + * @param value The rankingExpression to set. + * @return This builder for chaining. + */ + public Builder setRankingExpression(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + rankingExpression_ = value; + bitField0_ |= 0x20000000; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The ranking expression controls the customized ranking on retrieval
        +     * documents. This overrides
        +     * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +     * The syntax and supported features depend on the
        +     * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +     * provided, it defaults to `RANK_BY_EMBEDDING`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +     * function or multiple functions that are joined by "+".
        +     *
        +     *   * ranking_expression = function, { " + ", function };
        +     *
        +     * Supported functions:
        +     *
        +     *   * double * relevance_score
        +     *   * double * dotProduct(embedding_field_path)
        +     *
        +     * Function variables:
        +     *
        +     *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +     *   between query and document.
        +     *   * `embedding_field_path`: the document embedding field
        +     *   used with query embedding vector.
        +     *   * `dotProduct`: embedding function between `embedding_field_path` and
        +     *   query embedding vector.
        +     *
        +     *  Example ranking expression:
        +     *
        +     *    If document has an embedding field doc_embedding, the ranking expression
        +     *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is set to `RANK_BY_FORMULA`, the following expression types (and
        +     * combinations of those chained using + or
        +     * * operators) are supported:
        +     *
        +     *   * `double`
        +     *   * `signal`
        +     *   * `log(signal)`
        +     *   * `exp(signal)`
        +     *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +     *   argument being a denominator constant.
        +     *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +     *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +     *   signal2 | double, else returns signal1.
        +     *
        +     *   Here are a few examples of ranking formulas that use the supported
        +     *   ranking expression types:
        +     *
        +     *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +     *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +     *   `semantic_smilarity_score` adjustment.
        +     *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +     *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +     *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +     *   add constant 0.3 adjustment to the final score if
        +     *   `semantic_similarity_score` is NaN.
        +     *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +     *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +     *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +     *   of `semantic_smilarity_score`.
        +     *
        +     * The following signals are supported:
        +     *
        +     *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +     *   calculated using the embeddings generated by a proprietary Google model.
        +     *   This score determines how semantically similar a search query is to a
        +     *   document.
        +     *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +     *   Match 25 (BM25) ranking function. This score is calculated using a
        +     *   probabilistic model to estimate the probability that a document is
        +     *   relevant to a given query.
        +     *   * `relevance_score`: semantic relevance adjustment that uses a
        +     *   proprietary Google model to determine the meaning and intent behind a
        +     *   user's query in context with the content in the documents.
        +     *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +     *   predicted Click-through rate (pCTR) to gauge the relevance and
        +     *   attractiveness of a search result from a user's perspective. A higher
        +     *   pCTR suggests that the result is more likely to satisfy the user's query
        +     *   and intent, making it a valuable signal for ranking.
        +     *   * `freshness_rank`: freshness adjustment as a rank
        +     *   * `document_age`: The time in hours elapsed since the document was last
        +     *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +     *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +     *   Google model to determine the keyword-based overlap between the query and
        +     *   the document.
        +     *   * `base_rank`: the default rank of the result
        +     * 
        + * + * string ranking_expression = 26; + * + * @return This builder for chaining. + */ + public Builder clearRankingExpression() { + rankingExpression_ = getDefaultInstance().getRankingExpression(); + bitField0_ = (bitField0_ & ~0x20000000); + onChanged(); + return this; + } + + /** + * + * + *
        +     * The ranking expression controls the customized ranking on retrieval
        +     * documents. This overrides
        +     * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +     * The syntax and supported features depend on the
        +     * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +     * provided, it defaults to `RANK_BY_EMBEDDING`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +     * function or multiple functions that are joined by "+".
        +     *
        +     *   * ranking_expression = function, { " + ", function };
        +     *
        +     * Supported functions:
        +     *
        +     *   * double * relevance_score
        +     *   * double * dotProduct(embedding_field_path)
        +     *
        +     * Function variables:
        +     *
        +     *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +     *   between query and document.
        +     *   * `embedding_field_path`: the document embedding field
        +     *   used with query embedding vector.
        +     *   * `dotProduct`: embedding function between `embedding_field_path` and
        +     *   query embedding vector.
        +     *
        +     *  Example ranking expression:
        +     *
        +     *    If document has an embedding field doc_embedding, the ranking expression
        +     *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +     *
        +     * If
        +     * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +     * is set to `RANK_BY_FORMULA`, the following expression types (and
        +     * combinations of those chained using + or
        +     * * operators) are supported:
        +     *
        +     *   * `double`
        +     *   * `signal`
        +     *   * `log(signal)`
        +     *   * `exp(signal)`
        +     *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +     *   argument being a denominator constant.
        +     *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +     *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +     *   signal2 | double, else returns signal1.
        +     *
        +     *   Here are a few examples of ranking formulas that use the supported
        +     *   ranking expression types:
        +     *
        +     *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +     *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +     *   `semantic_smilarity_score` adjustment.
        +     *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +     *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +     *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +     *   add constant 0.3 adjustment to the final score if
        +     *   `semantic_similarity_score` is NaN.
        +     *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +     *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +     *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +     *   of `semantic_smilarity_score`.
        +     *
        +     * The following signals are supported:
        +     *
        +     *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +     *   calculated using the embeddings generated by a proprietary Google model.
        +     *   This score determines how semantically similar a search query is to a
        +     *   document.
        +     *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +     *   Match 25 (BM25) ranking function. This score is calculated using a
        +     *   probabilistic model to estimate the probability that a document is
        +     *   relevant to a given query.
        +     *   * `relevance_score`: semantic relevance adjustment that uses a
        +     *   proprietary Google model to determine the meaning and intent behind a
        +     *   user's query in context with the content in the documents.
        +     *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +     *   predicted Click-through rate (pCTR) to gauge the relevance and
        +     *   attractiveness of a search result from a user's perspective. A higher
        +     *   pCTR suggests that the result is more likely to satisfy the user's query
        +     *   and intent, making it a valuable signal for ranking.
        +     *   * `freshness_rank`: freshness adjustment as a rank
        +     *   * `document_age`: The time in hours elapsed since the document was last
        +     *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +     *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +     *   Google model to determine the keyword-based overlap between the query and
        +     *   the document.
        +     *   * `base_rank`: the default rank of the result
        +     * 
        + * + * string ranking_expression = 26; + * + * @param value The bytes for rankingExpression to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + rankingExpression_ = value; + bitField0_ |= 0x20000000; + onChanged(); + return this; + } + + private int rankingExpressionBackend_ = 0; + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + @java.lang.Override + public int getRankingExpressionBackendValue() { + return rankingExpressionBackend_; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for rankingExpressionBackend to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBackendValue(int value) { + rankingExpressionBackend_ = value; + bitField0_ |= 0x40000000; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend() { + com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend result = + com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend.forNumber( + rankingExpressionBackend_); + return result == null + ? com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend.UNRECOGNIZED + : result; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The rankingExpressionBackend to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBackend( + com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x40000000; + rankingExpressionBackend_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRankingExpressionBackend() { + bitField0_ = (bitField0_ & ~0x40000000); + rankingExpressionBackend_ = 0; + onChanged(); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequestOrBuilder.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequestOrBuilder.java index 142a94982170..33267065bd47 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequestOrBuilder.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchRequestOrBuilder.java @@ -1468,4 +1468,239 @@ java.lang.String getUserLabelsOrDefault( */ com.google.cloud.discoveryengine.v1.SearchRequest.RelevanceScoreSpecOrBuilder getRelevanceScoreSpecOrBuilder(); + + /** + * + * + *
        +   * The ranking expression controls the customized ranking on retrieval
        +   * documents. This overrides
        +   * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +   * The syntax and supported features depend on the
        +   * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +   * provided, it defaults to `RANK_BY_EMBEDDING`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +   * function or multiple functions that are joined by "+".
        +   *
        +   *   * ranking_expression = function, { " + ", function };
        +   *
        +   * Supported functions:
        +   *
        +   *   * double * relevance_score
        +   *   * double * dotProduct(embedding_field_path)
        +   *
        +   * Function variables:
        +   *
        +   *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +   *   between query and document.
        +   *   * `embedding_field_path`: the document embedding field
        +   *   used with query embedding vector.
        +   *   * `dotProduct`: embedding function between `embedding_field_path` and
        +   *   query embedding vector.
        +   *
        +   *  Example ranking expression:
        +   *
        +   *    If document has an embedding field doc_embedding, the ranking expression
        +   *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is set to `RANK_BY_FORMULA`, the following expression types (and
        +   * combinations of those chained using + or
        +   * * operators) are supported:
        +   *
        +   *   * `double`
        +   *   * `signal`
        +   *   * `log(signal)`
        +   *   * `exp(signal)`
        +   *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +   *   argument being a denominator constant.
        +   *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +   *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +   *   signal2 | double, else returns signal1.
        +   *
        +   *   Here are a few examples of ranking formulas that use the supported
        +   *   ranking expression types:
        +   *
        +   *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +   *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +   *   `semantic_smilarity_score` adjustment.
        +   *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +   *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +   *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +   *   add constant 0.3 adjustment to the final score if
        +   *   `semantic_similarity_score` is NaN.
        +   *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +   *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +   *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +   *   of `semantic_smilarity_score`.
        +   *
        +   * The following signals are supported:
        +   *
        +   *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +   *   calculated using the embeddings generated by a proprietary Google model.
        +   *   This score determines how semantically similar a search query is to a
        +   *   document.
        +   *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +   *   Match 25 (BM25) ranking function. This score is calculated using a
        +   *   probabilistic model to estimate the probability that a document is
        +   *   relevant to a given query.
        +   *   * `relevance_score`: semantic relevance adjustment that uses a
        +   *   proprietary Google model to determine the meaning and intent behind a
        +   *   user's query in context with the content in the documents.
        +   *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +   *   predicted Click-through rate (pCTR) to gauge the relevance and
        +   *   attractiveness of a search result from a user's perspective. A higher
        +   *   pCTR suggests that the result is more likely to satisfy the user's query
        +   *   and intent, making it a valuable signal for ranking.
        +   *   * `freshness_rank`: freshness adjustment as a rank
        +   *   * `document_age`: The time in hours elapsed since the document was last
        +   *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +   *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +   *   Google model to determine the keyword-based overlap between the query and
        +   *   the document.
        +   *   * `base_rank`: the default rank of the result
        +   * 
        + * + * string ranking_expression = 26; + * + * @return The rankingExpression. + */ + java.lang.String getRankingExpression(); + + /** + * + * + *
        +   * The ranking expression controls the customized ranking on retrieval
        +   * documents. This overrides
        +   * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression].
        +   * The syntax and supported features depend on the
        +   * `ranking_expression_backend` value. If `ranking_expression_backend` is not
        +   * provided, it defaults to `RANK_BY_EMBEDDING`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single
        +   * function or multiple functions that are joined by "+".
        +   *
        +   *   * ranking_expression = function, { " + ", function };
        +   *
        +   * Supported functions:
        +   *
        +   *   * double * relevance_score
        +   *   * double * dotProduct(embedding_field_path)
        +   *
        +   * Function variables:
        +   *
        +   *   * `relevance_score`: pre-defined keywords, used for measure relevance
        +   *   between query and document.
        +   *   * `embedding_field_path`: the document embedding field
        +   *   used with query embedding vector.
        +   *   * `dotProduct`: embedding function between `embedding_field_path` and
        +   *   query embedding vector.
        +   *
        +   *  Example ranking expression:
        +   *
        +   *    If document has an embedding field doc_embedding, the ranking expression
        +   *    could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`.
        +   *
        +   * If
        +   * [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend]
        +   * is set to `RANK_BY_FORMULA`, the following expression types (and
        +   * combinations of those chained using + or
        +   * * operators) are supported:
        +   *
        +   *   * `double`
        +   *   * `signal`
        +   *   * `log(signal)`
        +   *   * `exp(signal)`
        +   *   * `rr(signal, double > 0)`  -- reciprocal rank transformation with second
        +   *   argument being a denominator constant.
        +   *   * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise.
        +   *   * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns
        +   *   signal2 | double, else returns signal1.
        +   *
        +   *   Here are a few examples of ranking formulas that use the supported
        +   *   ranking expression types:
        +   *
        +   *   - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)`
        +   *   -- mostly rank by the logarithm of `keyword_similarity_score` with slight
        +   *   `semantic_smilarity_score` adjustment.
        +   *   - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 *
        +   *   is_nan(keyword_similarity_score)` -- rank by the exponent of
        +   *   `semantic_similarity_score` filling the value with 0 if it's NaN, also
        +   *   add constant 0.3 adjustment to the final score if
        +   *   `semantic_similarity_score` is NaN.
        +   *   - `0.2 * rr(semantic_similarity_score, 16) + 0.8 *
        +   *   rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank
        +   *   of `keyword_similarity_score` with slight adjustment of reciprocal rank
        +   *   of `semantic_smilarity_score`.
        +   *
        +   * The following signals are supported:
        +   *
        +   *   * `semantic_similarity_score`: semantic similarity adjustment that is
        +   *   calculated using the embeddings generated by a proprietary Google model.
        +   *   This score determines how semantically similar a search query is to a
        +   *   document.
        +   *   * `keyword_similarity_score`: keyword match adjustment uses the Best
        +   *   Match 25 (BM25) ranking function. This score is calculated using a
        +   *   probabilistic model to estimate the probability that a document is
        +   *   relevant to a given query.
        +   *   * `relevance_score`: semantic relevance adjustment that uses a
        +   *   proprietary Google model to determine the meaning and intent behind a
        +   *   user's query in context with the content in the documents.
        +   *   * `pctr_rank`: predicted conversion rate adjustment as a rank use
        +   *   predicted Click-through rate (pCTR) to gauge the relevance and
        +   *   attractiveness of a search result from a user's perspective. A higher
        +   *   pCTR suggests that the result is more likely to satisfy the user's query
        +   *   and intent, making it a valuable signal for ranking.
        +   *   * `freshness_rank`: freshness adjustment as a rank
        +   *   * `document_age`: The time in hours elapsed since the document was last
        +   *   updated, a floating-point number (e.g., 0.25 means 15 minutes).
        +   *   * `topicality_rank`: topicality adjustment as a rank. Uses proprietary
        +   *   Google model to determine the keyword-based overlap between the query and
        +   *   the document.
        +   *   * `base_rank`: the default rank of the result
        +   * 
        + * + * string ranking_expression = 26; + * + * @return The bytes for rankingExpression. + */ + com.google.protobuf.ByteString getRankingExpressionBytes(); + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + int getRankingExpressionBackendValue(); + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + com.google.cloud.discoveryengine.v1.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend(); } diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchResponse.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchResponse.java index 815b73a4e402..4aef22262db0 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchResponse.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchResponse.java @@ -265,6 +265,50 @@ com.google.cloud.discoveryengine.v1.DoubleList getModelScoresOrDefault( * */ com.google.cloud.discoveryengine.v1.DoubleList getModelScoresOrThrow(java.lang.String key); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + boolean hasRankSignals(); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals getRankSignals(); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder(); } /** @@ -287,41 +331,3351 @@ private SearchResult(com.google.protobuf.GeneratedMessageV3.Builder builder) super(builder); } - private SearchResult() { - id_ = ""; - } + private SearchResult() { + id_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SearchResult(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetModelScores(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.class, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.Builder.class); + } + + public interface RankSignalsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + boolean hasKeywordSimilarityScore(); + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + float getKeywordSimilarityScore(); + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the relevanceScore field is set. + */ + boolean hasRelevanceScore(); + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The relevanceScore. + */ + float getRelevanceScore(); + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + boolean hasSemanticSimilarityScore(); + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + float getSemanticSimilarityScore(); + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + boolean hasPctrRank(); + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + float getPctrRank(); + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the topicalityRank field is set. + */ + boolean hasTopicalityRank(); + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topicalityRank. + */ + float getTopicalityRank(); + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + boolean hasDocumentAge(); + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + float getDocumentAge(); + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the boostingFactor field is set. + */ + boolean hasBoostingFactor(); + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The boostingFactor. + */ + float getBoostingFactor(); + + /** + * + * + *
        +       * The default rank of the result.
        +       * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + float getDefaultRank(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + getCustomSignals(int index); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getCustomSignalsCount(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + ? extends + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index); + } + + /** + * + * + *
        +     * A set of ranking signals.
        +     * 
        + * + * Protobuf type {@code google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals} + */ + public static final class RankSignals extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) + RankSignalsOrBuilder { + private static final long serialVersionUID = 0L; + + // Use RankSignals.newBuilder() to construct. + private RankSignals(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RankSignals() { + customSignals_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RankSignals(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.class, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.Builder + .class); + } + + public interface CustomSignalOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +         * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +         * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + float getValue(); + } + + /** + * + * + *
        +       * Custom clearbox signal represented by name and value pair.
        +       * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal} + */ + public static final class CustomSignal extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal) + CustomSignalOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CustomSignal.newBuilder() to construct. + private CustomSignal(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CustomSignal() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CustomSignal(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.class, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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 VALUE_FIELD_NUMBER = 2; + private float value_ = 0F; + + /** + * + * + *
        +         * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +         * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + @java.lang.Override + public float getValue() { + return value_; + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (java.lang.Float.floatToRawIntBits(value_) != 0) { + output.writeFloat(2, value_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (java.lang.Float.floatToRawIntBits(value_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, 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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal)) { + return super.equals(obj); + } + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + other = + (com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal) + obj; + + if (!getName().equals(other.getName())) return false; + if (java.lang.Float.floatToIntBits(getValue()) + != java.lang.Float.floatToIntBits(other.getValue())) 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) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getValue()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + 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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + 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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +         * Custom clearbox signal represented by name and value pair.
        +         * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal) + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.class, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder.class); + } + + // Construct using + // com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + value_ = 0F; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstanceForType() { + return com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + build() { + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + buildPartial() { + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + result = + new com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.value_ = value_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal) { + return mergeFrom( + (com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + other) { + if (other + == com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getValue() != 0F) { + setValue(other.getValue()); + } + 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 21: + { + value_ = input.readFloat(); + bitField0_ |= 0x00000002; + break; + } // case 21 + 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_ = ""; + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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 float value_; + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + @java.lang.Override + public float getValue() { + return value_; + } + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(float value) { + + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + bitField0_ = (bitField0_ & ~0x00000002); + value_ = 0F; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal) + } + + // @@protoc_insertion_point(class_scope:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal) + private static final com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult + .RankSignals.CustomSignal + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal(); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CustomSignal 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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int KEYWORD_SIMILARITY_SCORE_FIELD_NUMBER = 1; + private float keywordSimilarityScore_ = 0F; + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasKeywordSimilarityScore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + @java.lang.Override + public float getKeywordSimilarityScore() { + return keywordSimilarityScore_; + } + + public static final int RELEVANCE_SCORE_FIELD_NUMBER = 2; + private float relevanceScore_ = 0F; + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the relevanceScore field is set. + */ + @java.lang.Override + public boolean hasRelevanceScore() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The relevanceScore. + */ + @java.lang.Override + public float getRelevanceScore() { + return relevanceScore_; + } + + public static final int SEMANTIC_SIMILARITY_SCORE_FIELD_NUMBER = 3; + private float semanticSimilarityScore_ = 0F; + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasSemanticSimilarityScore() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + @java.lang.Override + public float getSemanticSimilarityScore() { + return semanticSimilarityScore_; + } + + public static final int PCTR_RANK_FIELD_NUMBER = 4; + private float pctrRank_ = 0F; + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + @java.lang.Override + public boolean hasPctrRank() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + @java.lang.Override + public float getPctrRank() { + return pctrRank_; + } + + public static final int TOPICALITY_RANK_FIELD_NUMBER = 6; + private float topicalityRank_ = 0F; + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the topicalityRank field is set. + */ + @java.lang.Override + public boolean hasTopicalityRank() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topicalityRank. + */ + @java.lang.Override + public float getTopicalityRank() { + return topicalityRank_; + } + + public static final int DOCUMENT_AGE_FIELD_NUMBER = 7; + private float documentAge_ = 0F; + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + @java.lang.Override + public boolean hasDocumentAge() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + @java.lang.Override + public float getDocumentAge() { + return documentAge_; + } + + public static final int BOOSTING_FACTOR_FIELD_NUMBER = 8; + private float boostingFactor_ = 0F; + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the boostingFactor field is set. + */ + @java.lang.Override + public boolean hasBoostingFactor() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The boostingFactor. + */ + @java.lang.Override + public float getBoostingFactor() { + return boostingFactor_; + } + + public static final int DEFAULT_RANK_FIELD_NUMBER = 32; + private float defaultRank_ = 0F; + + /** + * + * + *
        +       * The default rank of the result.
        +       * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + @java.lang.Override + public float getDefaultRank() { + return defaultRank_; + } + + public static final int CUSTOM_SIGNALS_FIELD_NUMBER = 33; + + @SuppressWarnings("serial") + private java.util.List< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal> + customSignals_; + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList() { + return customSignals_; + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList() { + return customSignals_; + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getCustomSignalsCount() { + return customSignals_.size(); + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + getCustomSignals(int index) { + return customSignals_.get(index); + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index) { + return customSignals_.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 { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeFloat(1, keywordSimilarityScore_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeFloat(2, relevanceScore_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeFloat(3, semanticSimilarityScore_); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeFloat(4, pctrRank_); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeFloat(6, topicalityRank_); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeFloat(7, documentAge_); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeFloat(8, boostingFactor_); + } + if (java.lang.Float.floatToRawIntBits(defaultRank_) != 0) { + output.writeFloat(32, defaultRank_); + } + for (int i = 0; i < customSignals_.size(); i++) { + output.writeMessage(33, customSignals_.get(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.computeFloatSize(1, keywordSimilarityScore_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, relevanceScore_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeFloatSize(3, semanticSimilarityScore_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(4, pctrRank_); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(6, topicalityRank_); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(7, documentAge_); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(8, boostingFactor_); + } + if (java.lang.Float.floatToRawIntBits(defaultRank_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(32, defaultRank_); + } + for (int i = 0; i < customSignals_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(33, customSignals_.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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals)) { + return super.equals(obj); + } + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals other = + (com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) obj; + + if (hasKeywordSimilarityScore() != other.hasKeywordSimilarityScore()) return false; + if (hasKeywordSimilarityScore()) { + if (java.lang.Float.floatToIntBits(getKeywordSimilarityScore()) + != java.lang.Float.floatToIntBits(other.getKeywordSimilarityScore())) return false; + } + if (hasRelevanceScore() != other.hasRelevanceScore()) return false; + if (hasRelevanceScore()) { + if (java.lang.Float.floatToIntBits(getRelevanceScore()) + != java.lang.Float.floatToIntBits(other.getRelevanceScore())) return false; + } + if (hasSemanticSimilarityScore() != other.hasSemanticSimilarityScore()) return false; + if (hasSemanticSimilarityScore()) { + if (java.lang.Float.floatToIntBits(getSemanticSimilarityScore()) + != java.lang.Float.floatToIntBits(other.getSemanticSimilarityScore())) return false; + } + if (hasPctrRank() != other.hasPctrRank()) return false; + if (hasPctrRank()) { + if (java.lang.Float.floatToIntBits(getPctrRank()) + != java.lang.Float.floatToIntBits(other.getPctrRank())) return false; + } + if (hasTopicalityRank() != other.hasTopicalityRank()) return false; + if (hasTopicalityRank()) { + if (java.lang.Float.floatToIntBits(getTopicalityRank()) + != java.lang.Float.floatToIntBits(other.getTopicalityRank())) return false; + } + if (hasDocumentAge() != other.hasDocumentAge()) return false; + if (hasDocumentAge()) { + if (java.lang.Float.floatToIntBits(getDocumentAge()) + != java.lang.Float.floatToIntBits(other.getDocumentAge())) return false; + } + if (hasBoostingFactor() != other.hasBoostingFactor()) return false; + if (hasBoostingFactor()) { + if (java.lang.Float.floatToIntBits(getBoostingFactor()) + != java.lang.Float.floatToIntBits(other.getBoostingFactor())) return false; + } + if (java.lang.Float.floatToIntBits(getDefaultRank()) + != java.lang.Float.floatToIntBits(other.getDefaultRank())) return false; + if (!getCustomSignalsList().equals(other.getCustomSignalsList())) 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 (hasKeywordSimilarityScore()) { + hash = (37 * hash) + KEYWORD_SIMILARITY_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getKeywordSimilarityScore()); + } + if (hasRelevanceScore()) { + hash = (37 * hash) + RELEVANCE_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getRelevanceScore()); + } + if (hasSemanticSimilarityScore()) { + hash = (37 * hash) + SEMANTIC_SIMILARITY_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getSemanticSimilarityScore()); + } + if (hasPctrRank()) { + hash = (37 * hash) + PCTR_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getPctrRank()); + } + if (hasTopicalityRank()) { + hash = (37 * hash) + TOPICALITY_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getTopicalityRank()); + } + if (hasDocumentAge()) { + hash = (37 * hash) + DOCUMENT_AGE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getDocumentAge()); + } + if (hasBoostingFactor()) { + hash = (37 * hash) + BOOSTING_FACTOR_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getBoostingFactor()); + } + hash = (37 * hash) + DEFAULT_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getDefaultRank()); + if (getCustomSignalsCount() > 0) { + hash = (37 * hash) + CUSTOM_SIGNALS_FIELD_NUMBER; + hash = (53 * hash) + getCustomSignalsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + 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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + 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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.discoveryengine.v1.SearchResponse.SearchResult.RankSignals 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +       * A set of ranking signals.
        +       * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.class, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .Builder.class); + } + + // Construct using + // com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + keywordSimilarityScore_ = 0F; + relevanceScore_ = 0F; + semanticSimilarityScore_ = 0F; + pctrRank_ = 0F; + topicalityRank_ = 0F; + documentAge_ = 0F; + boostingFactor_ = 0F; + defaultRank_ = 0F; + if (customSignalsBuilder_ == null) { + customSignals_ = java.util.Collections.emptyList(); + } else { + customSignals_ = null; + customSignalsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000100); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.discoveryengine.v1.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + getDefaultInstanceForType() { + return com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals build() { + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + buildPartial() { + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals result = + new com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals(this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals result) { + if (customSignalsBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0)) { + customSignals_ = java.util.Collections.unmodifiableList(customSignals_); + bitField0_ = (bitField0_ & ~0x00000100); + } + result.customSignals_ = customSignals_; + } else { + result.customSignals_ = customSignalsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.keywordSimilarityScore_ = keywordSimilarityScore_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.relevanceScore_ = relevanceScore_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.semanticSimilarityScore_ = semanticSimilarityScore_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pctrRank_ = pctrRank_; + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.topicalityRank_ = topicalityRank_; + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.documentAge_ = documentAge_; + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.boostingFactor_ = boostingFactor_; + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.defaultRank_ = defaultRank_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) { + return mergeFrom( + (com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals other) { + if (other + == com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance()) return this; + if (other.hasKeywordSimilarityScore()) { + setKeywordSimilarityScore(other.getKeywordSimilarityScore()); + } + if (other.hasRelevanceScore()) { + setRelevanceScore(other.getRelevanceScore()); + } + if (other.hasSemanticSimilarityScore()) { + setSemanticSimilarityScore(other.getSemanticSimilarityScore()); + } + if (other.hasPctrRank()) { + setPctrRank(other.getPctrRank()); + } + if (other.hasTopicalityRank()) { + setTopicalityRank(other.getTopicalityRank()); + } + if (other.hasDocumentAge()) { + setDocumentAge(other.getDocumentAge()); + } + if (other.hasBoostingFactor()) { + setBoostingFactor(other.getBoostingFactor()); + } + if (other.getDefaultRank() != 0F) { + setDefaultRank(other.getDefaultRank()); + } + if (customSignalsBuilder_ == null) { + if (!other.customSignals_.isEmpty()) { + if (customSignals_.isEmpty()) { + customSignals_ = other.customSignals_; + bitField0_ = (bitField0_ & ~0x00000100); + } else { + ensureCustomSignalsIsMutable(); + customSignals_.addAll(other.customSignals_); + } + onChanged(); + } + } else { + if (!other.customSignals_.isEmpty()) { + if (customSignalsBuilder_.isEmpty()) { + customSignalsBuilder_.dispose(); + customSignalsBuilder_ = null; + customSignals_ = other.customSignals_; + bitField0_ = (bitField0_ & ~0x00000100); + customSignalsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getCustomSignalsFieldBuilder() + : null; + } else { + customSignalsBuilder_.addAllMessages(other.customSignals_); + } + } + } + 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 13: + { + keywordSimilarityScore_ = input.readFloat(); + bitField0_ |= 0x00000001; + break; + } // case 13 + case 21: + { + relevanceScore_ = input.readFloat(); + bitField0_ |= 0x00000002; + break; + } // case 21 + case 29: + { + semanticSimilarityScore_ = input.readFloat(); + bitField0_ |= 0x00000004; + break; + } // case 29 + case 37: + { + pctrRank_ = input.readFloat(); + bitField0_ |= 0x00000008; + break; + } // case 37 + case 53: + { + topicalityRank_ = input.readFloat(); + bitField0_ |= 0x00000010; + break; + } // case 53 + case 61: + { + documentAge_ = input.readFloat(); + bitField0_ |= 0x00000020; + break; + } // case 61 + case 69: + { + boostingFactor_ = input.readFloat(); + bitField0_ |= 0x00000040; + break; + } // case 69 + case 261: + { + defaultRank_ = input.readFloat(); + bitField0_ |= 0x00000080; + break; + } // case 261 + case 266: + { + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + m = + input.readMessage( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult + .RankSignals.CustomSignal.parser(), + extensionRegistry); + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(m); + } else { + customSignalsBuilder_.addMessage(m); + } + break; + } // case 266 + 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 float keywordSimilarityScore_; + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasKeywordSimilarityScore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + @java.lang.Override + public float getKeywordSimilarityScore() { + return keywordSimilarityScore_; + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The keywordSimilarityScore to set. + * @return This builder for chaining. + */ + public Builder setKeywordSimilarityScore(float value) { + + keywordSimilarityScore_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearKeywordSimilarityScore() { + bitField0_ = (bitField0_ & ~0x00000001); + keywordSimilarityScore_ = 0F; + onChanged(); + return this; + } + + private float relevanceScore_; + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the relevanceScore field is set. + */ + @java.lang.Override + public boolean hasRelevanceScore() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The relevanceScore. + */ + @java.lang.Override + public float getRelevanceScore() { + return relevanceScore_; + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The relevanceScore to set. + * @return This builder for chaining. + */ + public Builder setRelevanceScore(float value) { + + relevanceScore_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRelevanceScore() { + bitField0_ = (bitField0_ & ~0x00000002); + relevanceScore_ = 0F; + onChanged(); + return this; + } + + private float semanticSimilarityScore_; + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasSemanticSimilarityScore() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + @java.lang.Override + public float getSemanticSimilarityScore() { + return semanticSimilarityScore_; + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The semanticSimilarityScore to set. + * @return This builder for chaining. + */ + public Builder setSemanticSimilarityScore(float value) { + + semanticSimilarityScore_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSemanticSimilarityScore() { + bitField0_ = (bitField0_ & ~0x00000004); + semanticSimilarityScore_ = 0F; + onChanged(); + return this; + } + + private float pctrRank_; + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + @java.lang.Override + public boolean hasPctrRank() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + @java.lang.Override + public float getPctrRank() { + return pctrRank_; + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pctrRank to set. + * @return This builder for chaining. + */ + public Builder setPctrRank(float value) { + + pctrRank_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPctrRank() { + bitField0_ = (bitField0_ & ~0x00000008); + pctrRank_ = 0F; + onChanged(); + return this; + } + + private float topicalityRank_; + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the topicalityRank field is set. + */ + @java.lang.Override + public boolean hasTopicalityRank() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The topicalityRank. + */ + @java.lang.Override + public float getTopicalityRank() { + return topicalityRank_; + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The topicalityRank to set. + * @return This builder for chaining. + */ + public Builder setTopicalityRank(float value) { + + topicalityRank_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearTopicalityRank() { + bitField0_ = (bitField0_ & ~0x00000010); + topicalityRank_ = 0F; + onChanged(); + return this; + } + + private float documentAge_; + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + @java.lang.Override + public boolean hasDocumentAge() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + @java.lang.Override + public float getDocumentAge() { + return documentAge_; + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The documentAge to set. + * @return This builder for chaining. + */ + public Builder setDocumentAge(float value) { + + documentAge_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDocumentAge() { + bitField0_ = (bitField0_ & ~0x00000020); + documentAge_ = 0F; + onChanged(); + return this; + } + + private float boostingFactor_; + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the boostingFactor field is set. + */ + @java.lang.Override + public boolean hasBoostingFactor() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The boostingFactor. + */ + @java.lang.Override + public float getBoostingFactor() { + return boostingFactor_; + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The boostingFactor to set. + * @return This builder for chaining. + */ + public Builder setBoostingFactor(float value) { + + boostingFactor_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearBoostingFactor() { + bitField0_ = (bitField0_ & ~0x00000040); + boostingFactor_ = 0F; + onChanged(); + return this; + } + + private float defaultRank_; + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + @java.lang.Override + public float getDefaultRank() { + return defaultRank_; + } + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The defaultRank to set. + * @return This builder for chaining. + */ + public Builder setDefaultRank(float value) { + + defaultRank_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDefaultRank() { + bitField0_ = (bitField0_ & ~0x00000080); + defaultRank_ = 0F; + onChanged(); + return this; + } + + private java.util.List< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal> + customSignals_ = java.util.Collections.emptyList(); + + private void ensureCustomSignalsIsMutable() { + if (!((bitField0_ & 0x00000100) != 0)) { + customSignals_ = + new java.util.ArrayList< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal>(customSignals_); + bitField0_ |= 0x00000100; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + customSignalsBuilder_; + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList() { + if (customSignalsBuilder_ == null) { + return java.util.Collections.unmodifiableList(customSignals_); + } else { + return customSignalsBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getCustomSignalsCount() { + if (customSignalsBuilder_ == null) { + return customSignals_.size(); + } else { + return customSignalsBuilder_.getCount(); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal + getCustomSignals(int index) { + if (customSignalsBuilder_ == null) { + return customSignals_.get(index); + } else { + return customSignalsBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCustomSignals( + int index, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.set(index, value); + onChanged(); + } else { + customSignalsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCustomSignals( + int index, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + .Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.set(index, builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.add(value); + onChanged(); + } else { + customSignalsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + int index, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.add(index, value); + onChanged(); + } else { + customSignalsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + .Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + int index, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal + .Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(index, builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllCustomSignals( + java.lang.Iterable< + ? extends + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal> + values) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, customSignals_); + onChanged(); + } else { + customSignalsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearCustomSignals() { + if (customSignalsBuilder_ == null) { + customSignals_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + } else { + customSignalsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeCustomSignals(int index) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.remove(index); + onChanged(); + } else { + customSignalsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + getCustomSignalsBuilder(int index) { + return getCustomSignalsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index) { + if (customSignalsBuilder_ == null) { + return customSignals_.get(index); + } else { + return customSignalsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + ? extends + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList() { + if (customSignalsBuilder_ != null) { + return customSignalsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(customSignals_); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + addCustomSignalsBuilder() { + return getCustomSignalsFieldBuilder() + .addBuilder( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + addCustomSignalsBuilder(int index) { + return getCustomSignalsFieldBuilder() + .addBuilder( + index, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder> + getCustomSignalsBuilderList() { + return getCustomSignalsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsFieldBuilder() { + if (customSignalsBuilder_ == null) { + customSignalsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder>( + customSignals_, + ((bitField0_ & 0x00000100) != 0), + getParentForChildren(), + isClean()); + customSignals_ = null; + } + return customSignalsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) + } + + // @@protoc_insertion_point(class_scope:google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals) + private static final com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult + .RankSignals + DEFAULT_INSTANCE; - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new SearchResult(); - } + static { + DEFAULT_INSTANCE = + new com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals(); + } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.discoveryengine.v1.SearchServiceProto - .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_descriptor; - } + public static com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + getDefaultInstance() { + return DEFAULT_INSTANCE; + } - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( - int number) { - switch (number) { - case 4: - return internalGetModelScores(); - default: - throw new RuntimeException("Invalid map field number: " + number); + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RankSignals 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 - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.discoveryengine.v1.SearchServiceProto - .internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.class, - com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.Builder.class); + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } } private int bitField0_; @@ -627,6 +3981,70 @@ public com.google.cloud.discoveryengine.v1.DoubleList getModelScoresOrThrow( return map.get(key); } + public static final int RANK_SIGNALS_FIELD_NUMBER = 7; + private com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + rankSignals_; + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + @java.lang.Override + public boolean hasRankSignals() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + getRankSignals() { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder() { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -649,6 +4067,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetModelScores(), ModelScoresDefaultEntryHolder.defaultEntry, 4); + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(7, getRankSignals()); + } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(18, getChunk()); } @@ -679,6 +4100,9 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, modelScores__); } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getRankSignals()); + } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getChunk()); } @@ -708,6 +4132,10 @@ public boolean equals(final java.lang.Object obj) { if (!getChunk().equals(other.getChunk())) return false; } if (!internalGetModelScores().equals(other.internalGetModelScores())) return false; + if (hasRankSignals() != other.hasRankSignals()) return false; + if (hasRankSignals()) { + if (!getRankSignals().equals(other.getRankSignals())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -733,6 +4161,10 @@ public int hashCode() { hash = (37 * hash) + MODEL_SCORES_FIELD_NUMBER; hash = (53 * hash) + internalGetModelScores().hashCode(); } + if (hasRankSignals()) { + hash = (37 * hash) + RANK_SIGNALS_FIELD_NUMBER; + hash = (53 * hash) + getRankSignals().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -903,6 +4335,7 @@ private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getDocumentFieldBuilder(); getChunkFieldBuilder(); + getRankSignalsFieldBuilder(); } } @@ -922,6 +4355,11 @@ public Builder clear() { chunkBuilder_ = null; } internalGetMutableModelScores().clear(); + rankSignals_ = null; + if (rankSignalsBuilder_ != null) { + rankSignalsBuilder_.dispose(); + rankSignalsBuilder_ = null; + } return this; } @@ -976,6 +4414,11 @@ private void buildPartial0( result.modelScores_ = internalGetModelScores().build(ModelScoresDefaultEntryHolder.defaultEntry); } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.rankSignals_ = + rankSignalsBuilder_ == null ? rankSignals_ : rankSignalsBuilder_.build(); + to_bitField0_ |= 0x00000004; + } result.bitField0_ |= to_bitField0_; } @@ -1042,6 +4485,9 @@ public Builder mergeFrom( } internalGetMutableModelScores().mergeFrom(other.internalGetModelScores()); bitField0_ |= 0x00000008; + if (other.hasRankSignals()) { + mergeRankSignals(other.getRankSignals()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1094,6 +4540,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 58: + { + input.readMessage(getRankSignalsFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 58 case 146: { input.readMessage(getChunkFieldBuilder().getBuilder(), extensionRegistry); @@ -1923,6 +5375,231 @@ public com.google.cloud.discoveryengine.v1.DoubleList.Builder putModelScoresBuil return (com.google.cloud.discoveryengine.v1.DoubleList.Builder) entry; } + private com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + rankSignals_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.Builder, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsOrBuilder> + rankSignalsBuilder_; + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + public boolean hasRankSignals() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + getRankSignals() { + if (rankSignalsBuilder_ == null) { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } else { + return rankSignalsBuilder_.getMessage(); + } + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRankSignals( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals value) { + if (rankSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + rankSignals_ = value; + } else { + rankSignalsBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRankSignals( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.Builder + builderForValue) { + if (rankSignalsBuilder_ == null) { + rankSignals_ = builderForValue.build(); + } else { + rankSignalsBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeRankSignals( + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals value) { + if (rankSignalsBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && rankSignals_ != null + && rankSignals_ + != com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance()) { + getRankSignalsBuilder().mergeFrom(value); + } else { + rankSignals_ = value; + } + } else { + rankSignalsBuilder_.mergeFrom(value); + } + if (rankSignals_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearRankSignals() { + bitField0_ = (bitField0_ & ~0x00000010); + rankSignals_ = null; + if (rankSignalsBuilder_ != null) { + rankSignalsBuilder_.dispose(); + rankSignalsBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.Builder + getRankSignalsBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return getRankSignalsFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder() { + if (rankSignalsBuilder_ != null) { + return rankSignalsBuilder_.getMessageOrBuilder(); + } else { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals.Builder, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsOrBuilder> + getRankSignalsFieldBuilder() { + if (rankSignalsBuilder_ == null) { + rankSignalsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1.SearchResponse.SearchResult + .RankSignalsOrBuilder>(getRankSignals(), getParentForChildren(), isClean()); + rankSignals_ = null; + } + return rankSignalsBuilder_; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceProto.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceProto.java index 852612d6440b..0aed666d1a15 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceProto.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/java/com/google/cloud/discoveryengine/v1/SearchServiceProto.java @@ -136,6 +136,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_ModelScoresEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_ModelScoresEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_discoveryengine_v1_SearchResponse_Facet_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -200,7 +208,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "_behavior.proto\032\031google/api/resource.pro" + "to\032+google/cloud/discoveryengine/v1/chunk.proto\032,google/cloud/discoveryengine/v1" + "/common.proto\032.google/cloud/discoveryeng" - + "ine/v1/document.proto\032\034google/protobuf/struct.proto\"\2740\n\r" + + "ine/v1/document.proto\032\034google/protobuf/struct.proto\"\3122\n\r" + "SearchRequest\022L\n" + "\016serving_config\030\001 \001(\tB4\340A\002\372A.\n" + ",discoveryengine.googleapis.com/ServingConfig\022:\n" @@ -247,7 +255,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\023relevance_threshold\030, \001(\0162A.googl" + "e.cloud.discoveryengine.v1.SearchRequest.RelevanceThreshold\022d\n" + "\024relevance_score_spec\0304 \001(\0132A.google.cloud.discoveryengine" - + ".v1.SearchRequest.RelevanceScoreSpecB\003\340A\001\032,\n\n" + + ".v1.SearchRequest.RelevanceScoreSpecB\003\340A\001\022\032\n" + + "\022ranking_expression\030\032 \001(\t\022p\n" + + "\032ranking_expression_backend\0305 \001(\0162G.google.cloud" + + ".discoveryengine.v1.SearchRequest.RankingExpressionBackendB\003\340A\001\032,\n\n" + "ImageQuery\022\025\n" + "\013image_bytes\030\001 \001(\tH\000B\007\n" + "\005image\032\343\001\n\r" @@ -255,12 +266,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "data_store\030\001 \001(\tB0\340A\002\372A*\n" + "(discoveryengine.googleapis.com/DataStore\022\023\n" + "\006filter\030\005 \001(\tB\003\340A\001\022Q\n\n" - + "boost_spec\030\006 \001(\01328.google.cloud.discover" - + "yengine.v1.SearchRequest.BoostSpecB\003\340A\001\022$\n" + + "boost_spec\030\006 \001(\01328" + + ".google.cloud.discoveryengine.v1.SearchRequest.BoostSpecB\003\340A\001\022$\n" + "\027custom_search_operators\030\007 \001(\tB\003\340A\001\032\374\002\n" + "\tFacetSpec\022Y\n" - + "\tfacet_key\030\001 \001(\0132A.google." - + "cloud.discoveryengine.v1.SearchRequest.FacetSpec.FacetKeyB\003\340A\002\022\r\n" + + "\tfacet_key\030\001 \001(\0132A.google.cloud.discoveryeng" + + "ine.v1.SearchRequest.FacetSpec.FacetKeyB\003\340A\002\022\r\n" + "\005limit\030\002 \001(\005\022\034\n" + "\024excluded_filter_keys\030\003 \003(\t\022\037\n" + "\027enable_dynamic_position\030\004 \001(\010\032\305\001\n" @@ -273,24 +284,23 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020case_insensitive\030\006 \001(\010\022\020\n" + "\010order_by\030\007 \001(\t\032\274\007\n" + "\tBoostSpec\022j\n" - + "\025condition_boost_specs\030\001 \003(\0132K.google.cloud" - + ".discoveryengine.v1.SearchRequest.BoostSpec.ConditionBoostSpec\032\302\006\n" + + "\025condition_boost_specs\030\001 \003(\0132K.google.cloud.discoveryengine.v" + + "1.SearchRequest.BoostSpec.ConditionBoostSpec\032\302\006\n" + "\022ConditionBoostSpec\022\021\n" + "\tcondition\030\001 \001(\t\022\r\n" + "\005boost\030\002 \001(\002\022x\n" - + "\022boost_control_spec\030\003 \001(\0132\\.google.clo" - + "ud.discoveryengine.v1.SearchRequest.Boos" - + "tSpec.ConditionBoostSpec.BoostControlSpec\032\217\005\n" + + "\022boost_control_spec\030\003 \001(\0132\\.google.cloud.discoveryengine" + + ".v1.SearchRequest.BoostSpec.ConditionBoostSpec.BoostControlSpec\032\217\005\n" + "\020BoostControlSpec\022\022\n\n" + "field_name\030\001 \001(\t\022\202\001\n" - + "\016attribute_type\030\002 \001(\0162j.google.clo" - + "ud.discoveryengine.v1.SearchRequest.Boos" - + "tSpec.ConditionBoostSpec.BoostControlSpec.AttributeType\022\212\001\n" - + "\022interpolation_type\030\003 \001(\0162n.google.cloud.discoveryengine.v1.S" - + "earchRequest.BoostSpec.ConditionBoostSpec.BoostControlSpec.InterpolationType\022\201\001\n" - + "\016control_points\030\004 \003(\0132i.google.cloud.dis" - + "coveryengine.v1.SearchRequest.BoostSpec." - + "ConditionBoostSpec.BoostControlSpec.ControlPoint\032=\n" + + "\016attribute_type\030\002 \001(\0162j.google.cloud.discoveryengine" + + ".v1.SearchRequest.BoostSpec.ConditionBoo" + + "stSpec.BoostControlSpec.AttributeType\022\212\001\n" + + "\022interpolation_type\030\003 \001(\0162n.google.clou" + + "d.discoveryengine.v1.SearchRequest.Boost" + + "Spec.ConditionBoostSpec.BoostControlSpec.InterpolationType\022\201\001\n" + + "\016control_points\030\004 \003(\0132i.google.cloud.discoveryengine.v1.Se" + + "archRequest.BoostSpec.ConditionBoostSpec.BoostControlSpec.ControlPoint\032=\n" + "\014ControlPoint\022\027\n" + "\017attribute_value\030\001 \001(\t\022\024\n" + "\014boost_amount\030\002 \001(\002\"M\n\r" @@ -302,31 +312,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\036INTERPOLATION_TYPE_UNSPECIFIED\020\000\022\n\n" + "\006LINEAR\020\001\032\324\001\n" + "\022QueryExpansionSpec\022^\n" - + "\tcondition\030\001 \001(\0162K.google.cloud.dis" - + "coveryengine.v1.SearchRequest.QueryExpansionSpec.Condition\022\036\n" + + "\tcondition\030\001 \001(\0162K.google.cloud.discoveryengine.v1.Se" + + "archRequest.QueryExpansionSpec.Condition\022\036\n" + "\026pin_unexpanded_results\030\002 \001(\010\">\n" + "\tCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\010\n" + "\004AUTO\020\002\032\251\001\n" + "\023SpellCorrectionSpec\022U\n" - + "\004mode\030\001 \001(\0162G.googl" - + "e.cloud.discoveryengine.v1.SearchRequest.SpellCorrectionSpec.Mode\";\n" + + "\004mode\030\001 \001(\0162G.google.cloud.discoverye" + + "ngine.v1.SearchRequest.SpellCorrectionSpec.Mode\";\n" + "\004Mode\022\024\n" + "\020MODE_UNSPECIFIED\020\000\022\023\n" + "\017SUGGESTION_ONLY\020\001\022\010\n" + "\004AUTO\020\002\032\242\014\n" + "\021ContentSearchSpec\022b\n" - + "\014snippet_spec\030\001 \001(\0132L.google.cloud.discoveryengin" - + "e.v1.SearchRequest.ContentSearchSpec.SnippetSpec\022b\n" - + "\014summary_spec\030\002 \001(\0132L.google." - + "cloud.discoveryengine.v1.SearchRequest.ContentSearchSpec.SummarySpec\022w\n" - + "\027extractive_content_spec\030\003 \001(\0132V.google.cloud.dis" - + "coveryengine.v1.SearchRequest.ContentSearchSpec.ExtractiveContentSpec\022m\n" - + "\022search_result_mode\030\004 \001(\0162Q.google.cloud.discove" - + "ryengine.v1.SearchRequest.ContentSearchSpec.SearchResultMode\022^\n\n" - + "chunk_spec\030\005 \001(\013" - + "2J.google.cloud.discoveryengine.v1.SearchRequest.ContentSearchSpec.ChunkSpec\032`\n" + + "\014snippet_spec\030\001 \001(\0132L.googl" + + "e.cloud.discoveryengine.v1.SearchRequest.ContentSearchSpec.SnippetSpec\022b\n" + + "\014summary_spec\030\002 \001(\0132L.google.cloud.discoveryeng" + + "ine.v1.SearchRequest.ContentSearchSpec.SummarySpec\022w\n" + + "\027extractive_content_spec\030\003 \001(\0132V.google.cloud.discoveryengine.v1.Se" + + "archRequest.ContentSearchSpec.ExtractiveContentSpec\022m\n" + + "\022search_result_mode\030\004 \001(\0162Q.google.cloud.discoveryengine.v1.Search" + + "Request.ContentSearchSpec.SearchResultMode\022^\n\n" + + "chunk_spec\030\005 \001(\0132J.google.cloud.di" + + "scoveryengine.v1.SearchRequest.ContentSearchSpec.ChunkSpec\032`\n" + "\013SnippetSpec\022\035\n" + "\021max_snippet_count\030\001 \001(\005B\002\030\001\022\032\n" + "\016reference_only\030\002 \001(\010B\002\030\001\022\026\n" @@ -339,12 +349,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\033ignore_low_relevant_content\030\t \001(\010\022\'\n" + "\032ignore_jail_breaking_query\030\n" + " \001(\010B\003\340A\001\022w\n" - + "\021model_prompt_spec\030\005 \001(\0132\\.google.cl" - + "oud.discoveryengine.v1.SearchRequest.Con" - + "tentSearchSpec.SummarySpec.ModelPromptSpec\022\025\n\r" + + "\021model_prompt_spec\030\005 \001(\0132\\.google.cloud.discoveryengin" + + "e.v1.SearchRequest.ContentSearchSpec.SummarySpec.ModelPromptSpec\022\025\n\r" + "language_code\030\006 \001(\t\022j\n\n" - + "model_spec\030\007 \001(\0132V.google.cloud.discoveryengine.v1." - + "SearchRequest.ContentSearchSpec.SummarySpec.ModelSpec\022\033\n" + + "model_spec\030\007 \001(\0132V.google.clo" + + "ud.discoveryengine.v1.SearchRequest.ContentSearchSpec.SummarySpec.ModelSpec\022\033\n" + "\023use_semantic_chunks\030\010 \001(\010\032#\n" + "\017ModelPromptSpec\022\020\n" + "\010preamble\030\001 \001(\t\032\034\n" @@ -364,17 +373,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tDOCUMENTS\020\001\022\n\n" + "\006CHUNKS\020\002\032\303\001\n" + "\023SearchAsYouTypeSpec\022_\n" - + "\tcondition\030\001 \001(\0162L.google.cloud.di" - + "scoveryengine.v1.SearchRequest.SearchAsYouTypeSpec.Condition\"K\n" + + "\tcondition\030\001 \001(\0162L.google.cloud.discoveryengine.v1.S" + + "earchRequest.SearchAsYouTypeSpec.Condition\"K\n" + "\tCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\013\n" + "\007ENABLED\020\002\022\010\n" + "\004AUTO\020\003\032\230\002\n" + "\013DisplaySpec\022{\n" - + "\034match_highlighting_condition\030\001 \001(\0162U.google" - + ".cloud.discoveryengine.v1.SearchRequest." - + "DisplaySpec.MatchHighlightingCondition\"\213\001\n" + + "\034match_highlighting_condition\030\001 \001(\0162U.google.cloud.discoveryen" + + "gine.v1.SearchRequest.DisplaySpec.MatchHighlightingCondition\"\213\001\n" + "\032MatchHighlightingCondition\022,\n" + "(MATCH_HIGHLIGHTING_CONDITION_UNSPECIFIED\020\000\022\037\n" + "\033MATCH_HIGHLIGHTING_DISABLED\020\001\022\036\n" @@ -396,39 +404,67 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006LOWEST\020\001\022\007\n" + "\003LOW\020\002\022\n\n" + "\006MEDIUM\020\003\022\010\n" - + "\004HIGH\020\004\"\350\026\n" + + "\004HIGH\020\004\"~\n" + + "\030RankingExpressionBackend\022*\n" + + "&RANKING_EXPRESSION_BACKEND_UNSPECIFIED\020\000\022\025\n" + + "\021RANK_BY_EMBEDDING\020\003\022\023\n" + + "\017RANK_BY_FORMULA\020\004\"\004\010\001\020\001\"\004\010\002\020\002\"\276\034\n" + "\016SearchResponse\022M\n" + "\007results\030\001" + " \003(\0132<.google.cloud.discoveryengine.v1.SearchResponse.SearchResult\022E\n" - + "\006facets\030\002" - + " \003(\01325.google.cloud.discoveryengine.v1.SearchResponse.Facet\022\022\n\n" + + "\006facets\030\002 \003" + + "(\01325.google.cloud.discoveryengine.v1.SearchResponse.Facet\022\022\n\n" + "total_size\030\003 \001(\005\022\031\n" + "\021attribution_token\030\004 \001(\t\022\024\n" + "\014redirect_uri\030\014 \001(\t\022\027\n" + "\017next_page_token\030\005 \001(\t\022\027\n" + "\017corrected_query\030\007 \001(\t\022H\n" - + "\007summary\030\t " - + "\001(\01327.google.cloud.discoveryengine.v1.SearchResponse.Summary\022`\n" - + "\024query_expansion_info\030\016 \001(\0132B.google.cloud.discoveryengin" - + "e.v1.SearchResponse.QueryExpansionInfo\022Q\n" - + "\014session_info\030\023 \001(\0132;.google.cloud.disc" - + "overyengine.v1.SearchResponse.SessionInfo\022T\n" - + "\026search_link_promotions\030\027 \003(\01324.goog" - + "le.cloud.discoveryengine.v1.SearchLinkPromotion\032\331\002\n" + + "\007summary\030\t \001(\01327.goog" + + "le.cloud.discoveryengine.v1.SearchResponse.Summary\022`\n" + + "\024query_expansion_info\030\016 \001(\013" + + "2B.google.cloud.discoveryengine.v1.SearchResponse.QueryExpansionInfo\022Q\n" + + "\014session_info\030\023" + + " \001(\0132;.google.cloud.discoveryengine.v1.SearchResponse.SessionInfo\022T\n" + + "\026search_link_promotions\030\027 \003(\01324.google.cloud.d" + + "iscoveryengine.v1.SearchLinkPromotion\032\257\010\n" + "\014SearchResult\022\n\n" + "\002id\030\001 \001(\t\022;\n" + "\010document\030\002 \001(\0132).google.cloud.discoveryengine.v1.Document\0225\n" + "\005chunk\030\022 \001(\0132&.google.cloud.discoveryengine.v1.Chunk\022h\n" - + "\014model_scores\030\004 \003(\0132M.google.cloud.discoverye" - + "ngine.v1.SearchResponse.SearchResult.ModelScoresEntryB\003\340A\003\032_\n" + + "\014model_scores\030\004 \003(\0132M.google.cloud.discoveryengine.v1.S" + + "earchResponse.SearchResult.ModelScoresEntryB\003\340A\003\022c\n" + + "\014rank_signals\030\007 \001(\0132H.google." + + "cloud.discoveryengine.v1.SearchResponse.SearchResult.RankSignalsB\003\340A\001\032_\n" + "\020ModelScoresEntry\022\013\n" + "\003key\030\001 \001(\t\022:\n" - + "\005value\030\002" - + " \001(\0132+.google.cloud.discoveryengine.v1.DoubleList:\0028\001\032\371\001\n" + + "\005value\030\002 \001(\0132+." + + "google.cloud.discoveryengine.v1.DoubleList:\0028\001\032\356\004\n" + + "\013RankSignals\022*\n" + + "\030keyword_similarity_score\030\001 \001(\002B\003\340A\001H\000\210\001\001\022!\n" + + "\017relevance_score\030\002 \001(\002B\003\340A\001H\001\210\001\001\022+\n" + + "\031semantic_similarity_score\030\003" + + " \001(\002B\003\340A\001H\002\210\001\001\022\033\n" + + "\tpctr_rank\030\004 \001(\002B\003\340A\001H\003\210\001\001\022!\n" + + "\017topicality_rank\030\006 \001(\002B\003\340A\001H\004\210\001\001\022\036\n" + + "\014document_age\030\007 \001(\002B\003\340A\001H\005\210\001\001\022!\n" + + "\017boosting_factor\030\010 \001(\002B\003\340A\001H\006\210\001\001\022\031\n" + + "\014default_rank\030 \001(\002B\003\340A\001\022r\n" + + "\016custom_signals\030! \003(\0132U.google.cloud.discoveryengine." + + "v1.SearchResponse.SearchResult.RankSignals.CustomSignalB\003\340A\001\0325\n" + + "\014CustomSignal\022\021\n" + + "\004name\030\001 \001(\tB\003\340A\001\022\022\n" + + "\005value\030\002 \001(\002B\003\340A\001B\033\n" + + "\031_keyword_similarity_scoreB\022\n" + + "\020_relevance_scoreB\034\n" + + "\032_semantic_similarity_scoreB\014\n\n" + + "_pctr_rankB\022\n" + + "\020_topicality_rankB\017\n\r" + + "_document_ageB\022\n" + + "\020_boosting_factorJ\004\010\005\020\006\032\371\001\n" + "\005Facet\022\013\n" + "\003key\030\001 \001(\t\022P\n" - + "\006values\030\002 \003(\0132@.goo" - + "gle.cloud.discoveryengine.v1.SearchResponse.Facet.FacetValue\022\025\n\r" + + "\006values\030\002 \003(\0132@.google." + + "cloud.discoveryengine.v1.SearchResponse.Facet.FacetValue\022\025\n\r" + "dynamic_facet\030\003 \001(\010\032z\n\n" + "FacetValue\022\017\n" + "\005value\030\001 \001(\tH\000\022=\n" @@ -437,23 +473,23 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013facet_value\032\241\014\n" + "\007Summary\022\024\n" + "\014summary_text\030\001 \001(\t\022m\n" - + "\027summary_skipped_reasons\030\002 \003(\0162L.goo" - + "gle.cloud.discoveryengine.v1.SearchResponse.Summary.SummarySkippedReason\022c\n" - + "\021safety_attributes\030\003 \001(\0132H.google.cloud.disco" - + "veryengine.v1.SearchResponse.Summary.SafetyAttributes\022j\n" - + "\025summary_with_metadata\030\004 \001(\0132K.google.cloud.discoveryengine.v1.S" - + "earchResponse.Summary.SummaryWithMetadata\0326\n" + + "\027summary_skipped_reasons\030\002 \003(\0162L.google." + + "cloud.discoveryengine.v1.SearchResponse.Summary.SummarySkippedReason\022c\n" + + "\021safety_attributes\030\003 \001(\0132H.google.cloud.discovery" + + "engine.v1.SearchResponse.Summary.SafetyAttributes\022j\n" + + "\025summary_with_metadata\030\004 \001(\013" + + "2K.google.cloud.discoveryengine.v1.SearchResponse.Summary.SummaryWithMetadata\0326\n" + "\020SafetyAttributes\022\022\n\n" + "categories\030\001 \003(\t\022\016\n" + "\006scores\030\002 \003(\002\032g\n" + "\020CitationMetadata\022S\n" - + "\tcitations\030\001 \003(\0132@.google.cloud.discover" - + "yengine.v1.SearchResponse.Summary.Citation\032\213\001\n" + + "\tcitations\030\001 \003(\0132@.google.cloud.discoveryeng" + + "ine.v1.SearchResponse.Summary.Citation\032\213\001\n" + "\010Citation\022\023\n" + "\013start_index\030\001 \001(\003\022\021\n" + "\tend_index\030\002 \001(\003\022W\n" - + "\007sources\030\003 \003(\0132F.googl" - + "e.cloud.discoveryengine.v1.SearchResponse.Summary.CitationSource\032)\n" + + "\007sources\030\003 \003(\0132F.google.cl" + + "oud.discoveryengine.v1.SearchResponse.Summary.CitationSource\032)\n" + "\016CitationSource\022\027\n" + "\017reference_index\030\004 \001(\003\032\214\002\n" + "\tReference\022\r\n" @@ -461,17 +497,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010document\030\002 \001(\tB/\340A\002\372A)\n" + "\'discoveryengine.googleapis.com/Document\022\013\n" + "\003uri\030\003 \001(\t\022f\n" - + "\016chunk_contents\030\004 \003(\0132N.google.cloud.discoveryengine.v1.Searc" - + "hResponse.Summary.Reference.ChunkContent\0328\n" + + "\016chunk_contents\030\004 \003(\0132N.g" + + "oogle.cloud.discoveryengine.v1.SearchResponse.Summary.Reference.ChunkContent\0328\n" + "\014ChunkContent\022\017\n" + "\007content\030\001 \001(\t\022\027\n" + "\017page_identifier\030\002 \001(\t\032\342\001\n" + "\023SummaryWithMetadata\022\017\n" + "\007summary\030\001 \001(\t\022c\n" - + "\021citation_metadata\030\002 \001(\0132H.google.cloud.discoveryengine.v1" - + ".SearchResponse.Summary.CitationMetadata\022U\n\n" - + "references\030\003 \003(\0132A.google.cloud.disc" - + "overyengine.v1.SearchResponse.Summary.Reference\"\361\002\n" + + "\021citation_metadata\030\002 \001" + + "(\0132H.google.cloud.discoveryengine.v1.SearchResponse.Summary.CitationMetadata\022U\n\n" + + "references\030\003 \003(\0132A.google.cloud.discover" + + "yengine.v1.SearchResponse.Summary.Reference\"\361\002\n" + "\024SummarySkippedReason\022&\n" + "\"SUMMARY_SKIPPED_REASON_UNSPECIFIED\020\000\022\035\n" + "\031ADVERSARIAL_QUERY_IGNORED\020\001\022%\n" @@ -492,25 +528,26 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\004name\030\001 \001(\t\022\020\n" + "\010query_id\030\002 \001(\t2\227\007\n\r" + "SearchService\022\217\003\n" - + "\006Search\022..google.cloud.discoveryengine.v1.SearchRequest\032/.google.cloud.discov" - + "eryengine.v1.SearchResponse\"\243\002\202\323\344\223\002\234\002\"P/" - + "v1/{serving_config=projects/*/locations/*/dataStores/*/servingConfigs/*}:search:" - + "\001*Zc\"^/v1/{serving_config=projects/*/locations/*/collections/*/dataStores/*/serv" - + "ingConfigs/*}:search:\001*Z`\"[/v1/{serving_config=projects/*/locations/*/collection" - + "s/*/engines/*/servingConfigs/*}:search:\001*\022\237\003\n\n" - + "SearchLite\022..google.cloud.discoveryengine.v1.SearchRequest\032/.google.cloud." - + "discoveryengine.v1.SearchResponse\"\257\002\202\323\344\223" - + "\002\250\002\"T/v1/{serving_config=projects/*/loca" - + "tions/*/dataStores/*/servingConfigs/*}:searchLite:\001*Zg\"b/v1/{serving_config=proj" - + "ects/*/locations/*/collections/*/dataStores/*/servingConfigs/*}:searchLite:\001*Zd\"" - + "_/v1/{serving_config=projects/*/locations/*/collections/*/engines/*/servingConfi" - + "gs/*}:searchLite:\001*\032R\312A\036discoveryengine." - + "googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\205\002\n" - + "#com.google.cloud.discoveryengine.v1B\022SearchServicePr" - + "otoP\001ZMcloud.google.com/go/discoveryengine/apiv1/discoveryenginepb;discoveryengi" - + "nepb\242\002\017DISCOVERYENGINE\252\002\037Google.Cloud.Di" - + "scoveryEngine.V1\312\002\037Google\\Cloud\\Discover" - + "yEngine\\V1\352\002\"Google::Cloud::DiscoveryEngine::V1b\006proto3" + + "\006Search\022..google.cloud.discoveryengine.v1" + + ".SearchRequest\032/.google.cloud.discoverye" + + "ngine.v1.SearchResponse\"\243\002\202\323\344\223\002\234\002\"P/v1/{" + + "serving_config=projects/*/locations/*/dataStores/*/servingConfigs/*}:search:\001*Zc" + + "\"^/v1/{serving_config=projects/*/locations/*/collections/*/dataStores/*/servingC" + + "onfigs/*}:search:\001*Z`\"[/v1/{serving_config=projects/*/locations/*/collections/*/" + + "engines/*/servingConfigs/*}:search:\001*\022\237\003\n\n" + + "SearchLite\022..google.cloud.discoveryengine.v1.SearchRequest\032/.google.cloud.disc" + + "overyengine.v1.SearchResponse\"\257\002\202\323\344\223\002\250\002\"" + + "T/v1/{serving_config=projects/*/locations/*/dataStores/*/servingConfigs/*}:searc" + + "hLite:\001*Zg\"b/v1/{serving_config=projects/*/locations/*/collections/*/dataStores/" + + "*/servingConfigs/*}:searchLite:\001*Zd\"_/v1/{serving_config=projects/*/locations/*/" + + "collections/*/engines/*/servingConfigs/*" + + "}:searchLite:\001*\032R\312A\036discoveryengine.goog" + + "leapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\205\002\n" + + "#com.google.cloud.discoveryengine.v1B\022SearchServiceProtoP" + + "\001ZMcloud.google.com/go/discoveryengine/apiv1/discoveryenginepb;discoveryenginepb" + + "\242\002\017DISCOVERYENGINE\252\002\037Google.Cloud.Discov" + + "eryEngine.V1\312\002\037Google\\Cloud\\DiscoveryEng" + + "ine\\V1\352\002\"Google::Cloud::DiscoveryEngine::V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -560,6 +597,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "SessionSpec", "RelevanceThreshold", "RelevanceScoreSpec", + "RankingExpression", + "RankingExpressionBackend", }); internal_static_google_cloud_discoveryengine_v1_SearchRequest_ImageQuery_descriptor = internal_static_google_cloud_discoveryengine_v1_SearchRequest_descriptor @@ -840,7 +879,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_descriptor, new java.lang.String[] { - "Id", "Document", "Chunk", "ModelScores", + "Id", "Document", "Chunk", "ModelScores", "RankSignals", }); internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_ModelScoresEntry_descriptor = internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_descriptor @@ -852,6 +891,34 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor = + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor, + new java.lang.String[] { + "KeywordSimilarityScore", + "RelevanceScore", + "SemanticSimilarityScore", + "PctrRank", + "TopicalityRank", + "DocumentAge", + "BoostingFactor", + "DefaultRank", + "CustomSignals", + }); + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor = + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_discoveryengine_v1_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor, + new java.lang.String[] { + "Name", "Value", + }); internal_static_google_cloud_discoveryengine_v1_SearchResponse_Facet_descriptor = internal_static_google_cloud_discoveryengine_v1_SearchResponse_descriptor .getNestedTypes() diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/search_service.proto b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/search_service.proto index 061eb2fa6830..627cf940713b 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/search_service.proto +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1/src/main/proto/google/cloud/discoveryengine/v1/search_service.proto @@ -1069,6 +1069,115 @@ message SearchRequest { // Optional. The specification for returning the relevance score. RelevanceScoreSpec relevance_score_spec = 52 [(google.api.field_behavior) = OPTIONAL]; + + // The ranking expression controls the customized ranking on retrieval + // documents. This overrides + // [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1.ServingConfig.ranking_expression]. + // The syntax and supported features depend on the + // `ranking_expression_backend` value. If `ranking_expression_backend` is not + // provided, it defaults to `RANK_BY_EMBEDDING`. + // + // If + // [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend] + // is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + // function or multiple functions that are joined by "+". + // + // * ranking_expression = function, { " + ", function }; + // + // Supported functions: + // + // * double * relevance_score + // * double * dotProduct(embedding_field_path) + // + // Function variables: + // + // * `relevance_score`: pre-defined keywords, used for measure relevance + // between query and document. + // * `embedding_field_path`: the document embedding field + // used with query embedding vector. + // * `dotProduct`: embedding function between `embedding_field_path` and + // query embedding vector. + // + // Example ranking expression: + // + // If document has an embedding field doc_embedding, the ranking expression + // could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + // + // If + // [ranking_expression_backend][google.cloud.discoveryengine.v1.SearchRequest.ranking_expression_backend] + // is set to `RANK_BY_FORMULA`, the following expression types (and + // combinations of those chained using + or + // * operators) are supported: + // + // * `double` + // * `signal` + // * `log(signal)` + // * `exp(signal)` + // * `rr(signal, double > 0)` -- reciprocal rank transformation with second + // argument being a denominator constant. + // * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + // * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + // signal2 | double, else returns signal1. + // + // Here are a few examples of ranking formulas that use the supported + // ranking expression types: + // + // - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + // -- mostly rank by the logarithm of `keyword_similarity_score` with slight + // `semantic_smilarity_score` adjustment. + // - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + // is_nan(keyword_similarity_score)` -- rank by the exponent of + // `semantic_similarity_score` filling the value with 0 if it's NaN, also + // add constant 0.3 adjustment to the final score if + // `semantic_similarity_score` is NaN. + // - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + // rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + // of `keyword_similarity_score` with slight adjustment of reciprocal rank + // of `semantic_smilarity_score`. + // + // The following signals are supported: + // + // * `semantic_similarity_score`: semantic similarity adjustment that is + // calculated using the embeddings generated by a proprietary Google model. + // This score determines how semantically similar a search query is to a + // document. + // * `keyword_similarity_score`: keyword match adjustment uses the Best + // Match 25 (BM25) ranking function. This score is calculated using a + // probabilistic model to estimate the probability that a document is + // relevant to a given query. + // * `relevance_score`: semantic relevance adjustment that uses a + // proprietary Google model to determine the meaning and intent behind a + // user's query in context with the content in the documents. + // * `pctr_rank`: predicted conversion rate adjustment as a rank use + // predicted Click-through rate (pCTR) to gauge the relevance and + // attractiveness of a search result from a user's perspective. A higher + // pCTR suggests that the result is more likely to satisfy the user's query + // and intent, making it a valuable signal for ranking. + // * `freshness_rank`: freshness adjustment as a rank + // * `document_age`: The time in hours elapsed since the document was last + // updated, a floating-point number (e.g., 0.25 means 15 minutes). + // * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + // Google model to determine the keyword-based overlap between the query and + // the document. + // * `base_rank`: the default rank of the result + string ranking_expression = 26; + + // The backend to use for the ranking expression evaluation. + enum RankingExpressionBackend { + reserved 1, 2; + + // Default option for unspecified/unknown values. + RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + // Ranking by custom embedding model, the default way to evaluate the + // ranking expression. + RANK_BY_EMBEDDING = 3; + // Ranking by custom formula. + RANK_BY_FORMULA = 4; + } + + // The backend to use for the ranking expression evaluation. + RankingExpressionBackend ranking_expression_backend = 53 + [(google.api.field_behavior) = OPTIONAL]; } // Response message for @@ -1094,6 +1203,49 @@ message SearchResponse { // Output only. Google provided available scores. map model_scores = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; + + // A set of ranking signals. + message RankSignals { + reserved 5; + + // Keyword matching adjustment. + optional float keyword_similarity_score = 1 + [(google.api.field_behavior) = OPTIONAL]; + // Semantic relevance adjustment. + optional float relevance_score = 2 + [(google.api.field_behavior) = OPTIONAL]; + // Semantic similarity adjustment. + optional float semantic_similarity_score = 3 + [(google.api.field_behavior) = OPTIONAL]; + // Predicted conversion rate adjustment as a rank. + optional float pctr_rank = 4 [(google.api.field_behavior) = OPTIONAL]; + // Topicality adjustment as a rank. + optional float topicality_rank = 6 + [(google.api.field_behavior) = OPTIONAL]; + // Age of the document in hours. + optional float document_age = 7 [(google.api.field_behavior) = OPTIONAL]; + // Combined custom boosts for a doc. + optional float boosting_factor = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // The default rank of the result. + float default_rank = 32 [(google.api.field_behavior) = OPTIONAL]; + + // Custom clearbox signal represented by name and value pair. + message CustomSignal { + // Name of the signal. + string name = 1 [(google.api.field_behavior) = OPTIONAL]; + // Float value representing the ranking signal (e.g. 1.25 for BM25). + float value = 2 [(google.api.field_behavior) = OPTIONAL]; + } + + // A list of custom clearbox signals. + repeated CustomSignal custom_signals = 33 + [(google.api.field_behavior) = OPTIONAL]; + } + + // A set of ranking signals associated with the result. + RankSignals rank_signals = 7 [(google.api.field_behavior) = OPTIONAL]; } // A facet result. diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequest.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequest.java index 9c548c2d9400..676c9621328f 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequest.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequest.java @@ -55,6 +55,7 @@ private SearchRequest() { facetSpecs_ = java.util.Collections.emptyList(); userPseudoId_ = ""; rankingExpression_ = ""; + rankingExpressionBackend_ = 0; session_ = ""; relevanceThreshold_ = 0; } @@ -308,6 +309,173 @@ private RelevanceThreshold(int value) { // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1alpha.SearchRequest.RelevanceThreshold) } + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * Protobuf enum {@code + * google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend} + */ + public enum RankingExpressionBackend implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
        +     * Default option for unspecified/unknown values.
        +     * 
        + * + * RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + */ + RANKING_EXPRESSION_BACKEND_UNSPECIFIED(0), + /** + * + * + *
        +     * Ranking by custom embedding model, the default way to evaluate the
        +     * ranking expression.
        +     * 
        + * + * RANK_BY_EMBEDDING = 3; + */ + RANK_BY_EMBEDDING(3), + /** + * + * + *
        +     * Ranking by custom formula.
        +     * 
        + * + * RANK_BY_FORMULA = 4; + */ + RANK_BY_FORMULA(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
        +     * Default option for unspecified/unknown values.
        +     * 
        + * + * RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + */ + public static final int RANKING_EXPRESSION_BACKEND_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
        +     * Ranking by custom embedding model, the default way to evaluate the
        +     * ranking expression.
        +     * 
        + * + * RANK_BY_EMBEDDING = 3; + */ + public static final int RANK_BY_EMBEDDING_VALUE = 3; + + /** + * + * + *
        +     * Ranking by custom formula.
        +     * 
        + * + * RANK_BY_FORMULA = 4; + */ + public static final int RANK_BY_FORMULA_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 RankingExpressionBackend 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 RankingExpressionBackend forNumber(int value) { + switch (value) { + case 0: + return RANKING_EXPRESSION_BACKEND_UNSPECIFIED; + case 3: + return RANK_BY_EMBEDDING; + case 4: + return RANK_BY_FORMULA; + 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 RankingExpressionBackend findValueByNumber(int number) { + return RankingExpressionBackend.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1alpha.SearchRequest.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final RankingExpressionBackend[] VALUES = values(); + + public static RankingExpressionBackend 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 RankingExpressionBackend(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend) + } + public interface ImageQueryOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1alpha.SearchRequest.ImageQuery) @@ -31127,8 +31295,14 @@ public com.google.cloud.discoveryengine.v1alpha.SearchRequest.EmbeddingSpec getE * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -31143,13 +31317,71 @@ public com.google.cloud.discoveryengine.v1alpha.SearchRequest.EmbeddingSpec getE * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -31176,8 +31408,14 @@ public java.lang.String getRankingExpression() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -31192,13 +31430,71 @@ public java.lang.String getRankingExpression() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -31218,6 +31514,52 @@ public com.google.protobuf.ByteString getRankingExpressionBytes() { } } + public static final int RANKING_EXPRESSION_BACKEND_FIELD_NUMBER = 53; + private int rankingExpressionBackend_ = 0; + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + @java.lang.Override + public int getRankingExpressionBackendValue() { + return rankingExpressionBackend_; + } + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend() { + com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend result = + com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend.forNumber( + rankingExpressionBackend_); + return result == null + ? com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + .UNRECOGNIZED + : result; + } + public static final int SAFE_SEARCH_FIELD_NUMBER = 20; private boolean safeSearch_ = false; @@ -31924,6 +32266,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(44, relevanceThreshold_); } + if (rankingExpressionBackend_ + != com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + .RANKING_EXPRESSION_BACKEND_UNSPECIFIED + .getNumber()) { + output.writeEnum(53, rankingExpressionBackend_); + } getUnknownFields().writeTo(output); } @@ -32048,6 +32396,12 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(44, relevanceThreshold_); } + if (rankingExpressionBackend_ + != com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + .RANKING_EXPRESSION_BACKEND_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(53, rankingExpressionBackend_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -32108,6 +32462,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEmbeddingSpec().equals(other.getEmbeddingSpec())) return false; } if (!getRankingExpression().equals(other.getRankingExpression())) return false; + if (rankingExpressionBackend_ != other.rankingExpressionBackend_) return false; if (getSafeSearch() != other.getSafeSearch()) return false; if (!internalGetUserLabels().equals(other.internalGetUserLabels())) return false; if (hasNaturalLanguageQueryUnderstandingSpec() @@ -32207,6 +32562,8 @@ public int hashCode() { } hash = (37 * hash) + RANKING_EXPRESSION_FIELD_NUMBER; hash = (53 * hash) + getRankingExpression().hashCode(); + hash = (37 * hash) + RANKING_EXPRESSION_BACKEND_FIELD_NUMBER; + hash = (53 * hash) + rankingExpressionBackend_; hash = (37 * hash) + SAFE_SEARCH_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSafeSearch()); if (!internalGetUserLabels().getMap().isEmpty()) { @@ -32486,6 +32843,7 @@ public Builder clear() { embeddingSpecBuilder_ = null; } rankingExpression_ = ""; + rankingExpressionBackend_ = 0; safeSearch_ = false; internalGetMutableUserLabels().clear(); naturalLanguageQueryUnderstandingSpec_ = null; @@ -32651,42 +33009,45 @@ private void buildPartial0(com.google.cloud.discoveryengine.v1alpha.SearchReques result.rankingExpression_ = rankingExpression_; } if (((from_bitField0_ & 0x00800000) != 0)) { - result.safeSearch_ = safeSearch_; + result.rankingExpressionBackend_ = rankingExpressionBackend_; } if (((from_bitField0_ & 0x01000000) != 0)) { + result.safeSearch_ = safeSearch_; + } + if (((from_bitField0_ & 0x02000000) != 0)) { result.userLabels_ = internalGetUserLabels(); result.userLabels_.makeImmutable(); } - if (((from_bitField0_ & 0x02000000) != 0)) { + if (((from_bitField0_ & 0x04000000) != 0)) { result.naturalLanguageQueryUnderstandingSpec_ = naturalLanguageQueryUnderstandingSpecBuilder_ == null ? naturalLanguageQueryUnderstandingSpec_ : naturalLanguageQueryUnderstandingSpecBuilder_.build(); to_bitField0_ |= 0x00000080; } - if (((from_bitField0_ & 0x04000000) != 0)) { + if (((from_bitField0_ & 0x08000000) != 0)) { result.searchAsYouTypeSpec_ = searchAsYouTypeSpecBuilder_ == null ? searchAsYouTypeSpec_ : searchAsYouTypeSpecBuilder_.build(); to_bitField0_ |= 0x00000100; } - if (((from_bitField0_ & 0x08000000) != 0)) { + if (((from_bitField0_ & 0x10000000) != 0)) { result.customFineTuningSpec_ = customFineTuningSpecBuilder_ == null ? customFineTuningSpec_ : customFineTuningSpecBuilder_.build(); to_bitField0_ |= 0x00000200; } - if (((from_bitField0_ & 0x10000000) != 0)) { + if (((from_bitField0_ & 0x20000000) != 0)) { result.session_ = session_; } - if (((from_bitField0_ & 0x20000000) != 0)) { + if (((from_bitField0_ & 0x40000000) != 0)) { result.sessionSpec_ = sessionSpecBuilder_ == null ? sessionSpec_ : sessionSpecBuilder_.build(); to_bitField0_ |= 0x00000400; } - if (((from_bitField0_ & 0x40000000) != 0)) { + if (((from_bitField0_ & 0x80000000) != 0)) { result.relevanceThreshold_ = relevanceThreshold_; } result.bitField0_ |= to_bitField0_; @@ -32876,11 +33237,14 @@ public Builder mergeFrom(com.google.cloud.discoveryengine.v1alpha.SearchRequest bitField0_ |= 0x00400000; onChanged(); } + if (other.rankingExpressionBackend_ != 0) { + setRankingExpressionBackendValue(other.getRankingExpressionBackendValue()); + } if (other.getSafeSearch() != false) { setSafeSearch(other.getSafeSearch()); } internalGetMutableUserLabels().mergeFrom(other.internalGetUserLabels()); - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; if (other.hasNaturalLanguageQueryUnderstandingSpec()) { mergeNaturalLanguageQueryUnderstandingSpec( other.getNaturalLanguageQueryUnderstandingSpec()); @@ -32893,7 +33257,7 @@ public Builder mergeFrom(com.google.cloud.discoveryengine.v1alpha.SearchRequest } if (!other.getSession().isEmpty()) { session_ = other.session_; - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); } if (other.hasSessionSpec()) { @@ -33037,7 +33401,7 @@ public Builder mergeFrom( case 160: { safeSearch_ = input.readBool(); - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; break; } // case 160 case 170: @@ -33055,7 +33419,7 @@ public Builder mergeFrom( internalGetMutableUserLabels() .getMutableMap() .put(userLabels__.getKey(), userLabels__.getValue()); - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; break; } // case 178 case 186: @@ -33082,7 +33446,7 @@ public Builder mergeFrom( input.readMessage( getNaturalLanguageQueryUnderstandingSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; break; } // case 226 case 234: @@ -33095,7 +33459,7 @@ public Builder mergeFrom( { input.readMessage( getSearchAsYouTypeSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; break; } // case 250 case 258: @@ -33117,7 +33481,7 @@ public Builder mergeFrom( { input.readMessage( getCustomFineTuningSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; break; } // case 274 case 282: @@ -33135,21 +33499,27 @@ public Builder mergeFrom( case 330: { session_ = input.readStringRequireUtf8(); - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; break; } // case 330 case 338: { input.readMessage(getSessionSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; break; } // case 338 case 352: { relevanceThreshold_ = input.readEnum(); - bitField0_ |= 0x40000000; + bitField0_ |= 0x80000000; break; } // case 352 + case 424: + { + rankingExpressionBackend_ = input.readEnum(); + bitField0_ |= 0x00800000; + break; + } // case 424 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -37739,8 +38109,14 @@ public Builder clearEmbeddingSpec() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -37755,13 +38131,71 @@ public Builder clearEmbeddingSpec() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -37787,8 +38221,14 @@ public java.lang.String getRankingExpression() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -37803,13 +38243,71 @@ public java.lang.String getRankingExpression() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -37835,8 +38333,14 @@ public com.google.protobuf.ByteString getRankingExpressionBytes() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -37851,13 +38355,71 @@ public com.google.protobuf.ByteString getRankingExpressionBytes() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -37882,8 +38444,14 @@ public Builder setRankingExpression(java.lang.String value) { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -37898,13 +38466,71 @@ public Builder setRankingExpression(java.lang.String value) { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -37925,8 +38551,14 @@ public Builder clearRankingExpression() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -37941,13 +38573,71 @@ public Builder clearRankingExpression() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -37966,6 +38656,117 @@ public Builder setRankingExpressionBytes(com.google.protobuf.ByteString value) { return this; } + private int rankingExpressionBackend_ = 0; + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + @java.lang.Override + public int getRankingExpressionBackendValue() { + return rankingExpressionBackend_; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for rankingExpressionBackend to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBackendValue(int value) { + rankingExpressionBackend_ = value; + bitField0_ |= 0x00800000; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend() { + com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend result = + com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend.forNumber( + rankingExpressionBackend_); + return result == null + ? com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + .UNRECOGNIZED + : result; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The rankingExpressionBackend to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBackend( + com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00800000; + rankingExpressionBackend_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRankingExpressionBackend() { + bitField0_ = (bitField0_ & ~0x00800000); + rankingExpressionBackend_ = 0; + onChanged(); + return this; + } + private boolean safeSearch_; /** @@ -38001,7 +38802,7 @@ public boolean getSafeSearch() { public Builder setSafeSearch(boolean value) { safeSearch_ = value; - bitField0_ |= 0x00800000; + bitField0_ |= 0x01000000; onChanged(); return this; } @@ -38019,7 +38820,7 @@ public Builder setSafeSearch(boolean value) { * @return This builder for chaining. */ public Builder clearSafeSearch() { - bitField0_ = (bitField0_ & ~0x00800000); + bitField0_ = (bitField0_ & ~0x01000000); safeSearch_ = false; onChanged(); return this; @@ -38045,7 +38846,7 @@ public Builder clearSafeSearch() { if (!userLabels_.isMutable()) { userLabels_ = userLabels_.copy(); } - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; onChanged(); return userLabels_; } @@ -38199,7 +39000,7 @@ public java.lang.String getUserLabelsOrThrow(java.lang.String key) { } public Builder clearUserLabels() { - bitField0_ = (bitField0_ & ~0x01000000); + bitField0_ = (bitField0_ & ~0x02000000); internalGetMutableUserLabels().getMutableMap().clear(); return this; } @@ -38240,7 +39041,7 @@ public Builder removeUserLabels(java.lang.String key) { /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableUserLabels() { - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; return internalGetMutableUserLabels().getMutableMap(); } @@ -38277,7 +39078,7 @@ public Builder putUserLabels(java.lang.String key, java.lang.String value) { throw new NullPointerException("map value"); } internalGetMutableUserLabels().getMutableMap().put(key, value); - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; return this; } @@ -38308,7 +39109,7 @@ public Builder putUserLabels(java.lang.String key, java.lang.String value) { */ public Builder putAllUserLabels(java.util.Map values) { internalGetMutableUserLabels().getMutableMap().putAll(values); - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; return this; } @@ -38339,7 +39140,7 @@ public Builder putAllUserLabels(java.util.Map */ public Builder clearNaturalLanguageQueryUnderstandingSpec() { - bitField0_ = (bitField0_ & ~0x02000000); + bitField0_ = (bitField0_ & ~0x04000000); naturalLanguageQueryUnderstandingSpec_ = null; if (naturalLanguageQueryUnderstandingSpecBuilder_ != null) { naturalLanguageQueryUnderstandingSpecBuilder_.dispose(); @@ -38496,7 +39297,7 @@ public Builder clearNaturalLanguageQueryUnderstandingSpec() { public com.google.cloud.discoveryengine.v1alpha.SearchRequest .NaturalLanguageQueryUnderstandingSpec.Builder getNaturalLanguageQueryUnderstandingSpecBuilder() { - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; onChanged(); return getNaturalLanguageQueryUnderstandingSpecFieldBuilder().getBuilder(); } @@ -38585,7 +39386,7 @@ public Builder clearNaturalLanguageQueryUnderstandingSpec() { * @return Whether the searchAsYouTypeSpec field is set. */ public boolean hasSearchAsYouTypeSpec() { - return ((bitField0_ & 0x04000000) != 0); + return ((bitField0_ & 0x08000000) != 0); } /** @@ -38638,7 +39439,7 @@ public Builder setSearchAsYouTypeSpec( } else { searchAsYouTypeSpecBuilder_.setMessage(value); } - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return this; } @@ -38664,7 +39465,7 @@ public Builder setSearchAsYouTypeSpec( } else { searchAsYouTypeSpecBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return this; } @@ -38685,7 +39486,7 @@ public Builder setSearchAsYouTypeSpec( public Builder mergeSearchAsYouTypeSpec( com.google.cloud.discoveryengine.v1alpha.SearchRequest.SearchAsYouTypeSpec value) { if (searchAsYouTypeSpecBuilder_ == null) { - if (((bitField0_ & 0x04000000) != 0) + if (((bitField0_ & 0x08000000) != 0) && searchAsYouTypeSpec_ != null && searchAsYouTypeSpec_ != com.google.cloud.discoveryengine.v1alpha.SearchRequest.SearchAsYouTypeSpec @@ -38698,7 +39499,7 @@ public Builder mergeSearchAsYouTypeSpec( searchAsYouTypeSpecBuilder_.mergeFrom(value); } if (searchAsYouTypeSpec_ != null) { - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); } return this; @@ -38718,7 +39519,7 @@ public Builder mergeSearchAsYouTypeSpec( * */ public Builder clearSearchAsYouTypeSpec() { - bitField0_ = (bitField0_ & ~0x04000000); + bitField0_ = (bitField0_ & ~0x08000000); searchAsYouTypeSpec_ = null; if (searchAsYouTypeSpecBuilder_ != null) { searchAsYouTypeSpecBuilder_.dispose(); @@ -38743,7 +39544,7 @@ public Builder clearSearchAsYouTypeSpec() { */ public com.google.cloud.discoveryengine.v1alpha.SearchRequest.SearchAsYouTypeSpec.Builder getSearchAsYouTypeSpecBuilder() { - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return getSearchAsYouTypeSpecFieldBuilder().getBuilder(); } @@ -38827,7 +39628,7 @@ public Builder clearSearchAsYouTypeSpec() { * @return Whether the customFineTuningSpec field is set. */ public boolean hasCustomFineTuningSpec() { - return ((bitField0_ & 0x08000000) != 0); + return ((bitField0_ & 0x10000000) != 0); } /** @@ -38878,7 +39679,7 @@ public Builder setCustomFineTuningSpec( } else { customFineTuningSpecBuilder_.setMessage(value); } - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return this; } @@ -38903,7 +39704,7 @@ public Builder setCustomFineTuningSpec( } else { customFineTuningSpecBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return this; } @@ -38924,7 +39725,7 @@ public Builder setCustomFineTuningSpec( public Builder mergeCustomFineTuningSpec( com.google.cloud.discoveryengine.v1alpha.CustomFineTuningSpec value) { if (customFineTuningSpecBuilder_ == null) { - if (((bitField0_ & 0x08000000) != 0) + if (((bitField0_ & 0x10000000) != 0) && customFineTuningSpec_ != null && customFineTuningSpec_ != com.google.cloud.discoveryengine.v1alpha.CustomFineTuningSpec @@ -38937,7 +39738,7 @@ public Builder mergeCustomFineTuningSpec( customFineTuningSpecBuilder_.mergeFrom(value); } if (customFineTuningSpec_ != null) { - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); } return this; @@ -38957,7 +39758,7 @@ public Builder mergeCustomFineTuningSpec( * */ public Builder clearCustomFineTuningSpec() { - bitField0_ = (bitField0_ & ~0x08000000); + bitField0_ = (bitField0_ & ~0x10000000); customFineTuningSpec_ = null; if (customFineTuningSpecBuilder_ != null) { customFineTuningSpecBuilder_.dispose(); @@ -38982,7 +39783,7 @@ public Builder clearCustomFineTuningSpec() { */ public com.google.cloud.discoveryengine.v1alpha.CustomFineTuningSpec.Builder getCustomFineTuningSpecBuilder() { - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return getCustomFineTuningSpecFieldBuilder().getBuilder(); } @@ -39163,7 +39964,7 @@ public Builder setSession(java.lang.String value) { throw new NullPointerException(); } session_ = value; - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return this; } @@ -39200,7 +40001,7 @@ public Builder setSession(java.lang.String value) { */ public Builder clearSession() { session_ = getDefaultInstance().getSession(); - bitField0_ = (bitField0_ & ~0x10000000); + bitField0_ = (bitField0_ & ~0x20000000); onChanged(); return this; } @@ -39242,7 +40043,7 @@ public Builder setSessionBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); session_ = value; - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return this; } @@ -39269,7 +40070,7 @@ public Builder setSessionBytes(com.google.protobuf.ByteString value) { * @return Whether the sessionSpec field is set. */ public boolean hasSessionSpec() { - return ((bitField0_ & 0x20000000) != 0); + return ((bitField0_ & 0x40000000) != 0); } /** @@ -39319,7 +40120,7 @@ public Builder setSessionSpec( } else { sessionSpecBuilder_.setMessage(value); } - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return this; } @@ -39344,7 +40145,7 @@ public Builder setSessionSpec( } else { sessionSpecBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return this; } @@ -39364,7 +40165,7 @@ public Builder setSessionSpec( public Builder mergeSessionSpec( com.google.cloud.discoveryengine.v1alpha.SearchRequest.SessionSpec value) { if (sessionSpecBuilder_ == null) { - if (((bitField0_ & 0x20000000) != 0) + if (((bitField0_ & 0x40000000) != 0) && sessionSpec_ != null && sessionSpec_ != com.google.cloud.discoveryengine.v1alpha.SearchRequest.SessionSpec @@ -39377,7 +40178,7 @@ public Builder mergeSessionSpec( sessionSpecBuilder_.mergeFrom(value); } if (sessionSpec_ != null) { - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); } return this; @@ -39396,7 +40197,7 @@ public Builder mergeSessionSpec( * */ public Builder clearSessionSpec() { - bitField0_ = (bitField0_ & ~0x20000000); + bitField0_ = (bitField0_ & ~0x40000000); sessionSpec_ = null; if (sessionSpecBuilder_ != null) { sessionSpecBuilder_.dispose(); @@ -39420,7 +40221,7 @@ public Builder clearSessionSpec() { */ public com.google.cloud.discoveryengine.v1alpha.SearchRequest.SessionSpec.Builder getSessionSpecBuilder() { - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return getSessionSpecFieldBuilder().getBuilder(); } @@ -39522,7 +40323,7 @@ public int getRelevanceThresholdValue() { */ public Builder setRelevanceThresholdValue(int value) { relevanceThreshold_ = value; - bitField0_ |= 0x40000000; + bitField0_ |= 0x80000000; onChanged(); return this; } @@ -39578,7 +40379,7 @@ public Builder setRelevanceThreshold( if (value == null) { throw new NullPointerException(); } - bitField0_ |= 0x40000000; + bitField0_ |= 0x80000000; relevanceThreshold_ = value.getNumber(); onChanged(); return this; @@ -39602,7 +40403,7 @@ public Builder setRelevanceThreshold( * @return This builder for chaining. */ public Builder clearRelevanceThreshold() { - bitField0_ = (bitField0_ & ~0x40000000); + bitField0_ = (bitField0_ & ~0x80000000); relevanceThreshold_ = 0; onChanged(); return this; diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequestOrBuilder.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequestOrBuilder.java index a4482d5b8a9a..418520952699 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequestOrBuilder.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchRequestOrBuilder.java @@ -1111,8 +1111,14 @@ com.google.protobuf.Value getParamsOrDefault( * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -1127,13 +1133,71 @@ com.google.protobuf.Value getParamsOrDefault( * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -1149,8 +1213,14 @@ com.google.protobuf.Value getParamsOrDefault( * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -1165,13 +1235,71 @@ com.google.protobuf.Value getParamsOrDefault( * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -1180,6 +1308,37 @@ com.google.protobuf.Value getParamsOrDefault( */ com.google.protobuf.ByteString getRankingExpressionBytes(); + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + int getRankingExpressionBackendValue(); + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + com.google.cloud.discoveryengine.v1alpha.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend(); + /** * * diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchResponse.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchResponse.java index 150c69afd4a7..85772a186e53 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchResponse.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchResponse.java @@ -262,6 +262,51 @@ com.google.cloud.discoveryengine.v1alpha.DoubleList getModelScoresOrDefault( * */ com.google.cloud.discoveryengine.v1alpha.DoubleList getModelScoresOrThrow(java.lang.String key); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + boolean hasRankSignals(); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + getRankSignals(); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder(); } /** @@ -284,41 +329,3368 @@ private SearchResult(com.google.protobuf.GeneratedMessageV3.Builder builder) super(builder); } - private SearchResult() { - id_ = ""; - } + private SearchResult() { + id_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SearchResult(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetModelScores(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.class, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.Builder.class); + } + + public interface RankSignalsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + boolean hasKeywordSimilarityScore(); + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + float getKeywordSimilarityScore(); + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the relevanceScore field is set. + */ + boolean hasRelevanceScore(); + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The relevanceScore. + */ + float getRelevanceScore(); + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + boolean hasSemanticSimilarityScore(); + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + float getSemanticSimilarityScore(); + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + boolean hasPctrRank(); + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + float getPctrRank(); + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the topicalityRank field is set. + */ + boolean hasTopicalityRank(); + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topicalityRank. + */ + float getTopicalityRank(); + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + boolean hasDocumentAge(); + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + float getDocumentAge(); + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the boostingFactor field is set. + */ + boolean hasBoostingFactor(); + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The boostingFactor. + */ + float getBoostingFactor(); + + /** + * + * + *
        +       * The default rank of the result.
        +       * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + float getDefaultRank(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal + getCustomSignals(int index); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getCustomSignalsCount(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + ? extends + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index); + } + + /** + * + * + *
        +     * A set of ranking signals.
        +     * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals} + */ + public static final class RankSignals extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) + RankSignalsOrBuilder { + private static final long serialVersionUID = 0L; + + // Use RankSignals.newBuilder() to construct. + private RankSignals(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RankSignals() { + customSignals_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RankSignals(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .class, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .Builder.class); + } + + public interface CustomSignalOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +         * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +         * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + float getValue(); + } + + /** + * + * + *
        +       * Custom clearbox signal represented by name and value pair.
        +       * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal} + */ + public static final class CustomSignal extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal) + CustomSignalOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CustomSignal.newBuilder() to construct. + private CustomSignal(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CustomSignal() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CustomSignal(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.class, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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 VALUE_FIELD_NUMBER = 2; + private float value_ = 0F; + + /** + * + * + *
        +         * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +         * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + @java.lang.Override + public float getValue() { + return value_; + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (java.lang.Float.floatToRawIntBits(value_) != 0) { + output.writeFloat(2, value_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (java.lang.Float.floatToRawIntBits(value_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, 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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal)) { + return super.equals(obj); + } + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + other = + (com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal) + obj; + + if (!getName().equals(other.getName())) return false; + if (java.lang.Float.floatToIntBits(getValue()) + != java.lang.Float.floatToIntBits(other.getValue())) 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) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getValue()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + 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.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + 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.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +         * Custom clearbox signal represented by name and value pair.
        +         * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal) + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.class, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder.class); + } + + // Construct using + // com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + value_ = 0F; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstanceForType() { + return com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + build() { + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + buildPartial() { + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + result = + new com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.value_ = value_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal) { + return mergeFrom( + (com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + other) { + if (other + == com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getValue() != 0F) { + setValue(other.getValue()); + } + 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 21: + { + value_ = input.readFloat(); + bitField0_ |= 0x00000002; + break; + } // case 21 + 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_ = ""; + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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 float value_; + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + @java.lang.Override + public float getValue() { + return value_; + } + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(float value) { + + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + bitField0_ = (bitField0_ & ~0x00000002); + value_ = 0F; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal) + } + + // @@protoc_insertion_point(class_scope:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal) + private static final com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal(); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CustomSignal 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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int KEYWORD_SIMILARITY_SCORE_FIELD_NUMBER = 1; + private float keywordSimilarityScore_ = 0F; + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasKeywordSimilarityScore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + @java.lang.Override + public float getKeywordSimilarityScore() { + return keywordSimilarityScore_; + } + + public static final int RELEVANCE_SCORE_FIELD_NUMBER = 2; + private float relevanceScore_ = 0F; + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the relevanceScore field is set. + */ + @java.lang.Override + public boolean hasRelevanceScore() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The relevanceScore. + */ + @java.lang.Override + public float getRelevanceScore() { + return relevanceScore_; + } + + public static final int SEMANTIC_SIMILARITY_SCORE_FIELD_NUMBER = 3; + private float semanticSimilarityScore_ = 0F; + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasSemanticSimilarityScore() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + @java.lang.Override + public float getSemanticSimilarityScore() { + return semanticSimilarityScore_; + } + + public static final int PCTR_RANK_FIELD_NUMBER = 4; + private float pctrRank_ = 0F; + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + @java.lang.Override + public boolean hasPctrRank() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + @java.lang.Override + public float getPctrRank() { + return pctrRank_; + } + + public static final int TOPICALITY_RANK_FIELD_NUMBER = 6; + private float topicalityRank_ = 0F; + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the topicalityRank field is set. + */ + @java.lang.Override + public boolean hasTopicalityRank() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topicalityRank. + */ + @java.lang.Override + public float getTopicalityRank() { + return topicalityRank_; + } + + public static final int DOCUMENT_AGE_FIELD_NUMBER = 7; + private float documentAge_ = 0F; + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + @java.lang.Override + public boolean hasDocumentAge() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + @java.lang.Override + public float getDocumentAge() { + return documentAge_; + } + + public static final int BOOSTING_FACTOR_FIELD_NUMBER = 8; + private float boostingFactor_ = 0F; + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the boostingFactor field is set. + */ + @java.lang.Override + public boolean hasBoostingFactor() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The boostingFactor. + */ + @java.lang.Override + public float getBoostingFactor() { + return boostingFactor_; + } + + public static final int DEFAULT_RANK_FIELD_NUMBER = 32; + private float defaultRank_ = 0F; + + /** + * + * + *
        +       * The default rank of the result.
        +       * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + @java.lang.Override + public float getDefaultRank() { + return defaultRank_; + } + + public static final int CUSTOM_SIGNALS_FIELD_NUMBER = 33; + + @SuppressWarnings("serial") + private java.util.List< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal> + customSignals_; + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList() { + return customSignals_; + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList() { + return customSignals_; + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getCustomSignalsCount() { + return customSignals_.size(); + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + getCustomSignals(int index) { + return customSignals_.get(index); + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index) { + return customSignals_.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 { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeFloat(1, keywordSimilarityScore_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeFloat(2, relevanceScore_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeFloat(3, semanticSimilarityScore_); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeFloat(4, pctrRank_); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeFloat(6, topicalityRank_); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeFloat(7, documentAge_); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeFloat(8, boostingFactor_); + } + if (java.lang.Float.floatToRawIntBits(defaultRank_) != 0) { + output.writeFloat(32, defaultRank_); + } + for (int i = 0; i < customSignals_.size(); i++) { + output.writeMessage(33, customSignals_.get(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.computeFloatSize(1, keywordSimilarityScore_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, relevanceScore_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeFloatSize(3, semanticSimilarityScore_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(4, pctrRank_); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(6, topicalityRank_); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(7, documentAge_); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(8, boostingFactor_); + } + if (java.lang.Float.floatToRawIntBits(defaultRank_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(32, defaultRank_); + } + for (int i = 0; i < customSignals_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(33, customSignals_.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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals)) { + return super.equals(obj); + } + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals other = + (com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) obj; + + if (hasKeywordSimilarityScore() != other.hasKeywordSimilarityScore()) return false; + if (hasKeywordSimilarityScore()) { + if (java.lang.Float.floatToIntBits(getKeywordSimilarityScore()) + != java.lang.Float.floatToIntBits(other.getKeywordSimilarityScore())) return false; + } + if (hasRelevanceScore() != other.hasRelevanceScore()) return false; + if (hasRelevanceScore()) { + if (java.lang.Float.floatToIntBits(getRelevanceScore()) + != java.lang.Float.floatToIntBits(other.getRelevanceScore())) return false; + } + if (hasSemanticSimilarityScore() != other.hasSemanticSimilarityScore()) return false; + if (hasSemanticSimilarityScore()) { + if (java.lang.Float.floatToIntBits(getSemanticSimilarityScore()) + != java.lang.Float.floatToIntBits(other.getSemanticSimilarityScore())) return false; + } + if (hasPctrRank() != other.hasPctrRank()) return false; + if (hasPctrRank()) { + if (java.lang.Float.floatToIntBits(getPctrRank()) + != java.lang.Float.floatToIntBits(other.getPctrRank())) return false; + } + if (hasTopicalityRank() != other.hasTopicalityRank()) return false; + if (hasTopicalityRank()) { + if (java.lang.Float.floatToIntBits(getTopicalityRank()) + != java.lang.Float.floatToIntBits(other.getTopicalityRank())) return false; + } + if (hasDocumentAge() != other.hasDocumentAge()) return false; + if (hasDocumentAge()) { + if (java.lang.Float.floatToIntBits(getDocumentAge()) + != java.lang.Float.floatToIntBits(other.getDocumentAge())) return false; + } + if (hasBoostingFactor() != other.hasBoostingFactor()) return false; + if (hasBoostingFactor()) { + if (java.lang.Float.floatToIntBits(getBoostingFactor()) + != java.lang.Float.floatToIntBits(other.getBoostingFactor())) return false; + } + if (java.lang.Float.floatToIntBits(getDefaultRank()) + != java.lang.Float.floatToIntBits(other.getDefaultRank())) return false; + if (!getCustomSignalsList().equals(other.getCustomSignalsList())) 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 (hasKeywordSimilarityScore()) { + hash = (37 * hash) + KEYWORD_SIMILARITY_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getKeywordSimilarityScore()); + } + if (hasRelevanceScore()) { + hash = (37 * hash) + RELEVANCE_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getRelevanceScore()); + } + if (hasSemanticSimilarityScore()) { + hash = (37 * hash) + SEMANTIC_SIMILARITY_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getSemanticSimilarityScore()); + } + if (hasPctrRank()) { + hash = (37 * hash) + PCTR_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getPctrRank()); + } + if (hasTopicalityRank()) { + hash = (37 * hash) + TOPICALITY_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getTopicalityRank()); + } + if (hasDocumentAge()) { + hash = (37 * hash) + DOCUMENT_AGE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getDocumentAge()); + } + if (hasBoostingFactor()) { + hash = (37 * hash) + BOOSTING_FACTOR_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getBoostingFactor()); + } + hash = (37 * hash) + DEFAULT_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getDefaultRank()); + if (getCustomSignalsCount() > 0) { + hash = (37 * hash) + CUSTOM_SIGNALS_FIELD_NUMBER; + hash = (53 * hash) + getCustomSignalsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + 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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + 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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +       * A set of ranking signals.
        +       * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignalsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .class, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .Builder.class); + } + + // Construct using + // com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + keywordSimilarityScore_ = 0F; + relevanceScore_ = 0F; + semanticSimilarityScore_ = 0F; + pctrRank_ = 0F; + topicalityRank_ = 0F; + documentAge_ = 0F; + boostingFactor_ = 0F; + defaultRank_ = 0F; + if (customSignalsBuilder_ == null) { + customSignals_ = java.util.Collections.emptyList(); + } else { + customSignals_ = null; + customSignalsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000100); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + getDefaultInstanceForType() { + return com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + build() { + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + buildPartial() { + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals result = + new com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals( + this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + result) { + if (customSignalsBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0)) { + customSignals_ = java.util.Collections.unmodifiableList(customSignals_); + bitField0_ = (bitField0_ & ~0x00000100); + } + result.customSignals_ = customSignals_; + } else { + result.customSignals_ = customSignalsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.keywordSimilarityScore_ = keywordSimilarityScore_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.relevanceScore_ = relevanceScore_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.semanticSimilarityScore_ = semanticSimilarityScore_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pctrRank_ = pctrRank_; + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.topicalityRank_ = topicalityRank_; + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.documentAge_ = documentAge_; + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.boostingFactor_ = boostingFactor_; + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.defaultRank_ = defaultRank_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) { + return mergeFrom( + (com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + other) { + if (other + == com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .getDefaultInstance()) return this; + if (other.hasKeywordSimilarityScore()) { + setKeywordSimilarityScore(other.getKeywordSimilarityScore()); + } + if (other.hasRelevanceScore()) { + setRelevanceScore(other.getRelevanceScore()); + } + if (other.hasSemanticSimilarityScore()) { + setSemanticSimilarityScore(other.getSemanticSimilarityScore()); + } + if (other.hasPctrRank()) { + setPctrRank(other.getPctrRank()); + } + if (other.hasTopicalityRank()) { + setTopicalityRank(other.getTopicalityRank()); + } + if (other.hasDocumentAge()) { + setDocumentAge(other.getDocumentAge()); + } + if (other.hasBoostingFactor()) { + setBoostingFactor(other.getBoostingFactor()); + } + if (other.getDefaultRank() != 0F) { + setDefaultRank(other.getDefaultRank()); + } + if (customSignalsBuilder_ == null) { + if (!other.customSignals_.isEmpty()) { + if (customSignals_.isEmpty()) { + customSignals_ = other.customSignals_; + bitField0_ = (bitField0_ & ~0x00000100); + } else { + ensureCustomSignalsIsMutable(); + customSignals_.addAll(other.customSignals_); + } + onChanged(); + } + } else { + if (!other.customSignals_.isEmpty()) { + if (customSignalsBuilder_.isEmpty()) { + customSignalsBuilder_.dispose(); + customSignalsBuilder_ = null; + customSignals_ = other.customSignals_; + bitField0_ = (bitField0_ & ~0x00000100); + customSignalsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getCustomSignalsFieldBuilder() + : null; + } else { + customSignalsBuilder_.addAllMessages(other.customSignals_); + } + } + } + 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 13: + { + keywordSimilarityScore_ = input.readFloat(); + bitField0_ |= 0x00000001; + break; + } // case 13 + case 21: + { + relevanceScore_ = input.readFloat(); + bitField0_ |= 0x00000002; + break; + } // case 21 + case 29: + { + semanticSimilarityScore_ = input.readFloat(); + bitField0_ |= 0x00000004; + break; + } // case 29 + case 37: + { + pctrRank_ = input.readFloat(); + bitField0_ |= 0x00000008; + break; + } // case 37 + case 53: + { + topicalityRank_ = input.readFloat(); + bitField0_ |= 0x00000010; + break; + } // case 53 + case 61: + { + documentAge_ = input.readFloat(); + bitField0_ |= 0x00000020; + break; + } // case 61 + case 69: + { + boostingFactor_ = input.readFloat(); + bitField0_ |= 0x00000040; + break; + } // case 69 + case 261: + { + defaultRank_ = input.readFloat(); + bitField0_ |= 0x00000080; + break; + } // case 261 + case 266: + { + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + m = + input.readMessage( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal.parser(), + extensionRegistry); + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(m); + } else { + customSignalsBuilder_.addMessage(m); + } + break; + } // case 266 + 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 float keywordSimilarityScore_; + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasKeywordSimilarityScore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + @java.lang.Override + public float getKeywordSimilarityScore() { + return keywordSimilarityScore_; + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The keywordSimilarityScore to set. + * @return This builder for chaining. + */ + public Builder setKeywordSimilarityScore(float value) { + + keywordSimilarityScore_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearKeywordSimilarityScore() { + bitField0_ = (bitField0_ & ~0x00000001); + keywordSimilarityScore_ = 0F; + onChanged(); + return this; + } + + private float relevanceScore_; + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the relevanceScore field is set. + */ + @java.lang.Override + public boolean hasRelevanceScore() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The relevanceScore. + */ + @java.lang.Override + public float getRelevanceScore() { + return relevanceScore_; + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The relevanceScore to set. + * @return This builder for chaining. + */ + public Builder setRelevanceScore(float value) { + + relevanceScore_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRelevanceScore() { + bitField0_ = (bitField0_ & ~0x00000002); + relevanceScore_ = 0F; + onChanged(); + return this; + } + + private float semanticSimilarityScore_; + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasSemanticSimilarityScore() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + @java.lang.Override + public float getSemanticSimilarityScore() { + return semanticSimilarityScore_; + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The semanticSimilarityScore to set. + * @return This builder for chaining. + */ + public Builder setSemanticSimilarityScore(float value) { + + semanticSimilarityScore_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSemanticSimilarityScore() { + bitField0_ = (bitField0_ & ~0x00000004); + semanticSimilarityScore_ = 0F; + onChanged(); + return this; + } + + private float pctrRank_; + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + @java.lang.Override + public boolean hasPctrRank() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + @java.lang.Override + public float getPctrRank() { + return pctrRank_; + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pctrRank to set. + * @return This builder for chaining. + */ + public Builder setPctrRank(float value) { + + pctrRank_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPctrRank() { + bitField0_ = (bitField0_ & ~0x00000008); + pctrRank_ = 0F; + onChanged(); + return this; + } + + private float topicalityRank_; + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the topicalityRank field is set. + */ + @java.lang.Override + public boolean hasTopicalityRank() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The topicalityRank. + */ + @java.lang.Override + public float getTopicalityRank() { + return topicalityRank_; + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The topicalityRank to set. + * @return This builder for chaining. + */ + public Builder setTopicalityRank(float value) { + + topicalityRank_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearTopicalityRank() { + bitField0_ = (bitField0_ & ~0x00000010); + topicalityRank_ = 0F; + onChanged(); + return this; + } + + private float documentAge_; + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + @java.lang.Override + public boolean hasDocumentAge() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + @java.lang.Override + public float getDocumentAge() { + return documentAge_; + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The documentAge to set. + * @return This builder for chaining. + */ + public Builder setDocumentAge(float value) { + + documentAge_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDocumentAge() { + bitField0_ = (bitField0_ & ~0x00000020); + documentAge_ = 0F; + onChanged(); + return this; + } + + private float boostingFactor_; + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the boostingFactor field is set. + */ + @java.lang.Override + public boolean hasBoostingFactor() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The boostingFactor. + */ + @java.lang.Override + public float getBoostingFactor() { + return boostingFactor_; + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The boostingFactor to set. + * @return This builder for chaining. + */ + public Builder setBoostingFactor(float value) { + + boostingFactor_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearBoostingFactor() { + bitField0_ = (bitField0_ & ~0x00000040); + boostingFactor_ = 0F; + onChanged(); + return this; + } + + private float defaultRank_; + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + @java.lang.Override + public float getDefaultRank() { + return defaultRank_; + } + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The defaultRank to set. + * @return This builder for chaining. + */ + public Builder setDefaultRank(float value) { + + defaultRank_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDefaultRank() { + bitField0_ = (bitField0_ & ~0x00000080); + defaultRank_ = 0F; + onChanged(); + return this; + } + + private java.util.List< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal> + customSignals_ = java.util.Collections.emptyList(); + + private void ensureCustomSignalsIsMutable() { + if (!((bitField0_ & 0x00000100) != 0)) { + customSignals_ = + new java.util.ArrayList< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal>(customSignals_); + bitField0_ |= 0x00000100; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + customSignalsBuilder_; + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList() { + if (customSignalsBuilder_ == null) { + return java.util.Collections.unmodifiableList(customSignals_); + } else { + return customSignalsBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getCustomSignalsCount() { + if (customSignalsBuilder_ == null) { + return customSignals_.size(); + } else { + return customSignalsBuilder_.getCount(); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + getCustomSignals(int index) { + if (customSignalsBuilder_ == null) { + return customSignals_.get(index); + } else { + return customSignalsBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCustomSignals( + int index, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.set(index, value); + onChanged(); + } else { + customSignalsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCustomSignals( + int index, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.set(index, builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.add(value); + onChanged(); + } else { + customSignalsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + int index, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.add(index, value); + onChanged(); + } else { + customSignalsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + int index, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(index, builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllCustomSignals( + java.lang.Iterable< + ? extends + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.CustomSignal> + values) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, customSignals_); + onChanged(); + } else { + customSignalsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearCustomSignals() { + if (customSignalsBuilder_ == null) { + customSignals_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + } else { + customSignalsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeCustomSignals(int index) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.remove(index); + onChanged(); + } else { + customSignalsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + getCustomSignalsBuilder(int index) { + return getCustomSignalsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index) { + if (customSignalsBuilder_ == null) { + return customSignals_.get(index); + } else { + return customSignalsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + ? extends + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList() { + if (customSignalsBuilder_ != null) { + return customSignalsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(customSignals_); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + addCustomSignalsBuilder() { + return getCustomSignalsFieldBuilder() + .addBuilder( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + addCustomSignalsBuilder(int index) { + return getCustomSignalsFieldBuilder() + .addBuilder( + index, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder> + getCustomSignalsBuilderList() { + return getCustomSignalsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsFieldBuilder() { + if (customSignalsBuilder_ == null) { + customSignalsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder>( + customSignals_, + ((bitField0_ & 0x00000100) != 0), + getParentForChildren(), + isClean()); + customSignals_ = null; + } + return customSignalsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) + } + + // @@protoc_insertion_point(class_scope:google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals) + private static final com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals(); + } + + public static com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + getDefaultInstance() { + return DEFAULT_INSTANCE; + } - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new SearchResult(); - } + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RankSignals 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 final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto - .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_descriptor; - } + public static com.google.protobuf.Parser parser() { + return PARSER; + } - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( - int number) { - switch (number) { - case 4: - return internalGetModelScores(); - default: - throw new RuntimeException("Invalid map field number: " + number); + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; } - } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.discoveryengine.v1alpha.SearchServiceProto - .internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.class, - com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.Builder.class); + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } } private int bitField0_; @@ -621,6 +3993,70 @@ public com.google.cloud.discoveryengine.v1alpha.DoubleList getModelScoresOrThrow return map.get(key); } + public static final int RANK_SIGNALS_FIELD_NUMBER = 7; + private com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + rankSignals_; + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + @java.lang.Override + public boolean hasRankSignals() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + getRankSignals() { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder() { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -643,6 +4079,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetModelScores(), ModelScoresDefaultEntryHolder.defaultEntry, 4); + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(7, getRankSignals()); + } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(18, getChunk()); } @@ -674,6 +4113,9 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, modelScores__); } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getRankSignals()); + } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getChunk()); } @@ -703,6 +4145,10 @@ public boolean equals(final java.lang.Object obj) { if (!getChunk().equals(other.getChunk())) return false; } if (!internalGetModelScores().equals(other.internalGetModelScores())) return false; + if (hasRankSignals() != other.hasRankSignals()) return false; + if (hasRankSignals()) { + if (!getRankSignals().equals(other.getRankSignals())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -728,6 +4174,10 @@ public int hashCode() { hash = (37 * hash) + MODEL_SCORES_FIELD_NUMBER; hash = (53 * hash) + internalGetModelScores().hashCode(); } + if (hasRankSignals()) { + hash = (37 * hash) + RANK_SIGNALS_FIELD_NUMBER; + hash = (53 * hash) + getRankSignals().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -898,6 +4348,7 @@ private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getDocumentFieldBuilder(); getChunkFieldBuilder(); + getRankSignalsFieldBuilder(); } } @@ -917,6 +4368,11 @@ public Builder clear() { chunkBuilder_ = null; } internalGetMutableModelScores().clear(); + rankSignals_ = null; + if (rankSignalsBuilder_ != null) { + rankSignalsBuilder_.dispose(); + rankSignalsBuilder_ = null; + } return this; } @@ -973,6 +4429,11 @@ private void buildPartial0( result.modelScores_ = internalGetModelScores().build(ModelScoresDefaultEntryHolder.defaultEntry); } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.rankSignals_ = + rankSignalsBuilder_ == null ? rankSignals_ : rankSignalsBuilder_.build(); + to_bitField0_ |= 0x00000004; + } result.bitField0_ |= to_bitField0_; } @@ -1040,6 +4501,9 @@ public Builder mergeFrom( } internalGetMutableModelScores().mergeFrom(other.internalGetModelScores()); bitField0_ |= 0x00000008; + if (other.hasRankSignals()) { + mergeRankSignals(other.getRankSignals()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1092,6 +4556,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 58: + { + input.readMessage(getRankSignalsFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 58 case 146: { input.readMessage(getChunkFieldBuilder().getBuilder(), extensionRegistry); @@ -1921,6 +5391,237 @@ public Builder putAllModelScores( return (com.google.cloud.discoveryengine.v1alpha.DoubleList.Builder) entry; } + private com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + rankSignals_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignalsOrBuilder> + rankSignalsBuilder_; + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + public boolean hasRankSignals() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + getRankSignals() { + if (rankSignalsBuilder_ == null) { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } else { + return rankSignalsBuilder_.getMessage(); + } + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRankSignals( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals value) { + if (rankSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + rankSignals_ = value; + } else { + rankSignalsBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRankSignals( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals.Builder + builderForValue) { + if (rankSignalsBuilder_ == null) { + rankSignals_ = builderForValue.build(); + } else { + rankSignalsBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeRankSignals( + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals value) { + if (rankSignalsBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && rankSignals_ != null + && rankSignals_ + != com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignals.getDefaultInstance()) { + getRankSignalsBuilder().mergeFrom(value); + } else { + rankSignals_ = value; + } + } else { + rankSignalsBuilder_.mergeFrom(value); + } + if (rankSignals_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearRankSignals() { + bitField0_ = (bitField0_ & ~0x00000010); + rankSignals_ = null; + if (rankSignalsBuilder_ != null) { + rankSignalsBuilder_.dispose(); + rankSignalsBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .Builder + getRankSignalsBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return getRankSignalsFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignalsOrBuilder + getRankSignalsOrBuilder() { + if (rankSignalsBuilder_ != null) { + return rankSignalsBuilder_.getMessageOrBuilder(); + } else { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignalsOrBuilder> + getRankSignalsFieldBuilder() { + if (rankSignalsBuilder_ == null) { + rankSignalsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult + .RankSignalsOrBuilder>(getRankSignals(), getParentForChildren(), isClean()); + rankSignals_ = null; + } + return rankSignalsBuilder_; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceProto.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceProto.java index 3e9893b46f4b..84ea48858ecf 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceProto.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/java/com/google/cloud/discoveryengine/v1alpha/SearchServiceProto.java @@ -140,6 +140,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_ModelScoresEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_ModelScoresEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_Facet_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -252,7 +260,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "/api/field_behavior.proto\032\031google/api/re" + "source.proto\0320google/cloud/discoveryengine/v1alpha/chunk.proto\0321google/cloud/dis" + "coveryengine/v1alpha/common.proto\0323googl" - + "e/cloud/discoveryengine/v1alpha/document.proto\032\034google/protobuf/struct.proto\"\3312\n" + + "e/cloud/discoveryengine/v1alpha/document.proto\032\034google/protobuf/struct.proto\"\3204\n" + "\r" + "SearchRequest\022L\n" + "\016serving_config\030\001 \001(\tB4\340A\002\372A.\n" @@ -290,23 +298,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + ".google.cloud.discoveryengine.v1alpha.SearchRequest.ContentSearchSpec\022Y\n" + "\016embedding_spec\030\027 \001(\0132A.google.cloud.discoveryen" + "gine.v1alpha.SearchRequest.EmbeddingSpec\022\032\n" - + "\022ranking_expression\030\032 \001(\t\022\023\n" + + "\022ranking_expression\030\032 \001(\t\022u\n" + + "\032ranking_expression_backend\0305 \001(\0162L.google.cloud." + + "discoveryengine.v1alpha.SearchRequest.RankingExpressionBackendB\003\340A\001\022\023\n" + "\013safe_search\030\024 \001(\010\022X\n" - + "\013user_labels\030\026 \003(\0132C.google." - + "cloud.discoveryengine.v1alpha.SearchRequest.UserLabelsEntry\022\214\001\n" - + ")natural_language_query_understanding_spec\030\034 \001(\0132Y.google" - + ".cloud.discoveryengine.v1alpha.SearchReq" - + "uest.NaturalLanguageQueryUnderstandingSpec\022h\n" - + "\027search_as_you_type_spec\030\037 \001(\0132G.go" - + "ogle.cloud.discoveryengine.v1alpha.SearchRequest.SearchAsYouTypeSpec\022[\n" - + "\027custom_fine_tuning_spec\030\" \001(\0132:.google.cloud.dis" - + "coveryengine.v1alpha.CustomFineTuningSpec\022<\n" + + "\013user_labels\030\026 \003(\0132C.google.c" + + "loud.discoveryengine.v1alpha.SearchRequest.UserLabelsEntry\022\214\001\n" + + ")natural_language_query_understanding_spec\030\034 \001(\0132Y.google." + + "cloud.discoveryengine.v1alpha.SearchRequ" + + "est.NaturalLanguageQueryUnderstandingSpec\022h\n" + + "\027search_as_you_type_spec\030\037 \001(\0132G.goo" + + "gle.cloud.discoveryengine.v1alpha.SearchRequest.SearchAsYouTypeSpec\022[\n" + + "\027custom_fine_tuning_spec\030\" \001(\0132:.google.cloud.disc" + + "overyengine.v1alpha.CustomFineTuningSpec\022<\n" + "\007session\030) \001(\tB+\372A(\n" + "&discoveryengine.googleapis.com/Session\022U\n" + "\014session_spec\030*" + " \001(\0132?.google.cloud.discoveryengine.v1alpha.SearchRequest.SessionSpec\022c\n" - + "\023relevance_threshold\030, \001(\0162F.google.cloud.disco" - + "veryengine.v1alpha.SearchRequest.RelevanceThreshold\032,\n\n" + + "\023relevance_threshold\030, \001(\0162F.google.cloud.discov" + + "eryengine.v1alpha.SearchRequest.RelevanceThreshold\032,\n\n" + "ImageQuery\022\025\n" + "\013image_bytes\030\001 \001(\tH\000B\007\n" + "\005image\032U\n\r" @@ -314,8 +324,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "data_store\030\001 \001(\tB0\340A\002\372A*\n" + "(discoveryengine.googleapis.com/DataStore\032\206\003\n" + "\tFacetSpec\022^\n" - + "\tfacet_key\030\001 \001(\0132F.google.cloud.discove" - + "ryengine.v1alpha.SearchRequest.FacetSpec.FacetKeyB\003\340A\002\022\r\n" + + "\tfacet_key\030\001 \001(\0132F.google.cloud.discover" + + "yengine.v1alpha.SearchRequest.FacetSpec.FacetKeyB\003\340A\002\022\r\n" + "\005limit\030\002 \001(\005\022\034\n" + "\024excluded_filter_keys\030\003 \003(\t\022\037\n" + "\027enable_dynamic_position\030\004 \001(\010\032\312\001\n" @@ -329,23 +339,23 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020case_insensitive\030\006 \001(\010\022\020\n" + "\010order_by\030\007 \001(\t\032\325\007\n" + "\tBoostSpec\022o\n" - + "\025condition_boost_specs\030\001 \003(\0132P.google.cloud.di" - + "scoveryengine.v1alpha.SearchRequest.BoostSpec.ConditionBoostSpec\032\326\006\n" + + "\025condition_boost_specs\030\001 \003(\0132P.google.cloud.dis" + + "coveryengine.v1alpha.SearchRequest.BoostSpec.ConditionBoostSpec\032\326\006\n" + "\022ConditionBoostSpec\022\021\n" + "\tcondition\030\001 \001(\t\022\r\n" + "\005boost\030\002 \001(\002\022}\n" - + "\022boost_control_spec\030\003 \001(\0132a.google.c" - + "loud.discoveryengine.v1alpha.SearchReque" - + "st.BoostSpec.ConditionBoostSpec.BoostControlSpec\032\236\005\n" + + "\022boost_control_spec\030\003 \001(\0132a.google.cl" + + "oud.discoveryengine.v1alpha.SearchReques" + + "t.BoostSpec.ConditionBoostSpec.BoostControlSpec\032\236\005\n" + "\020BoostControlSpec\022\022\n\n" + "field_name\030\001 \001(\t\022\207\001\n" - + "\016attribute_type\030\002 \001(\0162o.google.cloud.discoveryengine.v1alpha.Search" - + "Request.BoostSpec.ConditionBoostSpec.BoostControlSpec.AttributeType\022\217\001\n" - + "\022interpolation_type\030\003 \001(\0162s.google.cloud.discover" - + "yengine.v1alpha.SearchRequest.BoostSpec." - + "ConditionBoostSpec.BoostControlSpec.InterpolationType\022\206\001\n" - + "\016control_points\030\004 \003(\0132n.google.cloud.discoveryengine.v1alpha.Se" - + "archRequest.BoostSpec.ConditionBoostSpec.BoostControlSpec.ControlPoint\032=\n" + + "\016attribute_type\030\002 \001(\0162o.google.cloud.discoveryengine.v1alpha.SearchR" + + "equest.BoostSpec.ConditionBoostSpec.BoostControlSpec.AttributeType\022\217\001\n" + + "\022interpolation_type\030\003 \001(\0162s.google.cloud.discovery" + + "engine.v1alpha.SearchRequest.BoostSpec.C" + + "onditionBoostSpec.BoostControlSpec.InterpolationType\022\206\001\n" + + "\016control_points\030\004 \003(\0132n.google.cloud.discoveryengine.v1alpha.Sea" + + "rchRequest.BoostSpec.ConditionBoostSpec.BoostControlSpec.ControlPoint\032=\n" + "\014ControlPoint\022\027\n" + "\017attribute_value\030\001 \001(\t\022\024\n" + "\014boost_amount\030\002 \001(\002\"M\n\r" @@ -357,31 +367,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\036INTERPOLATION_TYPE_UNSPECIFIED\020\000\022\n\n" + "\006LINEAR\020\001\032\331\001\n" + "\022QueryExpansionSpec\022c\n" - + "\tcondition\030\001 \001(\0162P.google.cloud.discoveryengine.v1alp" - + "ha.SearchRequest.QueryExpansionSpec.Condition\022\036\n" + + "\tcondition\030\001 \001(\0162P.google.cloud.discoveryengine.v1alph" + + "a.SearchRequest.QueryExpansionSpec.Condition\022\036\n" + "\026pin_unexpanded_results\030\002 \001(\010\">\n" + "\tCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\010\n" + "\004AUTO\020\002\032\256\001\n" + "\023SpellCorrectionSpec\022Z\n" - + "\004mode\030\001 \001(\0162L.google.cloud.disco" - + "veryengine.v1alpha.SearchRequest.SpellCorrectionSpec.Mode\";\n" + + "\004mode\030\001 \001(\0162L.google.cloud.discov" + + "eryengine.v1alpha.SearchRequest.SpellCorrectionSpec.Mode\";\n" + "\004Mode\022\024\n" + "\020MODE_UNSPECIFIED\020\000\022\023\n" + "\017SUGGESTION_ONLY\020\001\022\010\n" + "\004AUTO\020\002\032\234\014\n" + "\021ContentSearchSpec\022g\n" - + "\014snippet_spec\030\001 \001(\0132Q.google.cloud.discoveryengine.v1alph" - + "a.SearchRequest.ContentSearchSpec.SnippetSpec\022g\n" - + "\014summary_spec\030\002 \001(\0132Q.google.clo" - + "ud.discoveryengine.v1alpha.SearchRequest.ContentSearchSpec.SummarySpec\022|\n" - + "\027extractive_content_spec\030\003 \001(\0132[.google.cloud.d" - + "iscoveryengine.v1alpha.SearchRequest.ContentSearchSpec.ExtractiveContentSpec\022r\n" - + "\022search_result_mode\030\004 \001(\0162V.google.cloud." - + "discoveryengine.v1alpha.SearchRequest.ContentSearchSpec.SearchResultMode\022c\n\n" - + "chunk_spec\030\005 \001(\0132O.google.cloud.discoveryeng" - + "ine.v1alpha.SearchRequest.ContentSearchSpec.ChunkSpec\032`\n" + + "\014snippet_spec\030\001 \001(\0132Q.google.cloud.discoveryengine.v1alpha" + + ".SearchRequest.ContentSearchSpec.SnippetSpec\022g\n" + + "\014summary_spec\030\002 \001(\0132Q.google.clou" + + "d.discoveryengine.v1alpha.SearchRequest.ContentSearchSpec.SummarySpec\022|\n" + + "\027extractive_content_spec\030\003 \001(\0132[.google.cloud.di" + + "scoveryengine.v1alpha.SearchRequest.ContentSearchSpec.ExtractiveContentSpec\022r\n" + + "\022search_result_mode\030\004 \001(\0162V.google.cloud.d" + + "iscoveryengine.v1alpha.SearchRequest.ContentSearchSpec.SearchResultMode\022c\n\n" + + "chunk_spec\030\005 \001(\0132O.google.cloud.discoveryengi" + + "ne.v1alpha.SearchRequest.ContentSearchSpec.ChunkSpec\032`\n" + "\013SnippetSpec\022\035\n" + "\021max_snippet_count\030\001 \001(\005B\002\030\001\022\032\n" + "\016reference_only\030\002 \001(\010B\002\030\001\022\026\n" @@ -392,11 +402,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\030ignore_adversarial_query\030\003 \001(\010\022(\n" + " ignore_non_summary_seeking_query\030\004 \001(\010\022#\n" + "\033ignore_low_relevant_content\030\t \001(\010\022|\n" - + "\021model_prompt_spec\030\005 \001(\0132a.google.cloud.discoveryengine.v1al" - + "pha.SearchRequest.ContentSearchSpec.SummarySpec.ModelPromptSpec\022\025\n\r" + + "\021model_prompt_spec\030\005 \001(\0132a.google.cloud.discoveryengine.v1alp" + + "ha.SearchRequest.ContentSearchSpec.SummarySpec.ModelPromptSpec\022\025\n\r" + "language_code\030\006 \001(\t\022o\n\n" - + "model_spec\030\007 \001(\0132[.google.cloud.discoveryengine.v1alpha.SearchRequest." - + "ContentSearchSpec.SummarySpec.ModelSpec\022\033\n" + + "model_spec\030\007 \001(\0132[.google.cloud.discoveryengine.v1alpha.SearchRequest.C" + + "ontentSearchSpec.SummarySpec.ModelSpec\022\033\n" + "\023use_semantic_chunks\030\010 \001(\010\032#\n" + "\017ModelPromptSpec\022\020\n" + "\010preamble\030\001 \001(\t\032\034\n" @@ -416,23 +426,23 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tDOCUMENTS\020\001\022\n\n" + "\006CHUNKS\020\002\032\264\001\n\r" + "EmbeddingSpec\022l\n" - + "\021embedding_vectors\030\001 \003(\0132Q.google.cloud.discoveryengin" - + "e.v1alpha.SearchRequest.EmbeddingSpec.EmbeddingVector\0325\n" + + "\021embedding_vectors\030\001 \003(\0132Q.google.cloud.discoveryengine" + + ".v1alpha.SearchRequest.EmbeddingSpec.EmbeddingVector\0325\n" + "\017EmbeddingVector\022\022\n\n" + "field_path\030\001 \001(\t\022\016\n" + "\006vector\030\002 \003(\002\032\305\002\n" + "%NaturalLanguageQueryUnderstandingSpec\022\230\001\n" - + "\033filter_extraction_condition\030\001 \001(\0162s.google.cl" - + "oud.discoveryengine.v1alpha.SearchReques" - + "t.NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition\022.\n" + + "\033filter_extraction_condition\030\001 \001(\0162s.google.clo" + + "ud.discoveryengine.v1alpha.SearchRequest" + + ".NaturalLanguageQueryUnderstandingSpec.FilterExtractionCondition\022.\n" + "&geo_search_query_detection_field_names\030\002 \003(\t\"Q\n" + "\031FilterExtractionCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\013\n" + "\007ENABLED\020\002\032\276\001\n" + "\023SearchAsYouTypeSpec\022d\n" - + "\tcondition\030\001 \001(\0162Q.google.cloud.discoveryengine.v1alpha.S" - + "earchRequest.SearchAsYouTypeSpec.Condition\"A\n" + + "\tcondition\030\001 \001(\0162Q.google.cloud.discoveryengine.v1alpha.Se" + + "archRequest.SearchAsYouTypeSpec.Condition\"A\n" + "\tCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\013\n" @@ -452,81 +462,110 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006LOWEST\020\001\022\007\n" + "\003LOW\020\002\022\n\n" + "\006MEDIUM\020\003\022\010\n" - + "\004HIGH\020\004\"\2520\n" + + "\004HIGH\020\004\"~\n" + + "\030RankingExpressionBackend\022*\n" + + "&RANKING_EXPRESSION_BACKEND_UNSPECIFIED\020\000\022\025\n" + + "\021RANK_BY_EMBEDDING\020\003\022\023\n" + + "\017RANK_BY_FORMULA\020\004\"\004\010\001\020\001\"\004\010\002\020\002\"\2126\n" + "\016SearchResponse\022R\n" - + "\007results\030\001" - + " \003(\0132A.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult\022J\n" + + "\007results\030\001 \003(\0132A.google.cloud.discoveryengi" + + "ne.v1alpha.SearchResponse.SearchResult\022J\n" + "\006facets\030\002" + " \003(\0132:.google.cloud.discoveryengine.v1alpha.SearchResponse.Facet\022e\n" - + "\024guided_search_result\030\010 \001(\0132G.google.cloud.discove" - + "ryengine.v1alpha.SearchResponse.GuidedSearchResult\022\022\n\n" + + "\024guided_search_result\030\010 \001(\0132G.google.cloud." + + "discoveryengine.v1alpha.SearchResponse.GuidedSearchResult\022\022\n\n" + "total_size\030\003 \001(\005\022\031\n" + "\021attribution_token\030\004 \001(\t\022\024\n" + "\014redirect_uri\030\014 \001(\t\022\027\n" + "\017next_page_token\030\005 \001(\t\022\027\n" + "\017corrected_query\030\007 \001(\t\022M\n" - + "\007summary\030\t \001(\0132<.google.clou" - + "d.discoveryengine.v1alpha.SearchResponse.Summary\022\030\n" + + "\007summary\030\t \001(\0132<.goog" + + "le.cloud.discoveryengine.v1alpha.SearchResponse.Summary\022\030\n" + "\020applied_controls\030\n" + " \003(\t\022f\n" - + "\025geo_search_debug_info\030\020 \003(\0132G.google.cloud" - + ".discoveryengine.v1alpha.SearchResponse.GeoSearchDebugInfo\022e\n" - + "\024query_expansion_info\030\016 \001(\0132G.google.cloud.discoveryengine." - + "v1alpha.SearchResponse.QueryExpansionInfo\022\215\001\n" - + ")natural_language_query_understanding_info\030\017" - + " \001(\0132Z.google.cloud.discoveryen" - + "gine.v1alpha.SearchResponse.NaturalLanguageQueryUnderstandingInfo\022V\n" - + "\014session_info\030\023" - + " \001(\0132@.google.cloud.discoveryengine.v1alpha.SearchResponse.SessionInfo\022Z\n" - + "\017one_box_results\030\024 \003(\0132A.google.cloud.discov" - + "eryengine.v1alpha.SearchResponse.OneBoxResult\032\350\002\n" + + "\025geo_search_debug_info\030\020 \003(\0132G.googl" + + "e.cloud.discoveryengine.v1alpha.SearchResponse.GeoSearchDebugInfo\022e\n" + + "\024query_expansion_info\030\016 \001(\0132G.google.cloud.discovery" + + "engine.v1alpha.SearchResponse.QueryExpansionInfo\022\215\001\n" + + ")natural_language_query_understanding_info\030\017 \001(\0132Z.google.cloud.disc" + + "overyengine.v1alpha.SearchResponse.NaturalLanguageQueryUnderstandingInfo\022V\n" + + "\014session_info\030\023 \001(\0132@.google.cloud.discoverye" + + "ngine.v1alpha.SearchResponse.SessionInfo\022Z\n" + + "\017one_box_results\030\024 \003(\0132A.google.cloud" + + ".discoveryengine.v1alpha.SearchResponse.OneBoxResult\032\310\010\n" + "\014SearchResult\022\n\n" + "\002id\030\001 \001(\t\022@\n" + "\010document\030\002 \001(\0132..google.cloud.discoveryengine.v1alpha.Document\022:\n" + "\005chunk\030\022 \001(\0132+.google.cloud.discoveryengine.v1alpha.Chunk\022h\n" - + "\014model_scores\030\004 \003(\0132R.google.cloud.di" - + "scoveryengine.v1alpha.SearchResponse.SearchResult.ModelScoresEntry\032d\n" + + "\014model_scores\030\004 \003(\0132R.google.c" + + "loud.discoveryengine.v1alpha.SearchResponse.SearchResult.ModelScoresEntry\022h\n" + + "\014rank_signals\030\007 \001(\0132M.google.cloud.discovery" + + "engine.v1alpha.SearchResponse.SearchResult.RankSignalsB\003\340A\001\032d\n" + "\020ModelScoresEntry\022\013\n" + "\003key\030\001 \001(\t\022?\n" - + "\005value\030\002 \001(\01320.goo" - + "gle.cloud.discoveryengine.v1alpha.DoubleList:\0028\001\032\203\002\n" + + "\005value\030\002 \001(\01320.google.clo" + + "ud.discoveryengine.v1alpha.DoubleList:\0028\001\032\363\004\n" + + "\013RankSignals\022*\n" + + "\030keyword_similarity_score\030\001 \001(\002B\003\340A\001H\000\210\001\001\022!\n" + + "\017relevance_score\030\002 \001(\002B\003\340A\001H\001\210\001\001\022+\n" + + "\031semantic_similarity_score\030\003" + + " \001(\002B\003\340A\001H\002\210\001\001\022\033\n" + + "\tpctr_rank\030\004 \001(\002B\003\340A\001H\003\210\001\001\022!\n" + + "\017topicality_rank\030\006 \001(\002B\003\340A\001H\004\210\001\001\022\036\n" + + "\014document_age\030\007 \001(\002B\003\340A\001H\005\210\001\001\022!\n" + + "\017boosting_factor\030\010 \001(\002B\003\340A\001H\006\210\001\001\022\031\n" + + "\014default_rank\030 \001(\002B\003\340A\001\022w\n" + + "\016custom_signals\030! \003(\0132Z.google.cloud.discoveryengine.v1alp" + + "ha.SearchResponse.SearchResult.RankSignals.CustomSignalB\003\340A\001\0325\n" + + "\014CustomSignal\022\021\n" + + "\004name\030\001 \001(\tB\003\340A\001\022\022\n" + + "\005value\030\002 \001(\002B\003\340A\001B\033\n" + + "\031_keyword_similarity_scoreB\022\n" + + "\020_relevance_scoreB\034\n" + + "\032_semantic_similarity_scoreB\014\n\n" + + "_pctr_rankB\022\n" + + "\020_topicality_rankB\017\n\r" + + "_document_ageB\022\n" + + "\020_boosting_factorJ\004\010\005\020\006\032\203\002\n" + "\005Facet\022\013\n" + "\003key\030\001 \001(\t\022U\n" - + "\006values\030\002 \003(\0132E.google.cloud.discoveryengine.v" - + "1alpha.SearchResponse.Facet.FacetValue\022\025\n\r" + + "\006values\030\002 \003(\0132E.google." + + "cloud.discoveryengine.v1alpha.SearchResponse.Facet.FacetValue\022\025\n\r" + "dynamic_facet\030\003 \001(\010\032\177\n\n" + "FacetValue\022\017\n" + "\005value\030\001 \001(\tH\000\022B\n" - + "\010interval\030\002 \001(\0132..google." - + "cloud.discoveryengine.v1alpha.IntervalH\000\022\r\n" - + "\005count\030\003 \001(\003B\r\n" + + "\010interval\030\002" + + " \001(\0132..google.cloud.discoveryengine.v1alpha.IntervalH\000\022\r\n" + + "\005count\030\003 \001(\003B\r" + + "\n" + "\013facet_value\032\364\001\n" + "\022GuidedSearchResult\022z\n" - + "\025refinement_attributes\030\001 \003(\0132[.google.cloud.discoveryengine.v1al" - + "pha.SearchResponse.GuidedSearchResult.RefinementAttribute\022\033\n" + + "\025refinement_attributes\030\001 \003(\0132[.google.clo" + + "ud.discoveryengine.v1alpha.SearchRespons" + + "e.GuidedSearchResult.RefinementAttribute\022\033\n" + "\023follow_up_questions\030\002 \003(\t\032E\n" + "\023RefinementAttribute\022\025\n\r" + "attribute_key\030\001 \001(\t\022\027\n" + "\017attribute_value\030\002 \001(\t\032\273\014\n" + "\007Summary\022\024\n" + "\014summary_text\030\001 \001(\t\022r\n" - + "\027summary_skipped_reasons\030\002 \003(\0162Q.google.cloud." - + "discoveryengine.v1alpha.SearchResponse.Summary.SummarySkippedReason\022h\n" - + "\021safety_attributes\030\003 \001(\0132M.google.cloud.discoverye" - + "ngine.v1alpha.SearchResponse.Summary.SafetyAttributes\022o\n" - + "\025summary_with_metadata\030\004 \001(\0132P.google.cloud.discoveryengine.v1al" - + "pha.SearchResponse.Summary.SummaryWithMetadata\0326\n" + + "\027summary_skipped_reasons\030\002 \003(\0162Q.google.cloud.discoveryengine.v" + + "1alpha.SearchResponse.Summary.SummarySkippedReason\022h\n" + + "\021safety_attributes\030\003 \001(\0132M." + + "google.cloud.discoveryengine.v1alpha.SearchResponse.Summary.SafetyAttributes\022o\n" + + "\025summary_with_metadata\030\004 \001(\0132P.google.clo" + + "ud.discoveryengine.v1alpha.SearchResponse.Summary.SummaryWithMetadata\0326\n" + "\020SafetyAttributes\022\022\n\n" + "categories\030\001 \003(\t\022\016\n" + "\006scores\030\002 \003(\002\032l\n" + "\020CitationMetadata\022X\n" - + "\tcitations\030\001 \003(\0132E.google.cloud.dis" - + "coveryengine.v1alpha.SearchResponse.Summary.Citation\032\220\001\n" + + "\tcitations\030\001" + + " \003(\0132E.google.cloud.discoveryengine.v1alpha.SearchResponse.Summary.Citation\032\220\001\n" + "\010Citation\022\023\n" + "\013start_index\030\001 \001(\003\022\021\n" + "\tend_index\030\002 \001(\003\022\\\n" - + "\007sources\030\003 \003(\0132K.google.cloud.discoveryengine.v1alph" - + "a.SearchResponse.Summary.CitationSource\032)\n" + + "\007sources\030\003 \003(\0132K.google.cloud" + + ".discoveryengine.v1alpha.SearchResponse.Summary.CitationSource\032)\n" + "\016CitationSource\022\027\n" + "\017reference_index\030\004 \001(\003\032\221\002\n" + "\tReference\022\r\n" @@ -534,17 +573,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010document\030\002 \001(\tB/\340A\002\372A)\n" + "\'discoveryengine.googleapis.com/Document\022\013\n" + "\003uri\030\003 \001(\t\022k\n" - + "\016chunk_contents\030\004 \003(\0132S.google.cloud.discovery" - + "engine.v1alpha.SearchResponse.Summary.Reference.ChunkContent\0328\n" + + "\016chunk_contents\030\004 \003(\0132S.google.cloud.discoveryengine.v1alpha.Se" + + "archResponse.Summary.Reference.ChunkContent\0328\n" + "\014ChunkContent\022\017\n" + "\007content\030\001 \001(\t\022\027\n" + "\017page_identifier\030\002 \001(\t\032\354\001\n" + "\023SummaryWithMetadata\022\017\n" + "\007summary\030\001 \001(\t\022h\n" - + "\021citation_metadata\030\002 \001(\0132M.google.clou" - + "d.discoveryengine.v1alpha.SearchResponse.Summary.CitationMetadata\022Z\n\n" - + "references\030\003 \003(\0132F.google.cloud.discoveryengine.v1a" - + "lpha.SearchResponse.Summary.Reference\"\343\002\n" + + "\021citation_metadata\030\002 \001(\0132M.google.cloud.discoveryengine" + + ".v1alpha.SearchResponse.Summary.CitationMetadata\022Z\n\n" + + "references\030\003 \003(\0132F.google.cl" + + "oud.discoveryengine.v1alpha.SearchResponse.Summary.Reference\"\343\002\n" + "\024SummarySkippedReason\022&\n" + "\"SUMMARY_SKIPPED_REASON_UNSPECIFIED\020\000\022\035\n" + "\031ADVERSARIAL_QUERY_IGNORED\020\001\022%\n" @@ -565,24 +604,22 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "%NaturalLanguageQueryUnderstandingInfo\022\031\n" + "\021extracted_filters\030\001 \001(\t\022\027\n" + "\017rewritten_query\030\002 \001(\t\022\231\001\n" - + "\033structured_extracted_filter\030\003 \001(\0132" - + "t.google.cloud.discoveryengine.v1alpha.SearchResponse.NaturalLanguageQueryUnders" - + "tandingInfo.StructuredExtractedFilter\032\221\017\n" + + "\033structured_extracted_filter\030\003 \001(\0132t.google.cloud.di" + + "scoveryengine.v1alpha.SearchResponse.Nat" + + "uralLanguageQueryUnderstandingInfo.StructuredExtractedFilter\032\221\017\n" + "\031StructuredExtractedFilter\022\223\001\n\n" - + "expression\030\001 \001(\0132\177.google.cloud.discoveryengine." - + "v1alpha.SearchResponse.NaturalLanguageQu" - + "eryUnderstandingInfo.StructuredExtractedFilter.Expression\032M\n" - + "\020StringConstraint\022\022\n" - + "\n" + + "expression\030\001 \001(\0132\177.google.cloud.discoveryengine.v1alpha.SearchRes" + + "ponse.NaturalLanguageQueryUnderstandingI" + + "nfo.StructuredExtractedFilter.Expression\032M\n" + + "\020StringConstraint\022\022\n\n" + "field_name\030\001 \001(\t\022\016\n" + "\006values\030\002 \003(\t\022\025\n\r" + "query_segment\030\003 \001(\t\032\373\002\n" - + "\020NumberConstraint\022\022\n" - + "\n" + + "\020NumberConstraint\022\022\n\n" + "field_name\030\001 \001(\t\022\245\001\n\n" - + "comparison\030\002 \001(\0162\220\001.google.cloud.discoveryengine.v1alpha.S" - + "earchResponse.NaturalLanguageQueryUnders" - + "tandingInfo.StructuredExtractedFilter.NumberConstraint.Comparison\022\r\n" + + "comparison\030\002 \001(\0162\220\001.google.cloud.di" + + "scoveryengine.v1alpha.SearchResponse.NaturalLanguageQueryUnderstandingInfo.Struc" + + "turedExtractedFilter.NumberConstraint.Comparison\022\r\n" + "\005value\030\003 \001(\001\022\025\n\r" + "query_segment\030\004 \001(\t\"\204\001\n\n" + "Comparison\022\032\n" @@ -599,59 +636,59 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tlongitude\030\005 \001(\001\022\030\n" + "\020radius_in_meters\030\003 \001(\002\032\246\001\n\r" + "AndExpression\022\224\001\n" - + "\013expressions\030\001 \003(\0132\177.google.cloud.discoveryengine.v1alp" - + "ha.SearchResponse.NaturalLanguageQueryUn" - + "derstandingInfo.StructuredExtractedFilter.Expression\032\245\001\n" + + "\013expressions\030\001 \003(\0132\177.google.clou" + + "d.discoveryengine.v1alpha.SearchResponse" + + ".NaturalLanguageQueryUnderstandingInfo.StructuredExtractedFilter.Expression\032\245\001\n" + "\014OrExpression\022\224\001\n" - + "\013expressions\030\001 \003(\0132\177.google.cloud.discoveryengi" - + "ne.v1alpha.SearchResponse.NaturalLanguag" - + "eQueryUnderstandingInfo.StructuredExtractedFilter.Expression\032\302\006\n\n" + + "\013expressions\030\001 \003(\0132\177.google.cloud.discoveryengine.v1alpha.Search" + + "Response.NaturalLanguageQueryUnderstandi" + + "ngInfo.StructuredExtractedFilter.Expression\032\302\006\n\n" + "Expression\022\243\001\n" - + "\021string_constraint\030\001 \001(\0132\205\001.google.cloud." + + "\021string_constraint\030\001 \001(\0132\205\001.google.cloud.discoveryengine.v" + + "1alpha.SearchResponse.NaturalLanguageQue" + + "ryUnderstandingInfo.StructuredExtractedFilter.StringConstraintH\000\022\243\001\n" + + "\021number_constraint\030\002 \001(\0132\205\001.google.cloud.discoveryen" + + "gine.v1alpha.SearchResponse.NaturalLangu" + + "ageQueryUnderstandingInfo.StructuredExtractedFilter.NumberConstraintH\000\022\255\001\n" + + "\026geolocation_constraint\030\003 \001(\0132\212\001.google.cloud." + "discoveryengine.v1alpha.SearchResponse.NaturalLanguageQueryUnderstandingInfo.Str" - + "ucturedExtractedFilter.StringConstraintH\000\022\243\001\n" - + "\021number_constraint\030\002 \001(\0132\205\001.google." - + "cloud.discoveryengine.v1alpha.SearchResponse.NaturalLanguageQueryUnderstandingIn" - + "fo.StructuredExtractedFilter.NumberConstraintH\000\022\255\001\n" - + "\026geolocation_constraint\030\003 \001(\013" - + "2\212\001.google.cloud.discoveryengine.v1alpha.SearchResponse.NaturalLanguageQueryUnde" - + "rstandingInfo.StructuredExtractedFilter.GeolocationConstraintH\000\022\227\001\n" - + "\010and_expr\030\004 \001(\0132\202\001.google.cloud.discoveryengine.v1alp" - + "ha.SearchResponse.NaturalLanguageQueryUn" - + "derstandingInfo.StructuredExtractedFilter.AndExpressionH\000\022\225\001\n" - + "\007or_expr\030\005 \001(\0132\201\001.google.cloud.discoveryengine.v1alpha.Sear" - + "chResponse.NaturalLanguageQueryUnderstan" - + "dingInfo.StructuredExtractedFilter.OrExpressionH\000B\006\n" + + "ucturedExtractedFilter.GeolocationConstraintH\000\022\227\001\n" + + "\010and_expr\030\004 \001(\0132\202\001.google.clou" + + "d.discoveryengine.v1alpha.SearchResponse.NaturalLanguageQueryUnderstandingInfo.S" + + "tructuredExtractedFilter.AndExpressionH\000\022\225\001\n" + + "\007or_expr\030\005 \001(\0132\201\001.google.cloud.disco" + + "veryengine.v1alpha.SearchResponse.Natura" + + "lLanguageQueryUnderstandingInfo.StructuredExtractedFilter.OrExpressionH\000B\006\n" + "\004expr\032-\n" + "\013SessionInfo\022\014\n" + "\004name\030\001 \001(\t\022\020\n" + "\010query_id\030\002 \001(\t\032\242\002\n" + "\014OneBoxResult\022b\n" - + "\014one_box_type\030\001 \001(\0162L.google.cloud.d" - + "iscoveryengine.v1alpha.SearchResponse.OneBoxResult.OneBoxType\022Y\n" - + "\016search_results\030\002" - + " \003(\0132A.google.cloud.discoveryengine.v1alpha.SearchResponse.SearchResult\"S\n\n" + + "\014one_box_type\030\001 \001(\0162L.google.cloud.discoveryengine.v1" + + "alpha.SearchResponse.OneBoxResult.OneBoxType\022Y\n" + + "\016search_results\030\002 \003(\0132A.google.cl" + + "oud.discoveryengine.v1alpha.SearchResponse.SearchResult\"S\n\n" + "OneBoxType\022\034\n" + "\030ONE_BOX_TYPE_UNSPECIFIED\020\000\022\n\n" + "\006PEOPLE\020\001\022\020\n" + "\014ORGANIZATION\020\002\022\t\n" + "\005SLACK\020\0032\216\004\n\r" + "SearchService\022\250\003\n" - + "\006Search\0223.google.cloud.discoveryengine.v1alpha.SearchRequest\032" - + "4.google.cloud.discoveryengine.v1alpha.S" - + "earchResponse\"\262\002\202\323\344\223\002\253\002\"U/v1alpha/{servi" - + "ng_config=projects/*/locations/*/dataStores/*/servingConfigs/*}:search:\001*Zh\"c/v1" - + "alpha/{serving_config=projects/*/locations/*/collections/*/dataStores/*/servingC" - + "onfigs/*}:search:\001*Ze\"`/v1alpha/{serving_config=projects/*/locations/*/collectio" - + "ns/*/engines/*/servingConfigs/*}:search:" - + "\001*\032R\312A\036discoveryengine.googleapis.com\322A." - + "https://www.googleapis.com/auth/cloud-platformB\236\002\n" - + "(com.google.cloud.discoveryengine.v1alphaB\022SearchServiceProtoP\001ZRcloud" - + ".google.com/go/discoveryengine/apiv1alph" - + "a/discoveryenginepb;discoveryenginepb\242\002\017" - + "DISCOVERYENGINE\252\002$Google.Cloud.Discovery" - + "Engine.V1Alpha\312\002$Google\\Cloud\\DiscoveryE" - + "ngine\\V1alpha\352\002\'Google::Cloud::DiscoveryEngine::V1alphab\006proto3" + + "\006Search\0223.google.cloud.discoveryengine" + + ".v1alpha.SearchRequest\0324.google.cloud.di" + + "scoveryengine.v1alpha.SearchResponse\"\262\002\202" + + "\323\344\223\002\253\002\"U/v1alpha/{serving_config=project" + + "s/*/locations/*/dataStores/*/servingConfigs/*}:search:\001*Zh\"c/v1alpha/{serving_co" + + "nfig=projects/*/locations/*/collections/*/dataStores/*/servingConfigs/*}:search:" + + "\001*Ze\"`/v1alpha/{serving_config=projects/*/locations/*/collections/*/engines/*/se" + + "rvingConfigs/*}:search:\001*\032R\312A\036discoverye" + + "ngine.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\236\002\n" + + "(com.google.cloud.discoveryengine.v1alphaB\022Sear" + + "chServiceProtoP\001ZRcloud.google.com/go/discoveryengine/apiv1alpha/discoveryengine" + + "pb;discoveryenginepb\242\002\017DISCOVERYENGINE\252\002" + + "$Google.Cloud.DiscoveryEngine.V1Alpha\312\002$" + + "Google\\Cloud\\DiscoveryEngine\\V1alpha\352\002\'G" + + "oogle::Cloud::DiscoveryEngine::V1alphab\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -695,6 +732,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ContentSearchSpec", "EmbeddingSpec", "RankingExpression", + "RankingExpressionBackend", "SafeSearch", "UserLabels", "NaturalLanguageQueryUnderstandingSpec", @@ -996,7 +1034,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_descriptor, new java.lang.String[] { - "Id", "Document", "Chunk", "ModelScores", + "Id", "Document", "Chunk", "ModelScores", "RankSignals", }); internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_ModelScoresEntry_descriptor = internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_descriptor @@ -1008,6 +1046,34 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor = + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor, + new java.lang.String[] { + "KeywordSimilarityScore", + "RelevanceScore", + "SemanticSimilarityScore", + "PctrRank", + "TopicalityRank", + "DocumentAge", + "BoostingFactor", + "DefaultRank", + "CustomSignals", + }); + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor = + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor, + new java.lang.String[] { + "Name", "Value", + }); internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_Facet_descriptor = internal_static_google_cloud_discoveryengine_v1alpha_SearchResponse_descriptor .getNestedTypes() diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/proto/google/cloud/discoveryengine/v1alpha/search_service.proto b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/proto/google/cloud/discoveryengine/v1alpha/search_service.proto index aee4eb4563d5..63137e36a073 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/proto/google/cloud/discoveryengine/v1alpha/search_service.proto +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1alpha/src/main/proto/google/cloud/discoveryengine/v1alpha/search_service.proto @@ -966,8 +966,14 @@ message SearchRequest { // The ranking expression controls the customized ranking on retrieval // documents. This overrides // [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1alpha.ServingConfig.ranking_expression]. - // The ranking expression is a single function or multiple functions that are - // joined by "+". + // The syntax and supported features depend on the + // `ranking_expression_backend` value. If `ranking_expression_backend` is not + // provided, it defaults to `RANK_BY_EMBEDDING`. + // + // If + // [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + // is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + // function or multiple functions that are joined by "+". // // * ranking_expression = function, { " + ", function }; // @@ -982,15 +988,90 @@ message SearchRequest { // between query and document. // * `embedding_field_path`: the document embedding field // used with query embedding vector. - // * `dotProduct`: embedding function between embedding_field_path and query - // embedding vector. + // * `dotProduct`: embedding function between `embedding_field_path` and + // query embedding vector. // // Example ranking expression: // // If document has an embedding field doc_embedding, the ranking expression // could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + // + // If + // [ranking_expression_backend][google.cloud.discoveryengine.v1alpha.SearchRequest.ranking_expression_backend] + // is set to `RANK_BY_FORMULA`, the following expression types (and + // combinations of those chained using + or + // * operators) are supported: + // + // * `double` + // * `signal` + // * `log(signal)` + // * `exp(signal)` + // * `rr(signal, double > 0)` -- reciprocal rank transformation with second + // argument being a denominator constant. + // * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + // * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + // signal2 | double, else returns signal1. + // + // Here are a few examples of ranking formulas that use the supported + // ranking expression types: + // + // - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + // -- mostly rank by the logarithm of `keyword_similarity_score` with slight + // `semantic_smilarity_score` adjustment. + // - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + // is_nan(keyword_similarity_score)` -- rank by the exponent of + // `semantic_similarity_score` filling the value with 0 if it's NaN, also + // add constant 0.3 adjustment to the final score if + // `semantic_similarity_score` is NaN. + // - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + // rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + // of `keyword_similarity_score` with slight adjustment of reciprocal rank + // of `semantic_smilarity_score`. + // + // The following signals are supported: + // + // * `semantic_similarity_score`: semantic similarity adjustment that is + // calculated using the embeddings generated by a proprietary Google model. + // This score determines how semantically similar a search query is to a + // document. + // * `keyword_similarity_score`: keyword match adjustment uses the Best + // Match 25 (BM25) ranking function. This score is calculated using a + // probabilistic model to estimate the probability that a document is + // relevant to a given query. + // * `relevance_score`: semantic relevance adjustment that uses a + // proprietary Google model to determine the meaning and intent behind a + // user's query in context with the content in the documents. + // * `pctr_rank`: predicted conversion rate adjustment as a rank use + // predicted Click-through rate (pCTR) to gauge the relevance and + // attractiveness of a search result from a user's perspective. A higher + // pCTR suggests that the result is more likely to satisfy the user's query + // and intent, making it a valuable signal for ranking. + // * `freshness_rank`: freshness adjustment as a rank + // * `document_age`: The time in hours elapsed since the document was last + // updated, a floating-point number (e.g., 0.25 means 15 minutes). + // * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + // Google model to determine the keyword-based overlap between the query and + // the document. + // * `base_rank`: the default rank of the result string ranking_expression = 26; + // The backend to use for the ranking expression evaluation. + enum RankingExpressionBackend { + reserved 1, 2; + + // Default option for unspecified/unknown values. + RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + // Ranking by custom embedding model, the default way to evaluate the + // ranking expression. + RANK_BY_EMBEDDING = 3; + // Ranking by custom formula. + RANK_BY_FORMULA = 4; + } + + // The backend to use for the ranking expression evaluation. + RankingExpressionBackend ranking_expression_backend = 53 + [(google.api.field_behavior) = OPTIONAL]; + // Whether to turn on safe search. This is only supported for // website search. bool safe_search = 20; @@ -1088,6 +1169,49 @@ message SearchResponse { // Google provided available scores. map model_scores = 4; + + // A set of ranking signals. + message RankSignals { + reserved 5; + + // Keyword matching adjustment. + optional float keyword_similarity_score = 1 + [(google.api.field_behavior) = OPTIONAL]; + // Semantic relevance adjustment. + optional float relevance_score = 2 + [(google.api.field_behavior) = OPTIONAL]; + // Semantic similarity adjustment. + optional float semantic_similarity_score = 3 + [(google.api.field_behavior) = OPTIONAL]; + // Predicted conversion rate adjustment as a rank. + optional float pctr_rank = 4 [(google.api.field_behavior) = OPTIONAL]; + // Topicality adjustment as a rank. + optional float topicality_rank = 6 + [(google.api.field_behavior) = OPTIONAL]; + // Age of the document in hours. + optional float document_age = 7 [(google.api.field_behavior) = OPTIONAL]; + // Combined custom boosts for a doc. + optional float boosting_factor = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // The default rank of the result. + float default_rank = 32 [(google.api.field_behavior) = OPTIONAL]; + + // Custom clearbox signal represented by name and value pair. + message CustomSignal { + // Name of the signal. + string name = 1 [(google.api.field_behavior) = OPTIONAL]; + // Float value representing the ranking signal (e.g. 1.25 for BM25). + float value = 2 [(google.api.field_behavior) = OPTIONAL]; + } + + // A list of custom clearbox signals. + repeated CustomSignal custom_signals = 33 + [(google.api.field_behavior) = OPTIONAL]; + } + + // A set of ranking signals associated with the result. + RankSignals rank_signals = 7 [(google.api.field_behavior) = OPTIONAL]; } // A facet result. diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequest.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequest.java index 6acb51fd9acc..222babf28673 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequest.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequest.java @@ -55,6 +55,7 @@ private SearchRequest() { facetSpecs_ = java.util.Collections.emptyList(); userPseudoId_ = ""; rankingExpression_ = ""; + rankingExpressionBackend_ = 0; session_ = ""; relevanceThreshold_ = 0; } @@ -308,6 +309,173 @@ private RelevanceThreshold(int value) { // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1beta.SearchRequest.RelevanceThreshold) } + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * Protobuf enum {@code + * google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend} + */ + public enum RankingExpressionBackend implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
        +     * Default option for unspecified/unknown values.
        +     * 
        + * + * RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + */ + RANKING_EXPRESSION_BACKEND_UNSPECIFIED(0), + /** + * + * + *
        +     * Ranking by custom embedding model, the default way to evaluate the
        +     * ranking expression.
        +     * 
        + * + * RANK_BY_EMBEDDING = 3; + */ + RANK_BY_EMBEDDING(3), + /** + * + * + *
        +     * Ranking by custom formula.
        +     * 
        + * + * RANK_BY_FORMULA = 4; + */ + RANK_BY_FORMULA(4), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
        +     * Default option for unspecified/unknown values.
        +     * 
        + * + * RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + */ + public static final int RANKING_EXPRESSION_BACKEND_UNSPECIFIED_VALUE = 0; + + /** + * + * + *
        +     * Ranking by custom embedding model, the default way to evaluate the
        +     * ranking expression.
        +     * 
        + * + * RANK_BY_EMBEDDING = 3; + */ + public static final int RANK_BY_EMBEDDING_VALUE = 3; + + /** + * + * + *
        +     * Ranking by custom formula.
        +     * 
        + * + * RANK_BY_FORMULA = 4; + */ + public static final int RANK_BY_FORMULA_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 RankingExpressionBackend 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 RankingExpressionBackend forNumber(int value) { + switch (value) { + case 0: + return RANKING_EXPRESSION_BACKEND_UNSPECIFIED; + case 3: + return RANK_BY_EMBEDDING; + case 4: + return RANK_BY_FORMULA; + 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 RankingExpressionBackend findValueByNumber(int number) { + return RankingExpressionBackend.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 final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.SearchRequest.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final RankingExpressionBackend[] VALUES = values(); + + public static RankingExpressionBackend 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 RankingExpressionBackend(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend) + } + public interface ImageQueryOrBuilder extends // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1beta.SearchRequest.ImageQuery) @@ -32362,8 +32530,14 @@ public com.google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec getEm * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -32378,13 +32552,71 @@ public com.google.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec getEm * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -32411,8 +32643,14 @@ public java.lang.String getRankingExpression() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -32427,13 +32665,71 @@ public java.lang.String getRankingExpression() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -32453,6 +32749,52 @@ public com.google.protobuf.ByteString getRankingExpressionBytes() { } } + public static final int RANKING_EXPRESSION_BACKEND_FIELD_NUMBER = 53; + private int rankingExpressionBackend_ = 0; + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + @java.lang.Override + public int getRankingExpressionBackendValue() { + return rankingExpressionBackend_; + } + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend() { + com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend result = + com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend.forNumber( + rankingExpressionBackend_); + return result == null + ? com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + .UNRECOGNIZED + : result; + } + public static final int SAFE_SEARCH_FIELD_NUMBER = 20; private boolean safeSearch_ = false; @@ -33189,6 +33531,12 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (oneBoxPageSize_ != 0) { output.writeInt32(47, oneBoxPageSize_); } + if (rankingExpressionBackend_ + != com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + .RANKING_EXPRESSION_BACKEND_UNSPECIFIED + .getNumber()) { + output.writeEnum(53, rankingExpressionBackend_); + } getUnknownFields().writeTo(output); } @@ -33316,6 +33664,12 @@ public int getSerializedSize() { if (oneBoxPageSize_ != 0) { size += com.google.protobuf.CodedOutputStream.computeInt32Size(47, oneBoxPageSize_); } + if (rankingExpressionBackend_ + != com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + .RANKING_EXPRESSION_BACKEND_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(53, rankingExpressionBackend_); + } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; @@ -33377,6 +33731,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEmbeddingSpec().equals(other.getEmbeddingSpec())) return false; } if (!getRankingExpression().equals(other.getRankingExpression())) return false; + if (rankingExpressionBackend_ != other.rankingExpressionBackend_) return false; if (getSafeSearch() != other.getSafeSearch()) return false; if (!internalGetUserLabels().equals(other.internalGetUserLabels())) return false; if (hasNaturalLanguageQueryUnderstandingSpec() @@ -33478,6 +33833,8 @@ public int hashCode() { } hash = (37 * hash) + RANKING_EXPRESSION_FIELD_NUMBER; hash = (53 * hash) + getRankingExpression().hashCode(); + hash = (37 * hash) + RANKING_EXPRESSION_BACKEND_FIELD_NUMBER; + hash = (53 * hash) + rankingExpressionBackend_; hash = (37 * hash) + SAFE_SEARCH_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getSafeSearch()); if (!internalGetUserLabels().getMap().isEmpty()) { @@ -33694,6 +34051,7 @@ private void maybeForceBuilderInitialization() { public Builder clear() { super.clear(); bitField0_ = 0; + bitField1_ = 0; servingConfig_ = ""; branch_ = ""; query_ = ""; @@ -33758,6 +34116,7 @@ public Builder clear() { embeddingSpecBuilder_ = null; } rankingExpression_ = ""; + rankingExpressionBackend_ = 0; safeSearch_ = false; internalGetMutableUserLabels().clear(); naturalLanguageQueryUnderstandingSpec_ = null; @@ -33813,6 +34172,9 @@ public com.google.cloud.discoveryengine.v1beta.SearchRequest buildPartial() { if (bitField0_ != 0) { buildPartial0(result); } + if (bitField1_ != 0) { + buildPartial1(result); + } onBuilt(); return result; } @@ -33926,38 +34288,47 @@ private void buildPartial0(com.google.cloud.discoveryengine.v1beta.SearchRequest result.rankingExpression_ = rankingExpression_; } if (((from_bitField0_ & 0x01000000) != 0)) { - result.safeSearch_ = safeSearch_; + result.rankingExpressionBackend_ = rankingExpressionBackend_; } if (((from_bitField0_ & 0x02000000) != 0)) { + result.safeSearch_ = safeSearch_; + } + if (((from_bitField0_ & 0x04000000) != 0)) { result.userLabels_ = internalGetUserLabels(); result.userLabels_.makeImmutable(); } - if (((from_bitField0_ & 0x04000000) != 0)) { + if (((from_bitField0_ & 0x08000000) != 0)) { result.naturalLanguageQueryUnderstandingSpec_ = naturalLanguageQueryUnderstandingSpecBuilder_ == null ? naturalLanguageQueryUnderstandingSpec_ : naturalLanguageQueryUnderstandingSpecBuilder_.build(); to_bitField0_ |= 0x00000080; } - if (((from_bitField0_ & 0x08000000) != 0)) { + if (((from_bitField0_ & 0x10000000) != 0)) { result.searchAsYouTypeSpec_ = searchAsYouTypeSpecBuilder_ == null ? searchAsYouTypeSpec_ : searchAsYouTypeSpecBuilder_.build(); to_bitField0_ |= 0x00000100; } - if (((from_bitField0_ & 0x10000000) != 0)) { + if (((from_bitField0_ & 0x20000000) != 0)) { result.session_ = session_; } - if (((from_bitField0_ & 0x20000000) != 0)) { + if (((from_bitField0_ & 0x40000000) != 0)) { result.sessionSpec_ = sessionSpecBuilder_ == null ? sessionSpec_ : sessionSpecBuilder_.build(); to_bitField0_ |= 0x00000200; } - if (((from_bitField0_ & 0x40000000) != 0)) { + if (((from_bitField0_ & 0x80000000) != 0)) { result.relevanceThreshold_ = relevanceThreshold_; } - if (((from_bitField0_ & 0x80000000) != 0)) { + result.bitField0_ |= to_bitField0_; + } + + private void buildPartial1(com.google.cloud.discoveryengine.v1beta.SearchRequest result) { + int from_bitField1_ = bitField1_; + int to_bitField0_ = 0; + if (((from_bitField1_ & 0x00000001) != 0)) { result.personalizationSpec_ = personalizationSpecBuilder_ == null ? personalizationSpec_ @@ -34154,11 +34525,14 @@ public Builder mergeFrom(com.google.cloud.discoveryengine.v1beta.SearchRequest o bitField0_ |= 0x00800000; onChanged(); } + if (other.rankingExpressionBackend_ != 0) { + setRankingExpressionBackendValue(other.getRankingExpressionBackendValue()); + } if (other.getSafeSearch() != false) { setSafeSearch(other.getSafeSearch()); } internalGetMutableUserLabels().mergeFrom(other.internalGetUserLabels()); - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; if (other.hasNaturalLanguageQueryUnderstandingSpec()) { mergeNaturalLanguageQueryUnderstandingSpec( other.getNaturalLanguageQueryUnderstandingSpec()); @@ -34168,7 +34542,7 @@ public Builder mergeFrom(com.google.cloud.discoveryengine.v1beta.SearchRequest o } if (!other.getSession().isEmpty()) { session_ = other.session_; - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); } if (other.hasSessionSpec()) { @@ -34315,7 +34689,7 @@ public Builder mergeFrom( case 160: { safeSearch_ = input.readBool(); - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; break; } // case 160 case 170: @@ -34333,7 +34707,7 @@ public Builder mergeFrom( internalGetMutableUserLabels() .getMutableMap() .put(userLabels__.getKey(), userLabels__.getValue()); - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; break; } // case 178 case 186: @@ -34360,7 +34734,7 @@ public Builder mergeFrom( input.readMessage( getNaturalLanguageQueryUnderstandingSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; break; } // case 226 case 234: @@ -34373,7 +34747,7 @@ public Builder mergeFrom( { input.readMessage( getSearchAsYouTypeSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; break; } // case 250 case 258: @@ -34406,26 +34780,26 @@ public Builder mergeFrom( case 330: { session_ = input.readStringRequireUtf8(); - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; break; } // case 330 case 338: { input.readMessage(getSessionSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; break; } // case 338 case 352: { relevanceThreshold_ = input.readEnum(); - bitField0_ |= 0x40000000; + bitField0_ |= 0x80000000; break; } // case 352 case 370: { input.readMessage( getPersonalizationSpecFieldBuilder().getBuilder(), extensionRegistry); - bitField0_ |= 0x80000000; + bitField1_ |= 0x00000001; break; } // case 370 case 376: @@ -34434,6 +34808,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000080; break; } // case 376 + case 424: + { + rankingExpressionBackend_ = input.readEnum(); + bitField0_ |= 0x01000000; + break; + } // case 424 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { @@ -34452,6 +34832,7 @@ public Builder mergeFrom( } private int bitField0_; + private int bitField1_; private java.lang.Object servingConfig_ = ""; @@ -39078,8 +39459,14 @@ public Builder clearEmbeddingSpec() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -39094,13 +39481,71 @@ public Builder clearEmbeddingSpec() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -39126,8 +39571,14 @@ public java.lang.String getRankingExpression() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -39142,13 +39593,71 @@ public java.lang.String getRankingExpression() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -39174,8 +39683,14 @@ public com.google.protobuf.ByteString getRankingExpressionBytes() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -39190,13 +39705,71 @@ public com.google.protobuf.ByteString getRankingExpressionBytes() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -39221,8 +39794,14 @@ public Builder setRankingExpression(java.lang.String value) { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -39237,13 +39816,71 @@ public Builder setRankingExpression(java.lang.String value) { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -39264,8 +39901,14 @@ public Builder clearRankingExpression() { * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -39280,13 +39923,71 @@ public Builder clearRankingExpression() { * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -39305,6 +40006,117 @@ public Builder setRankingExpressionBytes(com.google.protobuf.ByteString value) { return this; } + private int rankingExpressionBackend_ = 0; + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + @java.lang.Override + public int getRankingExpressionBackendValue() { + return rankingExpressionBackend_; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The enum numeric value on the wire for rankingExpressionBackend to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBackendValue(int value) { + rankingExpressionBackend_ = value; + bitField0_ |= 0x01000000; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend() { + com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend result = + com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend.forNumber( + rankingExpressionBackend_); + return result == null + ? com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + .UNRECOGNIZED + : result; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The rankingExpressionBackend to set. + * @return This builder for chaining. + */ + public Builder setRankingExpressionBackend( + com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x01000000; + rankingExpressionBackend_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
        +     * The backend to use for the ranking expression evaluation.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRankingExpressionBackend() { + bitField0_ = (bitField0_ & ~0x01000000); + rankingExpressionBackend_ = 0; + onChanged(); + return this; + } + private boolean safeSearch_; /** @@ -39340,7 +40152,7 @@ public boolean getSafeSearch() { public Builder setSafeSearch(boolean value) { safeSearch_ = value; - bitField0_ |= 0x01000000; + bitField0_ |= 0x02000000; onChanged(); return this; } @@ -39358,7 +40170,7 @@ public Builder setSafeSearch(boolean value) { * @return This builder for chaining. */ public Builder clearSafeSearch() { - bitField0_ = (bitField0_ & ~0x01000000); + bitField0_ = (bitField0_ & ~0x02000000); safeSearch_ = false; onChanged(); return this; @@ -39384,7 +40196,7 @@ public Builder clearSafeSearch() { if (!userLabels_.isMutable()) { userLabels_ = userLabels_.copy(); } - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; onChanged(); return userLabels_; } @@ -39538,7 +40350,7 @@ public java.lang.String getUserLabelsOrThrow(java.lang.String key) { } public Builder clearUserLabels() { - bitField0_ = (bitField0_ & ~0x02000000); + bitField0_ = (bitField0_ & ~0x04000000); internalGetMutableUserLabels().getMutableMap().clear(); return this; } @@ -39579,7 +40391,7 @@ public Builder removeUserLabels(java.lang.String key) { /** Use alternate mutation accessors instead. */ @java.lang.Deprecated public java.util.Map getMutableUserLabels() { - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; return internalGetMutableUserLabels().getMutableMap(); } @@ -39616,7 +40428,7 @@ public Builder putUserLabels(java.lang.String key, java.lang.String value) { throw new NullPointerException("map value"); } internalGetMutableUserLabels().getMutableMap().put(key, value); - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; return this; } @@ -39647,7 +40459,7 @@ public Builder putUserLabels(java.lang.String key, java.lang.String value) { */ public Builder putAllUserLabels(java.util.Map values) { internalGetMutableUserLabels().getMutableMap().putAll(values); - bitField0_ |= 0x02000000; + bitField0_ |= 0x04000000; return this; } @@ -39678,7 +40490,7 @@ public Builder putAllUserLabels(java.util.Map */ public Builder clearNaturalLanguageQueryUnderstandingSpec() { - bitField0_ = (bitField0_ & ~0x04000000); + bitField0_ = (bitField0_ & ~0x08000000); naturalLanguageQueryUnderstandingSpec_ = null; if (naturalLanguageQueryUnderstandingSpecBuilder_ != null) { naturalLanguageQueryUnderstandingSpecBuilder_.dispose(); @@ -39835,7 +40647,7 @@ public Builder clearNaturalLanguageQueryUnderstandingSpec() { public com.google.cloud.discoveryengine.v1beta.SearchRequest .NaturalLanguageQueryUnderstandingSpec.Builder getNaturalLanguageQueryUnderstandingSpecBuilder() { - bitField0_ |= 0x04000000; + bitField0_ |= 0x08000000; onChanged(); return getNaturalLanguageQueryUnderstandingSpecFieldBuilder().getBuilder(); } @@ -39924,7 +40736,7 @@ public Builder clearNaturalLanguageQueryUnderstandingSpec() { * @return Whether the searchAsYouTypeSpec field is set. */ public boolean hasSearchAsYouTypeSpec() { - return ((bitField0_ & 0x08000000) != 0); + return ((bitField0_ & 0x10000000) != 0); } /** @@ -39977,7 +40789,7 @@ public Builder setSearchAsYouTypeSpec( } else { searchAsYouTypeSpecBuilder_.setMessage(value); } - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return this; } @@ -40003,7 +40815,7 @@ public Builder setSearchAsYouTypeSpec( } else { searchAsYouTypeSpecBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return this; } @@ -40024,7 +40836,7 @@ public Builder setSearchAsYouTypeSpec( public Builder mergeSearchAsYouTypeSpec( com.google.cloud.discoveryengine.v1beta.SearchRequest.SearchAsYouTypeSpec value) { if (searchAsYouTypeSpecBuilder_ == null) { - if (((bitField0_ & 0x08000000) != 0) + if (((bitField0_ & 0x10000000) != 0) && searchAsYouTypeSpec_ != null && searchAsYouTypeSpec_ != com.google.cloud.discoveryengine.v1beta.SearchRequest.SearchAsYouTypeSpec @@ -40037,7 +40849,7 @@ public Builder mergeSearchAsYouTypeSpec( searchAsYouTypeSpecBuilder_.mergeFrom(value); } if (searchAsYouTypeSpec_ != null) { - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); } return this; @@ -40057,7 +40869,7 @@ public Builder mergeSearchAsYouTypeSpec( * */ public Builder clearSearchAsYouTypeSpec() { - bitField0_ = (bitField0_ & ~0x08000000); + bitField0_ = (bitField0_ & ~0x10000000); searchAsYouTypeSpec_ = null; if (searchAsYouTypeSpecBuilder_ != null) { searchAsYouTypeSpecBuilder_.dispose(); @@ -40082,7 +40894,7 @@ public Builder clearSearchAsYouTypeSpec() { */ public com.google.cloud.discoveryengine.v1beta.SearchRequest.SearchAsYouTypeSpec.Builder getSearchAsYouTypeSpecBuilder() { - bitField0_ |= 0x08000000; + bitField0_ |= 0x10000000; onChanged(); return getSearchAsYouTypeSpecFieldBuilder().getBuilder(); } @@ -40264,7 +41076,7 @@ public Builder setSession(java.lang.String value) { throw new NullPointerException(); } session_ = value; - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return this; } @@ -40301,7 +41113,7 @@ public Builder setSession(java.lang.String value) { */ public Builder clearSession() { session_ = getDefaultInstance().getSession(); - bitField0_ = (bitField0_ & ~0x10000000); + bitField0_ = (bitField0_ & ~0x20000000); onChanged(); return this; } @@ -40343,7 +41155,7 @@ public Builder setSessionBytes(com.google.protobuf.ByteString value) { } checkByteStringIsUtf8(value); session_ = value; - bitField0_ |= 0x10000000; + bitField0_ |= 0x20000000; onChanged(); return this; } @@ -40370,7 +41182,7 @@ public Builder setSessionBytes(com.google.protobuf.ByteString value) { * @return Whether the sessionSpec field is set. */ public boolean hasSessionSpec() { - return ((bitField0_ & 0x20000000) != 0); + return ((bitField0_ & 0x40000000) != 0); } /** @@ -40419,7 +41231,7 @@ public Builder setSessionSpec( } else { sessionSpecBuilder_.setMessage(value); } - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return this; } @@ -40443,7 +41255,7 @@ public Builder setSessionSpec( } else { sessionSpecBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return this; } @@ -40463,7 +41275,7 @@ public Builder setSessionSpec( public Builder mergeSessionSpec( com.google.cloud.discoveryengine.v1beta.SearchRequest.SessionSpec value) { if (sessionSpecBuilder_ == null) { - if (((bitField0_ & 0x20000000) != 0) + if (((bitField0_ & 0x40000000) != 0) && sessionSpec_ != null && sessionSpec_ != com.google.cloud.discoveryengine.v1beta.SearchRequest.SessionSpec @@ -40476,7 +41288,7 @@ public Builder mergeSessionSpec( sessionSpecBuilder_.mergeFrom(value); } if (sessionSpec_ != null) { - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); } return this; @@ -40495,7 +41307,7 @@ public Builder mergeSessionSpec( * */ public Builder clearSessionSpec() { - bitField0_ = (bitField0_ & ~0x20000000); + bitField0_ = (bitField0_ & ~0x40000000); sessionSpec_ = null; if (sessionSpecBuilder_ != null) { sessionSpecBuilder_.dispose(); @@ -40519,7 +41331,7 @@ public Builder clearSessionSpec() { */ public com.google.cloud.discoveryengine.v1beta.SearchRequest.SessionSpec.Builder getSessionSpecBuilder() { - bitField0_ |= 0x20000000; + bitField0_ |= 0x40000000; onChanged(); return getSessionSpecFieldBuilder().getBuilder(); } @@ -40620,7 +41432,7 @@ public int getRelevanceThresholdValue() { */ public Builder setRelevanceThresholdValue(int value) { relevanceThreshold_ = value; - bitField0_ |= 0x40000000; + bitField0_ |= 0x80000000; onChanged(); return this; } @@ -40676,7 +41488,7 @@ public Builder setRelevanceThreshold( if (value == null) { throw new NullPointerException(); } - bitField0_ |= 0x40000000; + bitField0_ |= 0x80000000; relevanceThreshold_ = value.getNumber(); onChanged(); return this; @@ -40700,7 +41512,7 @@ public Builder setRelevanceThreshold( * @return This builder for chaining. */ public Builder clearRelevanceThreshold() { - bitField0_ = (bitField0_ & ~0x40000000); + bitField0_ = (bitField0_ & ~0x80000000); relevanceThreshold_ = 0; onChanged(); return this; @@ -40737,7 +41549,7 @@ public Builder clearRelevanceThreshold() { * @return Whether the personalizationSpec field is set. */ public boolean hasPersonalizationSpec() { - return ((bitField0_ & 0x80000000) != 0); + return ((bitField1_ & 0x00000001) != 0); } /** @@ -40804,7 +41616,7 @@ public Builder setPersonalizationSpec( } else { personalizationSpecBuilder_.setMessage(value); } - bitField0_ |= 0x80000000; + bitField1_ |= 0x00000001; onChanged(); return this; } @@ -40837,7 +41649,7 @@ public Builder setPersonalizationSpec( } else { personalizationSpecBuilder_.setMessage(builderForValue.build()); } - bitField0_ |= 0x80000000; + bitField1_ |= 0x00000001; onChanged(); return this; } @@ -40865,7 +41677,7 @@ public Builder setPersonalizationSpec( public Builder mergePersonalizationSpec( com.google.cloud.discoveryengine.v1beta.SearchRequest.PersonalizationSpec value) { if (personalizationSpecBuilder_ == null) { - if (((bitField0_ & 0x80000000) != 0) + if (((bitField1_ & 0x00000001) != 0) && personalizationSpec_ != null && personalizationSpec_ != com.google.cloud.discoveryengine.v1beta.SearchRequest.PersonalizationSpec @@ -40878,7 +41690,7 @@ public Builder mergePersonalizationSpec( personalizationSpecBuilder_.mergeFrom(value); } if (personalizationSpec_ != null) { - bitField0_ |= 0x80000000; + bitField1_ |= 0x00000001; onChanged(); } return this; @@ -40905,7 +41717,7 @@ public Builder mergePersonalizationSpec( * */ public Builder clearPersonalizationSpec() { - bitField0_ = (bitField0_ & ~0x80000000); + bitField1_ = (bitField1_ & ~0x00000001); personalizationSpec_ = null; if (personalizationSpecBuilder_ != null) { personalizationSpecBuilder_.dispose(); @@ -40937,7 +41749,7 @@ public Builder clearPersonalizationSpec() { */ public com.google.cloud.discoveryengine.v1beta.SearchRequest.PersonalizationSpec.Builder getPersonalizationSpecBuilder() { - bitField0_ |= 0x80000000; + bitField1_ |= 0x00000001; onChanged(); return getPersonalizationSpecFieldBuilder().getBuilder(); } diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequestOrBuilder.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequestOrBuilder.java index 2c69c84dbf8b..ae9236d07f96 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequestOrBuilder.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchRequestOrBuilder.java @@ -1124,8 +1124,14 @@ com.google.protobuf.Value getParamsOrDefault( * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -1140,13 +1146,71 @@ com.google.protobuf.Value getParamsOrDefault( * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -1162,8 +1226,14 @@ com.google.protobuf.Value getParamsOrDefault( * The ranking expression controls the customized ranking on retrieval * documents. This overrides * [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - * The ranking expression is a single function or multiple functions that are - * joined by "+". + * The syntax and supported features depend on the + * `ranking_expression_backend` value. If `ranking_expression_backend` is not + * provided, it defaults to `RANK_BY_EMBEDDING`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + * function or multiple functions that are joined by "+". * * * ranking_expression = function, { " + ", function }; * @@ -1178,13 +1248,71 @@ com.google.protobuf.Value getParamsOrDefault( * between query and document. * * `embedding_field_path`: the document embedding field * used with query embedding vector. - * * `dotProduct`: embedding function between embedding_field_path and query - * embedding vector. + * * `dotProduct`: embedding function between `embedding_field_path` and + * query embedding vector. * * Example ranking expression: * * If document has an embedding field doc_embedding, the ranking expression * could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + * + * If + * [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + * is set to `RANK_BY_FORMULA`, the following expression types (and + * combinations of those chained using + or + * * operators) are supported: + * + * * `double` + * * `signal` + * * `log(signal)` + * * `exp(signal)` + * * `rr(signal, double > 0)` -- reciprocal rank transformation with second + * argument being a denominator constant. + * * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + * * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + * signal2 | double, else returns signal1. + * + * Here are a few examples of ranking formulas that use the supported + * ranking expression types: + * + * - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + * -- mostly rank by the logarithm of `keyword_similarity_score` with slight + * `semantic_smilarity_score` adjustment. + * - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + * is_nan(keyword_similarity_score)` -- rank by the exponent of + * `semantic_similarity_score` filling the value with 0 if it's NaN, also + * add constant 0.3 adjustment to the final score if + * `semantic_similarity_score` is NaN. + * - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + * rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + * of `keyword_similarity_score` with slight adjustment of reciprocal rank + * of `semantic_smilarity_score`. + * + * The following signals are supported: + * + * * `semantic_similarity_score`: semantic similarity adjustment that is + * calculated using the embeddings generated by a proprietary Google model. + * This score determines how semantically similar a search query is to a + * document. + * * `keyword_similarity_score`: keyword match adjustment uses the Best + * Match 25 (BM25) ranking function. This score is calculated using a + * probabilistic model to estimate the probability that a document is + * relevant to a given query. + * * `relevance_score`: semantic relevance adjustment that uses a + * proprietary Google model to determine the meaning and intent behind a + * user's query in context with the content in the documents. + * * `pctr_rank`: predicted conversion rate adjustment as a rank use + * predicted Click-through rate (pCTR) to gauge the relevance and + * attractiveness of a search result from a user's perspective. A higher + * pCTR suggests that the result is more likely to satisfy the user's query + * and intent, making it a valuable signal for ranking. + * * `freshness_rank`: freshness adjustment as a rank + * * `document_age`: The time in hours elapsed since the document was last + * updated, a floating-point number (e.g., 0.25 means 15 minutes). + * * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + * Google model to determine the keyword-based overlap between the query and + * the document. + * * `base_rank`: the default rank of the result * * * string ranking_expression = 26; @@ -1193,6 +1321,37 @@ com.google.protobuf.Value getParamsOrDefault( */ com.google.protobuf.ByteString getRankingExpressionBytes(); + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The enum numeric value on the wire for rankingExpressionBackend. + */ + int getRankingExpressionBackendValue(); + + /** + * + * + *
        +   * The backend to use for the ranking expression evaluation.
        +   * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend ranking_expression_backend = 53 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankingExpressionBackend. + */ + com.google.cloud.discoveryengine.v1beta.SearchRequest.RankingExpressionBackend + getRankingExpressionBackend(); + /** * * diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchResponse.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchResponse.java index 06df83a1ae86..a13bb53864f9 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchResponse.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchResponse.java @@ -262,6 +262,51 @@ com.google.cloud.discoveryengine.v1beta.DoubleList getModelScoresOrDefault( * */ com.google.cloud.discoveryengine.v1beta.DoubleList getModelScoresOrThrow(java.lang.String key); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + boolean hasRankSignals(); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + getRankSignals(); + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder(); } /** @@ -284,41 +329,3366 @@ private SearchResult(com.google.protobuf.GeneratedMessageV3.Builder builder) super(builder); } - private SearchResult() { - id_ = ""; - } + private SearchResult() { + id_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SearchResult(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_descriptor; + } + + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( + int number) { + switch (number) { + case 4: + return internalGetModelScores(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.class, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.Builder.class); + } + + public interface RankSignalsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + boolean hasKeywordSimilarityScore(); + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + float getKeywordSimilarityScore(); + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the relevanceScore field is set. + */ + boolean hasRelevanceScore(); + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The relevanceScore. + */ + float getRelevanceScore(); + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + boolean hasSemanticSimilarityScore(); + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + float getSemanticSimilarityScore(); + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + boolean hasPctrRank(); + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + float getPctrRank(); + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the topicalityRank field is set. + */ + boolean hasTopicalityRank(); + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topicalityRank. + */ + float getTopicalityRank(); + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + boolean hasDocumentAge(); + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + float getDocumentAge(); + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the boostingFactor field is set. + */ + boolean hasBoostingFactor(); + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The boostingFactor. + */ + float getBoostingFactor(); + + /** + * + * + *
        +       * The default rank of the result.
        +       * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + float getDefaultRank(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal + getCustomSignals(int index); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + int getCustomSignalsCount(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + java.util.List< + ? extends + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList(); + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index); + } + + /** + * + * + *
        +     * A set of ranking signals.
        +     * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals} + */ + public static final class RankSignals extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) + RankSignalsOrBuilder { + private static final long serialVersionUID = 0L; + + // Use RankSignals.newBuilder() to construct. + private RankSignals(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private RankSignals() { + customSignals_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new RankSignals(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .class, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .Builder.class); + } + + public interface CustomSignalOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +         * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +         * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + float getValue(); + } + + /** + * + * + *
        +       * Custom clearbox signal represented by name and value pair.
        +       * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal} + */ + public static final class CustomSignal extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal) + CustomSignalOrBuilder { + private static final long serialVersionUID = 0L; + + // Use CustomSignal.newBuilder() to construct. + private CustomSignal(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CustomSignal() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CustomSignal(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.class, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +         * Name of the signal.
        +         * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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 VALUE_FIELD_NUMBER = 2; + private float value_ = 0F; + + /** + * + * + *
        +         * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +         * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + @java.lang.Override + public float getValue() { + return value_; + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (java.lang.Float.floatToRawIntBits(value_) != 0) { + output.writeFloat(2, value_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (java.lang.Float.floatToRawIntBits(value_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, 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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal)) { + return super.equals(obj); + } + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + other = + (com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal) + obj; + + if (!getName().equals(other.getName())) return false; + if (java.lang.Float.floatToIntBits(getValue()) + != java.lang.Float.floatToIntBits(other.getValue())) 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) + VALUE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getValue()); + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + 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.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + 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.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +         * Custom clearbox signal represented by name and value pair.
        +         * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal) + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.class, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder.class); + } + + // Construct using + // com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + value_ = 0F; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstanceForType() { + return com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + build() { + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + buildPartial() { + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + result = + new com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.value_ = value_; + } + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal) { + return mergeFrom( + (com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + other) { + if (other + == com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getValue() != 0F) { + setValue(other.getValue()); + } + 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 21: + { + value_ = input.readFloat(); + bitField0_ |= 0x00000002; + break; + } // case 21 + 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_ = ""; + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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; + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +           * Name of the signal.
        +           * 
        + * + * string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * @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 float value_; + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The value. + */ + @java.lang.Override + public float getValue() { + return value_; + } + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The value to set. + * @return This builder for chaining. + */ + public Builder setValue(float value) { + + value_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +           * Float value representing the ranking signal (e.g. 1.25 for BM25).
        +           * 
        + * + * float value = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearValue() { + bitField0_ = (bitField0_ & ~0x00000002); + value_ = 0F; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal) + } + + // @@protoc_insertion_point(class_scope:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal) + private static final com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal(); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CustomSignal 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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + private int bitField0_; + public static final int KEYWORD_SIMILARITY_SCORE_FIELD_NUMBER = 1; + private float keywordSimilarityScore_ = 0F; + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasKeywordSimilarityScore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +       * Keyword matching adjustment.
        +       * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + @java.lang.Override + public float getKeywordSimilarityScore() { + return keywordSimilarityScore_; + } + + public static final int RELEVANCE_SCORE_FIELD_NUMBER = 2; + private float relevanceScore_ = 0F; + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the relevanceScore field is set. + */ + @java.lang.Override + public boolean hasRelevanceScore() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +       * Semantic relevance adjustment.
        +       * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The relevanceScore. + */ + @java.lang.Override + public float getRelevanceScore() { + return relevanceScore_; + } + + public static final int SEMANTIC_SIMILARITY_SCORE_FIELD_NUMBER = 3; + private float semanticSimilarityScore_ = 0F; + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasSemanticSimilarityScore() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +       * Semantic similarity adjustment.
        +       * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + @java.lang.Override + public float getSemanticSimilarityScore() { + return semanticSimilarityScore_; + } + + public static final int PCTR_RANK_FIELD_NUMBER = 4; + private float pctrRank_ = 0F; + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + @java.lang.Override + public boolean hasPctrRank() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +       * Predicted conversion rate adjustment as a rank.
        +       * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + @java.lang.Override + public float getPctrRank() { + return pctrRank_; + } + + public static final int TOPICALITY_RANK_FIELD_NUMBER = 6; + private float topicalityRank_ = 0F; + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the topicalityRank field is set. + */ + @java.lang.Override + public boolean hasTopicalityRank() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +       * Topicality adjustment as a rank.
        +       * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The topicalityRank. + */ + @java.lang.Override + public float getTopicalityRank() { + return topicalityRank_; + } + + public static final int DOCUMENT_AGE_FIELD_NUMBER = 7; + private float documentAge_ = 0F; + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + @java.lang.Override + public boolean hasDocumentAge() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
        +       * Age of the document in hours.
        +       * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + @java.lang.Override + public float getDocumentAge() { + return documentAge_; + } + + public static final int BOOSTING_FACTOR_FIELD_NUMBER = 8; + private float boostingFactor_ = 0F; + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the boostingFactor field is set. + */ + @java.lang.Override + public boolean hasBoostingFactor() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
        +       * Combined custom boosts for a doc.
        +       * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The boostingFactor. + */ + @java.lang.Override + public float getBoostingFactor() { + return boostingFactor_; + } + + public static final int DEFAULT_RANK_FIELD_NUMBER = 32; + private float defaultRank_ = 0F; + + /** + * + * + *
        +       * The default rank of the result.
        +       * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + @java.lang.Override + public float getDefaultRank() { + return defaultRank_; + } + + public static final int CUSTOM_SIGNALS_FIELD_NUMBER = 33; + + @SuppressWarnings("serial") + private java.util.List< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal> + customSignals_; + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList() { + return customSignals_; + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList() { + return customSignals_; + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public int getCustomSignalsCount() { + return customSignals_.size(); + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + getCustomSignals(int index) { + return customSignals_.get(index); + } + + /** + * + * + *
        +       * A list of custom clearbox signals.
        +       * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index) { + return customSignals_.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 { + if (((bitField0_ & 0x00000001) != 0)) { + output.writeFloat(1, keywordSimilarityScore_); + } + if (((bitField0_ & 0x00000002) != 0)) { + output.writeFloat(2, relevanceScore_); + } + if (((bitField0_ & 0x00000004) != 0)) { + output.writeFloat(3, semanticSimilarityScore_); + } + if (((bitField0_ & 0x00000008) != 0)) { + output.writeFloat(4, pctrRank_); + } + if (((bitField0_ & 0x00000010) != 0)) { + output.writeFloat(6, topicalityRank_); + } + if (((bitField0_ & 0x00000020) != 0)) { + output.writeFloat(7, documentAge_); + } + if (((bitField0_ & 0x00000040) != 0)) { + output.writeFloat(8, boostingFactor_); + } + if (java.lang.Float.floatToRawIntBits(defaultRank_) != 0) { + output.writeFloat(32, defaultRank_); + } + for (int i = 0; i < customSignals_.size(); i++) { + output.writeMessage(33, customSignals_.get(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.computeFloatSize(1, keywordSimilarityScore_); + } + if (((bitField0_ & 0x00000002) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, relevanceScore_); + } + if (((bitField0_ & 0x00000004) != 0)) { + size += + com.google.protobuf.CodedOutputStream.computeFloatSize(3, semanticSimilarityScore_); + } + if (((bitField0_ & 0x00000008) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(4, pctrRank_); + } + if (((bitField0_ & 0x00000010) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(6, topicalityRank_); + } + if (((bitField0_ & 0x00000020) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(7, documentAge_); + } + if (((bitField0_ & 0x00000040) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(8, boostingFactor_); + } + if (java.lang.Float.floatToRawIntBits(defaultRank_) != 0) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(32, defaultRank_); + } + for (int i = 0; i < customSignals_.size(); i++) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(33, customSignals_.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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals)) { + return super.equals(obj); + } + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals other = + (com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) obj; + + if (hasKeywordSimilarityScore() != other.hasKeywordSimilarityScore()) return false; + if (hasKeywordSimilarityScore()) { + if (java.lang.Float.floatToIntBits(getKeywordSimilarityScore()) + != java.lang.Float.floatToIntBits(other.getKeywordSimilarityScore())) return false; + } + if (hasRelevanceScore() != other.hasRelevanceScore()) return false; + if (hasRelevanceScore()) { + if (java.lang.Float.floatToIntBits(getRelevanceScore()) + != java.lang.Float.floatToIntBits(other.getRelevanceScore())) return false; + } + if (hasSemanticSimilarityScore() != other.hasSemanticSimilarityScore()) return false; + if (hasSemanticSimilarityScore()) { + if (java.lang.Float.floatToIntBits(getSemanticSimilarityScore()) + != java.lang.Float.floatToIntBits(other.getSemanticSimilarityScore())) return false; + } + if (hasPctrRank() != other.hasPctrRank()) return false; + if (hasPctrRank()) { + if (java.lang.Float.floatToIntBits(getPctrRank()) + != java.lang.Float.floatToIntBits(other.getPctrRank())) return false; + } + if (hasTopicalityRank() != other.hasTopicalityRank()) return false; + if (hasTopicalityRank()) { + if (java.lang.Float.floatToIntBits(getTopicalityRank()) + != java.lang.Float.floatToIntBits(other.getTopicalityRank())) return false; + } + if (hasDocumentAge() != other.hasDocumentAge()) return false; + if (hasDocumentAge()) { + if (java.lang.Float.floatToIntBits(getDocumentAge()) + != java.lang.Float.floatToIntBits(other.getDocumentAge())) return false; + } + if (hasBoostingFactor() != other.hasBoostingFactor()) return false; + if (hasBoostingFactor()) { + if (java.lang.Float.floatToIntBits(getBoostingFactor()) + != java.lang.Float.floatToIntBits(other.getBoostingFactor())) return false; + } + if (java.lang.Float.floatToIntBits(getDefaultRank()) + != java.lang.Float.floatToIntBits(other.getDefaultRank())) return false; + if (!getCustomSignalsList().equals(other.getCustomSignalsList())) 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 (hasKeywordSimilarityScore()) { + hash = (37 * hash) + KEYWORD_SIMILARITY_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getKeywordSimilarityScore()); + } + if (hasRelevanceScore()) { + hash = (37 * hash) + RELEVANCE_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getRelevanceScore()); + } + if (hasSemanticSimilarityScore()) { + hash = (37 * hash) + SEMANTIC_SIMILARITY_SCORE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getSemanticSimilarityScore()); + } + if (hasPctrRank()) { + hash = (37 * hash) + PCTR_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getPctrRank()); + } + if (hasTopicalityRank()) { + hash = (37 * hash) + TOPICALITY_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getTopicalityRank()); + } + if (hasDocumentAge()) { + hash = (37 * hash) + DOCUMENT_AGE_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getDocumentAge()); + } + if (hasBoostingFactor()) { + hash = (37 * hash) + BOOSTING_FACTOR_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getBoostingFactor()); + } + hash = (37 * hash) + DEFAULT_RANK_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getDefaultRank()); + if (getCustomSignalsCount() > 0) { + hash = (37 * hash) + CUSTOM_SIGNALS_FIELD_NUMBER; + hash = (53 * hash) + getCustomSignalsList().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + 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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + 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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +       * A set of ranking signals.
        +       * 
        + * + * Protobuf type {@code + * google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignalsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .class, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .Builder.class); + } + + // Construct using + // com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + keywordSimilarityScore_ = 0F; + relevanceScore_ = 0F; + semanticSimilarityScore_ = 0F; + pctrRank_ = 0F; + topicalityRank_ = 0F; + documentAge_ = 0F; + boostingFactor_ = 0F; + defaultRank_ = 0F; + if (customSignalsBuilder_ == null) { + customSignals_ = java.util.Collections.emptyList(); + } else { + customSignals_ = null; + customSignalsBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000100); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.discoveryengine.v1beta.SearchServiceProto + .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + getDefaultInstanceForType() { + return com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + build() { + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + buildPartial() { + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals result = + new com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals( + this); + buildPartialRepeatedFields(result); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartialRepeatedFields( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + result) { + if (customSignalsBuilder_ == null) { + if (((bitField0_ & 0x00000100) != 0)) { + customSignals_ = java.util.Collections.unmodifiableList(customSignals_); + bitField0_ = (bitField0_ & ~0x00000100); + } + result.customSignals_ = customSignals_; + } else { + result.customSignals_ = customSignalsBuilder_.build(); + } + } + + private void buildPartial0( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + result) { + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.keywordSimilarityScore_ = keywordSimilarityScore_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.relevanceScore_ = relevanceScore_; + to_bitField0_ |= 0x00000002; + } + if (((from_bitField0_ & 0x00000004) != 0)) { + result.semanticSimilarityScore_ = semanticSimilarityScore_; + to_bitField0_ |= 0x00000004; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.pctrRank_ = pctrRank_; + to_bitField0_ |= 0x00000008; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.topicalityRank_ = topicalityRank_; + to_bitField0_ |= 0x00000010; + } + if (((from_bitField0_ & 0x00000020) != 0)) { + result.documentAge_ = documentAge_; + to_bitField0_ |= 0x00000020; + } + if (((from_bitField0_ & 0x00000040) != 0)) { + result.boostingFactor_ = boostingFactor_; + to_bitField0_ |= 0x00000040; + } + if (((from_bitField0_ & 0x00000080) != 0)) { + result.defaultRank_ = defaultRank_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, + int index, + java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) { + return mergeFrom( + (com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals other) { + if (other + == com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance()) return this; + if (other.hasKeywordSimilarityScore()) { + setKeywordSimilarityScore(other.getKeywordSimilarityScore()); + } + if (other.hasRelevanceScore()) { + setRelevanceScore(other.getRelevanceScore()); + } + if (other.hasSemanticSimilarityScore()) { + setSemanticSimilarityScore(other.getSemanticSimilarityScore()); + } + if (other.hasPctrRank()) { + setPctrRank(other.getPctrRank()); + } + if (other.hasTopicalityRank()) { + setTopicalityRank(other.getTopicalityRank()); + } + if (other.hasDocumentAge()) { + setDocumentAge(other.getDocumentAge()); + } + if (other.hasBoostingFactor()) { + setBoostingFactor(other.getBoostingFactor()); + } + if (other.getDefaultRank() != 0F) { + setDefaultRank(other.getDefaultRank()); + } + if (customSignalsBuilder_ == null) { + if (!other.customSignals_.isEmpty()) { + if (customSignals_.isEmpty()) { + customSignals_ = other.customSignals_; + bitField0_ = (bitField0_ & ~0x00000100); + } else { + ensureCustomSignalsIsMutable(); + customSignals_.addAll(other.customSignals_); + } + onChanged(); + } + } else { + if (!other.customSignals_.isEmpty()) { + if (customSignalsBuilder_.isEmpty()) { + customSignalsBuilder_.dispose(); + customSignalsBuilder_ = null; + customSignals_ = other.customSignals_; + bitField0_ = (bitField0_ & ~0x00000100); + customSignalsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getCustomSignalsFieldBuilder() + : null; + } else { + customSignalsBuilder_.addAllMessages(other.customSignals_); + } + } + } + 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 13: + { + keywordSimilarityScore_ = input.readFloat(); + bitField0_ |= 0x00000001; + break; + } // case 13 + case 21: + { + relevanceScore_ = input.readFloat(); + bitField0_ |= 0x00000002; + break; + } // case 21 + case 29: + { + semanticSimilarityScore_ = input.readFloat(); + bitField0_ |= 0x00000004; + break; + } // case 29 + case 37: + { + pctrRank_ = input.readFloat(); + bitField0_ |= 0x00000008; + break; + } // case 37 + case 53: + { + topicalityRank_ = input.readFloat(); + bitField0_ |= 0x00000010; + break; + } // case 53 + case 61: + { + documentAge_ = input.readFloat(); + bitField0_ |= 0x00000020; + break; + } // case 61 + case 69: + { + boostingFactor_ = input.readFloat(); + bitField0_ |= 0x00000040; + break; + } // case 69 + case 261: + { + defaultRank_ = input.readFloat(); + bitField0_ |= 0x00000080; + break; + } // case 261 + case 266: + { + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + m = + input.readMessage( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal.parser(), + extensionRegistry); + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(m); + } else { + customSignalsBuilder_.addMessage(m); + } + break; + } // case 266 + 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 float keywordSimilarityScore_; + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the keywordSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasKeywordSimilarityScore() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The keywordSimilarityScore. + */ + @java.lang.Override + public float getKeywordSimilarityScore() { + return keywordSimilarityScore_; + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The keywordSimilarityScore to set. + * @return This builder for chaining. + */ + public Builder setKeywordSimilarityScore(float value) { + + keywordSimilarityScore_ = value; + bitField0_ |= 0x00000001; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Keyword matching adjustment.
        +         * 
        + * + * + * optional float keyword_similarity_score = 1 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearKeywordSimilarityScore() { + bitField0_ = (bitField0_ & ~0x00000001); + keywordSimilarityScore_ = 0F; + onChanged(); + return this; + } + + private float relevanceScore_; + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the relevanceScore field is set. + */ + @java.lang.Override + public boolean hasRelevanceScore() { + return ((bitField0_ & 0x00000002) != 0); + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The relevanceScore. + */ + @java.lang.Override + public float getRelevanceScore() { + return relevanceScore_; + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The relevanceScore to set. + * @return This builder for chaining. + */ + public Builder setRelevanceScore(float value) { + + relevanceScore_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Semantic relevance adjustment.
        +         * 
        + * + * optional float relevance_score = 2 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearRelevanceScore() { + bitField0_ = (bitField0_ & ~0x00000002); + relevanceScore_ = 0F; + onChanged(); + return this; + } + + private float semanticSimilarityScore_; + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the semanticSimilarityScore field is set. + */ + @java.lang.Override + public boolean hasSemanticSimilarityScore() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The semanticSimilarityScore. + */ + @java.lang.Override + public float getSemanticSimilarityScore() { + return semanticSimilarityScore_; + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The semanticSimilarityScore to set. + * @return This builder for chaining. + */ + public Builder setSemanticSimilarityScore(float value) { + + semanticSimilarityScore_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Semantic similarity adjustment.
        +         * 
        + * + * + * optional float semantic_similarity_score = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearSemanticSimilarityScore() { + bitField0_ = (bitField0_ & ~0x00000004); + semanticSimilarityScore_ = 0F; + onChanged(); + return this; + } + + private float pctrRank_; + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the pctrRank field is set. + */ + @java.lang.Override + public boolean hasPctrRank() { + return ((bitField0_ & 0x00000008) != 0); + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The pctrRank. + */ + @java.lang.Override + public float getPctrRank() { + return pctrRank_; + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The pctrRank to set. + * @return This builder for chaining. + */ + public Builder setPctrRank(float value) { + + pctrRank_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Predicted conversion rate adjustment as a rank.
        +         * 
        + * + * optional float pctr_rank = 4 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearPctrRank() { + bitField0_ = (bitField0_ & ~0x00000008); + pctrRank_ = 0F; + onChanged(); + return this; + } + + private float topicalityRank_; + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the topicalityRank field is set. + */ + @java.lang.Override + public boolean hasTopicalityRank() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The topicalityRank. + */ + @java.lang.Override + public float getTopicalityRank() { + return topicalityRank_; + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The topicalityRank to set. + * @return This builder for chaining. + */ + public Builder setTopicalityRank(float value) { + + topicalityRank_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Topicality adjustment as a rank.
        +         * 
        + * + * optional float topicality_rank = 6 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearTopicalityRank() { + bitField0_ = (bitField0_ & ~0x00000010); + topicalityRank_ = 0F; + onChanged(); + return this; + } + + private float documentAge_; + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return Whether the documentAge field is set. + */ + @java.lang.Override + public boolean hasDocumentAge() { + return ((bitField0_ & 0x00000020) != 0); + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The documentAge. + */ + @java.lang.Override + public float getDocumentAge() { + return documentAge_; + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The documentAge to set. + * @return This builder for chaining. + */ + public Builder setDocumentAge(float value) { + + documentAge_ = value; + bitField0_ |= 0x00000020; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Age of the document in hours.
        +         * 
        + * + * optional float document_age = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDocumentAge() { + bitField0_ = (bitField0_ & ~0x00000020); + documentAge_ = 0F; + onChanged(); + return this; + } + + private float boostingFactor_; + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the boostingFactor field is set. + */ + @java.lang.Override + public boolean hasBoostingFactor() { + return ((bitField0_ & 0x00000040) != 0); + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The boostingFactor. + */ + @java.lang.Override + public float getBoostingFactor() { + return boostingFactor_; + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @param value The boostingFactor to set. + * @return This builder for chaining. + */ + public Builder setBoostingFactor(float value) { + + boostingFactor_ = value; + bitField0_ |= 0x00000040; + onChanged(); + return this; + } + + /** + * + * + *
        +         * Combined custom boosts for a doc.
        +         * 
        + * + * optional float boosting_factor = 8 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return This builder for chaining. + */ + public Builder clearBoostingFactor() { + bitField0_ = (bitField0_ & ~0x00000040); + boostingFactor_ = 0F; + onChanged(); + return this; + } + + private float defaultRank_; + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return The defaultRank. + */ + @java.lang.Override + public float getDefaultRank() { + return defaultRank_; + } + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @param value The defaultRank to set. + * @return This builder for chaining. + */ + public Builder setDefaultRank(float value) { + + defaultRank_ = value; + bitField0_ |= 0x00000080; + onChanged(); + return this; + } + + /** + * + * + *
        +         * The default rank of the result.
        +         * 
        + * + * float default_rank = 32 [(.google.api.field_behavior) = OPTIONAL]; + * + * @return This builder for chaining. + */ + public Builder clearDefaultRank() { + bitField0_ = (bitField0_ & ~0x00000080); + defaultRank_ = 0F; + onChanged(); + return this; + } + + private java.util.List< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal> + customSignals_ = java.util.Collections.emptyList(); + + private void ensureCustomSignalsIsMutable() { + if (!((bitField0_ & 0x00000100) != 0)) { + customSignals_ = + new java.util.ArrayList< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal>(customSignals_); + bitField0_ |= 0x00000100; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + customSignalsBuilder_; + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal> + getCustomSignalsList() { + if (customSignalsBuilder_ == null) { + return java.util.Collections.unmodifiableList(customSignals_); + } else { + return customSignalsBuilder_.getMessageList(); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public int getCustomSignalsCount() { + if (customSignalsBuilder_ == null) { + return customSignals_.size(); + } else { + return customSignalsBuilder_.getCount(); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + getCustomSignals(int index) { + if (customSignalsBuilder_ == null) { + return customSignals_.get(index); + } else { + return customSignalsBuilder_.getMessage(index); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCustomSignals( + int index, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.set(index, value); + onChanged(); + } else { + customSignalsBuilder_.setMessage(index, value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCustomSignals( + int index, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.set(index, builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.add(value); + onChanged(); + } else { + customSignalsBuilder_.addMessage(value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + int index, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal + value) { + if (customSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureCustomSignalsIsMutable(); + customSignals_.add(index, value); + onChanged(); + } else { + customSignalsBuilder_.addMessage(index, value); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addCustomSignals( + int index, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + builderForValue) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.add(index, builderForValue.build()); + onChanged(); + } else { + customSignalsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder addAllCustomSignals( + java.lang.Iterable< + ? extends + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals.CustomSignal> + values) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, customSignals_); + onChanged(); + } else { + customSignalsBuilder_.addAllMessages(values); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearCustomSignals() { + if (customSignalsBuilder_ == null) { + customSignals_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000100); + onChanged(); + } else { + customSignalsBuilder_.clear(); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder removeCustomSignals(int index) { + if (customSignalsBuilder_ == null) { + ensureCustomSignalsIsMutable(); + customSignals_.remove(index); + onChanged(); + } else { + customSignalsBuilder_.remove(index); + } + return this; + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + getCustomSignalsBuilder(int index) { + return getCustomSignalsFieldBuilder().getBuilder(index); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder + getCustomSignalsOrBuilder(int index) { + if (customSignalsBuilder_ == null) { + return customSignals_.get(index); + } else { + return customSignalsBuilder_.getMessageOrBuilder(index); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + ? extends + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsOrBuilderList() { + if (customSignalsBuilder_ != null) { + return customSignalsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(customSignals_); + } + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + addCustomSignalsBuilder() { + return getCustomSignalsFieldBuilder() + .addBuilder( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder + addCustomSignalsBuilder(int index) { + return getCustomSignalsFieldBuilder() + .addBuilder( + index, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.getDefaultInstance()); + } + + /** + * + * + *
        +         * A list of custom clearbox signals.
        +         * 
        + * + * + * repeated .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignal custom_signals = 33 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public java.util.List< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder> + getCustomSignalsBuilderList() { + return getCustomSignalsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder> + getCustomSignalsFieldBuilder() { + if (customSignalsBuilder_ == null) { + customSignalsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignal.Builder, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .CustomSignalOrBuilder>( + customSignals_, + ((bitField0_ & 0x00000100) != 0), + getParentForChildren(), + isClean()); + customSignals_ = null; + } + return customSignalsBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) + } + + // @@protoc_insertion_point(class_scope:google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals) + private static final com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignals + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals(); + } + + public static com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + getDefaultInstance() { + return DEFAULT_INSTANCE; + } - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new SearchResult(); - } + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public RankSignals 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 final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.discoveryengine.v1beta.SearchServiceProto - .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_descriptor; - } + public static com.google.protobuf.Parser parser() { + return PARSER; + } - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection( - int number) { - switch (number) { - case 4: - return internalGetModelScores(); - default: - throw new RuntimeException("Invalid map field number: " + number); + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; } - } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.discoveryengine.v1beta.SearchServiceProto - .internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.class, - com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.Builder.class); + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } } private int bitField0_; @@ -621,6 +3991,70 @@ public com.google.cloud.discoveryengine.v1beta.DoubleList getModelScoresOrThrow( return map.get(key); } + public static final int RANK_SIGNALS_FIELD_NUMBER = 7; + private com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + rankSignals_; + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + @java.lang.Override + public boolean hasRankSignals() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + getRankSignals() { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + + /** + * + * + *
        +     * A set of ranking signals associated with the result.
        +     * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignalsOrBuilder + getRankSignalsOrBuilder() { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -643,6 +4077,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetModelScores(), ModelScoresDefaultEntryHolder.defaultEntry, 4); + if (((bitField0_ & 0x00000004) != 0)) { + output.writeMessage(7, getRankSignals()); + } if (((bitField0_ & 0x00000002) != 0)) { output.writeMessage(18, getChunk()); } @@ -673,6 +4110,9 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, modelScores__); } + if (((bitField0_ & 0x00000004) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getRankSignals()); + } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(18, getChunk()); } @@ -702,6 +4142,10 @@ public boolean equals(final java.lang.Object obj) { if (!getChunk().equals(other.getChunk())) return false; } if (!internalGetModelScores().equals(other.internalGetModelScores())) return false; + if (hasRankSignals() != other.hasRankSignals()) return false; + if (hasRankSignals()) { + if (!getRankSignals().equals(other.getRankSignals())) return false; + } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -727,6 +4171,10 @@ public int hashCode() { hash = (37 * hash) + MODEL_SCORES_FIELD_NUMBER; hash = (53 * hash) + internalGetModelScores().hashCode(); } + if (hasRankSignals()) { + hash = (37 * hash) + RANK_SIGNALS_FIELD_NUMBER; + hash = (53 * hash) + getRankSignals().hashCode(); + } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; @@ -897,6 +4345,7 @@ private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getDocumentFieldBuilder(); getChunkFieldBuilder(); + getRankSignalsFieldBuilder(); } } @@ -916,6 +4365,11 @@ public Builder clear() { chunkBuilder_ = null; } internalGetMutableModelScores().clear(); + rankSignals_ = null; + if (rankSignalsBuilder_ != null) { + rankSignalsBuilder_.dispose(); + rankSignalsBuilder_ = null; + } return this; } @@ -971,6 +4425,11 @@ private void buildPartial0( result.modelScores_ = internalGetModelScores().build(ModelScoresDefaultEntryHolder.defaultEntry); } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.rankSignals_ = + rankSignalsBuilder_ == null ? rankSignals_ : rankSignalsBuilder_.build(); + to_bitField0_ |= 0x00000004; + } result.bitField0_ |= to_bitField0_; } @@ -1038,6 +4497,9 @@ public Builder mergeFrom( } internalGetMutableModelScores().mergeFrom(other.internalGetModelScores()); bitField0_ |= 0x00000008; + if (other.hasRankSignals()) { + mergeRankSignals(other.getRankSignals()); + } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; @@ -1090,6 +4552,12 @@ public Builder mergeFrom( bitField0_ |= 0x00000008; break; } // case 34 + case 58: + { + input.readMessage(getRankSignalsFieldBuilder().getBuilder(), extensionRegistry); + bitField0_ |= 0x00000010; + break; + } // case 58 case 146: { input.readMessage(getChunkFieldBuilder().getBuilder(), extensionRegistry); @@ -1916,6 +5384,236 @@ public Builder putAllModelScores( return (com.google.cloud.discoveryengine.v1beta.DoubleList.Builder) entry; } + private com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + rankSignals_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignalsOrBuilder> + rankSignalsBuilder_; + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the rankSignals field is set. + */ + public boolean hasRankSignals() { + return ((bitField0_ & 0x00000010) != 0); + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The rankSignals. + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + getRankSignals() { + if (rankSignalsBuilder_ == null) { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } else { + return rankSignalsBuilder_.getMessage(); + } + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRankSignals( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals value) { + if (rankSignalsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + rankSignals_ = value; + } else { + rankSignalsBuilder_.setMessage(value); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setRankSignals( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.Builder + builderForValue) { + if (rankSignalsBuilder_ == null) { + rankSignals_ = builderForValue.build(); + } else { + rankSignalsBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeRankSignals( + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals value) { + if (rankSignalsBuilder_ == null) { + if (((bitField0_ & 0x00000010) != 0) + && rankSignals_ != null + && rankSignals_ + != com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance()) { + getRankSignalsBuilder().mergeFrom(value); + } else { + rankSignals_ = value; + } + } else { + rankSignalsBuilder_.mergeFrom(value); + } + if (rankSignals_ != null) { + bitField0_ |= 0x00000010; + onChanged(); + } + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearRankSignals() { + bitField0_ = (bitField0_ & ~0x00000010); + rankSignals_ = null; + if (rankSignalsBuilder_ != null) { + rankSignalsBuilder_.dispose(); + rankSignalsBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals.Builder + getRankSignalsBuilder() { + bitField0_ |= 0x00000010; + onChanged(); + return getRankSignalsFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignalsOrBuilder + getRankSignalsOrBuilder() { + if (rankSignalsBuilder_ != null) { + return rankSignalsBuilder_.getMessageOrBuilder(); + } else { + return rankSignals_ == null + ? com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .getDefaultInstance() + : rankSignals_; + } + } + + /** + * + * + *
        +       * A set of ranking signals associated with the result.
        +       * 
        + * + * + * .google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals rank_signals = 7 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignalsOrBuilder> + getRankSignalsFieldBuilder() { + if (rankSignalsBuilder_ == null) { + rankSignalsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignals + .Builder, + com.google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult + .RankSignalsOrBuilder>(getRankSignals(), getParentForChildren(), isClean()); + rankSignals_ = null; + } + return rankSignalsBuilder_; + } + @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchServiceProto.java b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchServiceProto.java index fa908481519d..fed9f4731032 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchServiceProto.java +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/java/com/google/cloud/discoveryengine/v1beta/SearchServiceProto.java @@ -144,6 +144,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_ModelScoresEntry_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_ModelScoresEntry_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_Facet_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -256,7 +264,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "pi/field_behavior.proto\032\031google/api/reso" + "urce.proto\032/google/cloud/discoveryengine/v1beta/chunk.proto\0320google/cloud/discov" + "eryengine/v1beta/common.proto\0322google/cl" - + "oud/discoveryengine/v1beta/document.proto\032\034google/protobuf/struct.proto\"\3024\n\r" + + "oud/discoveryengine/v1beta/document.proto\032\034google/protobuf/struct.proto\"\2706\n\r" + "SearchRequest\022L\n" + "\016serving_config\030\001 \001(\tB4\340A\002\372A.\n" + ",discoveryengine.googleapis.com/ServingConfig\022:\n" @@ -294,23 +302,26 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ine.v1beta.SearchRequest.ContentSearchSpec\022X\n" + "\016embedding_spec\030\027 \001(\0132@.google.clou" + "d.discoveryengine.v1beta.SearchRequest.EmbeddingSpec\022\032\n" - + "\022ranking_expression\030\032 \001(\t\022\023\n" + + "\022ranking_expression\030\032 \001(\t\022t\n" + + "\032ranking_expression_backend\0305 \001(\0162K.g" + + "oogle.cloud.discoveryengine.v1beta.Searc" + + "hRequest.RankingExpressionBackendB\003\340A\001\022\023\n" + "\013safe_search\030\024 \001(\010\022W\n" - + "\013user_labels\030\026 \003" - + "(\0132B.google.cloud.discoveryengine.v1beta.SearchRequest.UserLabelsEntry\022\213\001\n" - + ")natural_language_query_understanding_spec\030\034 \001" - + "(\0132X.google.cloud.discoveryengine.v1beta" - + ".SearchRequest.NaturalLanguageQueryUnderstandingSpec\022g\n" - + "\027search_as_you_type_spec\030\037" - + " \001(\0132F.google.cloud.discoveryengine.v1beta.SearchRequest.SearchAsYouTypeSpec\022<\n" + + "\013user_labels\030\026 \003(\013" + + "2B.google.cloud.discoveryengine.v1beta.SearchRequest.UserLabelsEntry\022\213\001\n" + + ")natural_language_query_understanding_spec\030\034 \001(\013" + + "2X.google.cloud.discoveryengine.v1beta.S" + + "earchRequest.NaturalLanguageQueryUnderstandingSpec\022g\n" + + "\027search_as_you_type_spec\030\037 " + + "\001(\0132F.google.cloud.discoveryengine.v1beta.SearchRequest.SearchAsYouTypeSpec\022<\n" + "\007session\030) \001(\tB+\372A(\n" + "&discoveryengine.googleapis.com/Session\022T\n" - + "\014session_spec\030* \001(" - + "\0132>.google.cloud.discoveryengine.v1beta.SearchRequest.SessionSpec\022b\n" - + "\023relevance_threshold\030, \001(\0162E.google.cloud.discoverye" - + "ngine.v1beta.SearchRequest.RelevanceThreshold\022d\n" - + "\024personalization_spec\030. \001(\0132F.go" - + "ogle.cloud.discoveryengine.v1beta.SearchRequest.PersonalizationSpec\032,\n\n" + + "\014session_spec\030* \001(\0132" + + ">.google.cloud.discoveryengine.v1beta.SearchRequest.SessionSpec\022b\n" + + "\023relevance_threshold\030, \001(\0162E.google.cloud.discoveryeng" + + "ine.v1beta.SearchRequest.RelevanceThreshold\022d\n" + + "\024personalization_spec\030. \001(\0132F.goog" + + "le.cloud.discoveryengine.v1beta.SearchRequest.PersonalizationSpec\032,\n\n" + "ImageQuery\022\025\n" + "\013image_bytes\030\001 \001(\tH\000B\007\n" + "\005image\032j\n\r" @@ -319,8 +330,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "(discoveryengine.googleapis.com/DataStore\022\023\n" + "\006filter\030\005 \001(\tB\003\340A\001\032\204\003\n" + "\tFacetSpec\022]\n" - + "\tfacet_key\030\001 \001(\0132E.google.cloud.discoverye" - + "ngine.v1beta.SearchRequest.FacetSpec.FacetKeyB\003\340A\002\022\r\n" + + "\tfacet_key\030\001 \001(\0132E.google.cloud.discoveryeng" + + "ine.v1beta.SearchRequest.FacetSpec.FacetKeyB\003\340A\002\022\r\n" + "\005limit\030\002 \001(\005\022\034\n" + "\024excluded_filter_keys\030\003 \003(\t\022\037\n" + "\027enable_dynamic_position\030\004 \001(\010\032\311\001\n" @@ -333,25 +344,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\020case_insensitive\030\006 \001(\010\022\020\n" + "\010order_by\030\007 \001(\t\032\320\007\n" + "\tBoostSpec\022n\n" - + "\025condition_boost_specs\030\001 \003(\0132O.google.cloud.discove" - + "ryengine.v1beta.SearchRequest.BoostSpec.ConditionBoostSpec\032\322\006\n" + + "\025condition_boost_specs\030\001 \003(\0132O.google.cloud.discovery" + + "engine.v1beta.SearchRequest.BoostSpec.ConditionBoostSpec\032\322\006\n" + "\022ConditionBoostSpec\022\021\n" + "\tcondition\030\001 \001(\t\022\r\n" + "\005boost\030\002 \001(\002\022|\n" - + "\022boost_control_spec\030\003 \001(\0132`.google.cloud.d" - + "iscoveryengine.v1beta.SearchRequest.Boos" - + "tSpec.ConditionBoostSpec.BoostControlSpec\032\233\005\n" + + "\022boost_control_spec\030\003 \001(\0132`.google.cloud.dis" + + "coveryengine.v1beta.SearchRequest.BoostS" + + "pec.ConditionBoostSpec.BoostControlSpec\032\233\005\n" + "\020BoostControlSpec\022\022\n\n" + "field_name\030\001 \001(\t\022\206\001\n" - + "\016attribute_type\030\002 \001(\0162n.google.clo" + + "\016attribute_type\030\002 \001(\0162n.google.cloud" + + ".discoveryengine.v1beta.SearchRequest.Bo" + + "ostSpec.ConditionBoostSpec.BoostControlSpec.AttributeType\022\216\001\n" + + "\022interpolation_type\030\003 \001(\0162r.google.cloud.discoveryengine.v1" + + "beta.SearchRequest.BoostSpec.ConditionBo" + + "ostSpec.BoostControlSpec.InterpolationType\022\205\001\n" + + "\016control_points\030\004 \003(\0132m.google.clo" + "ud.discoveryengine.v1beta.SearchRequest." - + "BoostSpec.ConditionBoostSpec.BoostControlSpec.AttributeType\022\216\001\n" - + "\022interpolation_type\030\003 \001(\0162r.google.cloud.discoveryengine." - + "v1beta.SearchRequest.BoostSpec.Condition" - + "BoostSpec.BoostControlSpec.InterpolationType\022\205\001\n" - + "\016control_points\030\004 \003(\0132m.google.c" - + "loud.discoveryengine.v1beta.SearchReques" - + "t.BoostSpec.ConditionBoostSpec.BoostControlSpec.ControlPoint\032=\n" + + "BoostSpec.ConditionBoostSpec.BoostControlSpec.ControlPoint\032=\n" + "\014ControlPoint\022\027\n" + "\017attribute_value\030\001 \001(\t\022\024\n" + "\014boost_amount\030\002 \001(\002\"M\n\r" @@ -363,31 +374,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\036INTERPOLATION_TYPE_UNSPECIFIED\020\000\022\n\n" + "\006LINEAR\020\001\032\330\001\n" + "\022QueryExpansionSpec\022b\n" - + "\tcondition\030\001 \001(\0162O.goog" - + "le.cloud.discoveryengine.v1beta.SearchRequest.QueryExpansionSpec.Condition\022\036\n" + + "\tcondition\030\001 \001(\0162O.google" + + ".cloud.discoveryengine.v1beta.SearchRequest.QueryExpansionSpec.Condition\022\036\n" + "\026pin_unexpanded_results\030\002 \001(\010\">\n" + "\tCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\010\n" + "\004AUTO\020\002\032\255\001\n" + "\023SpellCorrectionSpec\022Y\n" - + "\004mode\030\001 \001(\0162K.google.cloud.discoveryengine." - + "v1beta.SearchRequest.SpellCorrectionSpec.Mode\";\n" + + "\004mode\030\001 \001(\0162K.google.cloud.discoveryengine.v1" + + "beta.SearchRequest.SpellCorrectionSpec.Mode\";\n" + "\004Mode\022\024\n" + "\020MODE_UNSPECIFIED\020\000\022\023\n" + "\017SUGGESTION_ONLY\020\001\022\010\n" + "\004AUTO\020\002\032\276\014\n" + "\021ContentSearchSpec\022f\n" - + "\014snippet_spec\030\001 \001(\0132P.google." - + "cloud.discoveryengine.v1beta.SearchRequest.ContentSearchSpec.SnippetSpec\022f\n" - + "\014summary_spec\030\002 \001(\0132P.google.cloud.discoverye" - + "ngine.v1beta.SearchRequest.ContentSearchSpec.SummarySpec\022{\n" - + "\027extractive_content_spec\030\003 \001(\0132Z.google.cloud.discoveryengine" - + ".v1beta.SearchRequest.ContentSearchSpec.ExtractiveContentSpec\022q\n" - + "\022search_result_mode\030\004 \001(\0162U.google.cloud.discoveryengine" - + ".v1beta.SearchRequest.ContentSearchSpec.SearchResultMode\022b\n\n" - + "chunk_spec\030\005 \001(\0132N.g" - + "oogle.cloud.discoveryengine.v1beta.SearchRequest.ContentSearchSpec.ChunkSpec\032`\n" + + "\014snippet_spec\030\001 \001(\0132P.google.cl" + + "oud.discoveryengine.v1beta.SearchRequest.ContentSearchSpec.SnippetSpec\022f\n" + + "\014summary_spec\030\002 \001(\0132P.google.cloud.discoveryeng" + + "ine.v1beta.SearchRequest.ContentSearchSpec.SummarySpec\022{\n" + + "\027extractive_content_spec\030\003 \001(\0132Z.google.cloud.discoveryengine.v" + + "1beta.SearchRequest.ContentSearchSpec.ExtractiveContentSpec\022q\n" + + "\022search_result_mode\030\004 \001(\0162U.google.cloud.discoveryengine.v" + + "1beta.SearchRequest.ContentSearchSpec.SearchResultMode\022b\n\n" + + "chunk_spec\030\005 \001(\0132N.goo" + + "gle.cloud.discoveryengine.v1beta.SearchRequest.ContentSearchSpec.ChunkSpec\032`\n" + "\013SnippetSpec\022\035\n" + "\021max_snippet_count\030\001 \001(\005B\002\030\001\022\032\n" + "\016reference_only\030\002 \001(\010B\002\030\001\022\026\n" @@ -400,12 +411,12 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\033ignore_low_relevant_content\030\t \001(\010\022\'\n" + "\032ignore_jail_breaking_query\030\n" + " \001(\010B\003\340A\001\022{\n" - + "\021model_prompt_spec\030\005 \001(\0132`.google.cl" - + "oud.discoveryengine.v1beta.SearchRequest" - + ".ContentSearchSpec.SummarySpec.ModelPromptSpec\022\025\n\r" + + "\021model_prompt_spec\030\005 \001(\0132`.google.clou" + + "d.discoveryengine.v1beta.SearchRequest.C" + + "ontentSearchSpec.SummarySpec.ModelPromptSpec\022\025\n\r" + "language_code\030\006 \001(\t\022n\n\n" - + "model_spec\030\007 \001(\0132Z.google.cloud.discoveryengine" - + ".v1beta.SearchRequest.ContentSearchSpec.SummarySpec.ModelSpec\022\033\n" + + "model_spec\030\007 \001(\0132Z.google.cloud.discoveryengine.v" + + "1beta.SearchRequest.ContentSearchSpec.SummarySpec.ModelSpec\022\033\n" + "\023use_semantic_chunks\030\010 \001(\010\032#\n" + "\017ModelPromptSpec\022\020\n" + "\010preamble\030\001 \001(\t\032\034\n" @@ -421,27 +432,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\023num_previous_chunks\030\001 \001(\005\022\027\n" + "\017num_next_chunks\030\002 \001(\005\"Q\n" + "\020SearchResultMode\022\"\n" - + "\036SEARCH_RESULT_MODE_UNSPECIFIED\020\000\022\r\n" + + "\036SEARCH_RESULT_MODE_UNSPECIFIED\020\000\022\r" + + "\n" + "\tDOCUMENTS\020\001\022\n\n" + "\006CHUNKS\020\002\032\263\001\n\r" + "EmbeddingSpec\022k\n" - + "\021embedding_vectors\030\001 \003(\0132P.googl" - + "e.cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector\0325\n" + + "\021embedding_vectors\030\001 \003(\0132P.google." + + "cloud.discoveryengine.v1beta.SearchRequest.EmbeddingSpec.EmbeddingVector\0325\n" + "\017EmbeddingVector\022\022\n\n" + "field_path\030\001 \001(\t\022\016\n" + "\006vector\030\002 \003(\002\032\304\002\n" + "%NaturalLanguageQueryUnderstandingSpec\022\227\001\n" - + "\033filter_extraction_condition\030\001 \001(\0162r.google.cloud.discoveryengine" - + ".v1beta.SearchRequest.NaturalLanguageQue" - + "ryUnderstandingSpec.FilterExtractionCondition\022.\n" + + "\033filter_extraction_condition\030\001 \001(\0162r.google.cloud.discoveryengine.v" + + "1beta.SearchRequest.NaturalLanguageQuery" + + "UnderstandingSpec.FilterExtractionCondition\022.\n" + "&geo_search_query_detection_field_names\030\002 \003(\t\"Q\n" + "\031FilterExtractionCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\013\n" + "\007ENABLED\020\002\032\275\001\n" + "\023SearchAsYouTypeSpec\022c\n" - + "\tcondition\030\001 \001(\0162P.google.cloud.disco" - + "veryengine.v1beta.SearchRequest.SearchAsYouTypeSpec.Condition\"A\n" + + "\tcondition\030\001 \001(\0162P.google.cloud.discove" + + "ryengine.v1beta.SearchRequest.SearchAsYouTypeSpec.Condition\"A\n" + "\tCondition\022\031\n" + "\025CONDITION_UNSPECIFIED\020\000\022\014\n" + "\010DISABLED\020\001\022\013\n" @@ -451,8 +463,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\037search_result_persistence_count\030\002 \001(\005H\000\210\001\001B\"\n" + " _search_result_persistence_count\032\246\001\n" + "\023PersonalizationSpec\022Y\n" - + "\004mode\030\001 \001(\0162K.google.cloud.discoveryengine.v1beta." - + "SearchRequest.PersonalizationSpec.Mode\"4\n" + + "\004mode\030\001 \001(\0162" + + "K.google.cloud.discoveryengine.v1beta.SearchRequest.PersonalizationSpec.Mode\"4\n" + "\004Mode\022\024\n" + "\020MODE_UNSPECIFIED\020\000\022\010\n" + "\004AUTO\020\001\022\014\n" @@ -468,48 +480,76 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006LOWEST\020\001\022\007\n" + "\003LOW\020\002\022\n\n" + "\006MEDIUM\020\003\022\010\n" - + "\004HIGH\020\004\"\2330\n" + + "\004HIGH\020\004\"~\n" + + "\030RankingExpressionBackend\022*\n" + + "&RANKING_EXPRESSION_BACKEND_UNSPECIFIED\020\000\022\025\n" + + "\021RANK_BY_EMBEDDING\020\003\022\023\n" + + "\017RANK_BY_FORMULA\020\004\"\004\010\001\020\001\"\004\010\002\020\002\"\3715\n" + "\016SearchResponse\022Q\n" - + "\007results\030\001 \003(\0132@.googl" - + "e.cloud.discoveryengine.v1beta.SearchResponse.SearchResult\022I\n" - + "\006facets\030\002 \003(\01329.goo" - + "gle.cloud.discoveryengine.v1beta.SearchResponse.Facet\022d\n" - + "\024guided_search_result\030\010 " - + "\001(\0132F.google.cloud.discoveryengine.v1beta.SearchResponse.GuidedSearchResult\022\022\n\n" + + "\007results\030\001 \003(\0132@" + + ".google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult\022I\n" + + "\006facets\030\002 \003(\013" + + "29.google.cloud.discoveryengine.v1beta.SearchResponse.Facet\022d\n" + + "\024guided_search_result\030\010 \001(\0132F.google.cloud.discoveryengine" + + ".v1beta.SearchResponse.GuidedSearchResult\022\022\n\n" + "total_size\030\003 \001(\005\022\031\n" + "\021attribution_token\030\004 \001(\t\022\024\n" + "\014redirect_uri\030\014 \001(\t\022\027\n" + "\017next_page_token\030\005 \001(\t\022\027\n" + "\017corrected_query\030\007 \001(\t\022L\n" - + "\007summary\030\t" - + " \001(\0132;.google.cloud.discoveryengine.v1beta.SearchResponse.Summary\022\030\n" + + "\007summary\030\t \001(\0132;.google.cloud.discove" + + "ryengine.v1beta.SearchResponse.Summary\022\030\n" + "\020applied_controls\030\n" + " \003(\t\022e\n" - + "\025geo_search_debug_info\030\020 \003(\0132F.google.cloud.discoveryengine" - + ".v1beta.SearchResponse.GeoSearchDebugInfo\022d\n" - + "\024query_expansion_info\030\016 \001(\0132F.google" - + ".cloud.discoveryengine.v1beta.SearchResponse.QueryExpansionInfo\022\214\001\n" - + ")natural_language_query_understanding_info\030\017 \001(\0132Y.go" - + "ogle.cloud.discoveryengine.v1beta.Search" - + "Response.NaturalLanguageQueryUnderstandingInfo\022U\n" - + "\014session_info\030\023 \001(\0132?.google.cl" - + "oud.discoveryengine.v1beta.SearchResponse.SessionInfo\022Y\n" - + "\017one_box_results\030\024 \003(\0132@" - + ".google.cloud.discoveryengine.v1beta.SearchResponse.OneBoxResult\032\344\002\n" + + "\025geo_search_debug_info\030\020 \003(\0132F.google.cloud.discovery" + + "engine.v1beta.SearchResponse.GeoSearchDebugInfo\022d\n" + + "\024query_expansion_info\030\016 \001(\0132F." + + "google.cloud.discoveryengine.v1beta.SearchResponse.QueryExpansionInfo\022\214\001\n" + + ")natural_language_query_understanding_info\030\017 \001(" + + "\0132Y.google.cloud.discoveryengine.v1beta." + + "SearchResponse.NaturalLanguageQueryUnderstandingInfo\022U\n" + + "\014session_info\030\023 \001(\0132?.goo" + + "gle.cloud.discoveryengine.v1beta.SearchResponse.SessionInfo\022Y\n" + + "\017one_box_results\030\024" + + " \003(\0132@.google.cloud.discoveryengine.v1beta.SearchResponse.OneBoxResult\032\302\010\n" + "\014SearchResult\022\n\n" + "\002id\030\001 \001(\t\022?\n" + "\010document\030\002 \001(\0132-.google.cloud.discoveryengine.v1beta.Document\0229\n" + "\005chunk\030\022 \001(\0132*.google.cloud.discoveryengine.v1beta.Chunk\022g\n" - + "\014model_scores\030\004 \003(\0132Q.google.cloud.discoveryengine.v1beta.Se" - + "archResponse.SearchResult.ModelScoresEntry\032c\n" + + "\014model_scores\030\004 \003(\0132Q.google.cloud.discoveryengine.v1b" + + "eta.SearchResponse.SearchResult.ModelScoresEntry\022g\n" + + "\014rank_signals\030\007 \001(\0132L.google." + + "cloud.discoveryengine.v1beta.SearchResponse.SearchResult.RankSignalsB\003\340A\001\032c\n" + "\020ModelScoresEntry\022\013\n" + "\003key\030\001 \001(\t\022>\n" - + "\005value\030\002" - + " \001(\0132/.google.cloud.discoveryengine.v1beta.DoubleList:\0028\001\032\201\002\n" + + "\005value\030\002 \001(" + + "\0132/.google.cloud.discoveryengine.v1beta.DoubleList:\0028\001\032\362\004\n" + + "\013RankSignals\022*\n" + + "\030keyword_similarity_score\030\001 \001(\002B\003\340A\001H\000\210\001\001\022!\n" + + "\017relevance_score\030\002 \001(\002B\003\340A\001H\001\210\001\001\022+\n" + + "\031semantic_similarity_score\030\003" + + " \001(\002B\003\340A\001H\002\210\001\001\022\033\n" + + "\tpctr_rank\030\004 \001(\002B\003\340A\001H\003\210\001\001\022!\n" + + "\017topicality_rank\030\006 \001(\002B\003\340A\001H\004\210\001\001\022\036\n" + + "\014document_age\030\007 \001(\002B\003\340A\001H\005\210\001\001\022!\n" + + "\017boosting_factor\030\010 \001(\002B\003\340A\001H\006\210\001\001\022\031\n" + + "\014default_rank\030 \001(\002B\003\340A\001\022v\n" + + "\016custom_signals\030! \003(\0132Y.google.cloud.discover" + + "yengine.v1beta.SearchResponse.SearchResult.RankSignals.CustomSignalB\003\340A\001\0325\n" + + "\014CustomSignal\022\021\n" + + "\004name\030\001 \001(\tB\003\340A\001\022\022\n" + + "\005value\030\002 \001(\002B\003\340A\001B\033\n" + + "\031_keyword_similarity_scoreB\022\n" + + "\020_relevance_scoreB\034\n" + + "\032_semantic_similarity_scoreB\014\n\n" + + "_pctr_rankB\022\n" + + "\020_topicality_rankB\017\n\r" + + "_document_ageB\022\n" + + "\020_boosting_factorJ\004\010\005\020\006\032\201\002\n" + "\005Facet\022\013\n" + "\003key\030\001 \001(\t\022T\n" - + "\006values\030\002 \003(\0132D.google.cloud.di" - + "scoveryengine.v1beta.SearchResponse.Facet.FacetValue\022\025\n\r" + + "\006values\030\002 \003" + + "(\0132D.google.cloud.discoveryengine.v1beta.SearchResponse.Facet.FacetValue\022\025\n\r" + "dynamic_facet\030\003 \001(\010\032~\n\n" + "FacetValue\022\017\n" + "\005value\030\001 \001(\tH\000\022A\n" @@ -518,31 +558,31 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005count\030\003 \001(\003B\r\n" + "\013facet_value\032\363\001\n" + "\022GuidedSearchResult\022y\n" - + "\025refinement_attributes\030\001 \003(\0132Z.google.cloud.discove" - + "ryengine.v1beta.SearchResponse.GuidedSearchResult.RefinementAttribute\022\033\n" + + "\025refinement_attributes\030\001 \003(\0132Z.google.cloud.discoveryengine.v1beta.Sear" + + "chResponse.GuidedSearchResult.RefinementAttribute\022\033\n" + "\023follow_up_questions\030\002 \003(\t\032E\n" + "\023RefinementAttribute\022\025\n\r" + "attribute_key\030\001 \001(\t\022\027\n" + "\017attribute_value\030\002 \001(\t\032\263\014\n" + "\007Summary\022\024\n" + "\014summary_text\030\001 \001(\t\022q\n" - + "\027summary_skipped_reasons\030\002 \003(\0162P.g" - + "oogle.cloud.discoveryengine.v1beta.SearchResponse.Summary.SummarySkippedReason\022g\n" - + "\021safety_attributes\030\003 \001(\0132L.google.cloud" - + ".discoveryengine.v1beta.SearchResponse.Summary.SafetyAttributes\022n\n" - + "\025summary_with_metadata\030\004 \001(\0132O.google.cloud.discoverye" - + "ngine.v1beta.SearchResponse.Summary.SummaryWithMetadata\0326\n" + + "\027summary_skipped_reasons\030\002 \003(\0162P.google.cloud.discover" + + "yengine.v1beta.SearchResponse.Summary.SummarySkippedReason\022g\n" + + "\021safety_attributes\030\003 \001(\0132L.google.cloud.discoveryengine.v1b" + + "eta.SearchResponse.Summary.SafetyAttributes\022n\n" + + "\025summary_with_metadata\030\004 \001(\0132O.goo" + + "gle.cloud.discoveryengine.v1beta.SearchResponse.Summary.SummaryWithMetadata\0326\n" + "\020SafetyAttributes\022\022\n\n" + "categories\030\001 \003(\t\022\016\n" + "\006scores\030\002 \003(\002\032k\n" + "\020CitationMetadata\022W\n" - + "\tcitations\030\001 \003(\0132D.google." - + "cloud.discoveryengine.v1beta.SearchResponse.Summary.Citation\032\217\001\n" + + "\tcitations\030\001 \003(\0132D.google.cloud.discoveryengin" + + "e.v1beta.SearchResponse.Summary.Citation\032\217\001\n" + "\010Citation\022\023\n" + "\013start_index\030\001 \001(\003\022\021\n" + "\tend_index\030\002 \001(\003\022[\n" - + "\007sources\030\003 \003(\0132J.google.cloud.discoveryengin" - + "e.v1beta.SearchResponse.Summary.CitationSource\032)\n" + + "\007sources\030\003 \003(\0132J.google." + + "cloud.discoveryengine.v1beta.SearchResponse.Summary.CitationSource\032)\n" + "\016CitationSource\022\027\n" + "\017reference_index\030\004 \001(\003\032\220\002\n" + "\tReference\022\r\n" @@ -550,17 +590,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\010document\030\002 \001(\tB/\340A\002\372A)\n" + "\'discoveryengine.googleapis.com/Document\022\013\n" + "\003uri\030\003 \001(\t\022j\n" - + "\016chunk_contents\030\004 \003(\0132R.google.cloud.di" - + "scoveryengine.v1beta.SearchResponse.Summary.Reference.ChunkContent\0328\n" + + "\016chunk_contents\030\004 \003(\0132R.google.cloud.discoveryengine.v1beta" + + ".SearchResponse.Summary.Reference.ChunkContent\0328\n" + "\014ChunkContent\022\017\n" + "\007content\030\001 \001(\t\022\027\n" + "\017page_identifier\030\002 \001(\t\032\352\001\n" + "\023SummaryWithMetadata\022\017\n" + "\007summary\030\001 \001(\t\022g\n" - + "\021citation_metadata\030\002 \001(\0132L.googl" - + "e.cloud.discoveryengine.v1beta.SearchResponse.Summary.CitationMetadata\022Y\n\n" - + "references\030\003 \003(\0132E.google.cloud.discoveryengin" - + "e.v1beta.SearchResponse.Summary.Reference\"\343\002\n" + + "\021citation_metadata\030\002 \001(\0132L.google.cloud.discoveryeng" + + "ine.v1beta.SearchResponse.Summary.CitationMetadata\022Y\n\n" + + "references\030\003 \003(\0132E.google." + + "cloud.discoveryengine.v1beta.SearchResponse.Summary.Reference\"\343\002\n" + "\024SummarySkippedReason\022&\n" + "\"SUMMARY_SKIPPED_REASON_UNSPECIFIED\020\000\022\035\n" + "\031ADVERSARIAL_QUERY_IGNORED\020\001\022%\n" @@ -581,22 +621,21 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "%NaturalLanguageQueryUnderstandingInfo\022\031\n" + "\021extracted_filters\030\001 \001(\t\022\027\n" + "\017rewritten_query\030\002 \001(\t\022\230\001\n" - + "\033structured_extracted_filter\030\003 \001(\0132s.google.cloud.discoveryengine.v1bet" - + "a.SearchResponse.NaturalLanguageQueryUnd" - + "erstandingInfo.StructuredExtractedFilter\032\210\017\n" + + "\033structured_extracted_filter\030\003 \001(\0132s.google.cloud.d" + + "iscoveryengine.v1beta.SearchResponse.Nat" + + "uralLanguageQueryUnderstandingInfo.StructuredExtractedFilter\032\210\017\n" + "\031StructuredExtractedFilter\022\222\001\n\n" - + "expression\030\001 \001(\0132~.google.cloud.discoveryengi" - + "ne.v1beta.SearchResponse.NaturalLanguage" - + "QueryUnderstandingInfo.StructuredExtractedFilter.Expression\032M\n" + + "expression\030\001 \001(\0132~.google.cloud.discoveryengine.v1beta.SearchResp" + + "onse.NaturalLanguageQueryUnderstandingInfo.StructuredExtractedFilter.Expression\032M\n" + "\020StringConstraint\022\022\n\n" + "field_name\030\001 \001(\t\022\016\n" + "\006values\030\002 \003(\t\022\025\n\r" + "query_segment\030\003 \001(\t\032\372\002\n" + "\020NumberConstraint\022\022\n\n" + "field_name\030\001 \001(\t\022\244\001\n\n" - + "comparison\030\002 \001(\0162\217\001.google.cloud.discoveryengine.v1beta." - + "SearchResponse.NaturalLanguageQueryUnder" - + "standingInfo.StructuredExtractedFilter.NumberConstraint.Comparison\022\r\n" + + "comparison\030\002 \001(\0162\217\001.google.cloud.dis" + + "coveryengine.v1beta.SearchResponse.NaturalLanguageQueryUnderstandingInfo.Structu" + + "redExtractedFilter.NumberConstraint.Comparison\022\r\n" + "\005value\030\003 \001(\001\022\025\n\r" + "query_segment\030\004 \001(\t\"\204\001\n\n" + "Comparison\022\032\n" @@ -613,38 +652,38 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tlongitude\030\005 \001(\001\022\030\n" + "\020radius_in_meters\030\003 \001(\002\032\245\001\n\r" + "AndExpression\022\223\001\n" - + "\013expressions\030\001 \003(\0132~.google.cloud.discoveryengine.v1be" - + "ta.SearchResponse.NaturalLanguageQueryUn" - + "derstandingInfo.StructuredExtractedFilter.Expression\032\244\001\n" + + "\013expressions\030\001 \003(\0132~.google.cloud." + + "discoveryengine.v1beta.SearchResponse.Na" + + "turalLanguageQueryUnderstandingInfo.StructuredExtractedFilter.Expression\032\244\001\n" + "\014OrExpression\022\223\001\n" - + "\013expressions\030\001 \003(\0132~.google.cloud.discoveryengi" - + "ne.v1beta.SearchResponse.NaturalLanguage" - + "QueryUnderstandingInfo.StructuredExtractedFilter.Expression\032\275\006\n\n" - + "Expression\022\242\001\n" - + "\021string_constraint\030\001 \001(\0132\204\001.google.cloud.d" - + "iscoveryengine.v1beta.SearchResponse.NaturalLanguageQueryUnderstandingInfo.Struc" - + "turedExtractedFilter.StringConstraintH\000\022\242\001\n" - + "\021number_constraint\030\002 \001(\0132\204\001.google.cl" - + "oud.discoveryengine.v1beta.SearchResponse.NaturalLanguageQueryUnderstandingInfo." - + "StructuredExtractedFilter.NumberConstraintH\000\022\254\001\n" - + "\026geolocation_constraint\030\003 \001(\0132\211\001" - + ".google.cloud.discoveryengine.v1beta.SearchResponse.NaturalLanguageQueryUndersta" - + "ndingInfo.StructuredExtractedFilter.GeolocationConstraintH\000\022\226\001\n" - + "\010and_expr\030\004 \001(\0132\201\001.google.cloud.discoveryengine.v1beta.Se" - + "archResponse.NaturalLanguageQueryUnderst" - + "andingInfo.StructuredExtractedFilter.AndExpressionH\000\022\224\001\n" - + "\007or_expr\030\005 \001(\0132\200\001.google.cloud.discoveryengine.v1beta.SearchResp" + + "\013expressions\030\001 \003(\0132~.google.cloud.discoveryengine.v1beta.SearchResp" + "onse.NaturalLanguageQueryUnderstandingIn" - + "fo.StructuredExtractedFilter.OrExpressionH\000B\006\n" + + "fo.StructuredExtractedFilter.Expression\032\275\006\n\n" + + "Expression\022\242\001\n" + + "\021string_constraint\030\001 \001(\0132\204\001.google.cloud.discoveryengine.v1bet" + + "a.SearchResponse.NaturalLanguageQueryUnd" + + "erstandingInfo.StructuredExtractedFilter.StringConstraintH\000\022\242\001\n" + + "\021number_constraint\030\002 \001(\0132\204\001.google.cloud.discoveryengine." + + "v1beta.SearchResponse.NaturalLanguageQue" + + "ryUnderstandingInfo.StructuredExtractedFilter.NumberConstraintH\000\022\254\001\n" + + "\026geolocation_constraint\030\003 \001(\0132\211\001.google.cloud.discov" + + "eryengine.v1beta.SearchResponse.NaturalLanguageQueryUnderstandingInfo.Structured" + + "ExtractedFilter.GeolocationConstraintH\000\022\226\001\n" + + "\010and_expr\030\004 \001(\0132\201\001.google.cloud.disco" + + "veryengine.v1beta.SearchResponse.Natural" + + "LanguageQueryUnderstandingInfo.StructuredExtractedFilter.AndExpressionH\000\022\224\001\n" + + "\007or_expr\030\005 \001(\0132\200\001.google.cloud.discoveryengi" + + "ne.v1beta.SearchResponse.NaturalLanguage" + + "QueryUnderstandingInfo.StructuredExtractedFilter.OrExpressionH\000B\006\n" + "\004expr\032-\n" + "\013SessionInfo\022\014\n" + "\004name\030\001 \001(\t\022\020\n" + "\010query_id\030\002 \001(\t\032\265\002\n" + "\014OneBoxResult\022a\n" - + "\014one_box_type\030\001 \001(\0162K.google.cloud.discove" - + "ryengine.v1beta.SearchResponse.OneBoxResult.OneBoxType\022X\n" - + "\016search_results\030\002 \003(\0132@" - + ".google.cloud.discoveryengine.v1beta.SearchResponse.SearchResult\"h\n\n" + + "\014one_box_type\030\001 \001(\0162K." + + "google.cloud.discoveryengine.v1beta.SearchResponse.OneBoxResult.OneBoxType\022X\n" + + "\016search_results\030\002 \003(\0132@.google.cloud.discov" + + "eryengine.v1beta.SearchResponse.SearchResult\"h\n\n" + "OneBoxType\022\034\n" + "\030ONE_BOX_TYPE_UNSPECIFIED\020\000\022\n\n" + "\006PEOPLE\020\001\022\020\n" @@ -652,27 +691,28 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\005SLACK\020\003\022\023\n" + "\017KNOWLEDGE_GRAPH\020\0042\277\007\n\r" + "SearchService\022\243\003\n" - + "\006Search\0222.google.cloud.discoveryengine.v1beta.Se" - + "archRequest\0323.google.cloud.discoveryengi" - + "ne.v1beta.SearchResponse\"\257\002\202\323\344\223\002\250\002\"T/v1b" - + "eta/{serving_config=projects/*/locations/*/dataStores/*/servingConfigs/*}:search" - + ":\001*Zg\"b/v1beta/{serving_config=projects/*/locations/*/collections/*/dataStores/*" - + "/servingConfigs/*}:search:\001*Zd\"_/v1beta/{serving_config=projects/*/locations/*/c" - + "ollections/*/engines/*/servingConfigs/*}:search:\001*\022\263\003\n\n" - + "SearchLite\0222.google.cloud.discoveryengine.v1beta.SearchRequest\0323." - + "google.cloud.discoveryengine.v1beta.Sear" - + "chResponse\"\273\002\202\323\344\223\002\264\002\"X/v1beta/{serving_c" - + "onfig=projects/*/locations/*/dataStores/*/servingConfigs/*}:searchLite:\001*Zk\"f/v1" - + "beta/{serving_config=projects/*/locations/*/collections/*/dataStores/*/servingCo" - + "nfigs/*}:searchLite:\001*Zh\"c/v1beta/{serving_config=projects/*/locations/*/collect" - + "ions/*/engines/*/servingConfigs/*}:searc" - + "hLite:\001*\032R\312A\036discoveryengine.googleapis." - + "com\322A.https://www.googleapis.com/auth/cloud-platformB\231\002\n" - + "\'com.google.cloud.discoveryengine.v1betaB\022SearchServiceProtoP\001ZQ" - + "cloud.google.com/go/discoveryengine/apiv1beta/discoveryenginepb;discoveryenginep" - + "b\242\002\017DISCOVERYENGINE\252\002#Google.Cloud.Disco" - + "veryEngine.V1Beta\312\002#Google\\Cloud\\Discove" - + "ryEngine\\V1beta\352\002&Google::Cloud::DiscoveryEngine::V1betab\006proto3" + + "\006Search\0222.google.cloud.discoveryengine.v1beta.SearchRequest\0323.google" + + ".cloud.discoveryengine.v1beta.SearchResp" + + "onse\"\257\002\202\323\344\223\002\250\002\"T/v1beta/{serving_config=" + + "projects/*/locations/*/dataStores/*/servingConfigs/*}:search:\001*Zg\"b/v1beta/{serv" + + "ing_config=projects/*/locations/*/collections/*/dataStores/*/servingConfigs/*}:s" + + "earch:\001*Zd\"_/v1beta/{serving_config=proj" + + "ects/*/locations/*/collections/*/engines/*/servingConfigs/*}:search:\001*\022\263\003\n\n" + + "SearchLite\0222.google.cloud.discoveryengine.v1b" + + "eta.SearchRequest\0323.google.cloud.discove" + + "ryengine.v1beta.SearchResponse\"\273\002\202\323\344\223\002\264\002" + + "\"X/v1beta/{serving_config=projects/*/locations/*/dataStores/*/servingConfigs/*}:" + + "searchLite:\001*Zk\"f/v1beta/{serving_config=projects/*/locations/*/collections/*/da" + + "taStores/*/servingConfigs/*}:searchLite:\001*Zh\"c/v1beta/{serving_config=projects/*" + + "/locations/*/collections/*/engines/*/ser" + + "vingConfigs/*}:searchLite:\001*\032R\312A\036discove" + + "ryengine.googleapis.com\322A.https://www.googleapis.com/auth/cloud-platformB\231\002\n" + + "\'com.google.cloud.discoveryengine.v1betaB\022Se" + + "archServiceProtoP\001ZQcloud.google.com/go/discoveryengine/apiv1beta/discoveryengin" + + "epb;discoveryenginepb\242\002\017DISCOVERYENGINE\252" + + "\002#Google.Cloud.DiscoveryEngine.V1Beta\312\002#" + + "Google\\Cloud\\DiscoveryEngine\\V1beta\352\002&Go" + + "ogle::Cloud::DiscoveryEngine::V1betab\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -717,6 +757,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ContentSearchSpec", "EmbeddingSpec", "RankingExpression", + "RankingExpressionBackend", "SafeSearch", "UserLabels", "NaturalLanguageQueryUnderstandingSpec", @@ -1029,7 +1070,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_descriptor, new java.lang.String[] { - "Id", "Document", "Chunk", "ModelScores", + "Id", "Document", "Chunk", "ModelScores", "RankSignals", }); internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_ModelScoresEntry_descriptor = internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_descriptor @@ -1041,6 +1082,34 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Key", "Value", }); + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor = + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor, + new java.lang.String[] { + "KeywordSimilarityScore", + "RelevanceScore", + "SemanticSimilarityScore", + "PctrRank", + "TopicalityRank", + "DocumentAge", + "BoostingFactor", + "DefaultRank", + "CustomSignals", + }); + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor = + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_SearchResult_RankSignals_CustomSignal_descriptor, + new java.lang.String[] { + "Name", "Value", + }); internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_Facet_descriptor = internal_static_google_cloud_discoveryengine_v1beta_SearchResponse_descriptor .getNestedTypes() diff --git a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/search_service.proto b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/search_service.proto index 9cb0c44d8a68..67d723af6232 100644 --- a/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/search_service.proto +++ b/java-discoveryengine/proto-google-cloud-discoveryengine-v1beta/src/main/proto/google/cloud/discoveryengine/v1beta/search_service.proto @@ -1038,8 +1038,14 @@ message SearchRequest { // The ranking expression controls the customized ranking on retrieval // documents. This overrides // [ServingConfig.ranking_expression][google.cloud.discoveryengine.v1beta.ServingConfig.ranking_expression]. - // The ranking expression is a single function or multiple functions that are - // joined by "+". + // The syntax and supported features depend on the + // `ranking_expression_backend` value. If `ranking_expression_backend` is not + // provided, it defaults to `RANK_BY_EMBEDDING`. + // + // If + // [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + // is not provided or set to `RANK_BY_EMBEDDING`, it should be a single + // function or multiple functions that are joined by "+". // // * ranking_expression = function, { " + ", function }; // @@ -1054,15 +1060,90 @@ message SearchRequest { // between query and document. // * `embedding_field_path`: the document embedding field // used with query embedding vector. - // * `dotProduct`: embedding function between embedding_field_path and query - // embedding vector. + // * `dotProduct`: embedding function between `embedding_field_path` and + // query embedding vector. // // Example ranking expression: // // If document has an embedding field doc_embedding, the ranking expression // could be `0.5 * relevance_score + 0.3 * dotProduct(doc_embedding)`. + // + // If + // [ranking_expression_backend][google.cloud.discoveryengine.v1beta.SearchRequest.ranking_expression_backend] + // is set to `RANK_BY_FORMULA`, the following expression types (and + // combinations of those chained using + or + // * operators) are supported: + // + // * `double` + // * `signal` + // * `log(signal)` + // * `exp(signal)` + // * `rr(signal, double > 0)` -- reciprocal rank transformation with second + // argument being a denominator constant. + // * `is_nan(signal)` -- returns 0 if signal is NaN, 1 otherwise. + // * `fill_nan(signal1, signal2 | double)` -- if signal1 is NaN, returns + // signal2 | double, else returns signal1. + // + // Here are a few examples of ranking formulas that use the supported + // ranking expression types: + // + // - `0.2 * semantic_similarity_score + 0.8 * log(keyword_similarity_score)` + // -- mostly rank by the logarithm of `keyword_similarity_score` with slight + // `semantic_smilarity_score` adjustment. + // - `0.2 * exp(fill_nan(semantic_similarity_score, 0)) + 0.3 * + // is_nan(keyword_similarity_score)` -- rank by the exponent of + // `semantic_similarity_score` filling the value with 0 if it's NaN, also + // add constant 0.3 adjustment to the final score if + // `semantic_similarity_score` is NaN. + // - `0.2 * rr(semantic_similarity_score, 16) + 0.8 * + // rr(keyword_similarity_score, 16)` -- mostly rank by the reciprocal rank + // of `keyword_similarity_score` with slight adjustment of reciprocal rank + // of `semantic_smilarity_score`. + // + // The following signals are supported: + // + // * `semantic_similarity_score`: semantic similarity adjustment that is + // calculated using the embeddings generated by a proprietary Google model. + // This score determines how semantically similar a search query is to a + // document. + // * `keyword_similarity_score`: keyword match adjustment uses the Best + // Match 25 (BM25) ranking function. This score is calculated using a + // probabilistic model to estimate the probability that a document is + // relevant to a given query. + // * `relevance_score`: semantic relevance adjustment that uses a + // proprietary Google model to determine the meaning and intent behind a + // user's query in context with the content in the documents. + // * `pctr_rank`: predicted conversion rate adjustment as a rank use + // predicted Click-through rate (pCTR) to gauge the relevance and + // attractiveness of a search result from a user's perspective. A higher + // pCTR suggests that the result is more likely to satisfy the user's query + // and intent, making it a valuable signal for ranking. + // * `freshness_rank`: freshness adjustment as a rank + // * `document_age`: The time in hours elapsed since the document was last + // updated, a floating-point number (e.g., 0.25 means 15 minutes). + // * `topicality_rank`: topicality adjustment as a rank. Uses proprietary + // Google model to determine the keyword-based overlap between the query and + // the document. + // * `base_rank`: the default rank of the result string ranking_expression = 26; + // The backend to use for the ranking expression evaluation. + enum RankingExpressionBackend { + reserved 1, 2; + + // Default option for unspecified/unknown values. + RANKING_EXPRESSION_BACKEND_UNSPECIFIED = 0; + // Ranking by custom embedding model, the default way to evaluate the + // ranking expression. + RANK_BY_EMBEDDING = 3; + // Ranking by custom formula. + RANK_BY_FORMULA = 4; + } + + // The backend to use for the ranking expression evaluation. + RankingExpressionBackend ranking_expression_backend = 53 + [(google.api.field_behavior) = OPTIONAL]; + // Whether to turn on safe search. This is only supported for // website search. bool safe_search = 20; @@ -1167,6 +1248,49 @@ message SearchResponse { // Google provided available scores. map model_scores = 4; + + // A set of ranking signals. + message RankSignals { + reserved 5; + + // Keyword matching adjustment. + optional float keyword_similarity_score = 1 + [(google.api.field_behavior) = OPTIONAL]; + // Semantic relevance adjustment. + optional float relevance_score = 2 + [(google.api.field_behavior) = OPTIONAL]; + // Semantic similarity adjustment. + optional float semantic_similarity_score = 3 + [(google.api.field_behavior) = OPTIONAL]; + // Predicted conversion rate adjustment as a rank. + optional float pctr_rank = 4 [(google.api.field_behavior) = OPTIONAL]; + // Topicality adjustment as a rank. + optional float topicality_rank = 6 + [(google.api.field_behavior) = OPTIONAL]; + // Age of the document in hours. + optional float document_age = 7 [(google.api.field_behavior) = OPTIONAL]; + // Combined custom boosts for a doc. + optional float boosting_factor = 8 + [(google.api.field_behavior) = OPTIONAL]; + + // The default rank of the result. + float default_rank = 32 [(google.api.field_behavior) = OPTIONAL]; + + // Custom clearbox signal represented by name and value pair. + message CustomSignal { + // Name of the signal. + string name = 1 [(google.api.field_behavior) = OPTIONAL]; + // Float value representing the ranking signal (e.g. 1.25 for BM25). + float value = 2 [(google.api.field_behavior) = OPTIONAL]; + } + + // A list of custom clearbox signals. + repeated CustomSignal custom_signals = 33 + [(google.api.field_behavior) = OPTIONAL]; + } + + // A set of ranking signals associated with the result. + RankSignals rank_signals = 7 [(google.api.field_behavior) = OPTIONAL]; } // A facet result. diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearch.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearch.java index 50d99d168a83..2dce1f2fd42d 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearch.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearch.java @@ -81,6 +81,7 @@ public static void asyncSearch() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); ApiFuture future = searchServiceClient.searchPagedCallable().futureCall(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearchPaged.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearchPaged.java index 325e37b27537..ba682ccbc136 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearchPaged.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/AsyncSearchPaged.java @@ -81,6 +81,7 @@ public static void asyncSearchPaged() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); while (true) { SearchResponse response = searchServiceClient.searchCallable().call(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/SyncSearch.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/SyncSearch.java index b803a9f79fca..57ea7a56f7e2 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/SyncSearch.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/search/SyncSearch.java @@ -80,6 +80,7 @@ public static void syncSearch() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); for (SearchResponse.SearchResult element : searchServiceClient.search(request).iterateAll()) { // doThingsWith(element); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLite.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLite.java index 67cdf6412140..5d4c3c177248 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLite.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLite.java @@ -81,6 +81,7 @@ public static void asyncSearchLite() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); ApiFuture future = searchServiceClient.searchLitePagedCallable().futureCall(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLitePaged.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLitePaged.java index 648fb67f440d..f58d1808399f 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLitePaged.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/AsyncSearchLitePaged.java @@ -81,6 +81,7 @@ public static void asyncSearchLitePaged() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); while (true) { SearchResponse response = searchServiceClient.searchLiteCallable().call(request); diff --git a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/SyncSearchLite.java b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/SyncSearchLite.java index 184b01a9e53a..900fda688ee3 100644 --- a/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/SyncSearchLite.java +++ b/java-discoveryengine/samples/snippets/generated/com/google/cloud/discoveryengine/v1/searchservice/searchlite/SyncSearchLite.java @@ -80,6 +80,7 @@ public static void syncSearchLite() throws Exception { .toString()) .setSessionSpec(SearchRequest.SessionSpec.newBuilder().build()) .setRelevanceScoreSpec(SearchRequest.RelevanceScoreSpec.newBuilder().build()) + .setRankingExpression("rankingExpression2110320494") .build(); for (SearchResponse.SearchResult element : searchServiceClient.searchLite(request).iterateAll()) { diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceClient.java b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceClient.java index 32e8592a30af..4f291aecf577 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceClient.java +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceClient.java @@ -598,6 +598,20 @@ * * * + *

        Decapsulate + *

        Decapsulates data that was encapsulated with a public key retrieved from [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey] corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose] KEY_ENCAPSULATION. + * + *

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

        + *
          + *
        • decapsulate(DecapsulateRequest request) + *

        + *

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

        + *
          + *
        • decapsulateCallable() + *

        + * + * + * *

        GenerateRandomBytes *

        Generate random bytes using the Cloud KMS randomness source in the provided location. * @@ -4781,6 +4795,88 @@ public final UnaryCallable macVerifyCallabl return stub.macVerifyCallable(); } + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Decapsulates data that was encapsulated with a public key retrieved from + * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey] corresponding to a + * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] with + * [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose] KEY_ENCAPSULATION. + * + *

        Sample code: + * + *

        {@code
        +   * // This snippet has been automatically generated and should be regarded as a code template only.
        +   * // It will require modifications to work:
        +   * // - It may require correct/in-range values for request initialization.
        +   * // - It may require specifying regional endpoints when creating the service client as shown in
        +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
        +   * try (KeyManagementServiceClient keyManagementServiceClient =
        +   *     KeyManagementServiceClient.create()) {
        +   *   DecapsulateRequest request =
        +   *       DecapsulateRequest.newBuilder()
        +   *           .setName(
        +   *               CryptoKeyVersionName.of(
        +   *                       "[PROJECT]",
        +   *                       "[LOCATION]",
        +   *                       "[KEY_RING]",
        +   *                       "[CRYPTO_KEY]",
        +   *                       "[CRYPTO_KEY_VERSION]")
        +   *                   .toString())
        +   *           .setCiphertext(ByteString.EMPTY)
        +   *           .setCiphertextCrc32C(Int64Value.newBuilder().build())
        +   *           .build();
        +   *   DecapsulateResponse response = keyManagementServiceClient.decapsulate(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 DecapsulateResponse decapsulate(DecapsulateRequest request) { + return decapsulateCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Decapsulates data that was encapsulated with a public key retrieved from + * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey] corresponding to a + * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] with + * [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose] KEY_ENCAPSULATION. + * + *

        Sample code: + * + *

        {@code
        +   * // This snippet has been automatically generated and should be regarded as a code template only.
        +   * // It will require modifications to work:
        +   * // - It may require correct/in-range values for request initialization.
        +   * // - It may require specifying regional endpoints when creating the service client as shown in
        +   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
        +   * try (KeyManagementServiceClient keyManagementServiceClient =
        +   *     KeyManagementServiceClient.create()) {
        +   *   DecapsulateRequest request =
        +   *       DecapsulateRequest.newBuilder()
        +   *           .setName(
        +   *               CryptoKeyVersionName.of(
        +   *                       "[PROJECT]",
        +   *                       "[LOCATION]",
        +   *                       "[KEY_RING]",
        +   *                       "[CRYPTO_KEY]",
        +   *                       "[CRYPTO_KEY_VERSION]")
        +   *                   .toString())
        +   *           .setCiphertext(ByteString.EMPTY)
        +   *           .setCiphertextCrc32C(Int64Value.newBuilder().build())
        +   *           .build();
        +   *   ApiFuture future =
        +   *       keyManagementServiceClient.decapsulateCallable().futureCall(request);
        +   *   // Do something.
        +   *   DecapsulateResponse response = future.get();
        +   * }
        +   * }
        + */ + public final UnaryCallable decapsulateCallable() { + return stub.decapsulateCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Generate random bytes using the Cloud KMS randomness source in the provided location. diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceSettings.java b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceSettings.java index 2184f0d724de..53eabfce7e21 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceSettings.java +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceSettings.java @@ -255,6 +255,11 @@ public UnaryCallSettings macVerifySettings( return ((KeyManagementServiceStubSettings) getStubSettings()).macVerifySettings(); } + /** Returns the object with the settings used for calls to decapsulate. */ + public UnaryCallSettings decapsulateSettings() { + return ((KeyManagementServiceStubSettings) getStubSettings()).decapsulateSettings(); + } + /** Returns the object with the settings used for calls to generateRandomBytes. */ public UnaryCallSettings generateRandomBytesSettings() { @@ -555,6 +560,12 @@ public UnaryCallSettings.Builder macVerifyS return getStubSettingsBuilder().macVerifySettings(); } + /** Returns the builder for the settings used for calls to decapsulate. */ + public UnaryCallSettings.Builder + decapsulateSettings() { + return getStubSettingsBuilder().decapsulateSettings(); + } + /** Returns the builder for the settings used for calls to generateRandomBytes. */ public UnaryCallSettings.Builder generateRandomBytesSettings() { diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/gapic_metadata.json b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/gapic_metadata.json index 2bde2ca09a19..b757509f381b 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/gapic_metadata.json +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/gapic_metadata.json @@ -139,6 +139,9 @@ "CreateKeyRing": { "methods": ["createKeyRing", "createKeyRing", "createKeyRing", "createKeyRingCallable"] }, + "Decapsulate": { + "methods": ["decapsulate", "decapsulateCallable"] + }, "Decrypt": { "methods": ["decrypt", "decrypt", "decrypt", "decryptCallable"] }, diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/GrpcKeyManagementServiceStub.java b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/GrpcKeyManagementServiceStub.java index 64a786d43a18..3ab0a6330e4b 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/GrpcKeyManagementServiceStub.java +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/GrpcKeyManagementServiceStub.java @@ -39,6 +39,8 @@ import com.google.cloud.kms.v1.CreateKeyRingRequest; import com.google.cloud.kms.v1.CryptoKey; import com.google.cloud.kms.v1.CryptoKeyVersion; +import com.google.cloud.kms.v1.DecapsulateRequest; +import com.google.cloud.kms.v1.DecapsulateResponse; import com.google.cloud.kms.v1.DecryptRequest; import com.google.cloud.kms.v1.DecryptResponse; import com.google.cloud.kms.v1.DestroyCryptoKeyVersionRequest; @@ -388,6 +390,17 @@ public class GrpcKeyManagementServiceStub extends KeyManagementServiceStub { .setSampledToLocalTracing(true) .build(); + private static final MethodDescriptor + decapsulateMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.kms.v1.KeyManagementService/Decapsulate") + .setRequestMarshaller(ProtoUtils.marshaller(DecapsulateRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(DecapsulateResponse.getDefaultInstance())) + .setSampledToLocalTracing(true) + .build(); + private static final MethodDescriptor generateRandomBytesMethodDescriptor = MethodDescriptor.newBuilder() @@ -495,6 +508,7 @@ public class GrpcKeyManagementServiceStub extends KeyManagementServiceStub { asymmetricDecryptCallable; private final UnaryCallable macSignCallable; private final UnaryCallable macVerifyCallable; + private final UnaryCallable decapsulateCallable; private final UnaryCallable generateRandomBytesCallable; private final UnaryCallable listLocationsCallable; @@ -835,6 +849,16 @@ protected GrpcKeyManagementServiceStub( return builder.build(); }) .build(); + GrpcCallSettings decapsulateTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(decapsulateMethodDescriptor) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); GrpcCallSettings generateRandomBytesTransportSettings = GrpcCallSettings.newBuilder() @@ -1011,6 +1035,9 @@ protected GrpcKeyManagementServiceStub( this.macVerifyCallable = callableFactory.createUnaryCallable( macVerifyTransportSettings, settings.macVerifySettings(), clientContext); + this.decapsulateCallable = + callableFactory.createUnaryCallable( + decapsulateTransportSettings, settings.decapsulateSettings(), clientContext); this.generateRandomBytesCallable = callableFactory.createUnaryCallable( generateRandomBytesTransportSettings, @@ -1211,6 +1238,11 @@ public UnaryCallable macVerifyCallable() { return macVerifyCallable; } + @Override + public UnaryCallable decapsulateCallable() { + return decapsulateCallable; + } + @Override public UnaryCallable generateRandomBytesCallable() { diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/HttpJsonKeyManagementServiceStub.java b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/HttpJsonKeyManagementServiceStub.java index 136894c6f40b..e69342f6278f 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/HttpJsonKeyManagementServiceStub.java +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/HttpJsonKeyManagementServiceStub.java @@ -44,6 +44,8 @@ import com.google.cloud.kms.v1.CreateKeyRingRequest; import com.google.cloud.kms.v1.CryptoKey; import com.google.cloud.kms.v1.CryptoKeyVersion; +import com.google.cloud.kms.v1.DecapsulateRequest; +import com.google.cloud.kms.v1.DecapsulateResponse; import com.google.cloud.kms.v1.DecryptRequest; import com.google.cloud.kms.v1.DecryptResponse; import com.google.cloud.kms.v1.DestroyCryptoKeyVersionRequest; @@ -1118,6 +1120,43 @@ public class HttpJsonKeyManagementServiceStub extends KeyManagementServiceStub { .build()) .build(); + private static final ApiMethodDescriptor + decapsulateMethodDescriptor = + ApiMethodDescriptor.newBuilder() + .setFullMethodName("google.cloud.kms.v1.KeyManagementService/Decapsulate") + .setHttpMethod("POST") + .setType(ApiMethodDescriptor.MethodType.UNARY) + .setRequestFormatter( + ProtoMessageRequestFormatter.newBuilder() + .setPath( + "/v1/{name=projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:decapsulate", + 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(DecapsulateResponse.getDefaultInstance()) + .setDefaultTypeRegistry(typeRegistry) + .build()) + .build(); + private static final ApiMethodDescriptor generateRandomBytesMethodDescriptor = ApiMethodDescriptor.newBuilder() @@ -1390,6 +1429,7 @@ public class HttpJsonKeyManagementServiceStub extends KeyManagementServiceStub { asymmetricDecryptCallable; private final UnaryCallable macSignCallable; private final UnaryCallable macVerifyCallable; + private final UnaryCallable decapsulateCallable; private final UnaryCallable generateRandomBytesCallable; private final UnaryCallable listLocationsCallable; @@ -1757,6 +1797,17 @@ protected HttpJsonKeyManagementServiceStub( return builder.build(); }) .build(); + HttpJsonCallSettings decapsulateTransportSettings = + HttpJsonCallSettings.newBuilder() + .setMethodDescriptor(decapsulateMethodDescriptor) + .setTypeRegistry(typeRegistry) + .setParamsExtractor( + request -> { + RequestParamsBuilder builder = RequestParamsBuilder.create(); + builder.add("name", String.valueOf(request.getName())); + return builder.build(); + }) + .build(); HttpJsonCallSettings generateRandomBytesTransportSettings = HttpJsonCallSettings @@ -1941,6 +1992,9 @@ protected HttpJsonKeyManagementServiceStub( this.macVerifyCallable = callableFactory.createUnaryCallable( macVerifyTransportSettings, settings.macVerifySettings(), clientContext); + this.decapsulateCallable = + callableFactory.createUnaryCallable( + decapsulateTransportSettings, settings.decapsulateSettings(), clientContext); this.generateRandomBytesCallable = callableFactory.createUnaryCallable( generateRandomBytesTransportSettings, @@ -2001,6 +2055,7 @@ public static List getMethodDescriptors() { methodDescriptors.add(asymmetricDecryptMethodDescriptor); methodDescriptors.add(macSignMethodDescriptor); methodDescriptors.add(macVerifyMethodDescriptor); + methodDescriptors.add(decapsulateMethodDescriptor); methodDescriptors.add(generateRandomBytesMethodDescriptor); methodDescriptors.add(listLocationsMethodDescriptor); methodDescriptors.add(getLocationMethodDescriptor); @@ -2176,6 +2231,11 @@ public UnaryCallable macVerifyCallable() { return macVerifyCallable; } + @Override + public UnaryCallable decapsulateCallable() { + return decapsulateCallable; + } + @Override public UnaryCallable generateRandomBytesCallable() { diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStub.java b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStub.java index 3b4762ce4f53..0d40818286e2 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStub.java +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStub.java @@ -34,6 +34,8 @@ import com.google.cloud.kms.v1.CreateKeyRingRequest; import com.google.cloud.kms.v1.CryptoKey; import com.google.cloud.kms.v1.CryptoKeyVersion; +import com.google.cloud.kms.v1.DecapsulateRequest; +import com.google.cloud.kms.v1.DecapsulateResponse; import com.google.cloud.kms.v1.DecryptRequest; import com.google.cloud.kms.v1.DecryptResponse; import com.google.cloud.kms.v1.DestroyCryptoKeyVersionRequest; @@ -227,6 +229,10 @@ public UnaryCallable macVerifyCallable() { throw new UnsupportedOperationException("Not implemented: macVerifyCallable()"); } + public UnaryCallable decapsulateCallable() { + throw new UnsupportedOperationException("Not implemented: decapsulateCallable()"); + } + public UnaryCallable generateRandomBytesCallable() { throw new UnsupportedOperationException("Not implemented: generateRandomBytesCallable()"); diff --git a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStubSettings.java b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStubSettings.java index c648b285559f..4a0786f5b094 100644 --- a/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStubSettings.java +++ b/java-kms/google-cloud-kms/src/main/java/com/google/cloud/kms/v1/stub/KeyManagementServiceStubSettings.java @@ -58,6 +58,8 @@ import com.google.cloud.kms.v1.CreateKeyRingRequest; import com.google.cloud.kms.v1.CryptoKey; import com.google.cloud.kms.v1.CryptoKeyVersion; +import com.google.cloud.kms.v1.DecapsulateRequest; +import com.google.cloud.kms.v1.DecapsulateResponse; import com.google.cloud.kms.v1.DecryptRequest; import com.google.cloud.kms.v1.DecryptResponse; import com.google.cloud.kms.v1.DestroyCryptoKeyVersionRequest; @@ -219,6 +221,7 @@ public class KeyManagementServiceStubSettings asymmetricDecryptSettings; private final UnaryCallSettings macSignSettings; private final UnaryCallSettings macVerifySettings; + private final UnaryCallSettings decapsulateSettings; private final UnaryCallSettings generateRandomBytesSettings; private final PagedCallSettings< @@ -651,6 +654,11 @@ public UnaryCallSettings macVerifySettings( return macVerifySettings; } + /** Returns the object with the settings used for calls to decapsulate. */ + public UnaryCallSettings decapsulateSettings() { + return decapsulateSettings; + } + /** Returns the object with the settings used for calls to generateRandomBytes. */ public UnaryCallSettings generateRandomBytesSettings() { @@ -823,6 +831,7 @@ protected KeyManagementServiceStubSettings(Builder settingsBuilder) throws IOExc asymmetricDecryptSettings = settingsBuilder.asymmetricDecryptSettings().build(); macSignSettings = settingsBuilder.macSignSettings().build(); macVerifySettings = settingsBuilder.macVerifySettings().build(); + decapsulateSettings = settingsBuilder.decapsulateSettings().build(); generateRandomBytesSettings = settingsBuilder.generateRandomBytesSettings().build(); listLocationsSettings = settingsBuilder.listLocationsSettings().build(); getLocationSettings = settingsBuilder.getLocationSettings().build(); @@ -886,6 +895,8 @@ public static class Builder asymmetricDecryptSettings; private final UnaryCallSettings.Builder macSignSettings; private final UnaryCallSettings.Builder macVerifySettings; + private final UnaryCallSettings.Builder + decapsulateSettings; private final UnaryCallSettings.Builder generateRandomBytesSettings; private final PagedCallSettings.Builder< @@ -977,6 +988,7 @@ protected Builder(ClientContext clientContext) { asymmetricDecryptSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); macSignSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); macVerifySettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + decapsulateSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); generateRandomBytesSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); listLocationsSettings = PagedCallSettings.newBuilder(LIST_LOCATIONS_PAGE_STR_FACT); getLocationSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); @@ -1013,6 +1025,7 @@ protected Builder(ClientContext clientContext) { asymmetricDecryptSettings, macSignSettings, macVerifySettings, + decapsulateSettings, generateRandomBytesSettings, listLocationsSettings, getLocationSettings, @@ -1053,6 +1066,7 @@ protected Builder(KeyManagementServiceStubSettings settings) { asymmetricDecryptSettings = settings.asymmetricDecryptSettings.toBuilder(); macSignSettings = settings.macSignSettings.toBuilder(); macVerifySettings = settings.macVerifySettings.toBuilder(); + decapsulateSettings = settings.decapsulateSettings.toBuilder(); generateRandomBytesSettings = settings.generateRandomBytesSettings.toBuilder(); listLocationsSettings = settings.listLocationsSettings.toBuilder(); getLocationSettings = settings.getLocationSettings.toBuilder(); @@ -1089,6 +1103,7 @@ protected Builder(KeyManagementServiceStubSettings settings) { asymmetricDecryptSettings, macSignSettings, macVerifySettings, + decapsulateSettings, generateRandomBytesSettings, listLocationsSettings, getLocationSettings, @@ -1257,6 +1272,11 @@ private static Builder initDefaults(Builder builder) { .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_1_codes")) .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_1_params")); + builder + .decapsulateSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); + builder .generateRandomBytesSettings() .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_1_codes")) @@ -1459,6 +1479,12 @@ public UnaryCallSettings.Builder macVerifyS return macVerifySettings; } + /** Returns the builder for the settings used for calls to decapsulate. */ + public UnaryCallSettings.Builder + decapsulateSettings() { + return decapsulateSettings; + } + /** Returns the builder for the settings used for calls to generateRandomBytes. */ public UnaryCallSettings.Builder generateRandomBytesSettings() { diff --git a/java-kms/google-cloud-kms/src/main/resources/META-INF/native-image/com.google.cloud.kms.v1/reflect-config.json b/java-kms/google-cloud-kms/src/main/resources/META-INF/native-image/com.google.cloud.kms.v1/reflect-config.json index e6b2f086f8d9..e20f6570bf37 100644 --- a/java-kms/google-cloud-kms/src/main/resources/META-INF/native-image/com.google.cloud.kms.v1/reflect-config.json +++ b/java-kms/google-cloud-kms/src/main/resources/META-INF/native-image/com.google.cloud.kms.v1/reflect-config.json @@ -773,6 +773,42 @@ "allDeclaredClasses": true, "allPublicClasses": true }, + { + "name": "com.google.cloud.kms.v1.DecapsulateRequest", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.kms.v1.DecapsulateRequest$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.kms.v1.DecapsulateResponse", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, + { + "name": "com.google.cloud.kms.v1.DecapsulateResponse$Builder", + "queryAllDeclaredConstructors": true, + "queryAllPublicConstructors": true, + "queryAllDeclaredMethods": true, + "allPublicMethods": true, + "allDeclaredClasses": true, + "allPublicClasses": true + }, { "name": "com.google.cloud.kms.v1.DecryptRequest", "queryAllDeclaredConstructors": true, diff --git a/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientHttpJsonTest.java b/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientHttpJsonTest.java index 744af3a5113a..56722bb71c0d 100644 --- a/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientHttpJsonTest.java +++ b/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientHttpJsonTest.java @@ -2988,6 +2988,78 @@ public void macVerifyExceptionTest2() throws Exception { } } + @Test + public void decapsulateTest() throws Exception { + DecapsulateResponse expectedResponse = + DecapsulateResponse.newBuilder() + .setName("name3373707") + .setSharedSecret(ByteString.EMPTY) + .setSharedSecretCrc32C(1482306981) + .setVerifiedCiphertextCrc32C(true) + .setProtectionLevel(ProtectionLevel.forNumber(0)) + .build(); + mockService.addResponse(expectedResponse); + + DecapsulateRequest request = + DecapsulateRequest.newBuilder() + .setName( + CryptoKeyVersionName.of( + "[PROJECT]", + "[LOCATION]", + "[KEY_RING]", + "[CRYPTO_KEY]", + "[CRYPTO_KEY_VERSION]") + .toString()) + .setCiphertext(ByteString.EMPTY) + .setCiphertextCrc32C(Int64Value.newBuilder().build()) + .build(); + + DecapsulateResponse actualResponse = client.decapsulate(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 decapsulateExceptionTest() throws Exception { + ApiException exception = + ApiExceptionFactory.createException( + new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); + mockService.addException(exception); + + try { + DecapsulateRequest request = + DecapsulateRequest.newBuilder() + .setName( + CryptoKeyVersionName.of( + "[PROJECT]", + "[LOCATION]", + "[KEY_RING]", + "[CRYPTO_KEY]", + "[CRYPTO_KEY_VERSION]") + .toString()) + .setCiphertext(ByteString.EMPTY) + .setCiphertextCrc32C(Int64Value.newBuilder().build()) + .build(); + client.decapsulate(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + @Test public void generateRandomBytesTest() throws Exception { GenerateRandomBytesResponse expectedResponse = diff --git a/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientTest.java b/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientTest.java index aa20aef490c8..1554ffb507cd 100644 --- a/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientTest.java +++ b/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/KeyManagementServiceClientTest.java @@ -2659,6 +2659,74 @@ public void macVerifyExceptionTest2() throws Exception { } } + @Test + public void decapsulateTest() throws Exception { + DecapsulateResponse expectedResponse = + DecapsulateResponse.newBuilder() + .setName("name3373707") + .setSharedSecret(ByteString.EMPTY) + .setSharedSecretCrc32C(1482306981) + .setVerifiedCiphertextCrc32C(true) + .setProtectionLevel(ProtectionLevel.forNumber(0)) + .build(); + mockKeyManagementService.addResponse(expectedResponse); + + DecapsulateRequest request = + DecapsulateRequest.newBuilder() + .setName( + CryptoKeyVersionName.of( + "[PROJECT]", + "[LOCATION]", + "[KEY_RING]", + "[CRYPTO_KEY]", + "[CRYPTO_KEY_VERSION]") + .toString()) + .setCiphertext(ByteString.EMPTY) + .setCiphertextCrc32C(Int64Value.newBuilder().build()) + .build(); + + DecapsulateResponse actualResponse = client.decapsulate(request); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockKeyManagementService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DecapsulateRequest actualRequest = ((DecapsulateRequest) actualRequests.get(0)); + + Assert.assertEquals(request.getName(), actualRequest.getName()); + Assert.assertEquals(request.getCiphertext(), actualRequest.getCiphertext()); + Assert.assertEquals(request.getCiphertextCrc32C(), actualRequest.getCiphertextCrc32C()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void decapsulateExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockKeyManagementService.addException(exception); + + try { + DecapsulateRequest request = + DecapsulateRequest.newBuilder() + .setName( + CryptoKeyVersionName.of( + "[PROJECT]", + "[LOCATION]", + "[KEY_RING]", + "[CRYPTO_KEY]", + "[CRYPTO_KEY_VERSION]") + .toString()) + .setCiphertext(ByteString.EMPTY) + .setCiphertextCrc32C(Int64Value.newBuilder().build()) + .build(); + client.decapsulate(request); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + @Test public void generateRandomBytesTest() throws Exception { GenerateRandomBytesResponse expectedResponse = diff --git a/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/MockKeyManagementServiceImpl.java b/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/MockKeyManagementServiceImpl.java index 23921554ca05..c8d8ee073e21 100644 --- a/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/MockKeyManagementServiceImpl.java +++ b/java-kms/google-cloud-kms/src/test/java/com/google/cloud/kms/v1/MockKeyManagementServiceImpl.java @@ -630,6 +630,27 @@ public void macVerify( } } + @Override + public void decapsulate( + DecapsulateRequest request, StreamObserver responseObserver) { + Object response = responses.poll(); + if (response instanceof DecapsulateResponse) { + requests.add(request); + responseObserver.onNext(((DecapsulateResponse) 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 Decapsulate, expected %s or %s", + response == null ? "null" : response.getClass().getName(), + DecapsulateResponse.class.getName(), + Exception.class.getName()))); + } + } + @Override public void generateRandomBytes( GenerateRandomBytesRequest request, diff --git a/java-kms/grpc-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceGrpc.java b/java-kms/grpc-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceGrpc.java index 0c3af78893dc..367a129744a3 100644 --- a/java-kms/grpc-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceGrpc.java +++ b/java-kms/grpc-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KeyManagementServiceGrpc.java @@ -1269,6 +1269,48 @@ private KeyManagementServiceGrpc() {} return getMacVerifyMethod; } + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.kms.v1.DecapsulateRequest, com.google.cloud.kms.v1.DecapsulateResponse> + getDecapsulateMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "Decapsulate", + requestType = com.google.cloud.kms.v1.DecapsulateRequest.class, + responseType = com.google.cloud.kms.v1.DecapsulateResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.kms.v1.DecapsulateRequest, com.google.cloud.kms.v1.DecapsulateResponse> + getDecapsulateMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.kms.v1.DecapsulateRequest, com.google.cloud.kms.v1.DecapsulateResponse> + getDecapsulateMethod; + if ((getDecapsulateMethod = KeyManagementServiceGrpc.getDecapsulateMethod) == null) { + synchronized (KeyManagementServiceGrpc.class) { + if ((getDecapsulateMethod = KeyManagementServiceGrpc.getDecapsulateMethod) == null) { + KeyManagementServiceGrpc.getDecapsulateMethod = + getDecapsulateMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "Decapsulate")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.kms.v1.DecapsulateRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.kms.v1.DecapsulateResponse.getDefaultInstance())) + .setSchemaDescriptor( + new KeyManagementServiceMethodDescriptorSupplier("Decapsulate")) + .build(); + } + } + } + return getDecapsulateMethod; + } + private static volatile io.grpc.MethodDescriptor< com.google.cloud.kms.v1.GenerateRandomBytesRequest, com.google.cloud.kms.v1.GenerateRandomBytesResponse> @@ -1859,6 +1901,24 @@ default void macVerify( io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getMacVerifyMethod(), responseObserver); } + /** + * + * + *
        +     * Decapsulates data that was encapsulated with a public key retrieved from
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]
        +     * with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose]
        +     * KEY_ENCAPSULATION.
        +     * 
        + */ + default void decapsulate( + com.google.cloud.kms.v1.DecapsulateRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( + getDecapsulateMethod(), responseObserver); + } + /** * * @@ -2443,6 +2503,26 @@ public void macVerify( getChannel().newCall(getMacVerifyMethod(), getCallOptions()), request, responseObserver); } + /** + * + * + *
        +     * Decapsulates data that was encapsulated with a public key retrieved from
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]
        +     * with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose]
        +     * KEY_ENCAPSULATION.
        +     * 
        + */ + public void decapsulate( + com.google.cloud.kms.v1.DecapsulateRequest request, + io.grpc.stub.StreamObserver responseObserver) { + io.grpc.stub.ClientCalls.asyncUnaryCall( + getChannel().newCall(getDecapsulateMethod(), getCallOptions()), + request, + responseObserver); + } + /** * * @@ -2933,6 +3013,23 @@ public com.google.cloud.kms.v1.MacVerifyResponse macVerify( getChannel(), getMacVerifyMethod(), getCallOptions(), request); } + /** + * + * + *
        +     * Decapsulates data that was encapsulated with a public key retrieved from
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]
        +     * with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose]
        +     * KEY_ENCAPSULATION.
        +     * 
        + */ + public com.google.cloud.kms.v1.DecapsulateResponse decapsulate( + com.google.cloud.kms.v1.DecapsulateRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDecapsulateMethod(), getCallOptions(), request); + } + /** * * @@ -3419,6 +3516,23 @@ public com.google.cloud.kms.v1.MacVerifyResponse macVerify( getChannel(), getMacVerifyMethod(), getCallOptions(), request); } + /** + * + * + *
        +     * Decapsulates data that was encapsulated with a public key retrieved from
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]
        +     * with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose]
        +     * KEY_ENCAPSULATION.
        +     * 
        + */ + public com.google.cloud.kms.v1.DecapsulateResponse decapsulate( + com.google.cloud.kms.v1.DecapsulateRequest request) { + return io.grpc.stub.ClientCalls.blockingUnaryCall( + getChannel(), getDecapsulateMethod(), getCallOptions(), request); + } + /** * * @@ -3925,6 +4039,24 @@ protected KeyManagementServiceFutureStub build( getChannel().newCall(getMacVerifyMethod(), getCallOptions()), request); } + /** + * + * + *
        +     * Decapsulates data that was encapsulated with a public key retrieved from
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion]
        +     * with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose]
        +     * KEY_ENCAPSULATION.
        +     * 
        + */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.kms.v1.DecapsulateResponse> + decapsulate(com.google.cloud.kms.v1.DecapsulateRequest request) { + return io.grpc.stub.ClientCalls.futureUnaryCall( + getChannel().newCall(getDecapsulateMethod(), getCallOptions()), request); + } + /** * * @@ -3968,7 +4100,8 @@ protected KeyManagementServiceFutureStub build( private static final int METHODID_ASYMMETRIC_DECRYPT = 24; private static final int METHODID_MAC_SIGN = 25; private static final int METHODID_MAC_VERIFY = 26; - private static final int METHODID_GENERATE_RANDOM_BYTES = 27; + private static final int METHODID_DECAPSULATE = 27; + private static final int METHODID_GENERATE_RANDOM_BYTES = 28; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, @@ -4140,6 +4273,12 @@ public void invoke(Req request, io.grpc.stub.StreamObserver responseObserv (io.grpc.stub.StreamObserver) responseObserver); break; + case METHODID_DECAPSULATE: + serviceImpl.decapsulate( + (com.google.cloud.kms.v1.DecapsulateRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; case METHODID_GENERATE_RANDOM_BYTES: serviceImpl.generateRandomBytes( (com.google.cloud.kms.v1.GenerateRandomBytesRequest) request, @@ -4339,6 +4478,12 @@ public static final io.grpc.ServerServiceDefinition bindService(AsyncService ser new MethodHandlers< com.google.cloud.kms.v1.MacVerifyRequest, com.google.cloud.kms.v1.MacVerifyResponse>(service, METHODID_MAC_VERIFY))) + .addMethod( + getDecapsulateMethod(), + io.grpc.stub.ServerCalls.asyncUnaryCall( + new MethodHandlers< + com.google.cloud.kms.v1.DecapsulateRequest, + com.google.cloud.kms.v1.DecapsulateResponse>(service, METHODID_DECAPSULATE))) .addMethod( getGenerateRandomBytesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -4424,6 +4569,7 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { .addMethod(getAsymmetricDecryptMethod()) .addMethod(getMacSignMethod()) .addMethod(getMacVerifyMethod()) + .addMethod(getDecapsulateMethod()) .addMethod(getGenerateRandomBytesMethod()) .build(); } diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKey.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKey.java index 085168922438..c78e11282442 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKey.java +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKey.java @@ -172,6 +172,19 @@ public enum CryptoKeyPurpose implements com.google.protobuf.ProtocolMessageEnum * MAC = 9; */ MAC(9), + /** + * + * + *
        +     * [CryptoKeys][google.cloud.kms.v1.CryptoKey] with this purpose may be used
        +     * with
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * and [Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate].
        +     * 
        + * + * KEY_ENCAPSULATION = 10; + */ + KEY_ENCAPSULATION(10), UNRECOGNIZED(-1), ; @@ -256,6 +269,20 @@ public enum CryptoKeyPurpose implements com.google.protobuf.ProtocolMessageEnum */ public static final int MAC_VALUE = 9; + /** + * + * + *
        +     * [CryptoKeys][google.cloud.kms.v1.CryptoKey] with this purpose may be used
        +     * with
        +     * [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey]
        +     * and [Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate].
        +     * 
        + * + * KEY_ENCAPSULATION = 10; + */ + public static final int KEY_ENCAPSULATION_VALUE = 10; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -292,6 +319,8 @@ public static CryptoKeyPurpose forNumber(int value) { return RAW_ENCRYPT_DECRYPT; case 9: return MAC; + case 10: + return KEY_ENCAPSULATION; default: return null; } diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKeyVersion.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKeyVersion.java index 39af8a2c615f..d0e771984bc5 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKeyVersion.java +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/CryptoKeyVersion.java @@ -504,6 +504,37 @@ public enum CryptoKeyVersionAlgorithm implements com.google.protobuf.ProtocolMes * EXTERNAL_SYMMETRIC_ENCRYPTION = 18; */ EXTERNAL_SYMMETRIC_ENCRYPTION(18), + /** + * + * + *
        +     * ML-KEM-768 (FIPS 203)
        +     * 
        + * + * ML_KEM_768 = 47; + */ + ML_KEM_768(47), + /** + * + * + *
        +     * ML-KEM-1024 (FIPS 203)
        +     * 
        + * + * ML_KEM_1024 = 48; + */ + ML_KEM_1024(48), + /** + * + * + *
        +     * X-Wing hybrid KEM combining ML-KEM-768 with X25519 following
        +     * datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/.
        +     * 
        + * + * KEM_XWING = 63; + */ + KEM_XWING(63), /** * * @@ -932,6 +963,40 @@ public enum CryptoKeyVersionAlgorithm implements com.google.protobuf.ProtocolMes */ public static final int EXTERNAL_SYMMETRIC_ENCRYPTION_VALUE = 18; + /** + * + * + *
        +     * ML-KEM-768 (FIPS 203)
        +     * 
        + * + * ML_KEM_768 = 47; + */ + public static final int ML_KEM_768_VALUE = 47; + + /** + * + * + *
        +     * ML-KEM-1024 (FIPS 203)
        +     * 
        + * + * ML_KEM_1024 = 48; + */ + public static final int ML_KEM_1024_VALUE = 48; + + /** + * + * + *
        +     * X-Wing hybrid KEM combining ML-KEM-768 with X25519 following
        +     * datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/.
        +     * 
        + * + * KEM_XWING = 63; + */ + public static final int KEM_XWING_VALUE = 63; + /** * * @@ -1052,6 +1117,12 @@ public static CryptoKeyVersionAlgorithm forNumber(int value) { return HMAC_SHA224; case 18: return EXTERNAL_SYMMETRIC_ENCRYPTION; + case 47: + return ML_KEM_768; + case 48: + return ML_KEM_1024; + case 63: + return KEM_XWING; case 56: return PQ_SIGN_ML_DSA_65; case 57: diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateRequest.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateRequest.java new file mode 100644 index 000000000000..e5a1edde8ec5 --- /dev/null +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateRequest.java @@ -0,0 +1,1304 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/kms/v1/service.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.kms.v1; + +/** + * + * + *
        + * Request message for
        + * [KeyManagementService.Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate].
        + * 
        + * + * Protobuf type {@code google.cloud.kms.v1.DecapsulateRequest} + */ +public final class DecapsulateRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.kms.v1.DecapsulateRequest) + DecapsulateRequestOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DecapsulateRequest.newBuilder() to construct. + private DecapsulateRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DecapsulateRequest() { + name_ = ""; + ciphertext_ = com.google.protobuf.ByteString.EMPTY; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DecapsulateRequest(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.kms.v1.DecapsulateRequest.class, + com.google.cloud.kms.v1.DecapsulateRequest.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * Required. The resource name of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +   * decapsulation.
        +   * 
        + * + * + * 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
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +   * decapsulation.
        +   * 
        + * + * + * 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 CIPHERTEXT_FIELD_NUMBER = 2; + private com.google.protobuf.ByteString ciphertext_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
        +   * Required. The ciphertext produced from encapsulation with the
        +   * named [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] public
        +   * key(s).
        +   * 
        + * + * bytes ciphertext = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The ciphertext. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCiphertext() { + return ciphertext_; + } + + public static final int CIPHERTEXT_CRC32C_FIELD_NUMBER = 3; + private com.google.protobuf.Int64Value ciphertextCrc32C_; + + /** + * + * + *
        +   * Optional. A CRC32C checksum of the
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +   * If specified,
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * verify the integrity of the received
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +   * using this checksum.
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * report an error if the checksum verification fails. If you receive a
        +   * checksum error, your client should verify that
        +   * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +   * is equal to
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +   * and if so, perform a limited number of retries. A persistent mismatch may
        +   * indicate an issue in your computation of the CRC32C checksum. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ciphertextCrc32c field is set. + */ + @java.lang.Override + public boolean hasCiphertextCrc32C() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Optional. A CRC32C checksum of the
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +   * If specified,
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * verify the integrity of the received
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +   * using this checksum.
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * report an error if the checksum verification fails. If you receive a
        +   * checksum error, your client should verify that
        +   * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +   * is equal to
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +   * and if so, perform a limited number of retries. A persistent mismatch may
        +   * indicate an issue in your computation of the CRC32C checksum. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ciphertextCrc32c. + */ + @java.lang.Override + public com.google.protobuf.Int64Value getCiphertextCrc32C() { + return ciphertextCrc32C_ == null + ? com.google.protobuf.Int64Value.getDefaultInstance() + : ciphertextCrc32C_; + } + + /** + * + * + *
        +   * Optional. A CRC32C checksum of the
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +   * If specified,
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * verify the integrity of the received
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +   * using this checksum.
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * report an error if the checksum verification fails. If you receive a
        +   * checksum error, your client should verify that
        +   * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +   * is equal to
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +   * and if so, perform a limited number of retries. A persistent mismatch may
        +   * indicate an issue in your computation of the CRC32C checksum. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + @java.lang.Override + public com.google.protobuf.Int64ValueOrBuilder getCiphertextCrc32COrBuilder() { + return ciphertextCrc32C_ == null + ? com.google.protobuf.Int64Value.getDefaultInstance() + : ciphertextCrc32C_; + } + + 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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!ciphertext_.isEmpty()) { + output.writeBytes(2, ciphertext_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeMessage(3, getCiphertextCrc32C()); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!ciphertext_.isEmpty()) { + size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, ciphertext_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCiphertextCrc32C()); + } + 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.kms.v1.DecapsulateRequest)) { + return super.equals(obj); + } + com.google.cloud.kms.v1.DecapsulateRequest other = + (com.google.cloud.kms.v1.DecapsulateRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!getCiphertext().equals(other.getCiphertext())) return false; + if (hasCiphertextCrc32C() != other.hasCiphertextCrc32C()) return false; + if (hasCiphertextCrc32C()) { + if (!getCiphertextCrc32C().equals(other.getCiphertextCrc32C())) 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) + CIPHERTEXT_FIELD_NUMBER; + hash = (53 * hash) + getCiphertext().hashCode(); + if (hasCiphertextCrc32C()) { + hash = (37 * hash) + CIPHERTEXT_CRC32C_FIELD_NUMBER; + hash = (53 * hash) + getCiphertextCrc32C().hashCode(); + } + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest 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.kms.v1.DecapsulateRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest 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.kms.v1.DecapsulateRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.kms.v1.DecapsulateRequest 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Request message for
        +   * [KeyManagementService.Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate].
        +   * 
        + * + * Protobuf type {@code google.cloud.kms.v1.DecapsulateRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.kms.v1.DecapsulateRequest) + com.google.cloud.kms.v1.DecapsulateRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.kms.v1.DecapsulateRequest.class, + com.google.cloud.kms.v1.DecapsulateRequest.Builder.class); + } + + // Construct using com.google.cloud.kms.v1.DecapsulateRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getCiphertextCrc32CFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + ciphertext_ = com.google.protobuf.ByteString.EMPTY; + ciphertextCrc32C_ = null; + if (ciphertextCrc32CBuilder_ != null) { + ciphertextCrc32CBuilder_.dispose(); + ciphertextCrc32CBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.kms.v1.DecapsulateRequest getDefaultInstanceForType() { + return com.google.cloud.kms.v1.DecapsulateRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.kms.v1.DecapsulateRequest build() { + com.google.cloud.kms.v1.DecapsulateRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.kms.v1.DecapsulateRequest buildPartial() { + com.google.cloud.kms.v1.DecapsulateRequest result = + new com.google.cloud.kms.v1.DecapsulateRequest(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.kms.v1.DecapsulateRequest result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.ciphertext_ = ciphertext_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.ciphertextCrc32C_ = + ciphertextCrc32CBuilder_ == null ? ciphertextCrc32C_ : ciphertextCrc32CBuilder_.build(); + to_bitField0_ |= 0x00000001; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.kms.v1.DecapsulateRequest) { + return mergeFrom((com.google.cloud.kms.v1.DecapsulateRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.kms.v1.DecapsulateRequest other) { + if (other == com.google.cloud.kms.v1.DecapsulateRequest.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getCiphertext() != com.google.protobuf.ByteString.EMPTY) { + setCiphertext(other.getCiphertext()); + } + if (other.hasCiphertextCrc32C()) { + mergeCiphertextCrc32C(other.getCiphertextCrc32C()); + } + 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: + { + ciphertext_ = input.readBytes(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 26: + { + input.readMessage( + getCiphertextCrc32CFieldBuilder().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 name_ = ""; + + /** + * + * + *
        +     * Required. The resource name of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +     * decapsulation.
        +     * 
        + * + * + * 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
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +     * decapsulation.
        +     * 
        + * + * + * 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
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +     * decapsulation.
        +     * 
        + * + * + * 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
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +     * decapsulation.
        +     * 
        + * + * + * 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
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +     * decapsulation.
        +     * 
        + * + * + * 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.protobuf.ByteString ciphertext_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
        +     * Required. The ciphertext produced from encapsulation with the
        +     * named [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] public
        +     * key(s).
        +     * 
        + * + * bytes ciphertext = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The ciphertext. + */ + @java.lang.Override + public com.google.protobuf.ByteString getCiphertext() { + return ciphertext_; + } + + /** + * + * + *
        +     * Required. The ciphertext produced from encapsulation with the
        +     * named [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] public
        +     * key(s).
        +     * 
        + * + * bytes ciphertext = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The ciphertext to set. + * @return This builder for chaining. + */ + public Builder setCiphertext(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + ciphertext_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Required. The ciphertext produced from encapsulation with the
        +     * named [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] public
        +     * key(s).
        +     * 
        + * + * bytes ciphertext = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearCiphertext() { + bitField0_ = (bitField0_ & ~0x00000002); + ciphertext_ = getDefaultInstance().getCiphertext(); + onChanged(); + return this; + } + + private com.google.protobuf.Int64Value ciphertextCrc32C_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Int64Value, + com.google.protobuf.Int64Value.Builder, + com.google.protobuf.Int64ValueOrBuilder> + ciphertextCrc32CBuilder_; + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ciphertextCrc32c field is set. + */ + public boolean hasCiphertextCrc32C() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ciphertextCrc32c. + */ + public com.google.protobuf.Int64Value getCiphertextCrc32C() { + if (ciphertextCrc32CBuilder_ == null) { + return ciphertextCrc32C_ == null + ? com.google.protobuf.Int64Value.getDefaultInstance() + : ciphertextCrc32C_; + } else { + return ciphertextCrc32CBuilder_.getMessage(); + } + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCiphertextCrc32C(com.google.protobuf.Int64Value value) { + if (ciphertextCrc32CBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ciphertextCrc32C_ = value; + } else { + ciphertextCrc32CBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder setCiphertextCrc32C(com.google.protobuf.Int64Value.Builder builderForValue) { + if (ciphertextCrc32CBuilder_ == null) { + ciphertextCrc32C_ = builderForValue.build(); + } else { + ciphertextCrc32CBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder mergeCiphertextCrc32C(com.google.protobuf.Int64Value value) { + if (ciphertextCrc32CBuilder_ == null) { + if (((bitField0_ & 0x00000004) != 0) + && ciphertextCrc32C_ != null + && ciphertextCrc32C_ != com.google.protobuf.Int64Value.getDefaultInstance()) { + getCiphertextCrc32CBuilder().mergeFrom(value); + } else { + ciphertextCrc32C_ = value; + } + } else { + ciphertextCrc32CBuilder_.mergeFrom(value); + } + if (ciphertextCrc32C_ != null) { + bitField0_ |= 0x00000004; + onChanged(); + } + return this; + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public Builder clearCiphertextCrc32C() { + bitField0_ = (bitField0_ & ~0x00000004); + ciphertextCrc32C_ = null; + if (ciphertextCrc32CBuilder_ != null) { + ciphertextCrc32CBuilder_.dispose(); + ciphertextCrc32CBuilder_ = null; + } + onChanged(); + return this; + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.Int64Value.Builder getCiphertextCrc32CBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return getCiphertextCrc32CFieldBuilder().getBuilder(); + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + public com.google.protobuf.Int64ValueOrBuilder getCiphertextCrc32COrBuilder() { + if (ciphertextCrc32CBuilder_ != null) { + return ciphertextCrc32CBuilder_.getMessageOrBuilder(); + } else { + return ciphertextCrc32C_ == null + ? com.google.protobuf.Int64Value.getDefaultInstance() + : ciphertextCrc32C_; + } + } + + /** + * + * + *
        +     * Optional. A CRC32C checksum of the
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +     * If specified,
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * verify the integrity of the received
        +     * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +     * using this checksum.
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +     * report an error if the checksum verification fails. If you receive a
        +     * checksum error, your client should verify that
        +     * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +     * is equal to
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +     * and if so, perform a limited number of retries. A persistent mismatch may
        +     * indicate an issue in your computation of the CRC32C checksum. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Int64Value, + com.google.protobuf.Int64Value.Builder, + com.google.protobuf.Int64ValueOrBuilder> + getCiphertextCrc32CFieldBuilder() { + if (ciphertextCrc32CBuilder_ == null) { + ciphertextCrc32CBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Int64Value, + com.google.protobuf.Int64Value.Builder, + com.google.protobuf.Int64ValueOrBuilder>( + getCiphertextCrc32C(), getParentForChildren(), isClean()); + ciphertextCrc32C_ = null; + } + return ciphertextCrc32CBuilder_; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.kms.v1.DecapsulateRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.kms.v1.DecapsulateRequest) + private static final com.google.cloud.kms.v1.DecapsulateRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.kms.v1.DecapsulateRequest(); + } + + public static com.google.cloud.kms.v1.DecapsulateRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DecapsulateRequest 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.kms.v1.DecapsulateRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateRequestOrBuilder.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateRequestOrBuilder.java new file mode 100644 index 000000000000..ea719773932d --- /dev/null +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateRequestOrBuilder.java @@ -0,0 +1,172 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/kms/v1/service.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.kms.v1; + +public interface DecapsulateRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.kms.v1.DecapsulateRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * Required. The resource name of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +   * decapsulation.
        +   * 
        + * + * + * 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
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for
        +   * decapsulation.
        +   * 
        + * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * Required. The ciphertext produced from encapsulation with the
        +   * named [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] public
        +   * key(s).
        +   * 
        + * + * bytes ciphertext = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The ciphertext. + */ + com.google.protobuf.ByteString getCiphertext(); + + /** + * + * + *
        +   * Optional. A CRC32C checksum of the
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +   * If specified,
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * verify the integrity of the received
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +   * using this checksum.
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * report an error if the checksum verification fails. If you receive a
        +   * checksum error, your client should verify that
        +   * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +   * is equal to
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +   * and if so, perform a limited number of retries. A persistent mismatch may
        +   * indicate an issue in your computation of the CRC32C checksum. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return Whether the ciphertextCrc32c field is set. + */ + boolean hasCiphertextCrc32C(); + + /** + * + * + *
        +   * Optional. A CRC32C checksum of the
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +   * If specified,
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * verify the integrity of the received
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +   * using this checksum.
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * report an error if the checksum verification fails. If you receive a
        +   * checksum error, your client should verify that
        +   * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +   * is equal to
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +   * and if so, perform a limited number of retries. A persistent mismatch may
        +   * indicate an issue in your computation of the CRC32C checksum. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + * + * @return The ciphertextCrc32c. + */ + com.google.protobuf.Int64Value getCiphertextCrc32C(); + + /** + * + * + *
        +   * Optional. A CRC32C checksum of the
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext].
        +   * If specified,
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * verify the integrity of the received
        +   * [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]
        +   * using this checksum.
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will
        +   * report an error if the checksum verification fails. If you receive a
        +   * checksum error, your client should verify that
        +   * CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext])
        +   * is equal to
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c],
        +   * and if so, perform a limited number of retries. A persistent mismatch may
        +   * indicate an issue in your computation of the CRC32C checksum. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * + * .google.protobuf.Int64Value ciphertext_crc32c = 3 [(.google.api.field_behavior) = OPTIONAL]; + * + */ + com.google.protobuf.Int64ValueOrBuilder getCiphertextCrc32COrBuilder(); +} diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateResponse.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateResponse.java new file mode 100644 index 000000000000..674a31c9c36e --- /dev/null +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateResponse.java @@ -0,0 +1,1314 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/kms/v1/service.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.kms.v1; + +/** + * + * + *
        + * Response message for
        + * [KeyManagementService.Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate].
        + * 
        + * + * Protobuf type {@code google.cloud.kms.v1.DecapsulateResponse} + */ +public final class DecapsulateResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.kms.v1.DecapsulateResponse) + DecapsulateResponseOrBuilder { + private static final long serialVersionUID = 0L; + + // Use DecapsulateResponse.newBuilder() to construct. + private DecapsulateResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DecapsulateResponse() { + name_ = ""; + sharedSecret_ = com.google.protobuf.ByteString.EMPTY; + protectionLevel_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DecapsulateResponse(); + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.kms.v1.DecapsulateResponse.class, + com.google.cloud.kms.v1.DecapsulateResponse.Builder.class); + } + + private int bitField0_; + public static final int NAME_FIELD_NUMBER = 1; + + @SuppressWarnings("serial") + private volatile java.lang.Object name_ = ""; + + /** + * + * + *
        +   * The resource name of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +   * decapsulation. Check this field to verify that the intended resource was
        +   * used for decapsulation.
        +   * 
        + * + * string name = 1; + * + * @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; + } + } + + /** + * + * + *
        +   * The resource name of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +   * decapsulation. Check this field to verify that the intended resource was
        +   * used for decapsulation.
        +   * 
        + * + * string name = 1; + * + * @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 SHARED_SECRET_FIELD_NUMBER = 2; + private com.google.protobuf.ByteString sharedSecret_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
        +   * The decapsulated shared_secret originally encapsulated with the matching
        +   * public key.
        +   * 
        + * + * bytes shared_secret = 2; + * + * @return The sharedSecret. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSharedSecret() { + return sharedSecret_; + } + + public static final int SHARED_SECRET_CRC32C_FIELD_NUMBER = 3; + private long sharedSecretCrc32C_ = 0L; + + /** + * + * + *
        +   * Integrity verification field. A CRC32C checksum of the returned
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +   * An integrity check of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * can be performed by computing the CRC32C checksum of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * and comparing your results to this field. Discard the response in case of
        +   * non-matching checksum values, and perform a limited number of retries. A
        +   * persistent mismatch may indicate an issue in your computation of the CRC32C
        +   * checksum. Note: receiving this response message indicates that
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +   * successfully decrypt the
        +   * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return Whether the sharedSecretCrc32c field is set. + */ + @java.lang.Override + public boolean hasSharedSecretCrc32C() { + return ((bitField0_ & 0x00000001) != 0); + } + + /** + * + * + *
        +   * Integrity verification field. A CRC32C checksum of the returned
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +   * An integrity check of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * can be performed by computing the CRC32C checksum of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * and comparing your results to this field. Discard the response in case of
        +   * non-matching checksum values, and perform a limited number of retries. A
        +   * persistent mismatch may indicate an issue in your computation of the CRC32C
        +   * checksum. Note: receiving this response message indicates that
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +   * successfully decrypt the
        +   * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return The sharedSecretCrc32c. + */ + @java.lang.Override + public long getSharedSecretCrc32C() { + return sharedSecretCrc32C_; + } + + public static final int VERIFIED_CIPHERTEXT_CRC32C_FIELD_NUMBER = 4; + private boolean verifiedCiphertextCrc32C_ = false; + + /** + * + * + *
        +   * Integrity verification field. A flag indicating whether
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +   * was received by
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] and used
        +   * for the integrity verification of the
        +   * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. A false
        +   * value of this field indicates either that
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +   * was left unset or that it was not delivered to
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService]. If you've
        +   * set
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +   * but this field is still false, discard the response and perform a limited
        +   * number of retries.
        +   * 
        + * + * bool verified_ciphertext_crc32c = 4; + * + * @return The verifiedCiphertextCrc32c. + */ + @java.lang.Override + public boolean getVerifiedCiphertextCrc32C() { + return verifiedCiphertextCrc32C_; + } + + public static final int PROTECTION_LEVEL_FIELD_NUMBER = 5; + private int protectionLevel_ = 0; + + /** + * + * + *
        +   * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +   * decapsulation.
        +   * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return The enum numeric value on the wire for protectionLevel. + */ + @java.lang.Override + public int getProtectionLevelValue() { + return protectionLevel_; + } + + /** + * + * + *
        +   * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +   * decapsulation.
        +   * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return The protectionLevel. + */ + @java.lang.Override + public com.google.cloud.kms.v1.ProtectionLevel getProtectionLevel() { + com.google.cloud.kms.v1.ProtectionLevel result = + com.google.cloud.kms.v1.ProtectionLevel.forNumber(protectionLevel_); + return result == null ? com.google.cloud.kms.v1.ProtectionLevel.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.GeneratedMessageV3.isStringEmpty(name_)) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!sharedSecret_.isEmpty()) { + output.writeBytes(2, sharedSecret_); + } + if (((bitField0_ & 0x00000001) != 0)) { + output.writeInt64(3, sharedSecretCrc32C_); + } + if (verifiedCiphertextCrc32C_ != false) { + output.writeBool(4, verifiedCiphertextCrc32C_); + } + if (protectionLevel_ + != com.google.cloud.kms.v1.ProtectionLevel.PROTECTION_LEVEL_UNSPECIFIED.getNumber()) { + output.writeEnum(5, protectionLevel_); + } + getUnknownFields().writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!sharedSecret_.isEmpty()) { + size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, sharedSecret_); + } + if (((bitField0_ & 0x00000001) != 0)) { + size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, sharedSecretCrc32C_); + } + if (verifiedCiphertextCrc32C_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, verifiedCiphertextCrc32C_); + } + if (protectionLevel_ + != com.google.cloud.kms.v1.ProtectionLevel.PROTECTION_LEVEL_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, protectionLevel_); + } + 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.kms.v1.DecapsulateResponse)) { + return super.equals(obj); + } + com.google.cloud.kms.v1.DecapsulateResponse other = + (com.google.cloud.kms.v1.DecapsulateResponse) obj; + + if (!getName().equals(other.getName())) return false; + if (!getSharedSecret().equals(other.getSharedSecret())) return false; + if (hasSharedSecretCrc32C() != other.hasSharedSecretCrc32C()) return false; + if (hasSharedSecretCrc32C()) { + if (getSharedSecretCrc32C() != other.getSharedSecretCrc32C()) return false; + } + if (getVerifiedCiphertextCrc32C() != other.getVerifiedCiphertextCrc32C()) return false; + if (protectionLevel_ != other.protectionLevel_) 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) + SHARED_SECRET_FIELD_NUMBER; + hash = (53 * hash) + getSharedSecret().hashCode(); + if (hasSharedSecretCrc32C()) { + hash = (37 * hash) + SHARED_SECRET_CRC32C_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSharedSecretCrc32C()); + } + hash = (37 * hash) + VERIFIED_CIPHERTEXT_CRC32C_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getVerifiedCiphertextCrc32C()); + hash = (37 * hash) + PROTECTION_LEVEL_FIELD_NUMBER; + hash = (53 * hash) + protectionLevel_; + hash = (29 * hash) + getUnknownFields().hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse 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.kms.v1.DecapsulateResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse 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.kms.v1.DecapsulateResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.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.kms.v1.DecapsulateResponse 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.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + + /** + * + * + *
        +   * Response message for
        +   * [KeyManagementService.Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate].
        +   * 
        + * + * Protobuf type {@code google.cloud.kms.v1.DecapsulateResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.kms.v1.DecapsulateResponse) + com.google.cloud.kms.v1.DecapsulateResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.kms.v1.DecapsulateResponse.class, + com.google.cloud.kms.v1.DecapsulateResponse.Builder.class); + } + + // Construct using com.google.cloud.kms.v1.DecapsulateResponse.newBuilder() + private Builder() {} + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + } + + @java.lang.Override + public Builder clear() { + super.clear(); + bitField0_ = 0; + name_ = ""; + sharedSecret_ = com.google.protobuf.ByteString.EMPTY; + sharedSecretCrc32C_ = 0L; + verifiedCiphertextCrc32C_ = false; + protectionLevel_ = 0; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.kms.v1.KmsProto + .internal_static_google_cloud_kms_v1_DecapsulateResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.kms.v1.DecapsulateResponse getDefaultInstanceForType() { + return com.google.cloud.kms.v1.DecapsulateResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.kms.v1.DecapsulateResponse build() { + com.google.cloud.kms.v1.DecapsulateResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.kms.v1.DecapsulateResponse buildPartial() { + com.google.cloud.kms.v1.DecapsulateResponse result = + new com.google.cloud.kms.v1.DecapsulateResponse(this); + if (bitField0_ != 0) { + buildPartial0(result); + } + onBuilt(); + return result; + } + + private void buildPartial0(com.google.cloud.kms.v1.DecapsulateResponse result) { + int from_bitField0_ = bitField0_; + if (((from_bitField0_ & 0x00000001) != 0)) { + result.name_ = name_; + } + if (((from_bitField0_ & 0x00000002) != 0)) { + result.sharedSecret_ = sharedSecret_; + } + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000004) != 0)) { + result.sharedSecretCrc32C_ = sharedSecretCrc32C_; + to_bitField0_ |= 0x00000001; + } + if (((from_bitField0_ & 0x00000008) != 0)) { + result.verifiedCiphertextCrc32C_ = verifiedCiphertextCrc32C_; + } + if (((from_bitField0_ & 0x00000010) != 0)) { + result.protectionLevel_ = protectionLevel_; + } + result.bitField0_ |= to_bitField0_; + } + + @java.lang.Override + public Builder clone() { + return super.clone(); + } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { + return super.setRepeatedField(field, index, value); + } + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.kms.v1.DecapsulateResponse) { + return mergeFrom((com.google.cloud.kms.v1.DecapsulateResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.kms.v1.DecapsulateResponse other) { + if (other == com.google.cloud.kms.v1.DecapsulateResponse.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + bitField0_ |= 0x00000001; + onChanged(); + } + if (other.getSharedSecret() != com.google.protobuf.ByteString.EMPTY) { + setSharedSecret(other.getSharedSecret()); + } + if (other.hasSharedSecretCrc32C()) { + setSharedSecretCrc32C(other.getSharedSecretCrc32C()); + } + if (other.getVerifiedCiphertextCrc32C() != false) { + setVerifiedCiphertextCrc32C(other.getVerifiedCiphertextCrc32C()); + } + if (other.protectionLevel_ != 0) { + setProtectionLevelValue(other.getProtectionLevelValue()); + } + 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: + { + sharedSecret_ = input.readBytes(); + bitField0_ |= 0x00000002; + break; + } // case 18 + case 24: + { + sharedSecretCrc32C_ = input.readInt64(); + bitField0_ |= 0x00000004; + break; + } // case 24 + case 32: + { + verifiedCiphertextCrc32C_ = input.readBool(); + bitField0_ |= 0x00000008; + break; + } // case 32 + case 40: + { + protectionLevel_ = 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 name_ = ""; + + /** + * + * + *
        +     * The resource name of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +     * decapsulation. Check this field to verify that the intended resource was
        +     * used for decapsulation.
        +     * 
        + * + * string name = 1; + * + * @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; + } + } + + /** + * + * + *
        +     * The resource name of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +     * decapsulation. Check this field to verify that the intended resource was
        +     * used for decapsulation.
        +     * 
        + * + * string name = 1; + * + * @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; + } + } + + /** + * + * + *
        +     * The resource name of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +     * decapsulation. Check this field to verify that the intended resource was
        +     * used for decapsulation.
        +     * 
        + * + * string name = 1; + * + * @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; + } + + /** + * + * + *
        +     * The resource name of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +     * decapsulation. Check this field to verify that the intended resource was
        +     * used for decapsulation.
        +     * 
        + * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + name_ = getDefaultInstance().getName(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + + /** + * + * + *
        +     * The resource name of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +     * decapsulation. Check this field to verify that the intended resource was
        +     * used for decapsulation.
        +     * 
        + * + * string name = 1; + * + * @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.ByteString sharedSecret_ = com.google.protobuf.ByteString.EMPTY; + + /** + * + * + *
        +     * The decapsulated shared_secret originally encapsulated with the matching
        +     * public key.
        +     * 
        + * + * bytes shared_secret = 2; + * + * @return The sharedSecret. + */ + @java.lang.Override + public com.google.protobuf.ByteString getSharedSecret() { + return sharedSecret_; + } + + /** + * + * + *
        +     * The decapsulated shared_secret originally encapsulated with the matching
        +     * public key.
        +     * 
        + * + * bytes shared_secret = 2; + * + * @param value The sharedSecret to set. + * @return This builder for chaining. + */ + public Builder setSharedSecret(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + sharedSecret_ = value; + bitField0_ |= 0x00000002; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The decapsulated shared_secret originally encapsulated with the matching
        +     * public key.
        +     * 
        + * + * bytes shared_secret = 2; + * + * @return This builder for chaining. + */ + public Builder clearSharedSecret() { + bitField0_ = (bitField0_ & ~0x00000002); + sharedSecret_ = getDefaultInstance().getSharedSecret(); + onChanged(); + return this; + } + + private long sharedSecretCrc32C_; + + /** + * + * + *
        +     * Integrity verification field. A CRC32C checksum of the returned
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +     * An integrity check of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * can be performed by computing the CRC32C checksum of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * and comparing your results to this field. Discard the response in case of
        +     * non-matching checksum values, and perform a limited number of retries. A
        +     * persistent mismatch may indicate an issue in your computation of the CRC32C
        +     * checksum. Note: receiving this response message indicates that
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +     * successfully decrypt the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return Whether the sharedSecretCrc32c field is set. + */ + @java.lang.Override + public boolean hasSharedSecretCrc32C() { + return ((bitField0_ & 0x00000004) != 0); + } + + /** + * + * + *
        +     * Integrity verification field. A CRC32C checksum of the returned
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +     * An integrity check of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * can be performed by computing the CRC32C checksum of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * and comparing your results to this field. Discard the response in case of
        +     * non-matching checksum values, and perform a limited number of retries. A
        +     * persistent mismatch may indicate an issue in your computation of the CRC32C
        +     * checksum. Note: receiving this response message indicates that
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +     * successfully decrypt the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return The sharedSecretCrc32c. + */ + @java.lang.Override + public long getSharedSecretCrc32C() { + return sharedSecretCrc32C_; + } + + /** + * + * + *
        +     * Integrity verification field. A CRC32C checksum of the returned
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +     * An integrity check of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * can be performed by computing the CRC32C checksum of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * and comparing your results to this field. Discard the response in case of
        +     * non-matching checksum values, and perform a limited number of retries. A
        +     * persistent mismatch may indicate an issue in your computation of the CRC32C
        +     * checksum. Note: receiving this response message indicates that
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +     * successfully decrypt the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @param value The sharedSecretCrc32c to set. + * @return This builder for chaining. + */ + public Builder setSharedSecretCrc32C(long value) { + + sharedSecretCrc32C_ = value; + bitField0_ |= 0x00000004; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Integrity verification field. A CRC32C checksum of the returned
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +     * An integrity check of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * can be performed by computing the CRC32C checksum of
        +     * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +     * and comparing your results to this field. Discard the response in case of
        +     * non-matching checksum values, and perform a limited number of retries. A
        +     * persistent mismatch may indicate an issue in your computation of the CRC32C
        +     * checksum. Note: receiving this response message indicates that
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +     * successfully decrypt the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +     * field is defined as int64 for reasons of compatibility across different
        +     * languages. However, it is a non-negative integer, which will never exceed
        +     * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +     * this type.
        +     * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return This builder for chaining. + */ + public Builder clearSharedSecretCrc32C() { + bitField0_ = (bitField0_ & ~0x00000004); + sharedSecretCrc32C_ = 0L; + onChanged(); + return this; + } + + private boolean verifiedCiphertextCrc32C_; + + /** + * + * + *
        +     * Integrity verification field. A flag indicating whether
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * was received by
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] and used
        +     * for the integrity verification of the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. A false
        +     * value of this field indicates either that
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * was left unset or that it was not delivered to
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService]. If you've
        +     * set
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * but this field is still false, discard the response and perform a limited
        +     * number of retries.
        +     * 
        + * + * bool verified_ciphertext_crc32c = 4; + * + * @return The verifiedCiphertextCrc32c. + */ + @java.lang.Override + public boolean getVerifiedCiphertextCrc32C() { + return verifiedCiphertextCrc32C_; + } + + /** + * + * + *
        +     * Integrity verification field. A flag indicating whether
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * was received by
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] and used
        +     * for the integrity verification of the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. A false
        +     * value of this field indicates either that
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * was left unset or that it was not delivered to
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService]. If you've
        +     * set
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * but this field is still false, discard the response and perform a limited
        +     * number of retries.
        +     * 
        + * + * bool verified_ciphertext_crc32c = 4; + * + * @param value The verifiedCiphertextCrc32c to set. + * @return This builder for chaining. + */ + public Builder setVerifiedCiphertextCrc32C(boolean value) { + + verifiedCiphertextCrc32C_ = value; + bitField0_ |= 0x00000008; + onChanged(); + return this; + } + + /** + * + * + *
        +     * Integrity verification field. A flag indicating whether
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * was received by
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] and used
        +     * for the integrity verification of the
        +     * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. A false
        +     * value of this field indicates either that
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * was left unset or that it was not delivered to
        +     * [KeyManagementService][google.cloud.kms.v1.KeyManagementService]. If you've
        +     * set
        +     * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +     * but this field is still false, discard the response and perform a limited
        +     * number of retries.
        +     * 
        + * + * bool verified_ciphertext_crc32c = 4; + * + * @return This builder for chaining. + */ + public Builder clearVerifiedCiphertextCrc32C() { + bitField0_ = (bitField0_ & ~0x00000008); + verifiedCiphertextCrc32C_ = false; + onChanged(); + return this; + } + + private int protectionLevel_ = 0; + + /** + * + * + *
        +     * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +     * decapsulation.
        +     * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return The enum numeric value on the wire for protectionLevel. + */ + @java.lang.Override + public int getProtectionLevelValue() { + return protectionLevel_; + } + + /** + * + * + *
        +     * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +     * decapsulation.
        +     * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @param value The enum numeric value on the wire for protectionLevel to set. + * @return This builder for chaining. + */ + public Builder setProtectionLevelValue(int value) { + protectionLevel_ = value; + bitField0_ |= 0x00000010; + onChanged(); + return this; + } + + /** + * + * + *
        +     * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +     * decapsulation.
        +     * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return The protectionLevel. + */ + @java.lang.Override + public com.google.cloud.kms.v1.ProtectionLevel getProtectionLevel() { + com.google.cloud.kms.v1.ProtectionLevel result = + com.google.cloud.kms.v1.ProtectionLevel.forNumber(protectionLevel_); + return result == null ? com.google.cloud.kms.v1.ProtectionLevel.UNRECOGNIZED : result; + } + + /** + * + * + *
        +     * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +     * decapsulation.
        +     * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @param value The protectionLevel to set. + * @return This builder for chaining. + */ + public Builder setProtectionLevel(com.google.cloud.kms.v1.ProtectionLevel value) { + if (value == null) { + throw new NullPointerException(); + } + bitField0_ |= 0x00000010; + protectionLevel_ = value.getNumber(); + onChanged(); + return this; + } + + /** + * + * + *
        +     * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +     * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +     * decapsulation.
        +     * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return This builder for chaining. + */ + public Builder clearProtectionLevel() { + bitField0_ = (bitField0_ & ~0x00000010); + protectionLevel_ = 0; + onChanged(); + return this; + } + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); + } + + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); + } + + // @@protoc_insertion_point(builder_scope:google.cloud.kms.v1.DecapsulateResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.kms.v1.DecapsulateResponse) + private static final com.google.cloud.kms.v1.DecapsulateResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.kms.v1.DecapsulateResponse(); + } + + public static com.google.cloud.kms.v1.DecapsulateResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DecapsulateResponse 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.kms.v1.DecapsulateResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateResponseOrBuilder.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateResponseOrBuilder.java new file mode 100644 index 000000000000..4fb3da813d98 --- /dev/null +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/DecapsulateResponseOrBuilder.java @@ -0,0 +1,186 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: google/cloud/kms/v1/service.proto + +// Protobuf Java Version: 3.25.8 +package com.google.cloud.kms.v1; + +public interface DecapsulateResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.kms.v1.DecapsulateResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
        +   * The resource name of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +   * decapsulation. Check this field to verify that the intended resource was
        +   * used for decapsulation.
        +   * 
        + * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + + /** + * + * + *
        +   * The resource name of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for
        +   * decapsulation. Check this field to verify that the intended resource was
        +   * used for decapsulation.
        +   * 
        + * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
        +   * The decapsulated shared_secret originally encapsulated with the matching
        +   * public key.
        +   * 
        + * + * bytes shared_secret = 2; + * + * @return The sharedSecret. + */ + com.google.protobuf.ByteString getSharedSecret(); + + /** + * + * + *
        +   * Integrity verification field. A CRC32C checksum of the returned
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +   * An integrity check of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * can be performed by computing the CRC32C checksum of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * and comparing your results to this field. Discard the response in case of
        +   * non-matching checksum values, and perform a limited number of retries. A
        +   * persistent mismatch may indicate an issue in your computation of the CRC32C
        +   * checksum. Note: receiving this response message indicates that
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +   * successfully decrypt the
        +   * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return Whether the sharedSecretCrc32c field is set. + */ + boolean hasSharedSecretCrc32C(); + + /** + * + * + *
        +   * Integrity verification field. A CRC32C checksum of the returned
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret].
        +   * An integrity check of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * can be performed by computing the CRC32C checksum of
        +   * [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]
        +   * and comparing your results to this field. Discard the response in case of
        +   * non-matching checksum values, and perform a limited number of retries. A
        +   * persistent mismatch may indicate an issue in your computation of the CRC32C
        +   * checksum. Note: receiving this response message indicates that
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to
        +   * successfully decrypt the
        +   * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This
        +   * field is defined as int64 for reasons of compatibility across different
        +   * languages. However, it is a non-negative integer, which will never exceed
        +   * 2^32-1, and can be safely downconverted to uint32 in languages that support
        +   * this type.
        +   * 
        + * + * optional int64 shared_secret_crc32c = 3; + * + * @return The sharedSecretCrc32c. + */ + long getSharedSecretCrc32C(); + + /** + * + * + *
        +   * Integrity verification field. A flag indicating whether
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +   * was received by
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService] and used
        +   * for the integrity verification of the
        +   * [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. A false
        +   * value of this field indicates either that
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +   * was left unset or that it was not delivered to
        +   * [KeyManagementService][google.cloud.kms.v1.KeyManagementService]. If you've
        +   * set
        +   * [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c]
        +   * but this field is still false, discard the response and perform a limited
        +   * number of retries.
        +   * 
        + * + * bool verified_ciphertext_crc32c = 4; + * + * @return The verifiedCiphertextCrc32c. + */ + boolean getVerifiedCiphertextCrc32C(); + + /** + * + * + *
        +   * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +   * decapsulation.
        +   * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return The enum numeric value on the wire for protectionLevel. + */ + int getProtectionLevelValue(); + + /** + * + * + *
        +   * The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the
        +   * [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in
        +   * decapsulation.
        +   * 
        + * + * .google.cloud.kms.v1.ProtectionLevel protection_level = 5; + * + * @return The protectionLevel. + */ + com.google.cloud.kms.v1.ProtectionLevel getProtectionLevel(); +} diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsProto.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsProto.java index 1fb4826e76a0..590d16ac1eae 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsProto.java +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsProto.java @@ -152,6 +152,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_kms_v1_MacVerifyRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_kms_v1_MacVerifyRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_kms_v1_DecapsulateRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_kms_v1_DecapsulateRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_kms_v1_GenerateRandomBytesRequest_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -188,6 +192,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_kms_v1_MacVerifyResponse_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_kms_v1_MacVerifyResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_kms_v1_DecapsulateResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_kms_v1_DecapsulateResponse_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_kms_v1_GenerateRandomBytesResponse_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -405,12 +413,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013data_crc32c\030\003" + " \001(\0132\033.google.protobuf.Int64ValueB\003\340A\001\022\020\n" + "\003mac\030\004 \001(\014B\003\340A\002\0224\n\n" - + "mac_crc32c\030\005 \001(\0132\033.google.protobuf.Int64ValueB\003\340A\001\"\204\001\n" + + "mac_crc32c\030\005 \001(\0132\033.google.protobuf.Int64ValueB\003\340A\001\"\252\001\n" + + "\022DecapsulateRequest\022>\n" + + "\004name\030\001 \001(\tB0\340A\002\372A*\n" + + "(cloudkms.googleapis.com/CryptoKeyVersion\022\027\n\n" + + "ciphertext\030\002 \001(\014B\003\340A\002\022;\n" + + "\021ciphertext_crc32c\030\003" + + " \001(\0132\033.google.protobuf.Int64ValueB\003\340A\001\"\204\001\n" + "\032GenerateRandomBytesRequest\022\020\n" + "\010location\030\001 \001(\t\022\024\n" + "\014length_bytes\030\002 \001(\005\022>\n" - + "\020protection_level\030\003" - + " \001(\0162$.google.cloud.kms.v1.ProtectionLevel\"\205\002\n" + + "\020protection_level\030\003 \001(\016" + + "2$.google.cloud.kms.v1.ProtectionLevel\"\205\002\n" + "\017EncryptResponse\022\014\n" + "\004name\030\001 \001(\t\022\022\n\n" + "ciphertext\030\002 \001(\014\0226\n" @@ -451,8 +465,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\026verified_digest_crc32c\030\003 \001(\010\022\014\n" + "\004name\030\004 \001(\t\022\034\n" + "\024verified_data_crc32c\030\005 \001(\010\022>\n" - + "\020protection_level\030\006 " - + "\001(\0162$.google.cloud.kms.v1.ProtectionLevel\"\311\001\n" + + "\020protection_level\030\006" + + " \001(\0162$.google.cloud.kms.v1.ProtectionLevel\"\311\001\n" + "\031AsymmetricDecryptResponse\022\021\n" + "\tplaintext\030\001 \001(\014\0225\n" + "\020plaintext_crc32c\030\002 \001(\0132\033.google.protobuf.Int64Value\022\"\n" @@ -472,7 +486,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\024verified_data_crc32c\030\003 \001(\010\022\033\n" + "\023verified_mac_crc32c\030\004 \001(\010\022\"\n" + "\032verified_success_integrity\030\005 \001(\010\022>\n" - + "\020protection_level\030\006 \001(\0162$.google.cloud.kms.v1.ProtectionLevel\"]\n" + + "\020protection_level\030\006" + + " \001(\0162$.google.cloud.kms.v1.ProtectionLevel\"\332\001\n" + + "\023DecapsulateResponse\022\014\n" + + "\004name\030\001 \001(\t\022\025\n\r" + + "shared_secret\030\002 \001(\014\022!\n" + + "\024shared_secret_crc32c\030\003 \001(\003H\000\210\001\001\022\"\n" + + "\032verified_ciphertext_crc32c\030\004 \001(\010\022>\n" + + "\020protection_level\030\005 \001(\0162$.google.cloud.kms.v1.ProtectionLevelB\027\n" + + "\025_shared_secret_crc32c\"]\n" + "\033GenerateRandomBytesResponse\022\014\n" + "\004data\030\001 \001(\014\0220\n" + "\013data_crc32c\030\003 \001(\0132\033.google.protobuf.Int64Value\"H\n" @@ -483,133 +505,138 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\006digest\"@\n" + "\020LocationMetadata\022\025\n\r" + "hsm_available\030\001 \001(\010\022\025\n\r" - + "ekm_available\030\002 \001(\0102\220.\n" + + "ekm_available\030\002 \001(\0102\331/\n" + "\024KeyManagementService\022\242\001\n" - + "\014ListKeyRings\022(.google.cloud.kms.v1.ListKeyRingsR" - + "equest\032).google.cloud.kms.v1.ListKeyRing" - + "sResponse\"=\332A\006parent\202\323\344\223\002.\022,/v1/{parent=projects/*/locations/*}/keyRings\022\265\001\n" - + "\016ListCryptoKeys\022*.google.cloud.kms.v1.ListCr" - + "yptoKeysRequest\032+.google.cloud.kms.v1.Li" - + "stCryptoKeysResponse\"J\332A\006parent\202\323\344\223\002;\0229/" - + "v1/{parent=projects/*/locations/*/keyRings/*}/cryptoKeys\022\336\001\n" - + "\025ListCryptoKeyVersions\0221.google.cloud.kms.v1.ListCryptoKeyVe" - + "rsionsRequest\0322.google.cloud.kms.v1.List" - + "CryptoKeyVersionsResponse\"^\332A\006parent\202\323\344\223" - + "\002O\022M/v1/{parent=projects/*/locations/*/k" - + "eyRings/*/cryptoKeys/*}/cryptoKeyVersions\022\265\001\n" - + "\016ListImportJobs\022*.google.cloud.kms.v1.ListImportJobsRequest\032+.google.cloud." - + "kms.v1.ListImportJobsResponse\"J\332A\006parent" - + "\202\323\344\223\002;\0229/v1/{parent=projects/*/locations/*/keyRings/*}/importJobs\022\217\001\n\n" - + "GetKeyRing\022&.google.cloud.kms.v1.GetKeyRingRequest" - + "\032\034.google.cloud.kms.v1.KeyRing\";\332A\004name\202" - + "\323\344\223\002.\022,/v1/{name=projects/*/locations/*/keyRings/*}\022\242\001\n" - + "\014GetCryptoKey\022(.google.cloud.kms.v1.GetCryptoKeyRequest\032\036.google." - + "cloud.kms.v1.CryptoKey\"H\332A\004name\202\323\344\223\002;\0229/" - + "v1/{name=projects/*/locations/*/keyRings/*/cryptoKeys/*}\022\313\001\n" - + "\023GetCryptoKeyVersion\022/.google.cloud.kms.v1.GetCryptoKeyVersi" - + "onRequest\032%.google.cloud.kms.v1.CryptoKe" - + "yVersion\"\\\332A\004name\202\323\344\223\002O\022M/v1/{name=proje" - + "cts/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}\022\300\001\n" - + "\014GetPublicKey\022(.google.cloud.kms.v1.GetPublicKeyReques" - + "t\032\036.google.cloud.kms.v1.PublicKey\"f\332A\004na" - + "me\202\323\344\223\002Y\022W/v1/{name=projects/*/locations" - + "/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}/publicKey\022\242\001\n" - + "\014GetImportJob\022(.google.cloud.kms.v1.GetImportJobRequest\032\036.g" - + "oogle.cloud.kms.v1.ImportJob\"H\332A\004name\202\323\344" - + "\223\002;\0229/v1/{name=projects/*/locations/*/keyRings/*/importJobs/*}\022\266\001\n\r" - + "CreateKeyRing\022).google.cloud.kms.v1.CreateKeyRingRequ" - + "est\032\034.google.cloud.kms.v1.KeyRing\"\\\332A\033pa" - + "rent,key_ring_id,key_ring\202\323\344\223\0028\",/v1/{pa" - + "rent=projects/*/locations/*}/keyRings:\010key_ring\022\317\001\n" - + "\017CreateCryptoKey\022+.google.cloud.kms.v1.CreateCryptoKeyRequest\032\036.googl" - + "e.cloud.kms.v1.CryptoKey\"o\332A\037parent,cryp" - + "to_key_id,crypto_key\202\323\344\223\002G\"9/v1/{parent=" - + "projects/*/locations/*/keyRings/*}/cryptoKeys:\n" + + "\014ListKeyRings\022(.google.cloud.kms.v1.ListKeyRingsRequest" + + "\032).google.cloud.kms.v1.ListKeyRingsRespo" + + "nse\"=\332A\006parent\202\323\344\223\002.\022,/v1/{parent=projects/*/locations/*}/keyRings\022\265\001\n" + + "\016ListCryptoKeys\022*.google.cloud.kms.v1.ListCryptoKe" + + "ysRequest\032+.google.cloud.kms.v1.ListCryp" + + "toKeysResponse\"J\332A\006parent\202\323\344\223\002;\0229/v1/{pa" + + "rent=projects/*/locations/*/keyRings/*}/cryptoKeys\022\336\001\n" + + "\025ListCryptoKeyVersions\0221.google.cloud.kms.v1.ListCryptoKeyVersions" + + "Request\0322.google.cloud.kms.v1.ListCrypto" + + "KeyVersionsResponse\"^\332A\006parent\202\323\344\223\002O\022M/v" + + "1/{parent=projects/*/locations/*/keyRings/*/cryptoKeys/*}/cryptoKeyVersions\022\265\001\n" + + "\016ListImportJobs\022*.google.cloud.kms.v1.Lis" + + "tImportJobsRequest\032+.google.cloud.kms.v1" + + ".ListImportJobsResponse\"J\332A\006parent\202\323\344\223\002;" + + "\0229/v1/{parent=projects/*/locations/*/keyRings/*}/importJobs\022\217\001\n\n" + + "GetKeyRing\022&.google.cloud.kms.v1.GetKeyRingRequest\032\034.goo" + + "gle.cloud.kms.v1.KeyRing\";\332A\004name\202\323\344\223\002.\022" + + ",/v1/{name=projects/*/locations/*/keyRings/*}\022\242\001\n" + + "\014GetCryptoKey\022(.google.cloud.kms.v1.GetCryptoKeyRequest\032\036.google.cloud." + + "kms.v1.CryptoKey\"H\332A\004name\202\323\344\223\002;\0229/v1/{na" + + "me=projects/*/locations/*/keyRings/*/cryptoKeys/*}\022\313\001\n" + + "\023GetCryptoKeyVersion\022/.google.cloud.kms.v1.GetCryptoKeyVersionRequ" + + "est\032%.google.cloud.kms.v1.CryptoKeyVersi" + + "on\"\\\332A\004name\202\323\344\223\002O\022M/v1/{name=projects/*/" + + "locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}\022\300\001\n" + + "\014GetPublicKey\022(.google.cloud.kms.v1.GetPublicKeyRequest\032\036.go" + + "ogle.cloud.kms.v1.PublicKey\"f\332A\004name\202\323\344\223" + + "\002Y\022W/v1/{name=projects/*/locations/*/key" + + "Rings/*/cryptoKeys/*/cryptoKeyVersions/*}/publicKey\022\242\001\n" + + "\014GetImportJob\022(.google.cloud.kms.v1.GetImportJobRequest\032\036.google." + + "cloud.kms.v1.ImportJob\"H\332A\004name\202\323\344\223\002;\0229/" + + "v1/{name=projects/*/locations/*/keyRings/*/importJobs/*}\022\266\001\n\r" + + "CreateKeyRing\022).google.cloud.kms.v1.CreateKeyRingRequest\032\034." + + "google.cloud.kms.v1.KeyRing\"\\\332A\033parent,k" + + "ey_ring_id,key_ring\202\323\344\223\0028\",/v1/{parent=p" + + "rojects/*/locations/*}/keyRings:\010key_ring\022\317\001\n" + + "\017CreateCryptoKey\022+.google.cloud.kms" + + ".v1.CreateCryptoKeyRequest\032\036.google.clou" + + "d.kms.v1.CryptoKey\"o\332A\037parent,crypto_key" + + "_id,crypto_key\202\323\344\223\002G\"9/v1/{parent=projec" + + "ts/*/locations/*/keyRings/*}/cryptoKeys:\n" + "crypto_key\022\373\001\n" - + "\026CreateCryptoKeyVersion\0222.google.cloud.kms.v1.CreateCryptoK" - + "eyVersionRequest\032%.google.cloud.kms.v1.C" - + "ryptoKeyVersion\"\205\001\332A\031parent,crypto_key_v" - + "ersion\202\323\344\223\002c\"M/v1/{parent=projects/*/loc" - + "ations/*/keyRings/*/cryptoKeys/*}/cryptoKeyVersions:\022crypto_key_version\022\324\001\n" - + "\026ImportCryptoKeyVersion\0222.google.cloud.kms.v1" - + ".ImportCryptoKeyVersionRequest\032%.google." - + "cloud.kms.v1.CryptoKeyVersion\"_\202\323\344\223\002Y\"T/" - + "v1/{parent=projects/*/locations/*/keyRin" - + "gs/*/cryptoKeys/*}/cryptoKeyVersions:import:\001*\022\317\001\n" - + "\017CreateImportJob\022+.google.cloud.kms.v1.CreateImportJobRequest\032\036.google" - + ".cloud.kms.v1.ImportJob\"o\332A\037parent,impor" - + "t_job_id,import_job\202\323\344\223\002G\"9/v1/{parent=p" - + "rojects/*/locations/*/keyRings/*}/importJobs:\n" + + "\026CreateCryptoKeyVersion\0222.google.cloud.kms.v1.CreateCryptoKeyVers" + + "ionRequest\032%.google.cloud.kms.v1.CryptoK" + + "eyVersion\"\205\001\332A\031parent,crypto_key_version" + + "\202\323\344\223\002c\"M/v1/{parent=projects/*/locations" + + "/*/keyRings/*/cryptoKeys/*}/cryptoKeyVersions:\022crypto_key_version\022\324\001\n" + + "\026ImportCryptoKeyVersion\0222.google.cloud.kms.v1.Impor" + + "tCryptoKeyVersionRequest\032%.google.cloud." + + "kms.v1.CryptoKeyVersion\"_\202\323\344\223\002Y\"T/v1/{pa" + + "rent=projects/*/locations/*/keyRings/*/c" + + "ryptoKeys/*}/cryptoKeyVersions:import:\001*\022\317\001\n" + + "\017CreateImportJob\022+.google.cloud.kms." + + "v1.CreateImportJobRequest\032\036.google.cloud" + + ".kms.v1.ImportJob\"o\332A\037parent,import_job_" + + "id,import_job\202\323\344\223\002G\"9/v1/{parent=projects/*/locations/*/keyRings/*}/importJobs:\n" + "import_job\022\321\001\n" - + "\017UpdateCryptoKey\022+.google.cloud.kms.v1.UpdateCryptoKeyReques" - + "t\032\036.google.cloud.kms.v1.CryptoKey\"q\332A\026cr" - + "ypto_key,update_mask\202\323\344\223\002R2D/v1/{crypto_" - + "key.name=projects/*/locations/*/keyRings/*/cryptoKeys/*}:\n" + + "\017UpdateCryptoKey\022+.google.cloud.kms.v1.UpdateCryptoKeyRequest\032\036.go" + + "ogle.cloud.kms.v1.CryptoKey\"q\332A\026crypto_k" + + "ey,update_mask\202\323\344\223\002R2D/v1/{crypto_key.na" + + "me=projects/*/locations/*/keyRings/*/cryptoKeys/*}:\n" + "crypto_key\022\223\002\n" - + "\026UpdateCryptoKeyVersion\0222.google.cloud.kms.v1.Up" - + "dateCryptoKeyVersionRequest\032%.google.clo" - + "ud.kms.v1.CryptoKeyVersion\"\235\001\332A\036crypto_k" - + "ey_version,update_mask\202\323\344\223\002v2`/v1/{crypt" - + "o_key_version.name=projects/*/locations/" - + "*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:\022crypto_key_version\022\362\001\n" - + "\035UpdateCryptoKeyPrimaryVersion\0229.google.cloud.kms." - + "v1.UpdateCryptoKeyPrimaryVersionRequest\032" - + "\036.google.cloud.kms.v1.CryptoKey\"v\332A\032name" - + ",crypto_key_version_id\202\323\344\223\002S\"N/v1/{name=" - + "projects/*/locations/*/keyRings/*/cryptoKeys/*}:updatePrimaryVersion:\001*\022\336\001\n" - + "\027DestroyCryptoKeyVersion\0223.google.cloud.kms.v" - + "1.DestroyCryptoKeyVersionRequest\032%.googl" - + "e.cloud.kms.v1.CryptoKeyVersion\"g\332A\004name" - + "\202\323\344\223\002Z\"U/v1/{name=projects/*/locations/*" - + "/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:destroy:\001*\022\336\001\n" - + "\027RestoreCryptoKeyVersion\0223.google.cloud.kms.v1.RestoreCrypto" - + "KeyVersionRequest\032%.google.cloud.kms.v1." - + "CryptoKeyVersion\"g\332A\004name\202\323\344\223\002Z\"U/v1/{na" - + "me=projects/*/locations/*/keyRings/*/cry" - + "ptoKeys/*/cryptoKeyVersions/*}:restore:\001*\022\264\001\n" - + "\007Encrypt\022#.google.cloud.kms.v1.EncryptRequest\032$.google.cloud.kms.v1.Encrypt" - + "Response\"^\332A\016name,plaintext\202\323\344\223\002G\"B/v1/{" - + "name=projects/*/locations/*/keyRings/*/cryptoKeys/**}:encrypt:\001*\022\264\001\n" - + "\007Decrypt\022#.google.cloud.kms.v1.DecryptRequest\032$.goog" - + "le.cloud.kms.v1.DecryptResponse\"^\332A\017name" - + ",ciphertext\202\323\344\223\002F\"A/v1/{name=projects/*/" - + "locations/*/keyRings/*/cryptoKeys/*}:decrypt:\001*\022\302\001\n\n" - + "RawEncrypt\022&.google.cloud.kms.v1.RawEncryptRequest\032\'.google.cloud.km" - + "s.v1.RawEncryptResponse\"c\202\323\344\223\002]\"X/v1/{na" - + "me=projects/*/locations/*/keyRings/*/cry" - + "ptoKeys/*/cryptoKeyVersions/*}:rawEncrypt:\001*\022\302\001\n\n" - + "RawDecrypt\022&.google.cloud.kms.v1.RawDecryptRequest\032\'.google.cloud.kms.v" - + "1.RawDecryptResponse\"c\202\323\344\223\002]\"X/v1/{name=" - + "projects/*/locations/*/keyRings/*/crypto" - + "Keys/*/cryptoKeyVersions/*}:rawDecrypt:\001*\022\340\001\n" - + "\016AsymmetricSign\022*.google.cloud.kms.v1.AsymmetricSignRequest\032+.google.cloud." - + "kms.v1.AsymmetricSignResponse\"u\332A\013name,d" - + "igest\202\323\344\223\002a\"\\/v1/{name=projects/*/locati" - + "ons/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:asymmetricSign:\001*\022\360\001\n" - + "\021AsymmetricDecrypt\022-.google.cloud.kms.v1.Asymmet" - + "ricDecryptRequest\032..google.cloud.kms.v1." - + "AsymmetricDecryptResponse\"|\332A\017name,ciphe" - + "rtext\202\323\344\223\002d\"_/v1/{name=projects/*/locati" - + "ons/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:asymmetricDecrypt:\001*\022\302\001\n" - + "\007MacSign\022#.google.cloud.kms.v1.MacSignRequest" - + "\032$.google.cloud.kms.v1.MacSignResponse\"l\332A" - + "\tname,data\202\323\344\223\002Z\"U/v1/{name=projects/*" - + "/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:macSign:\001*\022\316\001\n" - + "\tMacVerify\022%.google.cloud.kms.v1.MacVerifyReques" - + "t\032&.google.cloud.kms.v1.MacVerifyResponse\"r\332A\r" - + "name,data,mac\202\323\344\223\002\\\"W/v1/{name=pro" + + "\026UpdateCryptoKeyVersion\0222.google.cloud.kms.v1.UpdateCr" + + "yptoKeyVersionRequest\032%.google.cloud.kms" + + ".v1.CryptoKeyVersion\"\235\001\332A\036crypto_key_ver" + + "sion,update_mask\202\323\344\223\002v2`/v1/{crypto_key_" + + "version.name=projects/*/locations/*/keyR" + + "ings/*/cryptoKeys/*/cryptoKeyVersions/*}:\022crypto_key_version\022\362\001\n" + + "\035UpdateCryptoKeyPrimaryVersion\0229.google.cloud.kms.v1.Upd" + + "ateCryptoKeyPrimaryVersionRequest\032\036.goog" + + "le.cloud.kms.v1.CryptoKey\"v\332A\032name,crypt" + + "o_key_version_id\202\323\344\223\002S\"N/v1/{name=projec" + + "ts/*/locations/*/keyRings/*/cryptoKeys/*}:updatePrimaryVersion:\001*\022\336\001\n" + + "\027DestroyCryptoKeyVersion\0223.google.cloud.kms.v1.Dest" + + "royCryptoKeyVersionRequest\032%.google.clou" + + "d.kms.v1.CryptoKeyVersion\"g\332A\004name\202\323\344\223\002Z" + + "\"U/v1/{name=projects/*/locations/*/keyRi" + + "ngs/*/cryptoKeys/*/cryptoKeyVersions/*}:destroy:\001*\022\336\001\n" + + "\027RestoreCryptoKeyVersion\0223.google.cloud.kms.v1.RestoreCryptoKeyVer" + + "sionRequest\032%.google.cloud.kms.v1.Crypto" + + "KeyVersion\"g\332A\004name\202\323\344\223\002Z\"U/v1/{name=pro" + + "jects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:restore:\001*\022\264\001\n" + + "\007Encrypt\022#.google.cloud.kms.v1.EncryptReq" + + "uest\032$.google.cloud.kms.v1.EncryptRespon" + + "se\"^\332A\016name,plaintext\202\323\344\223\002G\"B/v1/{name=p" + + "rojects/*/locations/*/keyRings/*/cryptoKeys/**}:encrypt:\001*\022\264\001\n" + + "\007Decrypt\022#.google.cloud.kms.v1.DecryptRequest\032$.google.clo" + + "ud.kms.v1.DecryptResponse\"^\332A\017name,ciphe" + + "rtext\202\323\344\223\002F\"A/v1/{name=projects/*/locati" + + "ons/*/keyRings/*/cryptoKeys/*}:decrypt:\001*\022\302\001\n\n" + + "RawEncrypt\022&.google.cloud.kms.v1.RawEncryptRequest\032\'.google.cloud.kms.v1.R" + + "awEncryptResponse\"c\202\323\344\223\002]\"X/v1/{name=pro" + "jects/*/locations/*/keyRings/*/cryptoKey" - + "s/*/cryptoKeyVersions/*}:macVerify:\001*\022\347\001\n" - + "\023GenerateRandomBytes\022/.google.cloud.kms" - + ".v1.GenerateRandomBytesRequest\0320.google.cloud.kms.v1.GenerateRandomBytesResponse" - + "\"m\332A&location,length_bytes,protection_le" - + "vel\202\323\344\223\002>\"9/v1/{location=projects/*/loca" - + "tions/*}:generateRandomBytes:\001*\032t\312A\027clou" - + "dkms.googleapis.com\322AWhttps://www.google" - + "apis.com/auth/cloud-platform,https://www.googleapis.com/auth/cloudkmsB|\n" - + "\027com.google.cloud.kms.v1B\010KmsProtoP\001Z)cloud.goog" - + "le.com/go/kms/apiv1/kmspb;kmspb\252\002\023Google" - + ".Cloud.Kms.V1\312\002\023Google\\Cloud\\Kms\\V1b\006proto3" + + "s/*/cryptoKeyVersions/*}:rawEncrypt:\001*\022\302\001\n\n" + + "RawDecrypt\022&.google.cloud.kms.v1.RawDecryptRequest\032\'.google.cloud.kms.v1.RawD" + + "ecryptResponse\"c\202\323\344\223\002]\"X/v1/{name=projec" + + "ts/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:rawDecrypt:\001*\022\340\001\n" + + "\016AsymmetricSign\022*.google.cloud.kms.v1.Asy" + + "mmetricSignRequest\032+.google.cloud.kms.v1" + + ".AsymmetricSignResponse\"u\332A\013name,digest\202" + + "\323\344\223\002a\"\\/v1/{name=projects/*/locations/*/" + + "keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:asymmetricSign:\001*\022\360\001\n" + + "\021AsymmetricDecrypt\022-.google.cloud.kms.v1.AsymmetricDec" + + "ryptRequest\032..google.cloud.kms.v1.Asymme" + + "tricDecryptResponse\"|\332A\017name,ciphertext\202" + + "\323\344\223\002d\"_/v1/{name=projects/*/locations/*/" + + "keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:asymmetricDecrypt:\001*\022\302\001\n" + + "\007MacSign\022#." + + "google.cloud.kms.v1.MacSignRequest\032$.google.cloud.kms.v1.MacSignResponse\"l\332A" + + "\tname,data\202\323\344\223\002Z\"U/v1/{name=projects/*/locat" + + "ions/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:macSign:\001*\022\316\001\n" + + "\tMacVerify\022%.g" + + "oogle.cloud.kms.v1.MacVerifyRequest\032&.google.cloud.kms.v1.MacVerifyResponse\"r\332A\r" + + "name,data,mac\202\323\344\223\002\\\"W/v1/{name=projects/" + + "*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:macVerify:\001*\022\306\001\n" + + "\013Decapsulate\022\'.google.cloud.kms.v1.Decapsulat" + + "eRequest\032(.google.cloud.kms.v1.Decapsula" + + "teResponse\"d\202\323\344\223\002^\"Y/v1/{name=projects/*" + + "/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:decapsulate:\001*\022\347\001\n" + + "\023GenerateRandomBytes\022/.google.cloud.kms.v1.G" + + "enerateRandomBytesRequest\0320.google.cloud" + + ".kms.v1.GenerateRandomBytesResponse\"m\332A&" + + "location,length_bytes,protection_level\202\323" + + "\344\223\002>\"9/v1/{location=projects/*/locations" + + "/*}:generateRandomBytes:\001*\032t\312A\027cloudkms." + + "googleapis.com\322AWhttps://www.googleapis." + + "com/auth/cloud-platform,https://www.googleapis.com/auth/cloudkmsB|\n" + + "\027com.google.cloud.kms.v1B\010KmsProtoP\001Z)cloud.google.co" + + "m/go/kms/apiv1/kmspb;kmspb\252\002\023Google.Clou" + + "d.Kms.V1\312\002\023Google\\Cloud\\Kms\\V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -898,8 +925,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Name", "Data", "DataCrc32C", "Mac", "MacCrc32C", }); - internal_static_google_cloud_kms_v1_GenerateRandomBytesRequest_descriptor = + internal_static_google_cloud_kms_v1_DecapsulateRequest_descriptor = getDescriptor().getMessageTypes().get(31); + internal_static_google_cloud_kms_v1_DecapsulateRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_kms_v1_DecapsulateRequest_descriptor, + new java.lang.String[] { + "Name", "Ciphertext", "CiphertextCrc32C", + }); + internal_static_google_cloud_kms_v1_GenerateRandomBytesRequest_descriptor = + getDescriptor().getMessageTypes().get(32); internal_static_google_cloud_kms_v1_GenerateRandomBytesRequest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_GenerateRandomBytesRequest_descriptor, @@ -907,7 +942,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Location", "LengthBytes", "ProtectionLevel", }); internal_static_google_cloud_kms_v1_EncryptResponse_descriptor = - getDescriptor().getMessageTypes().get(32); + getDescriptor().getMessageTypes().get(33); internal_static_google_cloud_kms_v1_EncryptResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_EncryptResponse_descriptor, @@ -920,7 +955,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProtectionLevel", }); internal_static_google_cloud_kms_v1_DecryptResponse_descriptor = - getDescriptor().getMessageTypes().get(33); + getDescriptor().getMessageTypes().get(34); internal_static_google_cloud_kms_v1_DecryptResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_DecryptResponse_descriptor, @@ -928,7 +963,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Plaintext", "PlaintextCrc32C", "UsedPrimary", "ProtectionLevel", }); internal_static_google_cloud_kms_v1_RawEncryptResponse_descriptor = - getDescriptor().getMessageTypes().get(34); + getDescriptor().getMessageTypes().get(35); internal_static_google_cloud_kms_v1_RawEncryptResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_RawEncryptResponse_descriptor, @@ -945,7 +980,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProtectionLevel", }); internal_static_google_cloud_kms_v1_RawDecryptResponse_descriptor = - getDescriptor().getMessageTypes().get(35); + getDescriptor().getMessageTypes().get(36); internal_static_google_cloud_kms_v1_RawDecryptResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_RawDecryptResponse_descriptor, @@ -958,7 +993,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "VerifiedInitializationVectorCrc32C", }); internal_static_google_cloud_kms_v1_AsymmetricSignResponse_descriptor = - getDescriptor().getMessageTypes().get(36); + getDescriptor().getMessageTypes().get(37); internal_static_google_cloud_kms_v1_AsymmetricSignResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_AsymmetricSignResponse_descriptor, @@ -971,7 +1006,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "ProtectionLevel", }); internal_static_google_cloud_kms_v1_AsymmetricDecryptResponse_descriptor = - getDescriptor().getMessageTypes().get(37); + getDescriptor().getMessageTypes().get(38); internal_static_google_cloud_kms_v1_AsymmetricDecryptResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_AsymmetricDecryptResponse_descriptor, @@ -979,7 +1014,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Plaintext", "PlaintextCrc32C", "VerifiedCiphertextCrc32C", "ProtectionLevel", }); internal_static_google_cloud_kms_v1_MacSignResponse_descriptor = - getDescriptor().getMessageTypes().get(38); + getDescriptor().getMessageTypes().get(39); internal_static_google_cloud_kms_v1_MacSignResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_MacSignResponse_descriptor, @@ -987,7 +1022,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Name", "Mac", "MacCrc32C", "VerifiedDataCrc32C", "ProtectionLevel", }); internal_static_google_cloud_kms_v1_MacVerifyResponse_descriptor = - getDescriptor().getMessageTypes().get(39); + getDescriptor().getMessageTypes().get(40); internal_static_google_cloud_kms_v1_MacVerifyResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_MacVerifyResponse_descriptor, @@ -999,8 +1034,20 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "VerifiedSuccessIntegrity", "ProtectionLevel", }); + internal_static_google_cloud_kms_v1_DecapsulateResponse_descriptor = + getDescriptor().getMessageTypes().get(41); + internal_static_google_cloud_kms_v1_DecapsulateResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_kms_v1_DecapsulateResponse_descriptor, + new java.lang.String[] { + "Name", + "SharedSecret", + "SharedSecretCrc32C", + "VerifiedCiphertextCrc32C", + "ProtectionLevel", + }); internal_static_google_cloud_kms_v1_GenerateRandomBytesResponse_descriptor = - getDescriptor().getMessageTypes().get(40); + getDescriptor().getMessageTypes().get(42); internal_static_google_cloud_kms_v1_GenerateRandomBytesResponse_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_GenerateRandomBytesResponse_descriptor, @@ -1008,7 +1055,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Data", "DataCrc32C", }); internal_static_google_cloud_kms_v1_Digest_descriptor = - getDescriptor().getMessageTypes().get(41); + getDescriptor().getMessageTypes().get(43); internal_static_google_cloud_kms_v1_Digest_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_Digest_descriptor, @@ -1016,7 +1063,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Sha256", "Sha384", "Sha512", "Digest", }); internal_static_google_cloud_kms_v1_LocationMetadata_descriptor = - getDescriptor().getMessageTypes().get(42); + getDescriptor().getMessageTypes().get(44); internal_static_google_cloud_kms_v1_LocationMetadata_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_kms_v1_LocationMetadata_descriptor, diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsResourcesProto.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsResourcesProto.java index 3dc8a59d3c60..0436b0177065 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsResourcesProto.java +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/KmsResourcesProto.java @@ -100,7 +100,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013create_time\030\002" + " \001(\0132\032.google.protobuf.TimestampB\003\340A\003:a\352A^\n" + "\037cloudkms.googleapis.com/KeyRing\022;projects/{project}/l" - + "ocations/{location}/keyRings/{key_ring}\"\221\010\n" + + "ocations/{location}/keyRings/{key_ring}\"\250\010\n" + "\tCryptoKey\022\021\n" + "\004name\030\001 \001(\tB\003\340A\003\022;\n" + "\007primary\030\002" @@ -124,27 +124,29 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "oogle.cloud.kms.v1.KeyAccessJustificationsPolicyB\003\340A\001\032-\n" + "\013LabelsEntry\022\013\n" + "\003key\030\001 \001(\t\022\r\n" - + "\005value\030\002 \001(\t:\0028\001\"\232\001\n" + + "\005value\030\002 \001(\t:\0028\001\"\261\001\n" + "\020CryptoKeyPurpose\022\"\n" + "\036CRYPTO_KEY_PURPOSE_UNSPECIFIED\020\000\022\023\n" + "\017ENCRYPT_DECRYPT\020\001\022\023\n" + "\017ASYMMETRIC_SIGN\020\005\022\026\n" + "\022ASYMMETRIC_DECRYPT\020\006\022\027\n" + "\023RAW_ENCRYPT_DECRYPT\020\007\022\007\n" - + "\003MAC\020\t:{\352Ax\n" - + "!cloudkms.googleapis.com/CryptoKey\022Sprojects/{project}/lo" - + "cations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}B\023\n" + + "\003MAC\020\t\022\025\n" + + "\021KEY_ENCAPSULATION\020\n" + + ":{\352Ax\n" + + "!cloudkms.googleapis.com/CryptoKey\022Sprojects/{project}/locations/{location" + + "}/keyRings/{key_ring}/cryptoKeys/{crypto_key}B\023\n" + "\021rotation_schedule\"\263\001\n" + "\030CryptoKeyVersionTemplate\022>\n" + "\020protection_level\030\001 \001(\0162$.google.cloud.kms.v1.ProtectionLevel\022W\n" - + "\talgorithm\030\003 \001(\0162?.go" - + "ogle.cloud.kms.v1.CryptoKeyVersion.CryptoKeyVersionAlgorithmB\003\340A\002\"\261\003\n" + + "\talgorithm\030\003 \001(\0162?.google.cloud.kms.v1" + + ".CryptoKeyVersion.CryptoKeyVersionAlgorithmB\003\340A\002\"\261\003\n" + "\027KeyOperationAttestation\022S\n" - + "\006format\030\004 \001(\0162>.google.c" - + "loud.kms.v1.KeyOperationAttestation.AttestationFormatB\003\340A\003\022\024\n" + + "\006format\030\004 \001(\0162>.google.cloud.kms.v1.KeyOp" + + "erationAttestation.AttestationFormatB\003\340A\003\022\024\n" + "\007content\030\005 \001(\014B\003\340A\003\022X\n" - + "\013cert_chains\030\006 \001(\0132>.google.cloud.kms" - + ".v1.KeyOperationAttestation.CertificateChainsB\003\340A\003\032d\n" + + "\013cert_chains\030\006" + + " \001(\0132>.google.cloud.kms.v1.KeyOperationAttestation.CertificateChainsB\003\340A\003\032d\n" + "\021CertificateChains\022\024\n" + "\014cavium_certs\030\001 \003(\t\022\031\n" + "\021google_card_certs\030\002 \003(\t\022\036\n" @@ -152,18 +154,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\021AttestationFormat\022\"\n" + "\036ATTESTATION_FORMAT_UNSPECIFIED\020\000\022\030\n" + "\024CAVIUM_V1_COMPRESSED\020\003\022\030\n" - + "\024CAVIUM_V2_COMPRESSED\020\004\"\267\023\n" + + "\024CAVIUM_V2_COMPRESSED\020\004\"\347\023\n" + "\020CryptoKeyVersion\022\021\n" + "\004name\030\001 \001(\tB\003\340A\003\022J\n" - + "\005state\030\003 \001(\0162;.g" - + "oogle.cloud.kms.v1.CryptoKeyVersion.CryptoKeyVersionState\022C\n" - + "\020protection_level\030\007 " - + "\001(\0162$.google.cloud.kms.v1.ProtectionLevelB\003\340A\003\022W\n" + + "\005state\030\003 \001(\0162;.google.cloud.kms.v" + + "1.CryptoKeyVersion.CryptoKeyVersionState\022C\n" + + "\020protection_level\030\007" + + " \001(\0162$.google.cloud.kms.v1.ProtectionLevelB\003\340A\003\022W\n" + "\talgorithm\030\n" - + " \001(\0162?.google.cloud" - + ".kms.v1.CryptoKeyVersion.CryptoKeyVersionAlgorithmB\003\340A\003\022F\n" - + "\013attestation\030\010 \001(\0132,.g" - + "oogle.cloud.kms.v1.KeyOperationAttestationB\003\340A\003\0224\n" + + " \001(\0162?.google.cloud.kms.v1.CryptoKey" + + "Version.CryptoKeyVersionAlgorithmB\003\340A\003\022F\n" + + "\013attestation\030\010" + + " \001(\0132,.google.cloud.kms.v1.KeyOperationAttestationB\003\340A\003\0224\n" + "\013create_time\030\004" + " \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0226\n\r" + "generate_time\030\013 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0225\n" @@ -175,9 +177,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\025import_failure_reason\030\020 \001(\tB\003\340A\003\022&\n" + "\031generation_failure_reason\030\023 \001(\tB\003\340A\003\0220\n" + "#external_destruction_failure_reason\030\024 \001(\tB\003\340A\003\022^\n" - + "!external_protection_level_options\030\021 \001(" - + "\01323.google.cloud.kms.v1.ExternalProtectionLevelOptions\022\036\n" - + "\021reimport_eligible\030\022 \001(\010B\003\340A\003\"\230\010\n" + + "!external_protection_level_options\030\021" + + " \001(\01323.google.cloud.kms.v1.ExternalProtectionLevelOptions\022\036\n" + + "\021reimport_eligible\030\022 \001(\010B\003\340A\003\"\310\010\n" + "\031CryptoKeyVersionAlgorithm\022,\n" + "(CRYPTO_KEY_VERSION_ALGORITHM_UNSPECIFIED\020\000\022\037\n" + "\033GOOGLE_SYMMETRIC_ENCRYPTION\020\001\022\017\n" @@ -216,7 +218,10 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\013HMAC_SHA384\020\"\022\017\n" + "\013HMAC_SHA512\020#\022\017\n" + "\013HMAC_SHA224\020$\022!\n" - + "\035EXTERNAL_SYMMETRIC_ENCRYPTION\020\022\022\025\n" + + "\035EXTERNAL_SYMMETRIC_ENCRYPTION\020\022\022\016\n\n" + + "ML_KEM_768\020/\022\017\n" + + "\013ML_KEM_1024\0200\022\r\n" + + "\tKEM_XWING\020?\022\025\n" + "\021PQ_SIGN_ML_DSA_65\0208\022\035\n" + "\031PQ_SIGN_SLH_DSA_SHA2_128S\0209\"\233\002\n" + "\025CryptoKeyVersionState\022(\n" @@ -235,47 +240,50 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\024CryptoKeyVersionView\022\'\n" + "#CRYPTO_KEY_VERSION_VIEW_UNSPECIFIED\020\000\022\010\n" + "\004FULL\020\001:\252\001\352A\246\001\n" - + "(cloudkms.googleapis.com/CryptoKeyVersion\022zprojects/{p" - + "roject}/locations/{location}/keyRings/{k" - + "ey_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}\"U\n" + + "(cloudkms.googleapis.com/CryptoKeyVersion\022zprojects/{project}/l" + + "ocations/{location}/keyRings/{key_ring}/" + + "cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}\"U\n" + "\017ChecksummedData\022\014\n" + "\004data\030\003 \001(\014\0224\n" - + "\017crc32c_checksum\030\002 \001(\0132\033.google.protobuf.Int64Value\"\356\004\n" + + "\017crc32c_checksum\030\002 \001(\0132\033.google.protobuf.Int64Value\"\214\005\n" + "\tPublicKey\022\013\n" + "\003pem\030\001 \001(\t\022R\n" - + "\talgorithm\030\002" - + " \001(\0162?.google.cloud.kms.v1.CryptoKeyVersion.CryptoKeyVersionAlgorithm\022/\n\n" + + "\talgorithm\030\002 \001(\0162?.go" + + "ogle.cloud.kms.v1.CryptoKeyVersion.CryptoKeyVersionAlgorithm\022/\n\n" + "pem_crc32c\030\003 \001(\0132\033.google.protobuf.Int64Value\022\014\n" + "\004name\030\004 \001(\t\022>\n" + "\020protection_level\030\005 \001(\0162$.google.cloud.kms.v1.ProtectionLevel\022I\n" + "\021public_key_format\030\007" + " \001(\0162..google.cloud.kms.v1.PublicKey.PublicKeyFormat\0228\n\n" - + "public_key\030\010 \001(\0132$.google.cloud.kms.v1.ChecksummedData\"K\n" + + "public_key\030\010 \001(\0132$.google.cloud.kms.v1.ChecksummedData\"i\n" + "\017PublicKeyFormat\022!\n" + "\035PUBLIC_KEY_FORMAT_UNSPECIFIED\020\000\022\007\n" - + "\003PEM\020\001\022\014\n" - + "\010NIST_PQC\020\003:\256\001\352A\252\001\n" - + "!cloudkms.googleapis.com/PublicKey\022\204\001projects/{project}/locations/" - + "{location}/keyRings/{key_ring}/cryptoKey" - + "s/{crypto_key}/cryptoKeyVersions/{crypto_key_version}/publicKey\"\324\010\n" + + "\003PEM\020\001\022\007\n" + + "\003DER\020\002\022\014\n" + + "\010NIST_PQC\020\003\022\023\n" + + "\017XWING_RAW_BYTES\020\004:\256\001\352A\252\001\n" + + "!cloudkms.googleapis.com/PublicKey\022\204\001projects" + + "/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryp" + + "toKeyVersions/{crypto_key_version}/publicKey\"\324\010\n" + "\tImportJob\022\021\n" - + "\004name\030\001 \001(\tB\003\340A\003\022J\n\r" - + "import_method\030\002 \001(\0162" - + "+.google.cloud.kms.v1.ImportJob.ImportMethodB\006\340A\002\340A\005\022F\n" - + "\020protection_level\030\t \001(\0162$" - + ".google.cloud.kms.v1.ProtectionLevelB\006\340A\002\340A\005\0224\n" + + "\004name\030\001 \001(\tB\003\340A\003\022J\n" + + "\r" + + "import_method\030\002" + + " \001(\0162+.google.cloud.kms.v1.ImportJob.ImportMethodB\006\340A\002\340A\005\022F\n" + + "\020protection_level\030\t" + + " \001(\0162$.google.cloud.kms.v1.ProtectionLevelB\006\340A\002\340A\005\0224\n" + "\013create_time\030\003" + " \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0226\n\r" + "generate_time\030\004 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\0224\n" + "\013expire_time\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022:\n" + "\021expire_event_time\030\n" + " \001(\0132\032.google.protobuf.TimestampB\003\340A\003\022A\n" - + "\005state\030\006 " - + "\001(\0162-.google.cloud.kms.v1.ImportJob.ImportJobStateB\003\340A\003\022I\n\n" - + "public_key\030\007 \001(\01320.go" - + "ogle.cloud.kms.v1.ImportJob.WrappingPublicKeyB\003\340A\003\022F\n" - + "\013attestation\030\010 \001(\0132,.google" - + ".cloud.kms.v1.KeyOperationAttestationB\003\340A\003\032 \n" + + "\005state\030\006" + + " \001(\0162-.google.cloud.kms.v1.ImportJob.ImportJobStateB\003\340A\003\022I\n\n" + + "public_key\030\007" + + " \001(\01320.google.cloud.kms.v1.ImportJob.WrappingPublicKeyB\003\340A\003\022F\n" + + "\013attestation\030\010" + + " \001(\0132,.google.cloud.kms.v1.KeyOperationAttestationB\003\340A\003\032 \n" + "\021WrappingPublicKey\022\013\n" + "\003pem\030\001 \001(\t\"\345\001\n" + "\014ImportMethod\022\035\n" @@ -291,8 +299,8 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\022PENDING_GENERATION\020\001\022\n\n" + "\006ACTIVE\020\002\022\013\n" + "\007EXPIRED\020\003:{\352Ax\n" - + "!cloudkms.googleapis.com/ImportJob\022Sprojects/{project}/locations/" - + "{location}/keyRings/{key_ring}/importJobs/{import_job}\"[\n" + + "!cloudkms.googleapis.com/ImportJob\022Sprojects" + + "/{project}/locations/{location}/keyRings/{key_ring}/importJobs/{import_job}\"[\n" + "\036ExternalProtectionLevelOptions\022\030\n" + "\020external_key_uri\030\001 \001(\t\022\037\n" + "\027ekm_connection_key_path\030\002 \001(\t\"b\n" @@ -318,9 +326,9 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "#GOOGLE_RESPONSE_TO_PRODUCTION_ALERT\020\n" + "\022*\n" + "&CUSTOMER_AUTHORIZED_WORKFLOW_SERVICING\020\013B\205\001\n" - + "\027com.google.cloud.kms.v1B\021KmsResourcesProtoP\001Z)clou" - + "d.google.com/go/kms/apiv1/kmspb;kmspb\252\002\023" - + "Google.Cloud.Kms.V1\312\002\023Google\\Cloud\\Kms\\V1b\006proto3" + + "\027com.google.cloud.kms.v1B\021KmsResourcesProtoP\001Z)cloud.google.com/go/kms" + + "/apiv1/kmspb;kmspb\252\002\023Google.Cloud.Kms.V1" + + "\312\002\023Google\\Cloud\\Kms\\V1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/PublicKey.java b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/PublicKey.java index 18936db40167..3d7b70e76b9f 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/PublicKey.java +++ b/java-kms/proto-google-cloud-kms-v1/src/main/java/com/google/cloud/kms/v1/PublicKey.java @@ -113,6 +113,17 @@ public enum PublicKeyFormat implements com.google.protobuf.ProtocolMessageEnum { * PEM = 1; */ PEM(1), + /** + * + * + *
        +     * The returned public key will be encoded in DER format (the
        +     * PrivateKeyInfo structure from RFC 5208).
        +     * 
        + * + * DER = 2; + */ + DER(2), /** * * @@ -125,6 +136,17 @@ public enum PublicKeyFormat implements com.google.protobuf.ProtocolMessageEnum { * NIST_PQC = 3; */ NIST_PQC(3), + /** + * + * + *
        +     * The returned public key is in raw bytes format defined in its standard
        +     * https://datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem.
        +     * 
        + * + * XWING_RAW_BYTES = 4; + */ + XWING_RAW_BYTES(4), UNRECOGNIZED(-1), ; @@ -163,6 +185,18 @@ public enum PublicKeyFormat implements com.google.protobuf.ProtocolMessageEnum { */ public static final int PEM_VALUE = 1; + /** + * + * + *
        +     * The returned public key will be encoded in DER format (the
        +     * PrivateKeyInfo structure from RFC 5208).
        +     * 
        + * + * DER = 2; + */ + public static final int DER_VALUE = 2; + /** * * @@ -176,6 +210,18 @@ public enum PublicKeyFormat implements com.google.protobuf.ProtocolMessageEnum { */ public static final int NIST_PQC_VALUE = 3; + /** + * + * + *
        +     * The returned public key is in raw bytes format defined in its standard
        +     * https://datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem.
        +     * 
        + * + * XWING_RAW_BYTES = 4; + */ + public static final int XWING_RAW_BYTES_VALUE = 4; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -204,8 +250,12 @@ public static PublicKeyFormat forNumber(int value) { return PUBLIC_KEY_FORMAT_UNSPECIFIED; case 1: return PEM; + case 2: + return DER; case 3: return NIST_PQC; + case 4: + return XWING_RAW_BYTES; default: return null; } diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/resources.proto b/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/resources.proto index 2bbbdf14bfff..c8350038230f 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/resources.proto +++ b/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/resources.proto @@ -100,6 +100,12 @@ message CryptoKey { // [CryptoKeys][google.cloud.kms.v1.CryptoKey] with this purpose may be used // with [MacSign][google.cloud.kms.v1.KeyManagementService.MacSign]. MAC = 9; + + // [CryptoKeys][google.cloud.kms.v1.CryptoKey] with this purpose may be used + // with + // [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey] + // and [Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate]. + KEY_ENCAPSULATION = 10; } // Output only. The resource name for this @@ -469,6 +475,16 @@ message CryptoKeyVersion { // Algorithm representing symmetric encryption by an external key manager. EXTERNAL_SYMMETRIC_ENCRYPTION = 18; + // ML-KEM-768 (FIPS 203) + ML_KEM_768 = 47; + + // ML-KEM-1024 (FIPS 203) + ML_KEM_1024 = 48; + + // X-Wing hybrid KEM combining ML-KEM-768 with X25519 following + // datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem/. + KEM_XWING = 63; + // The post-quantum Module-Lattice-Based Digital Signature Algorithm, at // security level 3. Randomized version. PQ_SIGN_ML_DSA_65 = 56; @@ -719,10 +735,18 @@ message PublicKey { // (https://tools.ietf.org/html/rfc7468#section-13) for more information. PEM = 1; + // The returned public key will be encoded in DER format (the + // PrivateKeyInfo structure from RFC 5208). + DER = 2; + // This is supported only for PQC algorithms. // The key material is returned in the format defined by NIST PQC // standards (FIPS 203, FIPS 204, and FIPS 205). NIST_PQC = 3; + + // The returned public key is in raw bytes format defined in its standard + // https://datatracker.ietf.org/doc/draft-connolly-cfrg-xwing-kem. + XWING_RAW_BYTES = 4; } // The public key, encoded in PEM format. For more information, see the diff --git a/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/service.proto b/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/service.proto index 1adb6c0ed372..9678a8a4dd34 100644 --- a/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/service.proto +++ b/java-kms/proto-google-cloud-kms-v1/src/main/proto/google/cloud/kms/v1/service.proto @@ -390,6 +390,18 @@ service KeyManagementService { option (google.api.method_signature) = "name,data,mac"; } + // Decapsulates data that was encapsulated with a public key retrieved from + // [GetPublicKey][google.cloud.kms.v1.KeyManagementService.GetPublicKey] + // corresponding to a [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] + // with [CryptoKey.purpose][google.cloud.kms.v1.CryptoKey.purpose] + // KEY_ENCAPSULATION. + rpc Decapsulate(DecapsulateRequest) returns (DecapsulateResponse) { + option (google.api.http) = { + post: "/v1/{name=projects/*/locations/*/keyRings/*/cryptoKeys/*/cryptoKeyVersions/*}:decapsulate" + body: "*" + }; + } + // Generate random bytes using the Cloud KMS randomness source in the provided // location. rpc GenerateRandomBytes(GenerateRandomBytesRequest) @@ -1544,6 +1556,47 @@ message MacVerifyRequest { [(google.api.field_behavior) = OPTIONAL]; } +// Request message for +// [KeyManagementService.Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate]. +message DecapsulateRequest { + // Required. The resource name of the + // [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] to use for + // decapsulation. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "cloudkms.googleapis.com/CryptoKeyVersion" + } + ]; + + // Required. The ciphertext produced from encapsulation with the + // named [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] public + // key(s). + bytes ciphertext = 2 [(google.api.field_behavior) = REQUIRED]; + + // Optional. A CRC32C checksum of the + // [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. + // If specified, + // [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will + // verify the integrity of the received + // [DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext] + // using this checksum. + // [KeyManagementService][google.cloud.kms.v1.KeyManagementService] will + // report an error if the checksum verification fails. If you receive a + // checksum error, your client should verify that + // CRC32C([DecapsulateRequest.ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]) + // is equal to + // [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c], + // and if so, perform a limited number of retries. A persistent mismatch may + // indicate an issue in your computation of the CRC32C checksum. Note: This + // field is defined as int64 for reasons of compatibility across different + // languages. However, it is a non-negative integer, which will never exceed + // 2^32-1, and can be safely downconverted to uint32 in languages that support + // this type. + google.protobuf.Int64Value ciphertext_crc32c = 3 + [(google.api.field_behavior) = OPTIONAL]; +} + // Request message for // [KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes]. message GenerateRandomBytesRequest { @@ -2047,6 +2100,60 @@ message MacVerifyResponse { ProtectionLevel protection_level = 6; } +// Response message for +// [KeyManagementService.Decapsulate][google.cloud.kms.v1.KeyManagementService.Decapsulate]. +message DecapsulateResponse { + // The resource name of the + // [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used for + // decapsulation. Check this field to verify that the intended resource was + // used for decapsulation. + string name = 1; + + // The decapsulated shared_secret originally encapsulated with the matching + // public key. + bytes shared_secret = 2; + + // Integrity verification field. A CRC32C checksum of the returned + // [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret]. + // An integrity check of + // [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret] + // can be performed by computing the CRC32C checksum of + // [DecapsulateResponse.shared_secret][google.cloud.kms.v1.DecapsulateResponse.shared_secret] + // and comparing your results to this field. Discard the response in case of + // non-matching checksum values, and perform a limited number of retries. A + // persistent mismatch may indicate an issue in your computation of the CRC32C + // checksum. Note: receiving this response message indicates that + // [KeyManagementService][google.cloud.kms.v1.KeyManagementService] is able to + // successfully decrypt the + // [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. Note: This + // field is defined as int64 for reasons of compatibility across different + // languages. However, it is a non-negative integer, which will never exceed + // 2^32-1, and can be safely downconverted to uint32 in languages that support + // this type. + optional int64 shared_secret_crc32c = 3; + + // Integrity verification field. A flag indicating whether + // [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c] + // was received by + // [KeyManagementService][google.cloud.kms.v1.KeyManagementService] and used + // for the integrity verification of the + // [ciphertext][google.cloud.kms.v1.DecapsulateRequest.ciphertext]. A false + // value of this field indicates either that + // [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c] + // was left unset or that it was not delivered to + // [KeyManagementService][google.cloud.kms.v1.KeyManagementService]. If you've + // set + // [DecapsulateRequest.ciphertext_crc32c][google.cloud.kms.v1.DecapsulateRequest.ciphertext_crc32c] + // but this field is still false, discard the response and perform a limited + // number of retries. + bool verified_ciphertext_crc32c = 4; + + // The [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] of the + // [CryptoKeyVersion][google.cloud.kms.v1.CryptoKeyVersion] used in + // decapsulation. + ProtectionLevel protection_level = 5; +} + // Response message for // [KeyManagementService.GenerateRandomBytes][google.cloud.kms.v1.KeyManagementService.GenerateRandomBytes]. message GenerateRandomBytesResponse { diff --git a/java-kms/samples/snippets/generated/com/google/cloud/kms/v1/keymanagementservice/decapsulate/AsyncDecapsulate.java b/java-kms/samples/snippets/generated/com/google/cloud/kms/v1/keymanagementservice/decapsulate/AsyncDecapsulate.java new file mode 100644 index 000000000000..a39aaac9720f --- /dev/null +++ b/java-kms/samples/snippets/generated/com/google/cloud/kms/v1/keymanagementservice/decapsulate/AsyncDecapsulate.java @@ -0,0 +1,62 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.kms.v1.samples; + +// [START cloudkms_v1_generated_KeyManagementService_Decapsulate_async] +import com.google.api.core.ApiFuture; +import com.google.cloud.kms.v1.CryptoKeyVersionName; +import com.google.cloud.kms.v1.DecapsulateRequest; +import com.google.cloud.kms.v1.DecapsulateResponse; +import com.google.cloud.kms.v1.KeyManagementServiceClient; +import com.google.protobuf.ByteString; +import com.google.protobuf.Int64Value; + +public class AsyncDecapsulate { + + public static void main(String[] args) throws Exception { + asyncDecapsulate(); + } + + public static void asyncDecapsulate() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (KeyManagementServiceClient keyManagementServiceClient = + KeyManagementServiceClient.create()) { + DecapsulateRequest request = + DecapsulateRequest.newBuilder() + .setName( + CryptoKeyVersionName.of( + "[PROJECT]", + "[LOCATION]", + "[KEY_RING]", + "[CRYPTO_KEY]", + "[CRYPTO_KEY_VERSION]") + .toString()) + .setCiphertext(ByteString.EMPTY) + .setCiphertextCrc32C(Int64Value.newBuilder().build()) + .build(); + ApiFuture future = + keyManagementServiceClient.decapsulateCallable().futureCall(request); + // Do something. + DecapsulateResponse response = future.get(); + } + } +} +// [END cloudkms_v1_generated_KeyManagementService_Decapsulate_async] diff --git a/java-kms/samples/snippets/generated/com/google/cloud/kms/v1/keymanagementservice/decapsulate/SyncDecapsulate.java b/java-kms/samples/snippets/generated/com/google/cloud/kms/v1/keymanagementservice/decapsulate/SyncDecapsulate.java new file mode 100644 index 000000000000..afeacc594b6d --- /dev/null +++ b/java-kms/samples/snippets/generated/com/google/cloud/kms/v1/keymanagementservice/decapsulate/SyncDecapsulate.java @@ -0,0 +1,58 @@ +/* + * Copyright 2025 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.kms.v1.samples; + +// [START cloudkms_v1_generated_KeyManagementService_Decapsulate_sync] +import com.google.cloud.kms.v1.CryptoKeyVersionName; +import com.google.cloud.kms.v1.DecapsulateRequest; +import com.google.cloud.kms.v1.DecapsulateResponse; +import com.google.cloud.kms.v1.KeyManagementServiceClient; +import com.google.protobuf.ByteString; +import com.google.protobuf.Int64Value; + +public class SyncDecapsulate { + + public static void main(String[] args) throws Exception { + syncDecapsulate(); + } + + public static void syncDecapsulate() throws Exception { + // This snippet has been automatically generated and should be regarded as a code template only. + // It will require modifications to work: + // - It may require correct/in-range values for request initialization. + // - It may require specifying regional endpoints when creating the service client as shown in + // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + try (KeyManagementServiceClient keyManagementServiceClient = + KeyManagementServiceClient.create()) { + DecapsulateRequest request = + DecapsulateRequest.newBuilder() + .setName( + CryptoKeyVersionName.of( + "[PROJECT]", + "[LOCATION]", + "[KEY_RING]", + "[CRYPTO_KEY]", + "[CRYPTO_KEY_VERSION]") + .toString()) + .setCiphertext(ByteString.EMPTY) + .setCiphertextCrc32C(Int64Value.newBuilder().build()) + .build(); + DecapsulateResponse response = keyManagementServiceClient.decapsulate(request); + } + } +} +// [END cloudkms_v1_generated_KeyManagementService_Decapsulate_sync] diff --git a/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModel.java b/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModel.java index b58d12e3da8d..f86da7c87cf6 100644 --- a/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModel.java +++ b/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModel.java @@ -110,6 +110,26 @@ public enum DeploymentPlatform implements com.google.protobuf.ProtocolMessageEnu * GKE = 2; */ GKE(2), + /** + * + * + *
        +     * Google Compute Engine.
        +     * 
        + * + * GCE = 3; + */ + GCE(3), + /** + * + * + *
        +     * Fine tuned model.
        +     * 
        + * + * FINE_TUNED_MODEL = 4; + */ + FINE_TUNED_MODEL(4), UNRECOGNIZED(-1), ; @@ -146,6 +166,28 @@ public enum DeploymentPlatform implements com.google.protobuf.ProtocolMessageEnu */ public static final int GKE_VALUE = 2; + /** + * + * + *
        +     * Google Compute Engine.
        +     * 
        + * + * GCE = 3; + */ + public static final int GCE_VALUE = 3; + + /** + * + * + *
        +     * Fine tuned model.
        +     * 
        + * + * FINE_TUNED_MODEL = 4; + */ + public static final int FINE_TUNED_MODEL_VALUE = 4; + public final int getNumber() { if (this == UNRECOGNIZED) { throw new java.lang.IllegalArgumentException( @@ -176,6 +218,10 @@ public static DeploymentPlatform forNumber(int value) { return VERTEX_AI; case 2: return GKE; + case 3: + return GCE; + case 4: + return FINE_TUNED_MODEL; default: return null; } diff --git a/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModelProto.java b/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModelProto.java index 4aa0c113beff..c2c8ba04f8a1 100644 --- a/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModelProto.java +++ b/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/java/com/google/cloud/securitycenter/v2/AiModelProto.java @@ -43,7 +43,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { java.lang.String[] descriptorData = { "\n" + "-google/cloud/securitycenter/v2/ai_mode" - + "l.proto\022\036google.cloud.securitycenter.v2\"\237\002\n" + + "l.proto\022\036google.cloud.securitycenter.v2\"\276\002\n" + "\007AiModel\022\014\n" + "\004name\030\001 \001(\t\022\016\n" + "\006domain\030\002 \001(\t\022\017\n" @@ -52,16 +52,18 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\tpublisher\030\005 \001(\t\022W\n" + "\023deployment_platform\030\006" + " \001(\0162:.google.cloud.securitycenter.v2.AiModel.DeploymentPlatform\022\024\n" - + "\014display_name\030\007 \001(\t\"Q\n" + + "\014display_name\030\007 \001(\t\"p\n" + "\022DeploymentPlatform\022#\n" + "\037DEPLOYMENT_PLATFORM_UNSPECIFIED\020\000\022\r\n" + "\tVERTEX_AI\020\001\022\007\n" - + "\003GKE\020\002B\346\001\n" - + "\"com.google.cloud.securitycenter.v2B\014AiModelProtoP\001ZJcloud.google.c" - + "om/go/securitycenter/apiv2/securitycente" - + "rpb;securitycenterpb\252\002\036Google.Cloud.Secu" - + "rityCenter.V2\312\002\036Google\\Cloud\\SecurityCen" - + "ter\\V2\352\002!Google::Cloud::SecurityCenter::V2b\006proto3" + + "\003GKE\020\002\022\007\n" + + "\003GCE\020\003\022\024\n" + + "\020FINE_TUNED_MODEL\020\004B\346\001\n" + + "\"com.google.cloud.securitycenter.v2B\014AiModelProtoP\001ZJcloud.google.com/go/sec" + + "uritycenter/apiv2/securitycenterpb;secur" + + "itycenterpb\252\002\036Google.Cloud.SecurityCente" + + "r.V2\312\002\036Google\\Cloud\\SecurityCenter\\V2\352\002!" + + "Google::Cloud::SecurityCenter::V2b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( diff --git a/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/proto/google/cloud/securitycenter/v2/ai_model.proto b/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/proto/google/cloud/securitycenter/v2/ai_model.proto index 4977635d34d5..f293ae692cba 100644 --- a/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/proto/google/cloud/securitycenter/v2/ai_model.proto +++ b/java-securitycenter/proto-google-cloud-securitycenter-v2/src/main/proto/google/cloud/securitycenter/v2/ai_model.proto @@ -36,6 +36,12 @@ message AiModel { // Google Kubernetes Engine. GKE = 2; + + // Google Compute Engine. + GCE = 3; + + // Fine tuned model. + FINE_TUNED_MODEL = 4; } // The name of the AI model, for example, "gemini:1.0.0".