diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/AgentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/AgentsClient.java index 883f81f71..fcf763aea 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/AgentsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/AgentsClient.java @@ -93,8 +93,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class AgentsClient implements BackgroundResource { private final AgentsSettings settings; private final AgentsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EntityTypesClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EntityTypesClient.java index e68c0f94f..b14b15718 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EntityTypesClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EntityTypesClient.java @@ -90,8 +90,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class EntityTypesClient implements BackgroundResource { private final EntityTypesSettings settings; private final EntityTypesStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsClient.java index dcfa30aa0..138e4358c 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsClient.java @@ -95,8 +95,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class EnvironmentsClient implements BackgroundResource { private final EnvironmentsSettings settings; private final EnvironmentsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClient.java new file mode 100644 index 000000000..9c917cfc5 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClient.java @@ -0,0 +1,635 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3; + +import com.google.api.core.ApiFunction; +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.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3.stub.ExperimentsStub; +import com.google.cloud.dialogflow.cx.v3.stub.ExperimentsStubSettings; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: Service for managing + * [Experiments][google.cloud.dialogflow.cx.v3.Experiment]. + * + *

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: + * + *

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

The surface of this class includes several types of Java methods for each of the API's + * methods: + * + *

    + *
  1. A "flattened" method. With this type of method, the fields of the request type have been + * converted into function parameters. It may be the case that not all fields are available as + * parameters, and not every API method will have a flattened method entry point. + *
  2. A "request object" method. This type of method only takes one parameter, a request object, + * which must be constructed before the call. Not every API method will have a request object + * method. + *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API + * callable object, which can be used to initiate calls to the service. + *
+ * + *

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

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

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

To customize credentials: + * + *

{@code
+ * ExperimentsSettings experimentsSettings =
+ *     ExperimentsSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * ExperimentsClient experimentsClient = ExperimentsClient.create(experimentsSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * ExperimentsSettings experimentsSettings =
+ *     ExperimentsSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * ExperimentsClient experimentsClient = ExperimentsClient.create(experimentsSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@Generated("by gapic-generator-java") +public class ExperimentsClient implements BackgroundResource { + private final ExperimentsSettings settings; + private final ExperimentsStub stub; + + /** Constructs an instance of ExperimentsClient with default settings. */ + public static final ExperimentsClient create() throws IOException { + return create(ExperimentsSettings.newBuilder().build()); + } + + /** + * Constructs an instance of ExperimentsClient, 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 ExperimentsClient create(ExperimentsSettings settings) throws IOException { + return new ExperimentsClient(settings); + } + + /** + * Constructs an instance of ExperimentsClient, using the given stub for making calls. This is for + * advanced usage - prefer using create(ExperimentsSettings). + */ + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public static final ExperimentsClient create(ExperimentsStub stub) { + return new ExperimentsClient(stub); + } + + /** + * Constructs an instance of ExperimentsClient, 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 ExperimentsClient(ExperimentsSettings settings) throws IOException { + this.settings = settings; + this.stub = ((ExperimentsStubSettings) settings.getStubSettings()).createStub(); + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + protected ExperimentsClient(ExperimentsStub stub) { + this.settings = null; + this.stub = stub; + } + + public final ExperimentsSettings getSettings() { + return settings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public ExperimentsStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + * @param parent Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list + * all environments for. Format: `projects/<Project ID>/locations/<Location + * ID>/agents/<Agent ID>/environments/<Environment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListExperimentsPagedResponse listExperiments(EnvironmentName parent) { + ListExperimentsRequest request = + ListExperimentsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listExperiments(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + * @param parent Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list + * all environments for. Format: `projects/<Project ID>/locations/<Location + * ID>/agents/<Agent ID>/environments/<Environment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListExperimentsPagedResponse listExperiments(String parent) { + ListExperimentsRequest request = ListExperimentsRequest.newBuilder().setParent(parent).build(); + return listExperiments(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + * @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 ListExperimentsPagedResponse listExperiments(ListExperimentsRequest request) { + return listExperimentsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + *

Sample code: + */ + public final UnaryCallable + listExperimentsPagedCallable() { + return stub.listExperimentsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + *

Sample code: + */ + public final UnaryCallable + listExperimentsCallable() { + return stub.listExperimentsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @param name Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment getExperiment(ExperimentName name) { + GetExperimentRequest request = + GetExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @param name Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment getExperiment(String name) { + GetExperimentRequest request = GetExperimentRequest.newBuilder().setName(name).build(); + return getExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @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 Experiment getExperiment(GetExperimentRequest request) { + return getExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + *

Sample code: + */ + public final UnaryCallable getExperimentCallable() { + return stub.getExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + * @param parent Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an + * [Environment][google.cloud.dialogflow.cx.v3.Environment] for. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>`. + * @param experiment Required. The experiment to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment createExperiment(EnvironmentName parent, Experiment experiment) { + CreateExperimentRequest request = + CreateExperimentRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setExperiment(experiment) + .build(); + return createExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + * @param parent Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an + * [Environment][google.cloud.dialogflow.cx.v3.Environment] for. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>`. + * @param experiment Required. The experiment to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment createExperiment(String parent, Experiment experiment) { + CreateExperimentRequest request = + CreateExperimentRequest.newBuilder().setParent(parent).setExperiment(experiment).build(); + return createExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + * @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 Experiment createExperiment(CreateExperimentRequest request) { + return createExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3.Environment]. + * + *

Sample code: + */ + public final UnaryCallable createExperimentCallable() { + return stub.createExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @param experiment Required. The experiment to update. + * @param updateMask Required. The mask to control which fields get updated. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment updateExperiment(Experiment experiment, FieldMask updateMask) { + UpdateExperimentRequest request = + UpdateExperimentRequest.newBuilder() + .setExperiment(experiment) + .setUpdateMask(updateMask) + .build(); + return updateExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @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 Experiment updateExperiment(UpdateExperimentRequest request) { + return updateExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + *

Sample code: + */ + public final UnaryCallable updateExperimentCallable() { + return stub.updateExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @param name Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] + * to delete. Format: `projects/<Project ID>/locations/<Location + * ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteExperiment(ExperimentName name) { + DeleteExperimentRequest request = + DeleteExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + deleteExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @param name Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] + * to delete. Format: `projects/<Project ID>/locations/<Location + * ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteExperiment(String name) { + DeleteExperimentRequest request = DeleteExperimentRequest.newBuilder().setName(name).build(); + deleteExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + * @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 deleteExperiment(DeleteExperimentRequest request) { + deleteExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + * + *

Sample code: + */ + public final UnaryCallable deleteExperimentCallable() { + return stub.deleteExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + * @param name Required. Resource name of the experiment to start. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment startExperiment(ExperimentName name) { + StartExperimentRequest request = + StartExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return startExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + * @param name Required. Resource name of the experiment to start. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment startExperiment(String name) { + StartExperimentRequest request = StartExperimentRequest.newBuilder().setName(name).build(); + return startExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + * @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 Experiment startExperiment(StartExperimentRequest request) { + return startExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + *

Sample code: + */ + public final UnaryCallable startExperimentCallable() { + return stub.startExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + * @param name Required. Resource name of the experiment to stop. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment stopExperiment(ExperimentName name) { + StopExperimentRequest request = + StopExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return stopExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + * @param name Required. Resource name of the experiment to stop. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment stopExperiment(String name) { + StopExperimentRequest request = StopExperimentRequest.newBuilder().setName(name).build(); + return stopExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + * @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 Experiment stopExperiment(StopExperimentRequest request) { + return stopExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + *

Sample code: + */ + public final UnaryCallable stopExperimentCallable() { + return stub.stopExperimentCallable(); + } + + @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 ListExperimentsPagedResponse + extends AbstractPagedListResponse< + ListExperimentsRequest, + ListExperimentsResponse, + Experiment, + ListExperimentsPage, + ListExperimentsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListExperimentsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListExperimentsPagedResponse apply(ListExperimentsPage input) { + return new ListExperimentsPagedResponse(input); + } + }, + MoreExecutors.directExecutor()); + } + + private ListExperimentsPagedResponse(ListExperimentsPage page) { + super(page, ListExperimentsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListExperimentsPage + extends AbstractPage< + ListExperimentsRequest, ListExperimentsResponse, Experiment, ListExperimentsPage> { + + private ListExperimentsPage( + PageContext context, + ListExperimentsResponse response) { + super(context, response); + } + + private static ListExperimentsPage createEmptyPage() { + return new ListExperimentsPage(null, null); + } + + @Override + protected ListExperimentsPage createPage( + PageContext context, + ListExperimentsResponse response) { + return new ListExperimentsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListExperimentsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListExperimentsRequest, + ListExperimentsResponse, + Experiment, + ListExperimentsPage, + ListExperimentsFixedSizeCollection> { + + private ListExperimentsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListExperimentsFixedSizeCollection createEmptyCollection() { + return new ListExperimentsFixedSizeCollection(null, 0); + } + + @Override + protected ListExperimentsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListExperimentsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsSettings.java new file mode 100644 index 000000000..f48869a41 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsSettings.java @@ -0,0 +1,250 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3; + +import static com.google.cloud.dialogflow.cx.v3.ExperimentsClient.ListExperimentsPagedResponse; + +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.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +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.dialogflow.cx.v3.stub.ExperimentsStubSettings; +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 ExperimentsClient}. + * + *

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

+ * + *

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 total timeout of getExperiment to 30 seconds: + * + *

{@code
+ * ExperimentsSettings.Builder experimentsSettingsBuilder = ExperimentsSettings.newBuilder();
+ * experimentsSettingsBuilder
+ *     .getExperimentSettings()
+ *     .setRetrySettings(
+ *         experimentsSettingsBuilder
+ *             .getExperimentSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * ExperimentsSettings experimentsSettings = experimentsSettingsBuilder.build();
+ * }
+ */ +@Generated("by gapic-generator-java") +public class ExperimentsSettings extends ClientSettings { + + /** Returns the object with the settings used for calls to listExperiments. */ + public PagedCallSettings< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return ((ExperimentsStubSettings) getStubSettings()).listExperimentsSettings(); + } + + /** Returns the object with the settings used for calls to getExperiment. */ + public UnaryCallSettings getExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).getExperimentSettings(); + } + + /** Returns the object with the settings used for calls to createExperiment. */ + public UnaryCallSettings createExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).createExperimentSettings(); + } + + /** Returns the object with the settings used for calls to updateExperiment. */ + public UnaryCallSettings updateExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).updateExperimentSettings(); + } + + /** Returns the object with the settings used for calls to deleteExperiment. */ + public UnaryCallSettings deleteExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).deleteExperimentSettings(); + } + + /** Returns the object with the settings used for calls to startExperiment. */ + public UnaryCallSettings startExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).startExperimentSettings(); + } + + /** Returns the object with the settings used for calls to stopExperiment. */ + public UnaryCallSettings stopExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).stopExperimentSettings(); + } + + public static final ExperimentsSettings create(ExperimentsStubSettings stub) throws IOException { + return new ExperimentsSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return ExperimentsStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return ExperimentsStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return ExperimentsStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return ExperimentsStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return ExperimentsStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return ExperimentsStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ExperimentsStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(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 ExperimentsSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for ExperimentsSettings. */ + public static class Builder extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(ExperimentsStubSettings.newBuilder(clientContext)); + } + + protected Builder(ExperimentsSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(ExperimentsStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(ExperimentsStubSettings.newBuilder()); + } + + public ExperimentsStubSettings.Builder getStubSettingsBuilder() { + return ((ExperimentsStubSettings.Builder) getStubSettings()); + } + + // NEXT_MAJOR_VER: remove 'throws Exception'. + /** + * 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) throws Exception { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to listExperiments. */ + public PagedCallSettings.Builder< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return getStubSettingsBuilder().listExperimentsSettings(); + } + + /** Returns the builder for the settings used for calls to getExperiment. */ + public UnaryCallSettings.Builder getExperimentSettings() { + return getStubSettingsBuilder().getExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to createExperiment. */ + public UnaryCallSettings.Builder + createExperimentSettings() { + return getStubSettingsBuilder().createExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to updateExperiment. */ + public UnaryCallSettings.Builder + updateExperimentSettings() { + return getStubSettingsBuilder().updateExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to deleteExperiment. */ + public UnaryCallSettings.Builder deleteExperimentSettings() { + return getStubSettingsBuilder().deleteExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to startExperiment. */ + public UnaryCallSettings.Builder startExperimentSettings() { + return getStubSettingsBuilder().startExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to stopExperiment. */ + public UnaryCallSettings.Builder stopExperimentSettings() { + return getStubSettingsBuilder().stopExperimentSettings(); + } + + @Override + public ExperimentsSettings build() throws IOException { + return new ExperimentsSettings(this); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsClient.java index 71497dbd2..4197076d9 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsClient.java @@ -93,8 +93,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class FlowsClient implements BackgroundResource { private final FlowsSettings settings; private final FlowsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/IntentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/IntentsClient.java index 9589c02e6..dfb20ff88 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/IntentsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/IntentsClient.java @@ -88,8 +88,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class IntentsClient implements BackgroundResource { private final IntentsSettings settings; private final IntentsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/PagesClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/PagesClient.java index 7be5669f5..a879948f4 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/PagesClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/PagesClient.java @@ -88,8 +88,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class PagesClient implements BackgroundResource { private final PagesSettings settings; private final PagesStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SecuritySettingsServiceClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SecuritySettingsServiceClient.java index 7b603ce44..4560f26c0 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SecuritySettingsServiceClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SecuritySettingsServiceClient.java @@ -92,8 +92,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class SecuritySettingsServiceClient implements BackgroundResource { private final SecuritySettingsServiceSettings settings; private final SecuritySettingsServiceStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionEntityTypesClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionEntityTypesClient.java index a692241b5..b11b16975 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionEntityTypesClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionEntityTypesClient.java @@ -93,8 +93,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class SessionEntityTypesClient implements BackgroundResource { private final SessionEntityTypesSettings settings; private final SessionEntityTypesStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsClient.java index 89a6f26cd..6a3eb6c7e 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsClient.java @@ -81,8 +81,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class SessionsClient implements BackgroundResource { private final SessionsSettings settings; private final SessionsStub stub; @@ -139,6 +138,9 @@ public SessionsStub getStub() { * method is not idempotent, because it may cause session entity types to be updated, which in * turn might affect results of future queries. * + *

Note: Always use agent versions for production traffic. See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). + * * @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 */ @@ -152,6 +154,9 @@ public final DetectIntentResponse detectIntent(DetectIntentRequest request) { * method is not idempotent, because it may cause session entity types to be updated, which in * turn might affect results of future queries. * + *

Note: Always use agent versions for production traffic. See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). + * *

Sample code: */ public final UnaryCallable detectIntentCallable() { @@ -164,6 +169,9 @@ public final UnaryCallable detectInte * structured, actionable data as a result. This method is only available via the gRPC API (not * REST). * + *

Note: Always use agent versions for production traffic. See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). + * *

Sample code: */ public final BidiStreamingCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/TransitionRouteGroupsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/TransitionRouteGroupsClient.java index 13807556e..b188c7ada 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/TransitionRouteGroupsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/TransitionRouteGroupsClient.java @@ -93,8 +93,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class TransitionRouteGroupsClient implements BackgroundResource { private final TransitionRouteGroupsSettings settings; private final TransitionRouteGroupsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionsClient.java index 6e043c97c..3bba62b28 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionsClient.java @@ -94,8 +94,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class VersionsClient implements BackgroundResource { private final VersionsSettings settings; private final VersionsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/WebhooksClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/WebhooksClient.java index ae19f0602..87255df7c 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/WebhooksClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/WebhooksClient.java @@ -89,8 +89,7 @@ * *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ -@BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class WebhooksClient implements BackgroundResource { private final WebhooksSettings settings; private final WebhooksStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/package-info.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/package-info.java index 761ab736c..bc9b75f67 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/package-info.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/package-info.java @@ -37,6 +37,13 @@ * *

Sample for EnvironmentsClient: * + *

======================= ExperimentsClient ======================= + * + *

Service Description: Service for managing + * [Experiments][google.cloud.dialogflow.cx.v3.Experiment]. + * + *

Sample for ExperimentsClient: + * *

======================= FlowsClient ======================= * *

Service Description: Service for managing [Flows][google.cloud.dialogflow.cx.v3.Flow]. diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStub.java index df817663c..9742165ad 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStub.java @@ -43,7 +43,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class AgentsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStubSettings.java index 173f21d7b..e4c3c4eb4 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/AgentsStubSettings.java @@ -97,7 +97,6 @@ * AgentsStubSettings agentsSettings = agentsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class AgentsStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStub.java index 7d5e24b79..7b6667b13 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class EntityTypesStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStubSettings.java index 1e2472785..cf3f899f4 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStubSettings.java @@ -89,7 +89,6 @@ * EntityTypesStubSettings entityTypesSettings = entityTypesSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class EntityTypesStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStub.java index f2e0d0078..3f34baeba 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStub.java @@ -43,7 +43,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class EnvironmentsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStubSettings.java index 255e92ce6..b1f84d9da 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStubSettings.java @@ -98,7 +98,6 @@ * EnvironmentsStubSettings environmentsSettings = environmentsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class EnvironmentsStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStub.java new file mode 100644 index 000000000..8a69671e4 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStub.java @@ -0,0 +1,79 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3.stub; + +import static com.google.cloud.dialogflow.cx.v3.ExperimentsClient.ListExperimentsPagedResponse; + +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.Experiment; +import com.google.cloud.dialogflow.cx.v3.GetExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest; +import com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse; +import com.google.cloud.dialogflow.cx.v3.StartExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.StopExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest; +import com.google.protobuf.Empty; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the Experiments service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public abstract class ExperimentsStub implements BackgroundResource { + + public UnaryCallable + listExperimentsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listExperimentsPagedCallable()"); + } + + public UnaryCallable listExperimentsCallable() { + throw new UnsupportedOperationException("Not implemented: listExperimentsCallable()"); + } + + public UnaryCallable getExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: getExperimentCallable()"); + } + + public UnaryCallable createExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: createExperimentCallable()"); + } + + public UnaryCallable updateExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: updateExperimentCallable()"); + } + + public UnaryCallable deleteExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: deleteExperimentCallable()"); + } + + public UnaryCallable startExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: startExperimentCallable()"); + } + + public UnaryCallable stopExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: stopExperimentCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStubSettings.java new file mode 100644 index 000000000..46665a0b8 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStubSettings.java @@ -0,0 +1,491 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3.stub; + +import static com.google.cloud.dialogflow.cx.v3.ExperimentsClient.ListExperimentsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +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.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.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.dialogflow.cx.v3.CreateExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.Experiment; +import com.google.cloud.dialogflow.cx.v3.GetExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest; +import com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse; +import com.google.cloud.dialogflow.cx.v3.StartExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.StopExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest; +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.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link ExperimentsStub}. + * + *

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

    + *
  • The default service address (dialogflow.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 total timeout of getExperiment to 30 seconds: + * + *

{@code
+ * ExperimentsStubSettings.Builder experimentsSettingsBuilder =
+ *     ExperimentsStubSettings.newBuilder();
+ * experimentsSettingsBuilder
+ *     .getExperimentSettings()
+ *     .setRetrySettings(
+ *         experimentsSettingsBuilder
+ *             .getExperimentSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * ExperimentsStubSettings experimentsSettings = experimentsSettingsBuilder.build();
+ * }
+ */ +@Generated("by gapic-generator-java") +public class ExperimentsStubSettings 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") + .add("https://www.googleapis.com/auth/dialogflow") + .build(); + + private final PagedCallSettings< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings; + private final UnaryCallSettings getExperimentSettings; + private final UnaryCallSettings createExperimentSettings; + private final UnaryCallSettings updateExperimentSettings; + private final UnaryCallSettings deleteExperimentSettings; + private final UnaryCallSettings startExperimentSettings; + private final UnaryCallSettings stopExperimentSettings; + + private static final PagedListDescriptor< + ListExperimentsRequest, ListExperimentsResponse, Experiment> + LIST_EXPERIMENTS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListExperimentsRequest injectToken( + ListExperimentsRequest payload, String token) { + return ListExperimentsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListExperimentsRequest injectPageSize( + ListExperimentsRequest payload, int pageSize) { + return ListExperimentsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListExperimentsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListExperimentsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListExperimentsResponse payload) { + return payload.getExperimentsList() == null + ? ImmutableList.of() + : payload.getExperimentsList(); + } + }; + + private static final PagedListResponseFactory< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + LIST_EXPERIMENTS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListExperimentsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_EXPERIMENTS_PAGE_STR_DESC, request, context); + return ListExperimentsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to listExperiments. */ + public PagedCallSettings< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return listExperimentsSettings; + } + + /** Returns the object with the settings used for calls to getExperiment. */ + public UnaryCallSettings getExperimentSettings() { + return getExperimentSettings; + } + + /** Returns the object with the settings used for calls to createExperiment. */ + public UnaryCallSettings createExperimentSettings() { + return createExperimentSettings; + } + + /** Returns the object with the settings used for calls to updateExperiment. */ + public UnaryCallSettings updateExperimentSettings() { + return updateExperimentSettings; + } + + /** Returns the object with the settings used for calls to deleteExperiment. */ + public UnaryCallSettings deleteExperimentSettings() { + return deleteExperimentSettings; + } + + /** Returns the object with the settings used for calls to startExperiment. */ + public UnaryCallSettings startExperimentSettings() { + return startExperimentSettings; + } + + /** Returns the object with the settings used for calls to stopExperiment. */ + public UnaryCallSettings stopExperimentSettings() { + return stopExperimentSettings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public ExperimentsStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcExperimentsStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "dialogflow.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); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(ExperimentsStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(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 ExperimentsStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + listExperimentsSettings = settingsBuilder.listExperimentsSettings().build(); + getExperimentSettings = settingsBuilder.getExperimentSettings().build(); + createExperimentSettings = settingsBuilder.createExperimentSettings().build(); + updateExperimentSettings = settingsBuilder.updateExperimentSettings().build(); + deleteExperimentSettings = settingsBuilder.deleteExperimentSettings().build(); + startExperimentSettings = settingsBuilder.startExperimentSettings().build(); + stopExperimentSettings = settingsBuilder.stopExperimentSettings().build(); + } + + /** Builder for ExperimentsStubSettings. */ + public static class Builder extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final PagedCallSettings.Builder< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings; + private final UnaryCallSettings.Builder getExperimentSettings; + private final UnaryCallSettings.Builder + createExperimentSettings; + private final UnaryCallSettings.Builder + updateExperimentSettings; + private final UnaryCallSettings.Builder + deleteExperimentSettings; + private final UnaryCallSettings.Builder + startExperimentSettings; + private final UnaryCallSettings.Builder + stopExperimentSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "retry_policy_0_codes", + ImmutableSet.copyOf(Lists.newArrayList(StatusCode.Code.UNAVAILABLE))); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(100L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelay(Duration.ofMillis(60000L)) + .setInitialRpcTimeout(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(60000L)) + .setTotalTimeout(Duration.ofMillis(60000L)) + .build(); + definitions.put("retry_policy_0_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + listExperimentsSettings = PagedCallSettings.newBuilder(LIST_EXPERIMENTS_PAGE_STR_FACT); + getExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + startExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + stopExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + listExperimentsSettings, + getExperimentSettings, + createExperimentSettings, + updateExperimentSettings, + deleteExperimentSettings, + startExperimentSettings, + stopExperimentSettings); + initDefaults(this); + } + + protected Builder(ExperimentsStubSettings settings) { + super(settings); + + listExperimentsSettings = settings.listExperimentsSettings.toBuilder(); + getExperimentSettings = settings.getExperimentSettings.toBuilder(); + createExperimentSettings = settings.createExperimentSettings.toBuilder(); + updateExperimentSettings = settings.updateExperimentSettings.toBuilder(); + deleteExperimentSettings = settings.deleteExperimentSettings.toBuilder(); + startExperimentSettings = settings.startExperimentSettings.toBuilder(); + stopExperimentSettings = settings.stopExperimentSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + listExperimentsSettings, + getExperimentSettings, + createExperimentSettings, + updateExperimentSettings, + deleteExperimentSettings, + startExperimentSettings, + stopExperimentSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .listExperimentsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .createExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .deleteExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .startExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .stopExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + return builder; + } + + // NEXT_MAJOR_VER: remove 'throws Exception'. + /** + * 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) throws Exception { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to listExperiments. */ + public PagedCallSettings.Builder< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return listExperimentsSettings; + } + + /** Returns the builder for the settings used for calls to getExperiment. */ + public UnaryCallSettings.Builder getExperimentSettings() { + return getExperimentSettings; + } + + /** Returns the builder for the settings used for calls to createExperiment. */ + public UnaryCallSettings.Builder + createExperimentSettings() { + return createExperimentSettings; + } + + /** Returns the builder for the settings used for calls to updateExperiment. */ + public UnaryCallSettings.Builder + updateExperimentSettings() { + return updateExperimentSettings; + } + + /** Returns the builder for the settings used for calls to deleteExperiment. */ + public UnaryCallSettings.Builder deleteExperimentSettings() { + return deleteExperimentSettings; + } + + /** Returns the builder for the settings used for calls to startExperiment. */ + public UnaryCallSettings.Builder startExperimentSettings() { + return startExperimentSettings; + } + + /** Returns the builder for the settings used for calls to stopExperiment. */ + public UnaryCallSettings.Builder stopExperimentSettings() { + return stopExperimentSettings; + } + + @Override + public ExperimentsStubSettings build() throws IOException { + return new ExperimentsStubSettings(this); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStub.java index e4674f2e1..84c9b9707 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStub.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class FlowsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStubSettings.java index 7df591e9c..9da33359f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStubSettings.java @@ -95,7 +95,6 @@ * FlowsStubSettings flowsSettings = flowsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class FlowsStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcAgentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcAgentsCallableFactory.java index 85ae3965b..6ed958e01 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcAgentsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcAgentsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcAgentsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEntityTypesCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEntityTypesCallableFactory.java index eb8395bc7..13e8db413 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEntityTypesCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEntityTypesCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcEntityTypesCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEnvironmentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEnvironmentsCallableFactory.java index 40dbc708d..dc59c9a7a 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEnvironmentsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEnvironmentsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcEnvironmentsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsCallableFactory.java new file mode 100644 index 000000000..da36542d1 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsCallableFactory.java @@ -0,0 +1,113 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3.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 Experiments service API. + * + *

This class is for advanced usage. + */ +@Generated("by gapic-generator-java") +public class GrpcExperimentsCallableFactory 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/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsStub.java new file mode 100644 index 000000000..e33c42ae1 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsStub.java @@ -0,0 +1,368 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3.stub; + +import static com.google.cloud.dialogflow.cx.v3.ExperimentsClient.ListExperimentsPagedResponse; + +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.RequestParamsExtractor; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.Experiment; +import com.google.cloud.dialogflow.cx.v3.GetExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest; +import com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse; +import com.google.cloud.dialogflow.cx.v3.StartExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.StopExperimentRequest; +import com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest; +import com.google.common.collect.ImmutableMap; +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.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the Experiments service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@Generated("by gapic-generator-java") +public class GrpcExperimentsStub extends ExperimentsStub { + private static final MethodDescriptor + listExperimentsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/ListExperiments") + .setRequestMarshaller( + ProtoUtils.marshaller(ListExperimentsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListExperimentsResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + getExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/GetExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(GetExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + createExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/CreateExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + updateExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/UpdateExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + deleteExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/DeleteExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + startExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/StartExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(StartExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + stopExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3.Experiments/StopExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(StopExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private final UnaryCallable + listExperimentsCallable; + private final UnaryCallable + listExperimentsPagedCallable; + private final UnaryCallable getExperimentCallable; + private final UnaryCallable createExperimentCallable; + private final UnaryCallable updateExperimentCallable; + private final UnaryCallable deleteExperimentCallable; + private final UnaryCallable startExperimentCallable; + private final UnaryCallable stopExperimentCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcExperimentsStub create(ExperimentsStubSettings settings) + throws IOException { + return new GrpcExperimentsStub(settings, ClientContext.create(settings)); + } + + public static final GrpcExperimentsStub create(ClientContext clientContext) throws IOException { + return new GrpcExperimentsStub(ExperimentsStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcExperimentsStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcExperimentsStub( + ExperimentsStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcExperimentsStub, 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 GrpcExperimentsStub(ExperimentsStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcExperimentsCallableFactory()); + } + + /** + * Constructs an instance of GrpcExperimentsStub, 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 GrpcExperimentsStub( + ExperimentsStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings + listExperimentsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listExperimentsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListExperimentsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings getExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(GetExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings createExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(CreateExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings updateExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(UpdateExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put( + "experiment.name", String.valueOf(request.getExperiment().getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings deleteExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(DeleteExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings startExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(startExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(StartExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings stopExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(stopExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(StopExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + + this.listExperimentsCallable = + callableFactory.createUnaryCallable( + listExperimentsTransportSettings, settings.listExperimentsSettings(), clientContext); + this.listExperimentsPagedCallable = + callableFactory.createPagedCallable( + listExperimentsTransportSettings, settings.listExperimentsSettings(), clientContext); + this.getExperimentCallable = + callableFactory.createUnaryCallable( + getExperimentTransportSettings, settings.getExperimentSettings(), clientContext); + this.createExperimentCallable = + callableFactory.createUnaryCallable( + createExperimentTransportSettings, settings.createExperimentSettings(), clientContext); + this.updateExperimentCallable = + callableFactory.createUnaryCallable( + updateExperimentTransportSettings, settings.updateExperimentSettings(), clientContext); + this.deleteExperimentCallable = + callableFactory.createUnaryCallable( + deleteExperimentTransportSettings, settings.deleteExperimentSettings(), clientContext); + this.startExperimentCallable = + callableFactory.createUnaryCallable( + startExperimentTransportSettings, settings.startExperimentSettings(), clientContext); + this.stopExperimentCallable = + callableFactory.createUnaryCallable( + stopExperimentTransportSettings, settings.stopExperimentSettings(), clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + public UnaryCallable listExperimentsCallable() { + return listExperimentsCallable; + } + + public UnaryCallable + listExperimentsPagedCallable() { + return listExperimentsPagedCallable; + } + + public UnaryCallable getExperimentCallable() { + return getExperimentCallable; + } + + public UnaryCallable createExperimentCallable() { + return createExperimentCallable; + } + + public UnaryCallable updateExperimentCallable() { + return updateExperimentCallable; + } + + public UnaryCallable deleteExperimentCallable() { + return deleteExperimentCallable; + } + + public UnaryCallable startExperimentCallable() { + return startExperimentCallable; + } + + public UnaryCallable stopExperimentCallable() { + return stopExperimentCallable; + } + + @Override + public final void close() { + shutdown(); + } + + @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/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcFlowsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcFlowsCallableFactory.java index ac4d9854c..5a2977209 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcFlowsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcFlowsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcFlowsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcIntentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcIntentsCallableFactory.java index 5bfe77608..de3827094 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcIntentsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcIntentsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcIntentsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcPagesCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcPagesCallableFactory.java index d47dc9879..1b143e05b 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcPagesCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcPagesCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcPagesCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSecuritySettingsServiceCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSecuritySettingsServiceCallableFactory.java index 03c7fb881..11165969a 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSecuritySettingsServiceCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSecuritySettingsServiceCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcSecuritySettingsServiceCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionEntityTypesCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionEntityTypesCallableFactory.java index 2f6260246..d98770884 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionEntityTypesCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionEntityTypesCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcSessionEntityTypesCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionsCallableFactory.java index 8d62a7f92..8501b9b67 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcSessionsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcSessionsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcTransitionRouteGroupsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcTransitionRouteGroupsCallableFactory.java index 65c8f7e60..792a7a608 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcTransitionRouteGroupsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcTransitionRouteGroupsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcTransitionRouteGroupsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcVersionsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcVersionsCallableFactory.java index 2f208608d..49267120a 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcVersionsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcVersionsCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcVersionsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcWebhooksCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcWebhooksCallableFactory.java index c1e205a13..634995070 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcWebhooksCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcWebhooksCallableFactory.java @@ -41,7 +41,7 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class GrpcWebhooksCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStub.java index b4b5736a0..5a20a639f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class IntentsStub implements BackgroundResource { public UnaryCallable listIntentsPagedCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStubSettings.java index 78a9999da..0d685335e 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/IntentsStubSettings.java @@ -88,7 +88,6 @@ * IntentsStubSettings intentsSettings = intentsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class IntentsStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStub.java index 11e82584b..b242df6d3 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class PagesStub implements BackgroundResource { public UnaryCallable listPagesPagedCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStubSettings.java index 446f70bb5..1368af74b 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/PagesStubSettings.java @@ -88,7 +88,6 @@ * PagesStubSettings pagesSettings = pagesSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class PagesStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStub.java index b49dfd4c8..d90e49705 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class SecuritySettingsServiceStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStubSettings.java index 460e733b3..5234f2cb1 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SecuritySettingsServiceStubSettings.java @@ -90,7 +90,6 @@ * securitySettingsServiceSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class SecuritySettingsServiceStubSettings extends StubSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStub.java index 4b688c7f0..f1673b93b 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class SessionEntityTypesStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStubSettings.java index 26022ad38..a637cca07 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionEntityTypesStubSettings.java @@ -90,7 +90,6 @@ * sessionEntityTypesSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class SessionEntityTypesStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStub.java index 36802f5be..e94080d0a 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStub.java @@ -35,7 +35,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class SessionsStub implements BackgroundResource { public UnaryCallable detectIntentCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStubSettings.java index 915b4013e..d47ab7c09 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/SessionsStubSettings.java @@ -80,7 +80,6 @@ * SessionsStubSettings sessionsSettings = sessionsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class SessionsStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStub.java index ecb70c747..41adc5a2f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class TransitionRouteGroupsStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStubSettings.java index 65e998d4e..85dba2cf4 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/TransitionRouteGroupsStubSettings.java @@ -90,7 +90,6 @@ * transitionRouteGroupsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class TransitionRouteGroupsStubSettings extends StubSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStub.java index 005936a03..bab038092 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStub.java @@ -42,7 +42,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class VersionsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStubSettings.java index bbbc4ecc3..b6ba51bb9 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/VersionsStubSettings.java @@ -96,7 +96,6 @@ * VersionsStubSettings versionsSettings = versionsSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class VersionsStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStub.java index 4cac7fe04..0f0e3c738 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStub.java @@ -36,7 +36,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public abstract class WebhooksStub implements BackgroundResource { public UnaryCallable listWebhooksPagedCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStubSettings.java index a2c6f1661..a7423e913 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStubSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/WebhooksStubSettings.java @@ -88,7 +88,6 @@ * WebhooksStubSettings webhooksSettings = webhooksSettingsBuilder.build(); * } */ -@BetaApi @Generated("by gapic-generator-java") public class WebhooksStubSettings extends StubSettings { /** The default scopes of the service. */ diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsClient.java index 41c7c8ebc..be4b30b50 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsClient.java @@ -94,7 +94,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class AgentsClient implements BackgroundResource { private final AgentsSettings settings; private final AgentsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsSettings.java index 81b55b3fd..d33de6cec 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsSettings.java @@ -69,6 +69,7 @@ * AgentsSettings agentsSettings = agentsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class AgentsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesClient.java index 621a86e16..2610067e6 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesClient.java @@ -91,7 +91,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class EntityTypesClient implements BackgroundResource { private final EntityTypesSettings settings; private final EntityTypesStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesSettings.java index 878cafedc..3937d9810 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesSettings.java @@ -66,6 +66,7 @@ * EntityTypesSettings entityTypesSettings = entityTypesSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class EntityTypesSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsClient.java index 4e698d3f6..28c5f789b 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsClient.java @@ -96,7 +96,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class EnvironmentsClient implements BackgroundResource { private final EnvironmentsSettings settings; private final EnvironmentsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsSettings.java index a171dd7b2..83887b3af 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsSettings.java @@ -70,6 +70,7 @@ * EnvironmentsSettings environmentsSettings = environmentsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class EnvironmentsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClient.java new file mode 100644 index 000000000..d958df2f7 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClient.java @@ -0,0 +1,638 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import com.google.api.core.ApiFunction; +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.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3beta1.stub.ExperimentsStub; +import com.google.cloud.dialogflow.cx.v3beta1.stub.ExperimentsStubSettings; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: Service for managing + * [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + *

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: + * + *

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

The surface of this class includes several types of Java methods for each of the API's + * methods: + * + *

    + *
  1. A "flattened" method. With this type of method, the fields of the request type have been + * converted into function parameters. It may be the case that not all fields are available as + * parameters, and not every API method will have a flattened method entry point. + *
  2. A "request object" method. This type of method only takes one parameter, a request object, + * which must be constructed before the call. Not every API method will have a request object + * method. + *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API + * callable object, which can be used to initiate calls to the service. + *
+ * + *

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

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

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

To customize credentials: + * + *

{@code
+ * ExperimentsSettings experimentsSettings =
+ *     ExperimentsSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * ExperimentsClient experimentsClient = ExperimentsClient.create(experimentsSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * ExperimentsSettings experimentsSettings =
+ *     ExperimentsSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * ExperimentsClient experimentsClient = ExperimentsClient.create(experimentsSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class ExperimentsClient implements BackgroundResource { + private final ExperimentsSettings settings; + private final ExperimentsStub stub; + + /** Constructs an instance of ExperimentsClient with default settings. */ + public static final ExperimentsClient create() throws IOException { + return create(ExperimentsSettings.newBuilder().build()); + } + + /** + * Constructs an instance of ExperimentsClient, 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 ExperimentsClient create(ExperimentsSettings settings) throws IOException { + return new ExperimentsClient(settings); + } + + /** + * Constructs an instance of ExperimentsClient, using the given stub for making calls. This is for + * advanced usage - prefer using create(ExperimentsSettings). + */ + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public static final ExperimentsClient create(ExperimentsStub stub) { + return new ExperimentsClient(stub); + } + + /** + * Constructs an instance of ExperimentsClient, 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 ExperimentsClient(ExperimentsSettings settings) throws IOException { + this.settings = settings; + this.stub = ((ExperimentsStubSettings) settings.getStubSettings()).createStub(); + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + protected ExperimentsClient(ExperimentsStub stub) { + this.settings = null; + this.stub = stub; + } + + public final ExperimentsSettings getSettings() { + return settings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public ExperimentsStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + * @param parent Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to + * list all environments for. Format: `projects/<Project ID>/locations/<Location + * ID>/agents/<Agent ID>/environments/<Environment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListExperimentsPagedResponse listExperiments(EnvironmentName parent) { + ListExperimentsRequest request = + ListExperimentsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listExperiments(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + * @param parent Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to + * list all environments for. Format: `projects/<Project ID>/locations/<Location + * ID>/agents/<Agent ID>/environments/<Environment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListExperimentsPagedResponse listExperiments(String parent) { + ListExperimentsRequest request = ListExperimentsRequest.newBuilder().setParent(parent).build(); + return listExperiments(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + * @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 ListExperimentsPagedResponse listExperiments(ListExperimentsRequest request) { + return listExperimentsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + *

Sample code: + */ + public final UnaryCallable + listExperimentsPagedCallable() { + return stub.listExperimentsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all experiments in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + *

Sample code: + */ + public final UnaryCallable + listExperimentsCallable() { + return stub.listExperimentsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @param name Required. The name of the + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. Format: + * `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment getExperiment(ExperimentName name) { + GetExperimentRequest request = + GetExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return getExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @param name Required. The name of the + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. Format: + * `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment getExperiment(String name) { + GetExperimentRequest request = GetExperimentRequest.newBuilder().setName(name).build(); + return getExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @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 Experiment getExperiment(GetExperimentRequest request) { + return getExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + *

Sample code: + */ + public final UnaryCallable getExperimentCallable() { + return stub.getExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + * @param parent Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for. Format: + * `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>`. + * @param experiment Required. The experiment to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment createExperiment(EnvironmentName parent, Experiment experiment) { + CreateExperimentRequest request = + CreateExperimentRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setExperiment(experiment) + .build(); + return createExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + * @param parent Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for. Format: + * `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>`. + * @param experiment Required. The experiment to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment createExperiment(String parent, Experiment experiment) { + CreateExperimentRequest request = + CreateExperimentRequest.newBuilder().setParent(parent).setExperiment(experiment).build(); + return createExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + * @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 Experiment createExperiment(CreateExperimentRequest request) { + return createExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + * + *

Sample code: + */ + public final UnaryCallable createExperimentCallable() { + return stub.createExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @param experiment Required. The experiment to update. + * @param updateMask Required. The mask to control which fields get updated. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment updateExperiment(Experiment experiment, FieldMask updateMask) { + UpdateExperimentRequest request = + UpdateExperimentRequest.newBuilder() + .setExperiment(experiment) + .setUpdateMask(updateMask) + .build(); + return updateExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @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 Experiment updateExperiment(UpdateExperimentRequest request) { + return updateExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + *

Sample code: + */ + public final UnaryCallable updateExperimentCallable() { + return stub.updateExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @param name Required. The name of the + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete. Format: + * `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteExperiment(ExperimentName name) { + DeleteExperimentRequest request = + DeleteExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + deleteExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @param name Required. The name of the + * [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete. Format: + * `projects/<Project ID>/locations/<Location ID>/agents/<Agent + * ID>/environments/<Environment ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteExperiment(String name) { + DeleteExperimentRequest request = DeleteExperimentRequest.newBuilder().setName(name).build(); + deleteExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + * @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 deleteExperiment(DeleteExperimentRequest request) { + deleteExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + *

Sample code: + */ + public final UnaryCallable deleteExperimentCallable() { + return stub.deleteExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + * @param name Required. Resource name of the experiment to start. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment startExperiment(ExperimentName name) { + StartExperimentRequest request = + StartExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return startExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + * @param name Required. Resource name of the experiment to start. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment startExperiment(String name) { + StartExperimentRequest request = StartExperimentRequest.newBuilder().setName(name).build(); + return startExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + * @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 Experiment startExperiment(StartExperimentRequest request) { + return startExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from PENDING to RUNNING. + * + *

Sample code: + */ + public final UnaryCallable startExperimentCallable() { + return stub.startExperimentCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + * @param name Required. Resource name of the experiment to stop. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment stopExperiment(ExperimentName name) { + StopExperimentRequest request = + StopExperimentRequest.newBuilder().setName(name == null ? null : name.toString()).build(); + return stopExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + * @param name Required. Resource name of the experiment to stop. Format: `projects/<Project + * ID>/locations/<Location ID>/agents/<Agent ID>/environments/<Environment + * ID>/experiments/<Experiment ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final Experiment stopExperiment(String name) { + StopExperimentRequest request = StopExperimentRequest.newBuilder().setName(name).build(); + return stopExperiment(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + * @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 Experiment stopExperiment(StopExperimentRequest request) { + return stopExperimentCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only + * changes the state of experiment from RUNNING to DONE. + * + *

Sample code: + */ + public final UnaryCallable stopExperimentCallable() { + return stub.stopExperimentCallable(); + } + + @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 ListExperimentsPagedResponse + extends AbstractPagedListResponse< + ListExperimentsRequest, + ListExperimentsResponse, + Experiment, + ListExperimentsPage, + ListExperimentsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListExperimentsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListExperimentsPagedResponse apply(ListExperimentsPage input) { + return new ListExperimentsPagedResponse(input); + } + }, + MoreExecutors.directExecutor()); + } + + private ListExperimentsPagedResponse(ListExperimentsPage page) { + super(page, ListExperimentsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListExperimentsPage + extends AbstractPage< + ListExperimentsRequest, ListExperimentsResponse, Experiment, ListExperimentsPage> { + + private ListExperimentsPage( + PageContext context, + ListExperimentsResponse response) { + super(context, response); + } + + private static ListExperimentsPage createEmptyPage() { + return new ListExperimentsPage(null, null); + } + + @Override + protected ListExperimentsPage createPage( + PageContext context, + ListExperimentsResponse response) { + return new ListExperimentsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListExperimentsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListExperimentsRequest, + ListExperimentsResponse, + Experiment, + ListExperimentsPage, + ListExperimentsFixedSizeCollection> { + + private ListExperimentsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListExperimentsFixedSizeCollection createEmptyCollection() { + return new ListExperimentsFixedSizeCollection(null, 0); + } + + @Override + protected ListExperimentsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListExperimentsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsSettings.java new file mode 100644 index 000000000..3ec11eabb --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsSettings.java @@ -0,0 +1,251 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import static com.google.cloud.dialogflow.cx.v3beta1.ExperimentsClient.ListExperimentsPagedResponse; + +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.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +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.dialogflow.cx.v3beta1.stub.ExperimentsStubSettings; +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 ExperimentsClient}. + * + *

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

    + *
  • The default service address (dialogflow.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 total timeout of getExperiment to 30 seconds: + * + *

{@code
+ * ExperimentsSettings.Builder experimentsSettingsBuilder = ExperimentsSettings.newBuilder();
+ * experimentsSettingsBuilder
+ *     .getExperimentSettings()
+ *     .setRetrySettings(
+ *         experimentsSettingsBuilder
+ *             .getExperimentSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * ExperimentsSettings experimentsSettings = experimentsSettingsBuilder.build();
+ * }
+ */ +@BetaApi +@Generated("by gapic-generator-java") +public class ExperimentsSettings extends ClientSettings { + + /** Returns the object with the settings used for calls to listExperiments. */ + public PagedCallSettings< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return ((ExperimentsStubSettings) getStubSettings()).listExperimentsSettings(); + } + + /** Returns the object with the settings used for calls to getExperiment. */ + public UnaryCallSettings getExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).getExperimentSettings(); + } + + /** Returns the object with the settings used for calls to createExperiment. */ + public UnaryCallSettings createExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).createExperimentSettings(); + } + + /** Returns the object with the settings used for calls to updateExperiment. */ + public UnaryCallSettings updateExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).updateExperimentSettings(); + } + + /** Returns the object with the settings used for calls to deleteExperiment. */ + public UnaryCallSettings deleteExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).deleteExperimentSettings(); + } + + /** Returns the object with the settings used for calls to startExperiment. */ + public UnaryCallSettings startExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).startExperimentSettings(); + } + + /** Returns the object with the settings used for calls to stopExperiment. */ + public UnaryCallSettings stopExperimentSettings() { + return ((ExperimentsStubSettings) getStubSettings()).stopExperimentSettings(); + } + + public static final ExperimentsSettings create(ExperimentsStubSettings stub) throws IOException { + return new ExperimentsSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return ExperimentsStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return ExperimentsStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return ExperimentsStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return ExperimentsStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return ExperimentsStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return ExperimentsStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ExperimentsStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(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 ExperimentsSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for ExperimentsSettings. */ + public static class Builder extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(ExperimentsStubSettings.newBuilder(clientContext)); + } + + protected Builder(ExperimentsSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(ExperimentsStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(ExperimentsStubSettings.newBuilder()); + } + + public ExperimentsStubSettings.Builder getStubSettingsBuilder() { + return ((ExperimentsStubSettings.Builder) getStubSettings()); + } + + // NEXT_MAJOR_VER: remove 'throws Exception'. + /** + * 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) throws Exception { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to listExperiments. */ + public PagedCallSettings.Builder< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return getStubSettingsBuilder().listExperimentsSettings(); + } + + /** Returns the builder for the settings used for calls to getExperiment. */ + public UnaryCallSettings.Builder getExperimentSettings() { + return getStubSettingsBuilder().getExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to createExperiment. */ + public UnaryCallSettings.Builder + createExperimentSettings() { + return getStubSettingsBuilder().createExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to updateExperiment. */ + public UnaryCallSettings.Builder + updateExperimentSettings() { + return getStubSettingsBuilder().updateExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to deleteExperiment. */ + public UnaryCallSettings.Builder deleteExperimentSettings() { + return getStubSettingsBuilder().deleteExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to startExperiment. */ + public UnaryCallSettings.Builder startExperimentSettings() { + return getStubSettingsBuilder().startExperimentSettings(); + } + + /** Returns the builder for the settings used for calls to stopExperiment. */ + public UnaryCallSettings.Builder stopExperimentSettings() { + return getStubSettingsBuilder().stopExperimentSettings(); + } + + @Override + public ExperimentsSettings build() throws IOException { + return new ExperimentsSettings(this); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsClient.java index 23117a2a8..92c81e57f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsClient.java @@ -94,7 +94,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class FlowsClient implements BackgroundResource { private final FlowsSettings settings; private final FlowsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsSettings.java index 7b95a7b2d..95c94f84e 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsSettings.java @@ -69,6 +69,7 @@ * FlowsSettings flowsSettings = flowsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class FlowsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsClient.java index 261ffdf6c..970168839 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsClient.java @@ -89,7 +89,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class IntentsClient implements BackgroundResource { private final IntentsSettings settings; private final IntentsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsSettings.java index f70eecefe..b6364eca0 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsSettings.java @@ -66,6 +66,7 @@ * IntentsSettings intentsSettings = intentsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class IntentsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesClient.java index 246ba5ed5..1df4b8cff 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesClient.java @@ -89,7 +89,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class PagesClient implements BackgroundResource { private final PagesSettings settings; private final PagesStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesSettings.java index e5ea3dd6b..905331136 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesSettings.java @@ -66,6 +66,7 @@ * PagesSettings pagesSettings = pagesSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class PagesSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClient.java new file mode 100644 index 000000000..191194e1e --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClient.java @@ -0,0 +1,552 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import com.google.api.core.ApiFunction; +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.paging.AbstractFixedSizeCollection; +import com.google.api.gax.paging.AbstractPage; +import com.google.api.gax.paging.AbstractPagedListResponse; +import com.google.api.gax.rpc.PageContext; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3beta1.stub.SecuritySettingsServiceStub; +import com.google.cloud.dialogflow.cx.v3beta1.stub.SecuritySettingsServiceStubSettings; +import com.google.common.util.concurrent.MoreExecutors; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import java.io.IOException; +import java.util.List; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Service Description: Service for managing security settings for Dialogflow. + * + *

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: + * + *

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

The surface of this class includes several types of Java methods for each of the API's + * methods: + * + *

    + *
  1. A "flattened" method. With this type of method, the fields of the request type have been + * converted into function parameters. It may be the case that not all fields are available as + * parameters, and not every API method will have a flattened method entry point. + *
  2. A "request object" method. This type of method only takes one parameter, a request object, + * which must be constructed before the call. Not every API method will have a request object + * method. + *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API + * callable object, which can be used to initiate calls to the service. + *
+ * + *

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

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

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

To customize credentials: + * + *

{@code
+ * SecuritySettingsServiceSettings securitySettingsServiceSettings =
+ *     SecuritySettingsServiceSettings.newBuilder()
+ *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
+ *         .build();
+ * SecuritySettingsServiceClient securitySettingsServiceClient =
+ *     SecuritySettingsServiceClient.create(securitySettingsServiceSettings);
+ * }
+ * + *

To customize the endpoint: + * + *

{@code
+ * SecuritySettingsServiceSettings securitySettingsServiceSettings =
+ *     SecuritySettingsServiceSettings.newBuilder().setEndpoint(myEndpoint).build();
+ * SecuritySettingsServiceClient securitySettingsServiceClient =
+ *     SecuritySettingsServiceClient.create(securitySettingsServiceSettings);
+ * }
+ * + *

Please refer to the GitHub repository's samples for more quickstart code snippets. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class SecuritySettingsServiceClient implements BackgroundResource { + private final SecuritySettingsServiceSettings settings; + private final SecuritySettingsServiceStub stub; + + /** Constructs an instance of SecuritySettingsServiceClient with default settings. */ + public static final SecuritySettingsServiceClient create() throws IOException { + return create(SecuritySettingsServiceSettings.newBuilder().build()); + } + + /** + * Constructs an instance of SecuritySettingsServiceClient, 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 SecuritySettingsServiceClient create(SecuritySettingsServiceSettings settings) + throws IOException { + return new SecuritySettingsServiceClient(settings); + } + + /** + * Constructs an instance of SecuritySettingsServiceClient, using the given stub for making calls. + * This is for advanced usage - prefer using create(SecuritySettingsServiceSettings). + */ + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public static final SecuritySettingsServiceClient create(SecuritySettingsServiceStub stub) { + return new SecuritySettingsServiceClient(stub); + } + + /** + * Constructs an instance of SecuritySettingsServiceClient, 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 SecuritySettingsServiceClient(SecuritySettingsServiceSettings settings) + throws IOException { + this.settings = settings; + this.stub = ((SecuritySettingsServiceStubSettings) settings.getStubSettings()).createStub(); + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + protected SecuritySettingsServiceClient(SecuritySettingsServiceStub stub) { + this.settings = null; + this.stub = stub; + } + + public final SecuritySettingsServiceSettings getSettings() { + return settings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public SecuritySettingsServiceStub getStub() { + return stub; + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create security settings in the specified location. + * + * @param parent Required. The location to create an + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for. Format: + * `projects/<Project ID>/locations/<Location ID>`. + * @param securitySettings Required. The security settings to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SecuritySettings createSecuritySettings( + LocationName parent, SecuritySettings securitySettings) { + CreateSecuritySettingsRequest request = + CreateSecuritySettingsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .setSecuritySettings(securitySettings) + .build(); + return createSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create security settings in the specified location. + * + * @param parent Required. The location to create an + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for. Format: + * `projects/<Project ID>/locations/<Location ID>`. + * @param securitySettings Required. The security settings to create. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SecuritySettings createSecuritySettings( + String parent, SecuritySettings securitySettings) { + CreateSecuritySettingsRequest request = + CreateSecuritySettingsRequest.newBuilder() + .setParent(parent) + .setSecuritySettings(securitySettings) + .build(); + return createSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create security settings in the specified location. + * + * @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 SecuritySettings createSecuritySettings(CreateSecuritySettingsRequest request) { + return createSecuritySettingsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Create security settings in the specified location. + * + *

Sample code: + */ + public final UnaryCallable + createSecuritySettingsCallable() { + return stub.createSecuritySettingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. The returned settings + * may be stale by up to 1 minute. + * + * @param name Required. Resource name of the settings. Format: `projects/<Project + * ID>/locations/<Location ID>/securitySettings/<security settings ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SecuritySettings getSecuritySettings(SecuritySettingsName name) { + GetSecuritySettingsRequest request = + GetSecuritySettingsRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + return getSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. The returned settings + * may be stale by up to 1 minute. + * + * @param name Required. Resource name of the settings. Format: `projects/<Project + * ID>/locations/<Location ID>/securitySettings/<security settings ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SecuritySettings getSecuritySettings(String name) { + GetSecuritySettingsRequest request = + GetSecuritySettingsRequest.newBuilder().setName(name).build(); + return getSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. The returned settings + * may be stale by up to 1 minute. + * + * @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 SecuritySettings getSecuritySettings(GetSecuritySettingsRequest request) { + return getSecuritySettingsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Retrieves the specified + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. The returned settings + * may be stale by up to 1 minute. + * + *

Sample code: + */ + public final UnaryCallable + getSecuritySettingsCallable() { + return stub.getSecuritySettingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + * @param securitySettings Required. [SecuritySettings] object that contains values for each of + * the fields to update. + * @param updateMask Required. The mask to control which fields get updated. If the mask is not + * present, all fields will be updated. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final SecuritySettings updateSecuritySettings( + SecuritySettings securitySettings, FieldMask updateMask) { + UpdateSecuritySettingsRequest request = + UpdateSecuritySettingsRequest.newBuilder() + .setSecuritySettings(securitySettings) + .setUpdateMask(updateMask) + .build(); + return updateSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + * @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 SecuritySettings updateSecuritySettings(UpdateSecuritySettingsRequest request) { + return updateSecuritySettingsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + *

Sample code: + */ + public final UnaryCallable + updateSecuritySettingsCallable() { + return stub.updateSecuritySettingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all security settings in the specified location. + * + * @param parent Required. The location to list all security settings for. Format: + * `projects/<Project ID>/locations/<Location ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListSecuritySettingsPagedResponse listSecuritySettings(LocationName parent) { + ListSecuritySettingsRequest request = + ListSecuritySettingsRequest.newBuilder() + .setParent(parent == null ? null : parent.toString()) + .build(); + return listSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all security settings in the specified location. + * + * @param parent Required. The location to list all security settings for. Format: + * `projects/<Project ID>/locations/<Location ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final ListSecuritySettingsPagedResponse listSecuritySettings(String parent) { + ListSecuritySettingsRequest request = + ListSecuritySettingsRequest.newBuilder().setParent(parent).build(); + return listSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all security settings in the specified location. + * + * @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 ListSecuritySettingsPagedResponse listSecuritySettings( + ListSecuritySettingsRequest request) { + return listSecuritySettingsPagedCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all security settings in the specified location. + * + *

Sample code: + */ + public final UnaryCallable + listSecuritySettingsPagedCallable() { + return stub.listSecuritySettingsPagedCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Returns the list of all security settings in the specified location. + * + *

Sample code: + */ + public final UnaryCallable + listSecuritySettingsCallable() { + return stub.listSecuritySettingsCallable(); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + * @param name Required. The name of the + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete. Format: + * `projects/<Project ID>/locations/<Location ID>/securitySettings/<Security + * Settings ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteSecuritySettings(SecuritySettingsName name) { + DeleteSecuritySettingsRequest request = + DeleteSecuritySettingsRequest.newBuilder() + .setName(name == null ? null : name.toString()) + .build(); + deleteSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + * @param name Required. The name of the + * [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete. Format: + * `projects/<Project ID>/locations/<Location ID>/securitySettings/<Security + * Settings ID>`. + * @throws com.google.api.gax.rpc.ApiException if the remote call fails + */ + public final void deleteSecuritySettings(String name) { + DeleteSecuritySettingsRequest request = + DeleteSecuritySettingsRequest.newBuilder().setName(name).build(); + deleteSecuritySettings(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + * @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 deleteSecuritySettings(DeleteSecuritySettingsRequest request) { + deleteSecuritySettingsCallable().call(request); + } + + // AUTO-GENERATED DOCUMENTATION AND METHOD. + /** + * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + * + *

Sample code: + */ + public final UnaryCallable + deleteSecuritySettingsCallable() { + return stub.deleteSecuritySettingsCallable(); + } + + @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 ListSecuritySettingsPagedResponse + extends AbstractPagedListResponse< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + SecuritySettings, + ListSecuritySettingsPage, + ListSecuritySettingsFixedSizeCollection> { + + public static ApiFuture createAsync( + PageContext + context, + ApiFuture futureResponse) { + ApiFuture futurePage = + ListSecuritySettingsPage.createEmptyPage().createPageAsync(context, futureResponse); + return ApiFutures.transform( + futurePage, + new ApiFunction() { + @Override + public ListSecuritySettingsPagedResponse apply(ListSecuritySettingsPage input) { + return new ListSecuritySettingsPagedResponse(input); + } + }, + MoreExecutors.directExecutor()); + } + + private ListSecuritySettingsPagedResponse(ListSecuritySettingsPage page) { + super(page, ListSecuritySettingsFixedSizeCollection.createEmptyCollection()); + } + } + + public static class ListSecuritySettingsPage + extends AbstractPage< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + SecuritySettings, + ListSecuritySettingsPage> { + + private ListSecuritySettingsPage( + PageContext + context, + ListSecuritySettingsResponse response) { + super(context, response); + } + + private static ListSecuritySettingsPage createEmptyPage() { + return new ListSecuritySettingsPage(null, null); + } + + @Override + protected ListSecuritySettingsPage createPage( + PageContext + context, + ListSecuritySettingsResponse response) { + return new ListSecuritySettingsPage(context, response); + } + + @Override + public ApiFuture createPageAsync( + PageContext + context, + ApiFuture futureResponse) { + return super.createPageAsync(context, futureResponse); + } + } + + public static class ListSecuritySettingsFixedSizeCollection + extends AbstractFixedSizeCollection< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + SecuritySettings, + ListSecuritySettingsPage, + ListSecuritySettingsFixedSizeCollection> { + + private ListSecuritySettingsFixedSizeCollection( + List pages, int collectionSize) { + super(pages, collectionSize); + } + + private static ListSecuritySettingsFixedSizeCollection createEmptyCollection() { + return new ListSecuritySettingsFixedSizeCollection(null, 0); + } + + @Override + protected ListSecuritySettingsFixedSizeCollection createCollection( + List pages, int collectionSize) { + return new ListSecuritySettingsFixedSizeCollection(pages, collectionSize); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceSettings.java new file mode 100644 index 000000000..d6925c0d9 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceSettings.java @@ -0,0 +1,248 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsServiceClient.ListSecuritySettingsPagedResponse; + +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.rpc.ApiClientHeaderProvider; +import com.google.api.gax.rpc.ClientContext; +import com.google.api.gax.rpc.ClientSettings; +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.dialogflow.cx.v3beta1.stub.SecuritySettingsServiceStubSettings; +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 SecuritySettingsServiceClient}. + * + *

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

    + *
  • The default service address (dialogflow.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 total timeout of createSecuritySettings to 30 seconds: + * + *

{@code
+ * SecuritySettingsServiceSettings.Builder securitySettingsServiceSettingsBuilder =
+ *     SecuritySettingsServiceSettings.newBuilder();
+ * securitySettingsServiceSettingsBuilder
+ *     .createSecuritySettingsSettings()
+ *     .setRetrySettings(
+ *         securitySettingsServiceSettingsBuilder
+ *             .createSecuritySettingsSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * SecuritySettingsServiceSettings securitySettingsServiceSettings =
+ *     securitySettingsServiceSettingsBuilder.build();
+ * }
+ */ +@BetaApi +@Generated("by gapic-generator-java") +public class SecuritySettingsServiceSettings + extends ClientSettings { + + /** Returns the object with the settings used for calls to createSecuritySettings. */ + public UnaryCallSettings + createSecuritySettingsSettings() { + return ((SecuritySettingsServiceStubSettings) getStubSettings()) + .createSecuritySettingsSettings(); + } + + /** Returns the object with the settings used for calls to getSecuritySettings. */ + public UnaryCallSettings + getSecuritySettingsSettings() { + return ((SecuritySettingsServiceStubSettings) getStubSettings()).getSecuritySettingsSettings(); + } + + /** Returns the object with the settings used for calls to updateSecuritySettings. */ + public UnaryCallSettings + updateSecuritySettingsSettings() { + return ((SecuritySettingsServiceStubSettings) getStubSettings()) + .updateSecuritySettingsSettings(); + } + + /** Returns the object with the settings used for calls to listSecuritySettings. */ + public PagedCallSettings< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + listSecuritySettingsSettings() { + return ((SecuritySettingsServiceStubSettings) getStubSettings()).listSecuritySettingsSettings(); + } + + /** Returns the object with the settings used for calls to deleteSecuritySettings. */ + public UnaryCallSettings deleteSecuritySettingsSettings() { + return ((SecuritySettingsServiceStubSettings) getStubSettings()) + .deleteSecuritySettingsSettings(); + } + + public static final SecuritySettingsServiceSettings create( + SecuritySettingsServiceStubSettings stub) throws IOException { + return new SecuritySettingsServiceSettings.Builder(stub.toBuilder()).build(); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return SecuritySettingsServiceStubSettings.defaultExecutorProviderBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return SecuritySettingsServiceStubSettings.getDefaultEndpoint(); + } + + /** Returns the default service scopes. */ + public static List getDefaultServiceScopes() { + return SecuritySettingsServiceStubSettings.getDefaultServiceScopes(); + } + + /** Returns a builder for the default credentials for this service. */ + public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { + return SecuritySettingsServiceStubSettings.defaultCredentialsProviderBuilder(); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return SecuritySettingsServiceStubSettings.defaultGrpcTransportProviderBuilder(); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return SecuritySettingsServiceStubSettings.defaultTransportChannelProvider(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return SecuritySettingsServiceStubSettings.defaultApiClientHeaderProviderBuilder(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(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 SecuritySettingsServiceSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + } + + /** Builder for SecuritySettingsServiceSettings. */ + public static class Builder + extends ClientSettings.Builder { + + protected Builder() throws IOException { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(SecuritySettingsServiceStubSettings.newBuilder(clientContext)); + } + + protected Builder(SecuritySettingsServiceSettings settings) { + super(settings.getStubSettings().toBuilder()); + } + + protected Builder(SecuritySettingsServiceStubSettings.Builder stubSettings) { + super(stubSettings); + } + + private static Builder createDefault() { + return new Builder(SecuritySettingsServiceStubSettings.newBuilder()); + } + + public SecuritySettingsServiceStubSettings.Builder getStubSettingsBuilder() { + return ((SecuritySettingsServiceStubSettings.Builder) getStubSettings()); + } + + // NEXT_MAJOR_VER: remove 'throws Exception'. + /** + * 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) throws Exception { + super.applyToAllUnaryMethods( + getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); + return this; + } + + /** Returns the builder for the settings used for calls to createSecuritySettings. */ + public UnaryCallSettings.Builder + createSecuritySettingsSettings() { + return getStubSettingsBuilder().createSecuritySettingsSettings(); + } + + /** Returns the builder for the settings used for calls to getSecuritySettings. */ + public UnaryCallSettings.Builder + getSecuritySettingsSettings() { + return getStubSettingsBuilder().getSecuritySettingsSettings(); + } + + /** Returns the builder for the settings used for calls to updateSecuritySettings. */ + public UnaryCallSettings.Builder + updateSecuritySettingsSettings() { + return getStubSettingsBuilder().updateSecuritySettingsSettings(); + } + + /** Returns the builder for the settings used for calls to listSecuritySettings. */ + public PagedCallSettings.Builder< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + listSecuritySettingsSettings() { + return getStubSettingsBuilder().listSecuritySettingsSettings(); + } + + /** Returns the builder for the settings used for calls to deleteSecuritySettings. */ + public UnaryCallSettings.Builder + deleteSecuritySettingsSettings() { + return getStubSettingsBuilder().deleteSecuritySettingsSettings(); + } + + @Override + public SecuritySettingsServiceSettings build() throws IOException { + return new SecuritySettingsServiceSettings(this); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesClient.java index a031cbe21..333a0f081 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesClient.java @@ -94,7 +94,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class SessionEntityTypesClient implements BackgroundResource { private final SessionEntityTypesSettings settings; private final SessionEntityTypesStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesSettings.java index 901eb8107..e3c6d7879 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesSettings.java @@ -68,6 +68,7 @@ * sessionEntityTypesSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class SessionEntityTypesSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsClient.java index 9c58e1f25..d718c19bd 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsClient.java @@ -82,7 +82,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class SessionsClient implements BackgroundResource { private final SessionsSettings settings; private final SessionsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsSettings.java index c8eaf4bc3..119b7bc13 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsSettings.java @@ -63,6 +63,7 @@ * SessionsSettings sessionsSettings = sessionsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class SessionsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsClient.java index 9d99d6894..42655795f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsClient.java @@ -94,7 +94,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class TransitionRouteGroupsClient implements BackgroundResource { private final TransitionRouteGroupsSettings settings; private final TransitionRouteGroupsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsSettings.java index 826026d28..7f5674e67 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsSettings.java @@ -68,6 +68,7 @@ * transitionRouteGroupsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class TransitionRouteGroupsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsClient.java index 6446f5708..6c67a3d86 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsClient.java @@ -95,7 +95,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class VersionsClient implements BackgroundResource { private final VersionsSettings settings; private final VersionsStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsSettings.java index f5c6b5e33..8851a5aec 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionsSettings.java @@ -69,6 +69,7 @@ * VersionsSettings versionsSettings = versionsSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class VersionsSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksClient.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksClient.java index b0a44e5d7..226be5b0a 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksClient.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksClient.java @@ -90,7 +90,7 @@ *

Please refer to the GitHub repository's samples for more quickstart code snippets. */ @BetaApi -@Generated("by gapic-generator") +@Generated("by gapic-generator-java") public class WebhooksClient implements BackgroundResource { private final WebhooksSettings settings; private final WebhooksStub stub; diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksSettings.java index adeba06d0..14441883e 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksSettings.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/WebhooksSettings.java @@ -66,6 +66,7 @@ * WebhooksSettings webhooksSettings = webhooksSettingsBuilder.build(); * } */ +@BetaApi @Generated("by gapic-generator-java") public class WebhooksSettings extends ClientSettings { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/package-info.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/package-info.java index c91a900f2..7e0513beb 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/package-info.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/package-info.java @@ -37,6 +37,13 @@ * *

Sample for EnvironmentsClient: * + *

======================= ExperimentsClient ======================= + * + *

Service Description: Service for managing + * [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment]. + * + *

Sample for ExperimentsClient: + * *

======================= FlowsClient ======================= * *

Service Description: Service for managing [Flows][google.cloud.dialogflow.cx.v3beta1.Flow]. @@ -56,6 +63,12 @@ * *

Sample for PagesClient: * + *

======================= SecuritySettingsServiceClient ======================= + * + *

Service Description: Service for managing security settings for Dialogflow. + * + *

Sample for SecuritySettingsServiceClient: + * *

======================= SessionsClient ======================= * *

Service Description: A session represents an interaction with a user. You retrieve user input diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/AgentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/AgentsStub.java index 371879a85..db8548f4d 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/AgentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/AgentsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.AgentsClient.ListAgentsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; @@ -43,7 +44,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class AgentsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EntityTypesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EntityTypesStub.java index 54cabdc2f..09c7b1677 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EntityTypesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EntityTypesStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.EntityTypesClient.ListEntityTypesPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.dialogflow.cx.v3beta1.CreateEntityTypeRequest; @@ -36,7 +37,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class EntityTypesStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EnvironmentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EnvironmentsStub.java index 5e12d39aa..ef51f8dbe 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EnvironmentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EnvironmentsStub.java @@ -19,6 +19,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.EnvironmentsClient.ListEnvironmentsPagedResponse; import static com.google.cloud.dialogflow.cx.v3beta1.EnvironmentsClient.LookupEnvironmentHistoryPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; @@ -43,7 +44,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class EnvironmentsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStub.java new file mode 100644 index 000000000..ccc91afae --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStub.java @@ -0,0 +1,81 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import static com.google.cloud.dialogflow.cx.v3beta1.ExperimentsClient.ListExperimentsPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.Experiment; +import com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse; +import com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest; +import com.google.protobuf.Empty; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the Experiments service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@BetaApi +@Generated("by gapic-generator-java") +public abstract class ExperimentsStub implements BackgroundResource { + + public UnaryCallable + listExperimentsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listExperimentsPagedCallable()"); + } + + public UnaryCallable listExperimentsCallable() { + throw new UnsupportedOperationException("Not implemented: listExperimentsCallable()"); + } + + public UnaryCallable getExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: getExperimentCallable()"); + } + + public UnaryCallable createExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: createExperimentCallable()"); + } + + public UnaryCallable updateExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: updateExperimentCallable()"); + } + + public UnaryCallable deleteExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: deleteExperimentCallable()"); + } + + public UnaryCallable startExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: startExperimentCallable()"); + } + + public UnaryCallable stopExperimentCallable() { + throw new UnsupportedOperationException("Not implemented: stopExperimentCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStubSettings.java new file mode 100644 index 000000000..6d2948799 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStubSettings.java @@ -0,0 +1,492 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import static com.google.cloud.dialogflow.cx.v3beta1.ExperimentsClient.ListExperimentsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +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.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.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.dialogflow.cx.v3beta1.CreateExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.Experiment; +import com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse; +import com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest; +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.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link ExperimentsStub}. + * + *

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

    + *
  • The default service address (dialogflow.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 total timeout of getExperiment to 30 seconds: + * + *

{@code
+ * ExperimentsStubSettings.Builder experimentsSettingsBuilder =
+ *     ExperimentsStubSettings.newBuilder();
+ * experimentsSettingsBuilder
+ *     .getExperimentSettings()
+ *     .setRetrySettings(
+ *         experimentsSettingsBuilder
+ *             .getExperimentSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * ExperimentsStubSettings experimentsSettings = experimentsSettingsBuilder.build();
+ * }
+ */ +@BetaApi +@Generated("by gapic-generator-java") +public class ExperimentsStubSettings 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") + .add("https://www.googleapis.com/auth/dialogflow") + .build(); + + private final PagedCallSettings< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings; + private final UnaryCallSettings getExperimentSettings; + private final UnaryCallSettings createExperimentSettings; + private final UnaryCallSettings updateExperimentSettings; + private final UnaryCallSettings deleteExperimentSettings; + private final UnaryCallSettings startExperimentSettings; + private final UnaryCallSettings stopExperimentSettings; + + private static final PagedListDescriptor< + ListExperimentsRequest, ListExperimentsResponse, Experiment> + LIST_EXPERIMENTS_PAGE_STR_DESC = + new PagedListDescriptor() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListExperimentsRequest injectToken( + ListExperimentsRequest payload, String token) { + return ListExperimentsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListExperimentsRequest injectPageSize( + ListExperimentsRequest payload, int pageSize) { + return ListExperimentsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListExperimentsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListExperimentsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources(ListExperimentsResponse payload) { + return payload.getExperimentsList() == null + ? ImmutableList.of() + : payload.getExperimentsList(); + } + }; + + private static final PagedListResponseFactory< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + LIST_EXPERIMENTS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListExperimentsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext pageContext = + PageContext.create(callable, LIST_EXPERIMENTS_PAGE_STR_DESC, request, context); + return ListExperimentsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to listExperiments. */ + public PagedCallSettings< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return listExperimentsSettings; + } + + /** Returns the object with the settings used for calls to getExperiment. */ + public UnaryCallSettings getExperimentSettings() { + return getExperimentSettings; + } + + /** Returns the object with the settings used for calls to createExperiment. */ + public UnaryCallSettings createExperimentSettings() { + return createExperimentSettings; + } + + /** Returns the object with the settings used for calls to updateExperiment. */ + public UnaryCallSettings updateExperimentSettings() { + return updateExperimentSettings; + } + + /** Returns the object with the settings used for calls to deleteExperiment. */ + public UnaryCallSettings deleteExperimentSettings() { + return deleteExperimentSettings; + } + + /** Returns the object with the settings used for calls to startExperiment. */ + public UnaryCallSettings startExperimentSettings() { + return startExperimentSettings; + } + + /** Returns the object with the settings used for calls to stopExperiment. */ + public UnaryCallSettings stopExperimentSettings() { + return stopExperimentSettings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public ExperimentsStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcExperimentsStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "dialogflow.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); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(ExperimentsStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(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 ExperimentsStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + listExperimentsSettings = settingsBuilder.listExperimentsSettings().build(); + getExperimentSettings = settingsBuilder.getExperimentSettings().build(); + createExperimentSettings = settingsBuilder.createExperimentSettings().build(); + updateExperimentSettings = settingsBuilder.updateExperimentSettings().build(); + deleteExperimentSettings = settingsBuilder.deleteExperimentSettings().build(); + startExperimentSettings = settingsBuilder.startExperimentSettings().build(); + stopExperimentSettings = settingsBuilder.stopExperimentSettings().build(); + } + + /** Builder for ExperimentsStubSettings. */ + public static class Builder extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final PagedCallSettings.Builder< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings; + private final UnaryCallSettings.Builder getExperimentSettings; + private final UnaryCallSettings.Builder + createExperimentSettings; + private final UnaryCallSettings.Builder + updateExperimentSettings; + private final UnaryCallSettings.Builder + deleteExperimentSettings; + private final UnaryCallSettings.Builder + startExperimentSettings; + private final UnaryCallSettings.Builder + stopExperimentSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "retry_policy_0_codes", + ImmutableSet.copyOf(Lists.newArrayList(StatusCode.Code.UNAVAILABLE))); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(100L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelay(Duration.ofMillis(60000L)) + .setInitialRpcTimeout(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(60000L)) + .setTotalTimeout(Duration.ofMillis(60000L)) + .build(); + definitions.put("retry_policy_0_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + listExperimentsSettings = PagedCallSettings.newBuilder(LIST_EXPERIMENTS_PAGE_STR_FACT); + getExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + createExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + deleteExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + startExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + stopExperimentSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + listExperimentsSettings, + getExperimentSettings, + createExperimentSettings, + updateExperimentSettings, + deleteExperimentSettings, + startExperimentSettings, + stopExperimentSettings); + initDefaults(this); + } + + protected Builder(ExperimentsStubSettings settings) { + super(settings); + + listExperimentsSettings = settings.listExperimentsSettings.toBuilder(); + getExperimentSettings = settings.getExperimentSettings.toBuilder(); + createExperimentSettings = settings.createExperimentSettings.toBuilder(); + updateExperimentSettings = settings.updateExperimentSettings.toBuilder(); + deleteExperimentSettings = settings.deleteExperimentSettings.toBuilder(); + startExperimentSettings = settings.startExperimentSettings.toBuilder(); + stopExperimentSettings = settings.stopExperimentSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + listExperimentsSettings, + getExperimentSettings, + createExperimentSettings, + updateExperimentSettings, + deleteExperimentSettings, + startExperimentSettings, + stopExperimentSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .listExperimentsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .createExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .deleteExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .startExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .stopExperimentSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + return builder; + } + + // NEXT_MAJOR_VER: remove 'throws Exception'. + /** + * 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) throws Exception { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to listExperiments. */ + public PagedCallSettings.Builder< + ListExperimentsRequest, ListExperimentsResponse, ListExperimentsPagedResponse> + listExperimentsSettings() { + return listExperimentsSettings; + } + + /** Returns the builder for the settings used for calls to getExperiment. */ + public UnaryCallSettings.Builder getExperimentSettings() { + return getExperimentSettings; + } + + /** Returns the builder for the settings used for calls to createExperiment. */ + public UnaryCallSettings.Builder + createExperimentSettings() { + return createExperimentSettings; + } + + /** Returns the builder for the settings used for calls to updateExperiment. */ + public UnaryCallSettings.Builder + updateExperimentSettings() { + return updateExperimentSettings; + } + + /** Returns the builder for the settings used for calls to deleteExperiment. */ + public UnaryCallSettings.Builder deleteExperimentSettings() { + return deleteExperimentSettings; + } + + /** Returns the builder for the settings used for calls to startExperiment. */ + public UnaryCallSettings.Builder startExperimentSettings() { + return startExperimentSettings; + } + + /** Returns the builder for the settings used for calls to stopExperiment. */ + public UnaryCallSettings.Builder stopExperimentSettings() { + return stopExperimentSettings; + } + + @Override + public ExperimentsStubSettings build() throws IOException { + return new ExperimentsStubSettings(this); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/FlowsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/FlowsStub.java index 9669af249..654e22dcd 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/FlowsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/FlowsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.FlowsClient.ListFlowsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; @@ -41,7 +42,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class FlowsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsCallableFactory.java index a4bd45952..ff1bb81c3 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcAgentsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsStub.java index a8afd6d19..8f83a81df 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.AgentsClient.ListAgentsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -54,6 +55,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcAgentsStub extends AgentsStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesCallableFactory.java index 3302312a0..a788c8c33 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcEntityTypesCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesStub.java index 980ecd845..0bc95fcf1 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.EntityTypesClient.ListEntityTypesPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -48,6 +49,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcEntityTypesStub extends EntityTypesStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsCallableFactory.java index b48d0203d..209b42366 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcEnvironmentsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsStub.java index f5fe09034..011052bfa 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsStub.java @@ -19,6 +19,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.EnvironmentsClient.ListEnvironmentsPagedResponse; import static com.google.cloud.dialogflow.cx.v3beta1.EnvironmentsClient.LookupEnvironmentHistoryPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -54,6 +55,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcEnvironmentsStub extends EnvironmentsStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsCallableFactory.java new file mode 100644 index 000000000..a084001bd --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsCallableFactory.java @@ -0,0 +1,115 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import com.google.api.core.BetaApi; +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 Experiments service API. + * + *

This class is for advanced usage. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class GrpcExperimentsCallableFactory 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/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsStub.java new file mode 100644 index 000000000..193b77840 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsStub.java @@ -0,0 +1,370 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import static com.google.cloud.dialogflow.cx.v3beta1.ExperimentsClient.ListExperimentsPagedResponse; + +import com.google.api.core.BetaApi; +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.RequestParamsExtractor; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.Experiment; +import com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse; +import com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest; +import com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest; +import com.google.common.collect.ImmutableMap; +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.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the Experiments service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class GrpcExperimentsStub extends ExperimentsStub { + private static final MethodDescriptor + listExperimentsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/ListExperiments") + .setRequestMarshaller( + ProtoUtils.marshaller(ListExperimentsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListExperimentsResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + getExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/GetExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(GetExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + createExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/CreateExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + updateExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/UpdateExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + deleteExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/DeleteExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + startExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/StartExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(StartExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + stopExperimentMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName("google.cloud.dialogflow.cx.v3beta1.Experiments/StopExperiment") + .setRequestMarshaller( + ProtoUtils.marshaller(StopExperimentRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Experiment.getDefaultInstance())) + .build(); + + private final UnaryCallable + listExperimentsCallable; + private final UnaryCallable + listExperimentsPagedCallable; + private final UnaryCallable getExperimentCallable; + private final UnaryCallable createExperimentCallable; + private final UnaryCallable updateExperimentCallable; + private final UnaryCallable deleteExperimentCallable; + private final UnaryCallable startExperimentCallable; + private final UnaryCallable stopExperimentCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcExperimentsStub create(ExperimentsStubSettings settings) + throws IOException { + return new GrpcExperimentsStub(settings, ClientContext.create(settings)); + } + + public static final GrpcExperimentsStub create(ClientContext clientContext) throws IOException { + return new GrpcExperimentsStub(ExperimentsStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcExperimentsStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcExperimentsStub( + ExperimentsStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcExperimentsStub, 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 GrpcExperimentsStub(ExperimentsStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcExperimentsCallableFactory()); + } + + /** + * Constructs an instance of GrpcExperimentsStub, 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 GrpcExperimentsStub( + ExperimentsStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings + listExperimentsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listExperimentsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListExperimentsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings getExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(GetExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings createExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(CreateExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings updateExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(UpdateExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put( + "experiment.name", String.valueOf(request.getExperiment().getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings deleteExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(DeleteExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings startExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(startExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(StartExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings stopExperimentTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(stopExperimentMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(StopExperimentRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + + this.listExperimentsCallable = + callableFactory.createUnaryCallable( + listExperimentsTransportSettings, settings.listExperimentsSettings(), clientContext); + this.listExperimentsPagedCallable = + callableFactory.createPagedCallable( + listExperimentsTransportSettings, settings.listExperimentsSettings(), clientContext); + this.getExperimentCallable = + callableFactory.createUnaryCallable( + getExperimentTransportSettings, settings.getExperimentSettings(), clientContext); + this.createExperimentCallable = + callableFactory.createUnaryCallable( + createExperimentTransportSettings, settings.createExperimentSettings(), clientContext); + this.updateExperimentCallable = + callableFactory.createUnaryCallable( + updateExperimentTransportSettings, settings.updateExperimentSettings(), clientContext); + this.deleteExperimentCallable = + callableFactory.createUnaryCallable( + deleteExperimentTransportSettings, settings.deleteExperimentSettings(), clientContext); + this.startExperimentCallable = + callableFactory.createUnaryCallable( + startExperimentTransportSettings, settings.startExperimentSettings(), clientContext); + this.stopExperimentCallable = + callableFactory.createUnaryCallable( + stopExperimentTransportSettings, settings.stopExperimentSettings(), clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + public UnaryCallable listExperimentsCallable() { + return listExperimentsCallable; + } + + public UnaryCallable + listExperimentsPagedCallable() { + return listExperimentsPagedCallable; + } + + public UnaryCallable getExperimentCallable() { + return getExperimentCallable; + } + + public UnaryCallable createExperimentCallable() { + return createExperimentCallable; + } + + public UnaryCallable updateExperimentCallable() { + return updateExperimentCallable; + } + + public UnaryCallable deleteExperimentCallable() { + return deleteExperimentCallable; + } + + public UnaryCallable startExperimentCallable() { + return startExperimentCallable; + } + + public UnaryCallable stopExperimentCallable() { + return stopExperimentCallable; + } + + @Override + public final void close() { + shutdown(); + } + + @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/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsCallableFactory.java index baa6a1bb1..bd7a213d2 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcFlowsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsStub.java index a55275c88..5787fa14f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.FlowsClient.ListFlowsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -52,6 +53,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcFlowsStub extends FlowsStub { private static final MethodDescriptor createFlowMethodDescriptor = diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsCallableFactory.java index 806346858..278b1d166 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcIntentsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsStub.java index d6c143678..6230258db 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.IntentsClient.ListIntentsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -48,6 +49,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcIntentsStub extends IntentsStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesCallableFactory.java index 3ff0e65e9..a1fff7921 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcPagesCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesStub.java index 3f3170f1a..32d1d7df5 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.PagesClient.ListPagesPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -48,6 +49,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcPagesStub extends PagesStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceCallableFactory.java new file mode 100644 index 000000000..e25091715 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceCallableFactory.java @@ -0,0 +1,115 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import com.google.api.core.BetaApi; +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 SecuritySettingsService service API. + * + *

This class is for advanced usage. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class GrpcSecuritySettingsServiceCallableFactory 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/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceStub.java new file mode 100644 index 000000000..6109ecfc2 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceStub.java @@ -0,0 +1,336 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsServiceClient.ListSecuritySettingsPagedResponse; + +import com.google.api.core.BetaApi; +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.RequestParamsExtractor; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse; +import com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings; +import com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest; +import com.google.common.collect.ImmutableMap; +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.Map; +import java.util.concurrent.TimeUnit; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * gRPC stub implementation for the SecuritySettingsService service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@BetaApi +@Generated("by gapic-generator-java") +public class GrpcSecuritySettingsServiceStub extends SecuritySettingsServiceStub { + private static final MethodDescriptor + createSecuritySettingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService/CreateSecuritySettings") + .setRequestMarshaller( + ProtoUtils.marshaller(CreateSecuritySettingsRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(SecuritySettings.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + getSecuritySettingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService/GetSecuritySettings") + .setRequestMarshaller( + ProtoUtils.marshaller(GetSecuritySettingsRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(SecuritySettings.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + updateSecuritySettingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService/UpdateSecuritySettings") + .setRequestMarshaller( + ProtoUtils.marshaller(UpdateSecuritySettingsRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(SecuritySettings.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + listSecuritySettingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService/ListSecuritySettings") + .setRequestMarshaller( + ProtoUtils.marshaller(ListSecuritySettingsRequest.getDefaultInstance())) + .setResponseMarshaller( + ProtoUtils.marshaller(ListSecuritySettingsResponse.getDefaultInstance())) + .build(); + + private static final MethodDescriptor + deleteSecuritySettingsMethodDescriptor = + MethodDescriptor.newBuilder() + .setType(MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + "google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService/DeleteSecuritySettings") + .setRequestMarshaller( + ProtoUtils.marshaller(DeleteSecuritySettingsRequest.getDefaultInstance())) + .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) + .build(); + + private final UnaryCallable + createSecuritySettingsCallable; + private final UnaryCallable + getSecuritySettingsCallable; + private final UnaryCallable + updateSecuritySettingsCallable; + private final UnaryCallable + listSecuritySettingsCallable; + private final UnaryCallable + listSecuritySettingsPagedCallable; + private final UnaryCallable deleteSecuritySettingsCallable; + + private final BackgroundResource backgroundResources; + private final GrpcOperationsStub operationsStub; + private final GrpcStubCallableFactory callableFactory; + + public static final GrpcSecuritySettingsServiceStub create( + SecuritySettingsServiceStubSettings settings) throws IOException { + return new GrpcSecuritySettingsServiceStub(settings, ClientContext.create(settings)); + } + + public static final GrpcSecuritySettingsServiceStub create(ClientContext clientContext) + throws IOException { + return new GrpcSecuritySettingsServiceStub( + SecuritySettingsServiceStubSettings.newBuilder().build(), clientContext); + } + + public static final GrpcSecuritySettingsServiceStub create( + ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { + return new GrpcSecuritySettingsServiceStub( + SecuritySettingsServiceStubSettings.newBuilder().build(), clientContext, callableFactory); + } + + /** + * Constructs an instance of GrpcSecuritySettingsServiceStub, 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 GrpcSecuritySettingsServiceStub( + SecuritySettingsServiceStubSettings settings, ClientContext clientContext) + throws IOException { + this(settings, clientContext, new GrpcSecuritySettingsServiceCallableFactory()); + } + + /** + * Constructs an instance of GrpcSecuritySettingsServiceStub, 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 GrpcSecuritySettingsServiceStub( + SecuritySettingsServiceStubSettings settings, + ClientContext clientContext, + GrpcStubCallableFactory callableFactory) + throws IOException { + this.callableFactory = callableFactory; + this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); + + GrpcCallSettings + createSecuritySettingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(createSecuritySettingsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(CreateSecuritySettingsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + getSecuritySettingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(getSecuritySettingsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(GetSecuritySettingsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + updateSecuritySettingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(updateSecuritySettingsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(UpdateSecuritySettingsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put( + "security_settings.name", + String.valueOf(request.getSecuritySettings().getName())); + return params.build(); + } + }) + .build(); + GrpcCallSettings + listSecuritySettingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(listSecuritySettingsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(ListSecuritySettingsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("parent", String.valueOf(request.getParent())); + return params.build(); + } + }) + .build(); + GrpcCallSettings deleteSecuritySettingsTransportSettings = + GrpcCallSettings.newBuilder() + .setMethodDescriptor(deleteSecuritySettingsMethodDescriptor) + .setParamsExtractor( + new RequestParamsExtractor() { + @Override + public Map extract(DeleteSecuritySettingsRequest request) { + ImmutableMap.Builder params = ImmutableMap.builder(); + params.put("name", String.valueOf(request.getName())); + return params.build(); + } + }) + .build(); + + this.createSecuritySettingsCallable = + callableFactory.createUnaryCallable( + createSecuritySettingsTransportSettings, + settings.createSecuritySettingsSettings(), + clientContext); + this.getSecuritySettingsCallable = + callableFactory.createUnaryCallable( + getSecuritySettingsTransportSettings, + settings.getSecuritySettingsSettings(), + clientContext); + this.updateSecuritySettingsCallable = + callableFactory.createUnaryCallable( + updateSecuritySettingsTransportSettings, + settings.updateSecuritySettingsSettings(), + clientContext); + this.listSecuritySettingsCallable = + callableFactory.createUnaryCallable( + listSecuritySettingsTransportSettings, + settings.listSecuritySettingsSettings(), + clientContext); + this.listSecuritySettingsPagedCallable = + callableFactory.createPagedCallable( + listSecuritySettingsTransportSettings, + settings.listSecuritySettingsSettings(), + clientContext); + this.deleteSecuritySettingsCallable = + callableFactory.createUnaryCallable( + deleteSecuritySettingsTransportSettings, + settings.deleteSecuritySettingsSettings(), + clientContext); + + this.backgroundResources = + new BackgroundResourceAggregation(clientContext.getBackgroundResources()); + } + + public GrpcOperationsStub getOperationsStub() { + return operationsStub; + } + + public UnaryCallable + createSecuritySettingsCallable() { + return createSecuritySettingsCallable; + } + + public UnaryCallable getSecuritySettingsCallable() { + return getSecuritySettingsCallable; + } + + public UnaryCallable + updateSecuritySettingsCallable() { + return updateSecuritySettingsCallable; + } + + public UnaryCallable + listSecuritySettingsCallable() { + return listSecuritySettingsCallable; + } + + public UnaryCallable + listSecuritySettingsPagedCallable() { + return listSecuritySettingsPagedCallable; + } + + public UnaryCallable deleteSecuritySettingsCallable() { + return deleteSecuritySettingsCallable; + } + + @Override + public final void close() { + shutdown(); + } + + @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/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesCallableFactory.java index 1e5906d46..1faa4411a 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcSessionEntityTypesCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesStub.java index 858cfcc04..9934fcbf5 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.SessionEntityTypesClient.ListSessionEntityTypesPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -48,6 +49,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcSessionEntityTypesStub extends SessionEntityTypesStub { private static final MethodDescriptor< diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsCallableFactory.java index 66381e99a..9a8ca7032 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcSessionsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsStub.java index 211e04241..b90360edb 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsStub.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -47,6 +48,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcSessionsStub extends SessionsStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsCallableFactory.java index 5954fb5a2..7cec978f0 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcTransitionRouteGroupsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsStub.java index 983c4dcfa..e451fdb21 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcTransitionRouteGroupsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.TransitionRouteGroupsClient.ListTransitionRouteGroupsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -48,6 +49,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcTransitionRouteGroupsStub extends TransitionRouteGroupsStub { private static final MethodDescriptor< diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsCallableFactory.java index 0417c5478..41efb8577 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcVersionsCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsStub.java index 3422b9a34..ffb203085 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcVersionsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.VersionsClient.ListVersionsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -53,6 +54,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcVersionsStub extends VersionsStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksCallableFactory.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksCallableFactory.java index 583717c7b..40eb86699 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksCallableFactory.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksCallableFactory.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.grpc.GrpcCallSettings; import com.google.api.gax.grpc.GrpcCallableFactory; import com.google.api.gax.grpc.GrpcStubCallableFactory; @@ -41,7 +42,8 @@ * *

This class is for advanced usage. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public class GrpcWebhooksCallableFactory implements GrpcStubCallableFactory { @Override diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksStub.java index e0de461bb..27a8a0a25 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcWebhooksStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.WebhooksClient.ListWebhooksPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.core.BackgroundResourceAggregation; import com.google.api.gax.grpc.GrpcCallSettings; @@ -48,6 +49,7 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ +@BetaApi @Generated("by gapic-generator-java") public class GrpcWebhooksStub extends WebhooksStub { private static final MethodDescriptor diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/IntentsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/IntentsStub.java index f27d4655c..2d189fed3 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/IntentsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/IntentsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.IntentsClient.ListIntentsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.dialogflow.cx.v3beta1.CreateIntentRequest; @@ -36,7 +37,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class IntentsStub implements BackgroundResource { public UnaryCallable listIntentsPagedCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/PagesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/PagesStub.java index 8ca9d09ea..12bace43d 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/PagesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/PagesStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.PagesClient.ListPagesPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.dialogflow.cx.v3beta1.CreatePageRequest; @@ -36,7 +37,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class PagesStub implements BackgroundResource { public UnaryCallable listPagesPagedCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStub.java new file mode 100644 index 000000000..a0f5f9bd5 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStub.java @@ -0,0 +1,74 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsServiceClient.ListSecuritySettingsPagedResponse; + +import com.google.api.core.BetaApi; +import com.google.api.gax.core.BackgroundResource; +import com.google.api.gax.rpc.UnaryCallable; +import com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse; +import com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings; +import com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest; +import com.google.protobuf.Empty; +import javax.annotation.Generated; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Base stub class for the SecuritySettingsService service API. + * + *

This class is for advanced usage and reflects the underlying API directly. + */ +@BetaApi +@Generated("by gapic-generator-java") +public abstract class SecuritySettingsServiceStub implements BackgroundResource { + + public UnaryCallable + createSecuritySettingsCallable() { + throw new UnsupportedOperationException("Not implemented: createSecuritySettingsCallable()"); + } + + public UnaryCallable getSecuritySettingsCallable() { + throw new UnsupportedOperationException("Not implemented: getSecuritySettingsCallable()"); + } + + public UnaryCallable + updateSecuritySettingsCallable() { + throw new UnsupportedOperationException("Not implemented: updateSecuritySettingsCallable()"); + } + + public UnaryCallable + listSecuritySettingsPagedCallable() { + throw new UnsupportedOperationException("Not implemented: listSecuritySettingsPagedCallable()"); + } + + public UnaryCallable + listSecuritySettingsCallable() { + throw new UnsupportedOperationException("Not implemented: listSecuritySettingsCallable()"); + } + + public UnaryCallable deleteSecuritySettingsCallable() { + throw new UnsupportedOperationException("Not implemented: deleteSecuritySettingsCallable()"); + } + + @Override + public abstract void close(); +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStubSettings.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStubSettings.java new file mode 100644 index 000000000..04c6b5cbd --- /dev/null +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStubSettings.java @@ -0,0 +1,475 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1.stub; + +import static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsServiceClient.ListSecuritySettingsPagedResponse; + +import com.google.api.core.ApiFunction; +import com.google.api.core.ApiFuture; +import com.google.api.core.BetaApi; +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.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.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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest; +import com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse; +import com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings; +import com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest; +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.protobuf.Empty; +import java.io.IOException; +import java.util.List; +import javax.annotation.Generated; +import org.threeten.bp.Duration; + +// AUTO-GENERATED DOCUMENTATION AND CLASS. +/** + * Settings class to configure an instance of {@link SecuritySettingsServiceStub}. + * + *

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

    + *
  • The default service address (dialogflow.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 total timeout of createSecuritySettings to 30 seconds: + * + *

{@code
+ * SecuritySettingsServiceStubSettings.Builder securitySettingsServiceSettingsBuilder =
+ *     SecuritySettingsServiceStubSettings.newBuilder();
+ * securitySettingsServiceSettingsBuilder
+ *     .createSecuritySettingsSettings()
+ *     .setRetrySettings(
+ *         securitySettingsServiceSettingsBuilder
+ *             .createSecuritySettingsSettings()
+ *             .getRetrySettings()
+ *             .toBuilder()
+ *             .setTotalTimeout(Duration.ofSeconds(30))
+ *             .build());
+ * SecuritySettingsServiceStubSettings securitySettingsServiceSettings =
+ *     securitySettingsServiceSettingsBuilder.build();
+ * }
+ */ +@BetaApi +@Generated("by gapic-generator-java") +public class SecuritySettingsServiceStubSettings + 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") + .add("https://www.googleapis.com/auth/dialogflow") + .build(); + + private final UnaryCallSettings + createSecuritySettingsSettings; + private final UnaryCallSettings + getSecuritySettingsSettings; + private final UnaryCallSettings + updateSecuritySettingsSettings; + private final PagedCallSettings< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + listSecuritySettingsSettings; + private final UnaryCallSettings + deleteSecuritySettingsSettings; + + private static final PagedListDescriptor< + ListSecuritySettingsRequest, ListSecuritySettingsResponse, SecuritySettings> + LIST_SECURITY_SETTINGS_PAGE_STR_DESC = + new PagedListDescriptor< + ListSecuritySettingsRequest, ListSecuritySettingsResponse, SecuritySettings>() { + @Override + public String emptyToken() { + return ""; + } + + @Override + public ListSecuritySettingsRequest injectToken( + ListSecuritySettingsRequest payload, String token) { + return ListSecuritySettingsRequest.newBuilder(payload).setPageToken(token).build(); + } + + @Override + public ListSecuritySettingsRequest injectPageSize( + ListSecuritySettingsRequest payload, int pageSize) { + return ListSecuritySettingsRequest.newBuilder(payload).setPageSize(pageSize).build(); + } + + @Override + public Integer extractPageSize(ListSecuritySettingsRequest payload) { + return payload.getPageSize(); + } + + @Override + public String extractNextToken(ListSecuritySettingsResponse payload) { + return payload.getNextPageToken(); + } + + @Override + public Iterable extractResources( + ListSecuritySettingsResponse payload) { + return payload.getSecuritySettingsList() == null + ? ImmutableList.of() + : payload.getSecuritySettingsList(); + } + }; + + private static final PagedListResponseFactory< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + LIST_SECURITY_SETTINGS_PAGE_STR_FACT = + new PagedListResponseFactory< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse>() { + @Override + public ApiFuture getFuturePagedResponse( + UnaryCallable callable, + ListSecuritySettingsRequest request, + ApiCallContext context, + ApiFuture futureResponse) { + PageContext< + ListSecuritySettingsRequest, ListSecuritySettingsResponse, SecuritySettings> + pageContext = + PageContext.create( + callable, LIST_SECURITY_SETTINGS_PAGE_STR_DESC, request, context); + return ListSecuritySettingsPagedResponse.createAsync(pageContext, futureResponse); + } + }; + + /** Returns the object with the settings used for calls to createSecuritySettings. */ + public UnaryCallSettings + createSecuritySettingsSettings() { + return createSecuritySettingsSettings; + } + + /** Returns the object with the settings used for calls to getSecuritySettings. */ + public UnaryCallSettings + getSecuritySettingsSettings() { + return getSecuritySettingsSettings; + } + + /** Returns the object with the settings used for calls to updateSecuritySettings. */ + public UnaryCallSettings + updateSecuritySettingsSettings() { + return updateSecuritySettingsSettings; + } + + /** Returns the object with the settings used for calls to listSecuritySettings. */ + public PagedCallSettings< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + listSecuritySettingsSettings() { + return listSecuritySettingsSettings; + } + + /** Returns the object with the settings used for calls to deleteSecuritySettings. */ + public UnaryCallSettings deleteSecuritySettingsSettings() { + return deleteSecuritySettingsSettings; + } + + @BetaApi("A restructuring of stub classes is planned, so this may break in the future") + public SecuritySettingsServiceStub createStub() throws IOException { + if (getTransportChannelProvider() + .getTransportName() + .equals(GrpcTransportChannel.getGrpcTransportName())) { + return GrpcSecuritySettingsServiceStub.create(this); + } + throw new UnsupportedOperationException( + String.format( + "Transport not supported: %s", getTransportChannelProvider().getTransportName())); + } + + /** Returns a builder for the default ExecutorProvider for this service. */ + public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { + return InstantiatingExecutorProvider.newBuilder(); + } + + /** Returns the default service endpoint. */ + public static String getDefaultEndpoint() { + return "dialogflow.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); + } + + /** Returns a builder for the default ChannelProvider for this service. */ + public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { + return InstantiatingGrpcChannelProvider.newBuilder() + .setMaxInboundMessageSize(Integer.MAX_VALUE); + } + + public static TransportChannelProvider defaultTransportChannelProvider() { + return defaultGrpcTransportProviderBuilder().build(); + } + + @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") + public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { + return ApiClientHeaderProvider.newBuilder() + .setGeneratedLibToken( + "gapic", GaxProperties.getLibraryVersion(SecuritySettingsServiceStubSettings.class)) + .setTransportToken( + GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder() { + return Builder.createDefault(); + } + + /** Returns a new builder for this class. */ + public static Builder newBuilder(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 SecuritySettingsServiceStubSettings(Builder settingsBuilder) throws IOException { + super(settingsBuilder); + + createSecuritySettingsSettings = settingsBuilder.createSecuritySettingsSettings().build(); + getSecuritySettingsSettings = settingsBuilder.getSecuritySettingsSettings().build(); + updateSecuritySettingsSettings = settingsBuilder.updateSecuritySettingsSettings().build(); + listSecuritySettingsSettings = settingsBuilder.listSecuritySettingsSettings().build(); + deleteSecuritySettingsSettings = settingsBuilder.deleteSecuritySettingsSettings().build(); + } + + /** Builder for SecuritySettingsServiceStubSettings. */ + public static class Builder + extends StubSettings.Builder { + private final ImmutableList> unaryMethodSettingsBuilders; + private final UnaryCallSettings.Builder + createSecuritySettingsSettings; + private final UnaryCallSettings.Builder + getSecuritySettingsSettings; + private final UnaryCallSettings.Builder + updateSecuritySettingsSettings; + private final PagedCallSettings.Builder< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + listSecuritySettingsSettings; + private final UnaryCallSettings.Builder + deleteSecuritySettingsSettings; + private static final ImmutableMap> + RETRYABLE_CODE_DEFINITIONS; + + static { + ImmutableMap.Builder> definitions = + ImmutableMap.builder(); + definitions.put( + "retry_policy_0_codes", + ImmutableSet.copyOf(Lists.newArrayList(StatusCode.Code.UNAVAILABLE))); + RETRYABLE_CODE_DEFINITIONS = definitions.build(); + } + + private static final ImmutableMap RETRY_PARAM_DEFINITIONS; + + static { + ImmutableMap.Builder definitions = ImmutableMap.builder(); + RetrySettings settings = null; + settings = + RetrySettings.newBuilder() + .setInitialRetryDelay(Duration.ofMillis(100L)) + .setRetryDelayMultiplier(1.3) + .setMaxRetryDelay(Duration.ofMillis(60000L)) + .setInitialRpcTimeout(Duration.ofMillis(60000L)) + .setRpcTimeoutMultiplier(1.0) + .setMaxRpcTimeout(Duration.ofMillis(60000L)) + .setTotalTimeout(Duration.ofMillis(60000L)) + .build(); + definitions.put("retry_policy_0_params", settings); + RETRY_PARAM_DEFINITIONS = definitions.build(); + } + + protected Builder() { + this(((ClientContext) null)); + } + + protected Builder(ClientContext clientContext) { + super(clientContext); + + createSecuritySettingsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + getSecuritySettingsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + updateSecuritySettingsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + listSecuritySettingsSettings = + PagedCallSettings.newBuilder(LIST_SECURITY_SETTINGS_PAGE_STR_FACT); + deleteSecuritySettingsSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createSecuritySettingsSettings, + getSecuritySettingsSettings, + updateSecuritySettingsSettings, + listSecuritySettingsSettings, + deleteSecuritySettingsSettings); + initDefaults(this); + } + + protected Builder(SecuritySettingsServiceStubSettings settings) { + super(settings); + + createSecuritySettingsSettings = settings.createSecuritySettingsSettings.toBuilder(); + getSecuritySettingsSettings = settings.getSecuritySettingsSettings.toBuilder(); + updateSecuritySettingsSettings = settings.updateSecuritySettingsSettings.toBuilder(); + listSecuritySettingsSettings = settings.listSecuritySettingsSettings.toBuilder(); + deleteSecuritySettingsSettings = settings.deleteSecuritySettingsSettings.toBuilder(); + + unaryMethodSettingsBuilders = + ImmutableList.>of( + createSecuritySettingsSettings, + getSecuritySettingsSettings, + updateSecuritySettingsSettings, + listSecuritySettingsSettings, + deleteSecuritySettingsSettings); + } + + private static Builder createDefault() { + Builder builder = new Builder(((ClientContext) null)); + + builder.setTransportChannelProvider(defaultTransportChannelProvider()); + builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); + builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); + builder.setEndpoint(getDefaultEndpoint()); + + return initDefaults(builder); + } + + private static Builder initDefaults(Builder builder) { + builder + .createSecuritySettingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .getSecuritySettingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .updateSecuritySettingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .listSecuritySettingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + builder + .deleteSecuritySettingsSettings() + .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) + .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); + + return builder; + } + + // NEXT_MAJOR_VER: remove 'throws Exception'. + /** + * 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) throws Exception { + super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); + return this; + } + + public ImmutableList> unaryMethodSettingsBuilders() { + return unaryMethodSettingsBuilders; + } + + /** Returns the builder for the settings used for calls to createSecuritySettings. */ + public UnaryCallSettings.Builder + createSecuritySettingsSettings() { + return createSecuritySettingsSettings; + } + + /** Returns the builder for the settings used for calls to getSecuritySettings. */ + public UnaryCallSettings.Builder + getSecuritySettingsSettings() { + return getSecuritySettingsSettings; + } + + /** Returns the builder for the settings used for calls to updateSecuritySettings. */ + public UnaryCallSettings.Builder + updateSecuritySettingsSettings() { + return updateSecuritySettingsSettings; + } + + /** Returns the builder for the settings used for calls to listSecuritySettings. */ + public PagedCallSettings.Builder< + ListSecuritySettingsRequest, + ListSecuritySettingsResponse, + ListSecuritySettingsPagedResponse> + listSecuritySettingsSettings() { + return listSecuritySettingsSettings; + } + + /** Returns the builder for the settings used for calls to deleteSecuritySettings. */ + public UnaryCallSettings.Builder + deleteSecuritySettingsSettings() { + return deleteSecuritySettingsSettings; + } + + @Override + public SecuritySettingsServiceStubSettings build() throws IOException { + return new SecuritySettingsServiceStubSettings(this); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionEntityTypesStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionEntityTypesStub.java index 8949b964e..757864968 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionEntityTypesStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionEntityTypesStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.SessionEntityTypesClient.ListSessionEntityTypesPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.dialogflow.cx.v3beta1.CreateSessionEntityTypeRequest; @@ -36,7 +37,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class SessionEntityTypesStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionsStub.java index 19d6b2a03..1026a805e 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionsStub.java @@ -16,6 +16,7 @@ package com.google.cloud.dialogflow.cx.v3beta1.stub; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.BidiStreamingCallable; import com.google.api.gax.rpc.UnaryCallable; @@ -35,7 +36,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class SessionsStub implements BackgroundResource { public UnaryCallable detectIntentCallable() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/TransitionRouteGroupsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/TransitionRouteGroupsStub.java index 50025957a..c27cf036f 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/TransitionRouteGroupsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/TransitionRouteGroupsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.TransitionRouteGroupsClient.ListTransitionRouteGroupsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.dialogflow.cx.v3beta1.CreateTransitionRouteGroupRequest; @@ -36,7 +37,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class TransitionRouteGroupsStub implements BackgroundResource { public UnaryCallable diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/VersionsStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/VersionsStub.java index 3dcc0eb39..5d066fef1 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/VersionsStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/VersionsStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.VersionsClient.ListVersionsPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.OperationCallable; import com.google.api.gax.rpc.UnaryCallable; @@ -42,7 +43,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class VersionsStub implements BackgroundResource { public OperationsStub getOperationsStub() { diff --git a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/WebhooksStub.java b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/WebhooksStub.java index cd7ddb77a..ceb3b15d3 100644 --- a/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/WebhooksStub.java +++ b/google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/WebhooksStub.java @@ -18,6 +18,7 @@ import static com.google.cloud.dialogflow.cx.v3beta1.WebhooksClient.ListWebhooksPagedResponse; +import com.google.api.core.BetaApi; import com.google.api.gax.core.BackgroundResource; import com.google.api.gax.rpc.UnaryCallable; import com.google.cloud.dialogflow.cx.v3beta1.CreateWebhookRequest; @@ -36,7 +37,8 @@ * *

This class is for advanced usage and reflects the underlying API directly. */ -@Generated("by gapic-generator") +@BetaApi +@Generated("by gapic-generator-java") public abstract class WebhooksStub implements BackgroundResource { public UnaryCallable listWebhooksPagedCallable() { diff --git a/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClientTest.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClientTest.java new file mode 100644 index 000000000..2ec0fbdd4 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClientTest.java @@ -0,0 +1,721 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3; + +import static com.google.cloud.dialogflow.cx.v3.ExperimentsClient.ListExperimentsPagedResponse; + +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.common.collect.Lists; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Duration; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.UUID; +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 ExperimentsClientTest { + private static MockExperiments mockExperiments; + private static MockServiceHelper mockServiceHelper; + private ExperimentsClient client; + private LocalChannelProvider channelProvider; + + @BeforeClass + public static void startStaticServer() { + mockExperiments = new MockExperiments(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), Arrays.asList(mockExperiments)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + ExperimentsSettings settings = + ExperimentsSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = ExperimentsClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void listExperimentsTest() throws Exception { + Experiment responsesElement = Experiment.newBuilder().build(); + ListExperimentsResponse expectedResponse = + ListExperimentsResponse.newBuilder() + .setNextPageToken("") + .addAllExperiments(Arrays.asList(responsesElement)) + .build(); + mockExperiments.addResponse(expectedResponse); + + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + + ListExperimentsPagedResponse pagedListResponse = client.listExperiments(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getExperimentsList().get(0), resources.get(0)); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListExperimentsRequest actualRequest = ((ListExperimentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listExperimentsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + client.listExperiments(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listExperimentsTest2() throws Exception { + Experiment responsesElement = Experiment.newBuilder().build(); + ListExperimentsResponse expectedResponse = + ListExperimentsResponse.newBuilder() + .setNextPageToken("") + .addAllExperiments(Arrays.asList(responsesElement)) + .build(); + mockExperiments.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListExperimentsPagedResponse pagedListResponse = client.listExperiments(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getExperimentsList().get(0), resources.get(0)); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListExperimentsRequest actualRequest = ((ListExperimentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listExperimentsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String parent = "parent-995424086"; + client.listExperiments(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + Experiment actualResponse = client.getExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetExperimentRequest actualRequest = ((GetExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.getExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + Experiment actualResponse = client.getExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetExperimentRequest actualRequest = ((GetExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.getExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + Experiment experiment = Experiment.newBuilder().build(); + + Experiment actualResponse = client.createExperiment(parent, experiment); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateExperimentRequest actualRequest = ((CreateExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(experiment, actualRequest.getExperiment()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + Experiment experiment = Experiment.newBuilder().build(); + client.createExperiment(parent, experiment); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String parent = "parent-995424086"; + Experiment experiment = Experiment.newBuilder().build(); + + Experiment actualResponse = client.createExperiment(parent, experiment); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateExperimentRequest actualRequest = ((CreateExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(experiment, actualRequest.getExperiment()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String parent = "parent-995424086"; + Experiment experiment = Experiment.newBuilder().build(); + client.createExperiment(parent, experiment); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + Experiment experiment = Experiment.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Experiment actualResponse = client.updateExperiment(experiment, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateExperimentRequest actualRequest = ((UpdateExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(experiment, actualRequest.getExperiment()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + Experiment experiment = Experiment.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateExperiment(experiment, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteExperimentTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + client.deleteExperiment(name); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteExperimentRequest actualRequest = ((DeleteExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.deleteExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteExperimentTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + client.deleteExperiment(name); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteExperimentRequest actualRequest = ((DeleteExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.deleteExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void startExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + Experiment actualResponse = client.startExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StartExperimentRequest actualRequest = ((StartExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void startExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.startExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void startExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + Experiment actualResponse = client.startExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StartExperimentRequest actualRequest = ((StartExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void startExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.startExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void stopExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + Experiment actualResponse = client.stopExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StopExperimentRequest actualRequest = ((StopExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void stopExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.stopExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void stopExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + Experiment actualResponse = client.stopExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StopExperimentRequest actualRequest = ((StopExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void stopExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.stopExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperiments.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperiments.java new file mode 100644 index 000000000..7de1a382d --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperiments.java @@ -0,0 +1,59 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3; + +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 MockExperiments implements MockGrpcService { + private final MockExperimentsImpl serviceImpl; + + public MockExperiments() { + serviceImpl = new MockExperimentsImpl(); + } + + @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/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperimentsImpl.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperimentsImpl.java new file mode 100644 index 000000000..e5b7570dc --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperimentsImpl.java @@ -0,0 +1,166 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3; + +import com.google.api.core.BetaApi; +import com.google.cloud.dialogflow.cx.v3.ExperimentsGrpc.ExperimentsImplBase; +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 MockExperimentsImpl extends ExperimentsImplBase { + private List requests; + private Queue responses; + + public MockExperimentsImpl() { + 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 listExperiments( + ListExperimentsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListExperimentsResponse) { + requests.add(request); + responseObserver.onNext(((ListExperimentsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getExperiment( + GetExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void createExperiment( + CreateExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void updateExperiment( + UpdateExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void deleteExperiment( + DeleteExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + 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("Unrecognized response type")); + } + } + + @Override + public void startExperiment( + StartExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void stopExperiment( + StopExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClientTest.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClientTest.java new file mode 100644 index 000000000..ce993e9cc --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClientTest.java @@ -0,0 +1,721 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import static com.google.cloud.dialogflow.cx.v3beta1.ExperimentsClient.ListExperimentsPagedResponse; + +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.common.collect.Lists; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Duration; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import com.google.protobuf.Timestamp; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.UUID; +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 ExperimentsClientTest { + private static MockExperiments mockExperiments; + private static MockServiceHelper mockServiceHelper; + private ExperimentsClient client; + private LocalChannelProvider channelProvider; + + @BeforeClass + public static void startStaticServer() { + mockExperiments = new MockExperiments(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), Arrays.asList(mockExperiments)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + ExperimentsSettings settings = + ExperimentsSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = ExperimentsClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void listExperimentsTest() throws Exception { + Experiment responsesElement = Experiment.newBuilder().build(); + ListExperimentsResponse expectedResponse = + ListExperimentsResponse.newBuilder() + .setNextPageToken("") + .addAllExperiments(Arrays.asList(responsesElement)) + .build(); + mockExperiments.addResponse(expectedResponse); + + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + + ListExperimentsPagedResponse pagedListResponse = client.listExperiments(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getExperimentsList().get(0), resources.get(0)); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListExperimentsRequest actualRequest = ((ListExperimentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listExperimentsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + client.listExperiments(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listExperimentsTest2() throws Exception { + Experiment responsesElement = Experiment.newBuilder().build(); + ListExperimentsResponse expectedResponse = + ListExperimentsResponse.newBuilder() + .setNextPageToken("") + .addAllExperiments(Arrays.asList(responsesElement)) + .build(); + mockExperiments.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListExperimentsPagedResponse pagedListResponse = client.listExperiments(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getExperimentsList().get(0), resources.get(0)); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListExperimentsRequest actualRequest = ((ListExperimentsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listExperimentsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String parent = "parent-995424086"; + client.listExperiments(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + Experiment actualResponse = client.getExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetExperimentRequest actualRequest = ((GetExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.getExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + Experiment actualResponse = client.getExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetExperimentRequest actualRequest = ((GetExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.getExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + Experiment experiment = Experiment.newBuilder().build(); + + Experiment actualResponse = client.createExperiment(parent, experiment); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateExperimentRequest actualRequest = ((CreateExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(experiment, actualRequest.getExperiment()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + EnvironmentName parent = + EnvironmentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]"); + Experiment experiment = Experiment.newBuilder().build(); + client.createExperiment(parent, experiment); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String parent = "parent-995424086"; + Experiment experiment = Experiment.newBuilder().build(); + + Experiment actualResponse = client.createExperiment(parent, experiment); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateExperimentRequest actualRequest = ((CreateExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(experiment, actualRequest.getExperiment()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String parent = "parent-995424086"; + Experiment experiment = Experiment.newBuilder().build(); + client.createExperiment(parent, experiment); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + Experiment experiment = Experiment.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + Experiment actualResponse = client.updateExperiment(experiment, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateExperimentRequest actualRequest = ((UpdateExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(experiment, actualRequest.getExperiment()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + Experiment experiment = Experiment.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateExperiment(experiment, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteExperimentTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + client.deleteExperiment(name); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteExperimentRequest actualRequest = ((DeleteExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.deleteExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteExperimentTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + client.deleteExperiment(name); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteExperimentRequest actualRequest = ((DeleteExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.deleteExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void startExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + Experiment actualResponse = client.startExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StartExperimentRequest actualRequest = ((StartExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void startExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.startExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void startExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + Experiment actualResponse = client.startExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StartExperimentRequest actualRequest = ((StartExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void startExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.startExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void stopExperimentTest() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + + Experiment actualResponse = client.stopExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StopExperimentRequest actualRequest = ((StopExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void stopExperimentExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + ExperimentName name = + ExperimentName.of("[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]"); + client.stopExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void stopExperimentTest2() throws Exception { + Experiment expectedResponse = + Experiment.newBuilder() + .setName( + ExperimentName.of( + "[PROJECT]", "[LOCATION]", "[AGENT]", "[ENVIRONMENT]", "[EXPERIMENT]") + .toString()) + .setDisplayName("displayName1714148973") + .setDescription("description-1724546052") + .setDefinition(Experiment.Definition.newBuilder().build()) + .setResult(Experiment.Result.newBuilder().build()) + .setCreateTime(Timestamp.newBuilder().build()) + .setStartTime(Timestamp.newBuilder().build()) + .setEndTime(Timestamp.newBuilder().build()) + .setLastUpdateTime(Timestamp.newBuilder().build()) + .setExperimentLength(Duration.newBuilder().build()) + .addAllVariantsHistory(new ArrayList()) + .build(); + mockExperiments.addResponse(expectedResponse); + + String name = "name3373707"; + + Experiment actualResponse = client.stopExperiment(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockExperiments.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + StopExperimentRequest actualRequest = ((StopExperimentRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void stopExperimentExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockExperiments.addException(exception); + + try { + String name = "name3373707"; + client.stopExperiment(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperiments.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperiments.java new file mode 100644 index 000000000..6f017b132 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperiments.java @@ -0,0 +1,59 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +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 MockExperiments implements MockGrpcService { + private final MockExperimentsImpl serviceImpl; + + public MockExperiments() { + serviceImpl = new MockExperimentsImpl(); + } + + @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/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperimentsImpl.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperimentsImpl.java new file mode 100644 index 000000000..dcb58f977 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperimentsImpl.java @@ -0,0 +1,166 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import com.google.api.core.BetaApi; +import com.google.cloud.dialogflow.cx.v3beta1.ExperimentsGrpc.ExperimentsImplBase; +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 MockExperimentsImpl extends ExperimentsImplBase { + private List requests; + private Queue responses; + + public MockExperimentsImpl() { + 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 listExperiments( + ListExperimentsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListExperimentsResponse) { + requests.add(request); + responseObserver.onNext(((ListExperimentsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getExperiment( + GetExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void createExperiment( + CreateExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void updateExperiment( + UpdateExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void deleteExperiment( + DeleteExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + 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("Unrecognized response type")); + } + } + + @Override + public void startExperiment( + StartExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void stopExperiment( + StopExperimentRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof Experiment) { + requests.add(request); + responseObserver.onNext(((Experiment) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsService.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsService.java new file mode 100644 index 000000000..212903590 --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsService.java @@ -0,0 +1,59 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +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 MockSecuritySettingsService implements MockGrpcService { + private final MockSecuritySettingsServiceImpl serviceImpl; + + public MockSecuritySettingsService() { + serviceImpl = new MockSecuritySettingsServiceImpl(); + } + + @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/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsServiceImpl.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsServiceImpl.java new file mode 100644 index 000000000..f7225ac8c --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsServiceImpl.java @@ -0,0 +1,137 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import com.google.api.core.BetaApi; +import com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsServiceGrpc.SecuritySettingsServiceImplBase; +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 MockSecuritySettingsServiceImpl extends SecuritySettingsServiceImplBase { + private List requests; + private Queue responses; + + public MockSecuritySettingsServiceImpl() { + 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 createSecuritySettings( + CreateSecuritySettingsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof SecuritySettings) { + requests.add(request); + responseObserver.onNext(((SecuritySettings) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void getSecuritySettings( + GetSecuritySettingsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof SecuritySettings) { + requests.add(request); + responseObserver.onNext(((SecuritySettings) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void updateSecuritySettings( + UpdateSecuritySettingsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof SecuritySettings) { + requests.add(request); + responseObserver.onNext(((SecuritySettings) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void listSecuritySettings( + ListSecuritySettingsRequest request, + StreamObserver responseObserver) { + Object response = responses.remove(); + if (response instanceof ListSecuritySettingsResponse) { + requests.add(request); + responseObserver.onNext(((ListSecuritySettingsResponse) response)); + responseObserver.onCompleted(); + } else if (response instanceof Exception) { + responseObserver.onError(((Exception) response)); + } else { + responseObserver.onError(new IllegalArgumentException("Unrecognized response type")); + } + } + + @Override + public void deleteSecuritySettings( + DeleteSecuritySettingsRequest request, StreamObserver responseObserver) { + Object response = responses.remove(); + 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("Unrecognized response type")); + } + } +} diff --git a/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClientTest.java b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClientTest.java new file mode 100644 index 000000000..b1d2c021f --- /dev/null +++ b/google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClientTest.java @@ -0,0 +1,475 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +import static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsServiceClient.ListSecuritySettingsPagedResponse; + +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.common.collect.Lists; +import com.google.protobuf.AbstractMessage; +import com.google.protobuf.Empty; +import com.google.protobuf.FieldMask; +import io.grpc.StatusRuntimeException; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.UUID; +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 SecuritySettingsServiceClientTest { + private static MockServiceHelper mockServiceHelper; + private SecuritySettingsServiceClient client; + private static MockSecuritySettingsService mockSecuritySettingsService; + private LocalChannelProvider channelProvider; + + @BeforeClass + public static void startStaticServer() { + mockSecuritySettingsService = new MockSecuritySettingsService(); + mockServiceHelper = + new MockServiceHelper( + UUID.randomUUID().toString(), + Arrays.asList(mockSecuritySettingsService)); + mockServiceHelper.start(); + } + + @AfterClass + public static void stopServer() { + mockServiceHelper.stop(); + } + + @Before + public void setUp() throws IOException { + mockServiceHelper.reset(); + channelProvider = mockServiceHelper.createChannelProvider(); + SecuritySettingsServiceSettings settings = + SecuritySettingsServiceSettings.newBuilder() + .setTransportChannelProvider(channelProvider) + .setCredentialsProvider(NoCredentialsProvider.create()) + .build(); + client = SecuritySettingsServiceClient.create(settings); + } + + @After + public void tearDown() throws Exception { + client.close(); + } + + @Test + public void createSecuritySettingsTest() throws Exception { + SecuritySettings expectedResponse = + SecuritySettings.newBuilder() + .setName( + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]") + .toString()) + .setDisplayName("displayName1714148973") + .setInspectTemplate("inspectTemplate-2053620050") + .addAllPurgeDataTypes(new ArrayList()) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + SecuritySettings securitySettings = SecuritySettings.newBuilder().build(); + + SecuritySettings actualResponse = client.createSecuritySettings(parent, securitySettings); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateSecuritySettingsRequest actualRequest = + ((CreateSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertEquals(securitySettings, actualRequest.getSecuritySettings()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createSecuritySettingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + SecuritySettings securitySettings = SecuritySettings.newBuilder().build(); + client.createSecuritySettings(parent, securitySettings); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void createSecuritySettingsTest2() throws Exception { + SecuritySettings expectedResponse = + SecuritySettings.newBuilder() + .setName( + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]") + .toString()) + .setDisplayName("displayName1714148973") + .setInspectTemplate("inspectTemplate-2053620050") + .addAllPurgeDataTypes(new ArrayList()) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + SecuritySettings securitySettings = SecuritySettings.newBuilder().build(); + + SecuritySettings actualResponse = client.createSecuritySettings(parent, securitySettings); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + CreateSecuritySettingsRequest actualRequest = + ((CreateSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertEquals(securitySettings, actualRequest.getSecuritySettings()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void createSecuritySettingsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + String parent = "parent-995424086"; + SecuritySettings securitySettings = SecuritySettings.newBuilder().build(); + client.createSecuritySettings(parent, securitySettings); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSecuritySettingsTest() throws Exception { + SecuritySettings expectedResponse = + SecuritySettings.newBuilder() + .setName( + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]") + .toString()) + .setDisplayName("displayName1714148973") + .setInspectTemplate("inspectTemplate-2053620050") + .addAllPurgeDataTypes(new ArrayList()) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + SecuritySettingsName name = + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]"); + + SecuritySettings actualResponse = client.getSecuritySettings(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSecuritySettingsRequest actualRequest = ((GetSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSecuritySettingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + SecuritySettingsName name = + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]"); + client.getSecuritySettings(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void getSecuritySettingsTest2() throws Exception { + SecuritySettings expectedResponse = + SecuritySettings.newBuilder() + .setName( + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]") + .toString()) + .setDisplayName("displayName1714148973") + .setInspectTemplate("inspectTemplate-2053620050") + .addAllPurgeDataTypes(new ArrayList()) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + String name = "name3373707"; + + SecuritySettings actualResponse = client.getSecuritySettings(name); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + GetSecuritySettingsRequest actualRequest = ((GetSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void getSecuritySettingsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + String name = "name3373707"; + client.getSecuritySettings(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void updateSecuritySettingsTest() throws Exception { + SecuritySettings expectedResponse = + SecuritySettings.newBuilder() + .setName( + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]") + .toString()) + .setDisplayName("displayName1714148973") + .setInspectTemplate("inspectTemplate-2053620050") + .addAllPurgeDataTypes(new ArrayList()) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + SecuritySettings securitySettings = SecuritySettings.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + + SecuritySettings actualResponse = client.updateSecuritySettings(securitySettings, updateMask); + Assert.assertEquals(expectedResponse, actualResponse); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + UpdateSecuritySettingsRequest actualRequest = + ((UpdateSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(securitySettings, actualRequest.getSecuritySettings()); + Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void updateSecuritySettingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + SecuritySettings securitySettings = SecuritySettings.newBuilder().build(); + FieldMask updateMask = FieldMask.newBuilder().build(); + client.updateSecuritySettings(securitySettings, updateMask); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listSecuritySettingsTest() throws Exception { + SecuritySettings responsesElement = SecuritySettings.newBuilder().build(); + ListSecuritySettingsResponse expectedResponse = + ListSecuritySettingsResponse.newBuilder() + .setNextPageToken("") + .addAllSecuritySettings(Arrays.asList(responsesElement)) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + + ListSecuritySettingsPagedResponse pagedListResponse = client.listSecuritySettings(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSecuritySettingsList().get(0), resources.get(0)); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListSecuritySettingsRequest actualRequest = + ((ListSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent.toString(), actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listSecuritySettingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); + client.listSecuritySettings(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void listSecuritySettingsTest2() throws Exception { + SecuritySettings responsesElement = SecuritySettings.newBuilder().build(); + ListSecuritySettingsResponse expectedResponse = + ListSecuritySettingsResponse.newBuilder() + .setNextPageToken("") + .addAllSecuritySettings(Arrays.asList(responsesElement)) + .build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + String parent = "parent-995424086"; + + ListSecuritySettingsPagedResponse pagedListResponse = client.listSecuritySettings(parent); + + List resources = Lists.newArrayList(pagedListResponse.iterateAll()); + + Assert.assertEquals(1, resources.size()); + Assert.assertEquals(expectedResponse.getSecuritySettingsList().get(0), resources.get(0)); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + ListSecuritySettingsRequest actualRequest = + ((ListSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(parent, actualRequest.getParent()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void listSecuritySettingsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + String parent = "parent-995424086"; + client.listSecuritySettings(parent); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteSecuritySettingsTest() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + SecuritySettingsName name = + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]"); + + client.deleteSecuritySettings(name); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteSecuritySettingsRequest actualRequest = + ((DeleteSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(name.toString(), actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteSecuritySettingsExceptionTest() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + SecuritySettingsName name = + SecuritySettingsName.of("[PROJECT]", "[LOCATION]", "[SECURITY_SETTINGS]"); + client.deleteSecuritySettings(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } + + @Test + public void deleteSecuritySettingsTest2() throws Exception { + Empty expectedResponse = Empty.newBuilder().build(); + mockSecuritySettingsService.addResponse(expectedResponse); + + String name = "name3373707"; + + client.deleteSecuritySettings(name); + + List actualRequests = mockSecuritySettingsService.getRequests(); + Assert.assertEquals(1, actualRequests.size()); + DeleteSecuritySettingsRequest actualRequest = + ((DeleteSecuritySettingsRequest) actualRequests.get(0)); + + Assert.assertEquals(name, actualRequest.getName()); + Assert.assertTrue( + channelProvider.isHeaderSent( + ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), + GaxGrpcProperties.getDefaultApiClientHeaderPattern())); + } + + @Test + public void deleteSecuritySettingsExceptionTest2() throws Exception { + StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); + mockSecuritySettingsService.addException(exception); + + try { + String name = "name3373707"; + client.deleteSecuritySettings(name); + Assert.fail("No exception raised"); + } catch (InvalidArgumentException e) { + // Expected exception. + } + } +} diff --git a/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsGrpc.java b/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsGrpc.java new file mode 100644 index 000000000..2f08892f8 --- /dev/null +++ b/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsGrpc.java @@ -0,0 +1,1074 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.dialogflow.cx.v3; + +import static io.grpc.MethodDescriptor.generateFullMethodName; +import static io.grpc.stub.ClientCalls.asyncUnaryCall; +import static io.grpc.stub.ClientCalls.blockingUnaryCall; +import static io.grpc.stub.ClientCalls.futureUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; + +/** + * + * + *
+ * Service for managing [Experiments][google.cloud.dialogflow.cx.v3.Experiment].
+ * 
+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/cloud/dialogflow/cx/v3/experiment.proto") +public final class ExperimentsGrpc { + + private ExperimentsGrpc() {} + + public static final String SERVICE_NAME = "google.cloud.dialogflow.cx.v3.Experiments"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse> + getListExperimentsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListExperiments", + requestType = com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse> + getListExperimentsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse> + getListExperimentsMethod; + if ((getListExperimentsMethod = ExperimentsGrpc.getListExperimentsMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getListExperimentsMethod = ExperimentsGrpc.getListExperimentsMethod) == null) { + ExperimentsGrpc.getListExperimentsMethod = + getListExperimentsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListExperiments")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("ListExperiments")) + .build(); + } + } + } + return getListExperimentsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getGetExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetExperiment", + requestType = com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getGetExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getGetExperimentMethod; + if ((getGetExperimentMethod = ExperimentsGrpc.getGetExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getGetExperimentMethod = ExperimentsGrpc.getGetExperimentMethod) == null) { + ExperimentsGrpc.getGetExperimentMethod = + getGetExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance())) + .setSchemaDescriptor(new ExperimentsMethodDescriptorSupplier("GetExperiment")) + .build(); + } + } + } + return getGetExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getCreateExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateExperiment", + requestType = com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getCreateExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getCreateExperimentMethod; + if ((getCreateExperimentMethod = ExperimentsGrpc.getCreateExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getCreateExperimentMethod = ExperimentsGrpc.getCreateExperimentMethod) == null) { + ExperimentsGrpc.getCreateExperimentMethod = + getCreateExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("CreateExperiment")) + .build(); + } + } + } + return getCreateExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getUpdateExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateExperiment", + requestType = com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getUpdateExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getUpdateExperimentMethod; + if ((getUpdateExperimentMethod = ExperimentsGrpc.getUpdateExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getUpdateExperimentMethod = ExperimentsGrpc.getUpdateExperimentMethod) == null) { + ExperimentsGrpc.getUpdateExperimentMethod = + getUpdateExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("UpdateExperiment")) + .build(); + } + } + } + return getUpdateExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest, com.google.protobuf.Empty> + getDeleteExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteExperiment", + requestType = com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.class, + responseType = com.google.protobuf.Empty.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest, com.google.protobuf.Empty> + getDeleteExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest, com.google.protobuf.Empty> + getDeleteExperimentMethod; + if ((getDeleteExperimentMethod = ExperimentsGrpc.getDeleteExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getDeleteExperimentMethod = ExperimentsGrpc.getDeleteExperimentMethod) == null) { + ExperimentsGrpc.getDeleteExperimentMethod = + getDeleteExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.protobuf.Empty.getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("DeleteExperiment")) + .build(); + } + } + } + return getDeleteExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getStartExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "StartExperiment", + requestType = com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getStartExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getStartExperimentMethod; + if ((getStartExperimentMethod = ExperimentsGrpc.getStartExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getStartExperimentMethod = ExperimentsGrpc.getStartExperimentMethod) == null) { + ExperimentsGrpc.getStartExperimentMethod = + getStartExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "StartExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("StartExperiment")) + .build(); + } + } + } + return getStartExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getStopExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "StopExperiment", + requestType = com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getStopExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment> + getStopExperimentMethod; + if ((getStopExperimentMethod = ExperimentsGrpc.getStopExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getStopExperimentMethod = ExperimentsGrpc.getStopExperimentMethod) == null) { + ExperimentsGrpc.getStopExperimentMethod = + getStopExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "StopExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("StopExperiment")) + .build(); + } + } + } + return getStopExperimentMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static ExperimentsStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public ExperimentsStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsStub(channel, callOptions); + } + }; + return ExperimentsStub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static ExperimentsBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public ExperimentsBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsBlockingStub(channel, callOptions); + } + }; + return ExperimentsBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static ExperimentsFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public ExperimentsFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsFutureStub(channel, callOptions); + } + }; + return ExperimentsFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3.Experiment].
+   * 
+ */ + public abstract static class ExperimentsImplBase implements io.grpc.BindableService { + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public void listExperiments( + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getListExperimentsMethod(), responseObserver); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public void getExperiment( + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getGetExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public void createExperiment( + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getCreateExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public void updateExperiment( + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getUpdateExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public void deleteExperiment( + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getDeleteExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public void startExperiment( + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getStartExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public void stopExperiment( + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getStopExperimentMethod(), responseObserver); + } + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getListExperimentsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse>( + this, METHODID_LIST_EXPERIMENTS))) + .addMethod( + getGetExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment>(this, METHODID_GET_EXPERIMENT))) + .addMethod( + getCreateExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment>( + this, METHODID_CREATE_EXPERIMENT))) + .addMethod( + getUpdateExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment>( + this, METHODID_UPDATE_EXPERIMENT))) + .addMethod( + getDeleteExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest, + com.google.protobuf.Empty>(this, METHODID_DELETE_EXPERIMENT))) + .addMethod( + getStartExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment>( + this, METHODID_START_EXPERIMENT))) + .addMethod( + getStopExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3.Experiment>( + this, METHODID_STOP_EXPERIMENT))) + .build(); + } + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3.Experiment].
+   * 
+ */ + public static final class ExperimentsStub + extends io.grpc.stub.AbstractAsyncStub { + private ExperimentsStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected ExperimentsStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public void listExperiments( + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getListExperimentsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public void getExperiment( + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getGetExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public void createExperiment( + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getCreateExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public void updateExperiment( + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getUpdateExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public void deleteExperiment( + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnaryCall( + getChannel().newCall(getDeleteExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public void startExperiment( + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getStartExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public void stopExperiment( + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getStopExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3.Experiment].
+   * 
+ */ + public static final class ExperimentsBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private ExperimentsBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected ExperimentsBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse listExperiments( + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest request) { + return blockingUnaryCall(getChannel(), getListExperimentsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiment( + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest request) { + return blockingUnaryCall(getChannel(), getGetExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3.Experiment createExperiment( + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest request) { + return blockingUnaryCall( + getChannel(), getCreateExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3.Experiment updateExperiment( + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public com.google.protobuf.Empty deleteExperiment( + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest request) { + return blockingUnaryCall( + getChannel(), getDeleteExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3.Experiment startExperiment( + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest request) { + return blockingUnaryCall(getChannel(), getStartExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3.Experiment stopExperiment( + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest request) { + return blockingUnaryCall(getChannel(), getStopExperimentMethod(), getCallOptions(), request); + } + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3.Experiment].
+   * 
+ */ + public static final class ExperimentsFutureStub + extends io.grpc.stub.AbstractFutureStub { + private ExperimentsFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected ExperimentsFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse> + listExperiments(com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest request) { + return futureUnaryCall( + getChannel().newCall(getListExperimentsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3.Experiment> + getExperiment(com.google.cloud.dialogflow.cx.v3.GetExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getGetExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3.Experiment> + createExperiment(com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getCreateExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3.Experiment> + updateExperiment(com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getUpdateExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteExperiment(com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getDeleteExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3.Experiment> + startExperiment(com.google.cloud.dialogflow.cx.v3.StartExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getStartExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3.Experiment> + stopExperiment(com.google.cloud.dialogflow.cx.v3.StopExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getStopExperimentMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_LIST_EXPERIMENTS = 0; + private static final int METHODID_GET_EXPERIMENT = 1; + private static final int METHODID_CREATE_EXPERIMENT = 2; + private static final int METHODID_UPDATE_EXPERIMENT = 3; + private static final int METHODID_DELETE_EXPERIMENT = 4; + private static final int METHODID_START_EXPERIMENT = 5; + private static final int METHODID_STOP_EXPERIMENT = 6; + + 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 ExperimentsImplBase serviceImpl; + private final int methodId; + + MethodHandlers(ExperimentsImplBase serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_LIST_EXPERIMENTS: + serviceImpl.listExperiments( + (com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse>) + responseObserver); + break; + case METHODID_GET_EXPERIMENT: + serviceImpl.getExperiment( + (com.google.cloud.dialogflow.cx.v3.GetExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_EXPERIMENT: + serviceImpl.createExperiment( + (com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_EXPERIMENT: + serviceImpl.updateExperiment( + (com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_DELETE_EXPERIMENT: + serviceImpl.deleteExperiment( + (com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_START_EXPERIMENT: + serviceImpl.startExperiment( + (com.google.cloud.dialogflow.cx.v3.StartExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_STOP_EXPERIMENT: + serviceImpl.stopExperiment( + (com.google.cloud.dialogflow.cx.v3.StopExperimentRequest) 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(); + } + } + } + + private abstract static class ExperimentsBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + ExperimentsBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("Experiments"); + } + } + + private static final class ExperimentsFileDescriptorSupplier + extends ExperimentsBaseDescriptorSupplier { + ExperimentsFileDescriptorSupplier() {} + } + + private static final class ExperimentsMethodDescriptorSupplier + extends ExperimentsBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final String methodName; + + ExperimentsMethodDescriptorSupplier(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 (ExperimentsGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new ExperimentsFileDescriptorSupplier()) + .addMethod(getListExperimentsMethod()) + .addMethod(getGetExperimentMethod()) + .addMethod(getCreateExperimentMethod()) + .addMethod(getUpdateExperimentMethod()) + .addMethod(getDeleteExperimentMethod()) + .addMethod(getStartExperimentMethod()) + .addMethod(getStopExperimentMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsGrpc.java b/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsGrpc.java index dacd62eeb..36516cfc9 100644 --- a/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsGrpc.java +++ b/grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionsGrpc.java @@ -290,6 +290,9 @@ public abstract static class SessionsImplBase implements io.grpc.BindableService * as a result. This method is not idempotent, because it may cause session * entity types to be updated, which in turn might affect results of future * queries. + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * */ public void detectIntent( @@ -306,6 +309,9 @@ public void detectIntent( * Processes a natural language query in audio format in a streaming fashion * and returns structured, actionable data as a result. This method is only * available via the gRPC API (not REST). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * */ public io.grpc.stub.StreamObserver< @@ -410,6 +416,9 @@ protected SessionsStub build(io.grpc.Channel channel, io.grpc.CallOptions callOp * as a result. This method is not idempotent, because it may cause session * entity types to be updated, which in turn might affect results of future * queries. + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * */ public void detectIntent( @@ -429,6 +438,9 @@ public void detectIntent( * Processes a natural language query in audio format in a streaming fashion * and returns structured, actionable data as a result. This method is only * available via the gRPC API (not REST). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * */ public io.grpc.stub.StreamObserver< @@ -508,6 +520,9 @@ protected SessionsBlockingStub build(io.grpc.Channel channel, io.grpc.CallOption * as a result. This method is not idempotent, because it may cause session * entity types to be updated, which in turn might affect results of future * queries. + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * */ public com.google.cloud.dialogflow.cx.v3.DetectIntentResponse detectIntent( @@ -571,6 +586,9 @@ protected SessionsFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions * as a result. This method is not idempotent, because it may cause session * entity types to be updated, which in turn might affect results of future * queries. + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * */ public com.google.common.util.concurrent.ListenableFuture< diff --git a/grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsGrpc.java b/grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsGrpc.java new file mode 100644 index 000000000..3a8aed25d --- /dev/null +++ b/grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsGrpc.java @@ -0,0 +1,1081 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.dialogflow.cx.v3beta1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; +import static io.grpc.stub.ClientCalls.asyncUnaryCall; +import static io.grpc.stub.ClientCalls.blockingUnaryCall; +import static io.grpc.stub.ClientCalls.futureUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; + +/** + * + * + *
+ * Service for managing [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment].
+ * 
+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/cloud/dialogflow/cx/v3beta1/experiment.proto") +public final class ExperimentsGrpc { + + private ExperimentsGrpc() {} + + public static final String SERVICE_NAME = "google.cloud.dialogflow.cx.v3beta1.Experiments"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse> + getListExperimentsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListExperiments", + requestType = com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse> + getListExperimentsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse> + getListExperimentsMethod; + if ((getListExperimentsMethod = ExperimentsGrpc.getListExperimentsMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getListExperimentsMethod = ExperimentsGrpc.getListExperimentsMethod) == null) { + ExperimentsGrpc.getListExperimentsMethod = + getListExperimentsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListExperiments")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("ListExperiments")) + .build(); + } + } + } + return getListExperimentsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getGetExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetExperiment", + requestType = com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getGetExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getGetExperimentMethod; + if ((getGetExperimentMethod = ExperimentsGrpc.getGetExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getGetExperimentMethod = ExperimentsGrpc.getGetExperimentMethod) == null) { + ExperimentsGrpc.getGetExperimentMethod = + getGetExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.Experiment + .getDefaultInstance())) + .setSchemaDescriptor(new ExperimentsMethodDescriptorSupplier("GetExperiment")) + .build(); + } + } + } + return getGetExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getCreateExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateExperiment", + requestType = com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getCreateExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getCreateExperimentMethod; + if ((getCreateExperimentMethod = ExperimentsGrpc.getCreateExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getCreateExperimentMethod = ExperimentsGrpc.getCreateExperimentMethod) == null) { + ExperimentsGrpc.getCreateExperimentMethod = + getCreateExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.Experiment + .getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("CreateExperiment")) + .build(); + } + } + } + return getCreateExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getUpdateExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateExperiment", + requestType = com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getUpdateExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getUpdateExperimentMethod; + if ((getUpdateExperimentMethod = ExperimentsGrpc.getUpdateExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getUpdateExperimentMethod = ExperimentsGrpc.getUpdateExperimentMethod) == null) { + ExperimentsGrpc.getUpdateExperimentMethod = + getUpdateExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.Experiment + .getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("UpdateExperiment")) + .build(); + } + } + } + return getUpdateExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest, com.google.protobuf.Empty> + getDeleteExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteExperiment", + requestType = com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.class, + responseType = com.google.protobuf.Empty.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest, com.google.protobuf.Empty> + getDeleteExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest, + com.google.protobuf.Empty> + getDeleteExperimentMethod; + if ((getDeleteExperimentMethod = ExperimentsGrpc.getDeleteExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getDeleteExperimentMethod = ExperimentsGrpc.getDeleteExperimentMethod) == null) { + ExperimentsGrpc.getDeleteExperimentMethod = + getDeleteExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.protobuf.Empty.getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("DeleteExperiment")) + .build(); + } + } + } + return getDeleteExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getStartExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "StartExperiment", + requestType = com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getStartExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getStartExperimentMethod; + if ((getStartExperimentMethod = ExperimentsGrpc.getStartExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getStartExperimentMethod = ExperimentsGrpc.getStartExperimentMethod) == null) { + ExperimentsGrpc.getStartExperimentMethod = + getStartExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "StartExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.Experiment + .getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("StartExperiment")) + .build(); + } + } + } + return getStartExperimentMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getStopExperimentMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "StopExperiment", + requestType = com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getStopExperimentMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getStopExperimentMethod; + if ((getStopExperimentMethod = ExperimentsGrpc.getStopExperimentMethod) == null) { + synchronized (ExperimentsGrpc.class) { + if ((getStopExperimentMethod = ExperimentsGrpc.getStopExperimentMethod) == null) { + ExperimentsGrpc.getStopExperimentMethod = + getStopExperimentMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "StopExperiment")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.Experiment + .getDefaultInstance())) + .setSchemaDescriptor( + new ExperimentsMethodDescriptorSupplier("StopExperiment")) + .build(); + } + } + } + return getStopExperimentMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static ExperimentsStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public ExperimentsStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsStub(channel, callOptions); + } + }; + return ExperimentsStub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static ExperimentsBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public ExperimentsBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsBlockingStub(channel, callOptions); + } + }; + return ExperimentsBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static ExperimentsFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public ExperimentsFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsFutureStub(channel, callOptions); + } + }; + return ExperimentsFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment].
+   * 
+ */ + public abstract static class ExperimentsImplBase implements io.grpc.BindableService { + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public void listExperiments( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getListExperimentsMethod(), responseObserver); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public void getExperiment( + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getGetExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public void createExperiment( + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getCreateExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public void updateExperiment( + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getUpdateExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public void deleteExperiment( + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getDeleteExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public void startExperiment( + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getStartExperimentMethod(), responseObserver); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public void stopExperiment( + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getStopExperimentMethod(), responseObserver); + } + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getListExperimentsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse>( + this, METHODID_LIST_EXPERIMENTS))) + .addMethod( + getGetExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment>( + this, METHODID_GET_EXPERIMENT))) + .addMethod( + getCreateExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment>( + this, METHODID_CREATE_EXPERIMENT))) + .addMethod( + getUpdateExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment>( + this, METHODID_UPDATE_EXPERIMENT))) + .addMethod( + getDeleteExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest, + com.google.protobuf.Empty>(this, METHODID_DELETE_EXPERIMENT))) + .addMethod( + getStartExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment>( + this, METHODID_START_EXPERIMENT))) + .addMethod( + getStopExperimentMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest, + com.google.cloud.dialogflow.cx.v3beta1.Experiment>( + this, METHODID_STOP_EXPERIMENT))) + .build(); + } + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment].
+   * 
+ */ + public static final class ExperimentsStub + extends io.grpc.stub.AbstractAsyncStub { + private ExperimentsStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected ExperimentsStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public void listExperiments( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getListExperimentsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public void getExperiment( + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getGetExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public void createExperiment( + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getCreateExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public void updateExperiment( + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getUpdateExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public void deleteExperiment( + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnaryCall( + getChannel().newCall(getDeleteExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public void startExperiment( + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getStartExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public void stopExperiment( + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getStopExperimentMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment].
+   * 
+ */ + public static final class ExperimentsBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private ExperimentsBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected ExperimentsBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse listExperiments( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest request) { + return blockingUnaryCall(getChannel(), getListExperimentsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment( + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest request) { + return blockingUnaryCall(getChannel(), getGetExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment createExperiment( + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest request) { + return blockingUnaryCall( + getChannel(), getCreateExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment updateExperiment( + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public com.google.protobuf.Empty deleteExperiment( + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest request) { + return blockingUnaryCall( + getChannel(), getDeleteExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment startExperiment( + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest request) { + return blockingUnaryCall(getChannel(), getStartExperimentMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment stopExperiment( + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest request) { + return blockingUnaryCall(getChannel(), getStopExperimentMethod(), getCallOptions(), request); + } + } + + /** + * + * + *
+   * Service for managing [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment].
+   * 
+ */ + public static final class ExperimentsFutureStub + extends io.grpc.stub.AbstractFutureStub { + private ExperimentsFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected ExperimentsFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new ExperimentsFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse> + listExperiments(com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest request) { + return futureUnaryCall( + getChannel().newCall(getListExperimentsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + getExperiment(com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getGetExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + createExperiment(com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getCreateExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + updateExperiment(com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getUpdateExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteExperiment(com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getDeleteExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from PENDING to RUNNING.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + startExperiment(com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getStartExperimentMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of
+     * experiment from RUNNING to DONE.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.Experiment> + stopExperiment(com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest request) { + return futureUnaryCall( + getChannel().newCall(getStopExperimentMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_LIST_EXPERIMENTS = 0; + private static final int METHODID_GET_EXPERIMENT = 1; + private static final int METHODID_CREATE_EXPERIMENT = 2; + private static final int METHODID_UPDATE_EXPERIMENT = 3; + private static final int METHODID_DELETE_EXPERIMENT = 4; + private static final int METHODID_START_EXPERIMENT = 5; + private static final int METHODID_STOP_EXPERIMENT = 6; + + 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 ExperimentsImplBase serviceImpl; + private final int methodId; + + MethodHandlers(ExperimentsImplBase serviceImpl, int methodId) { + this.serviceImpl = serviceImpl; + this.methodId = methodId; + } + + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") + public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { + switch (methodId) { + case METHODID_LIST_EXPERIMENTS: + serviceImpl.listExperiments( + (com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse>) + responseObserver); + break; + case METHODID_GET_EXPERIMENT: + serviceImpl.getExperiment( + (com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_CREATE_EXPERIMENT: + serviceImpl.createExperiment( + (com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_EXPERIMENT: + serviceImpl.updateExperiment( + (com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_DELETE_EXPERIMENT: + serviceImpl.deleteExperiment( + (com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); + break; + case METHODID_START_EXPERIMENT: + serviceImpl.startExperiment( + (com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_STOP_EXPERIMENT: + serviceImpl.stopExperiment( + (com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) 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(); + } + } + } + + private abstract static class ExperimentsBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + ExperimentsBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("Experiments"); + } + } + + private static final class ExperimentsFileDescriptorSupplier + extends ExperimentsBaseDescriptorSupplier { + ExperimentsFileDescriptorSupplier() {} + } + + private static final class ExperimentsMethodDescriptorSupplier + extends ExperimentsBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final String methodName; + + ExperimentsMethodDescriptorSupplier(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 (ExperimentsGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new ExperimentsFileDescriptorSupplier()) + .addMethod(getListExperimentsMethod()) + .addMethod(getGetExperimentMethod()) + .addMethod(getCreateExperimentMethod()) + .addMethod(getUpdateExperimentMethod()) + .addMethod(getDeleteExperimentMethod()) + .addMethod(getStartExperimentMethod()) + .addMethod(getStopExperimentMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceGrpc.java b/grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceGrpc.java new file mode 100644 index 000000000..bd45742af --- /dev/null +++ b/grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceGrpc.java @@ -0,0 +1,884 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package com.google.cloud.dialogflow.cx.v3beta1; + +import static io.grpc.MethodDescriptor.generateFullMethodName; +import static io.grpc.stub.ClientCalls.asyncUnaryCall; +import static io.grpc.stub.ClientCalls.blockingUnaryCall; +import static io.grpc.stub.ClientCalls.futureUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnaryCall; +import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; + +/** + * + * + *
+ * Service for managing security settings for Dialogflow.
+ * 
+ */ +@javax.annotation.Generated( + value = "by gRPC proto compiler", + comments = "Source: google/cloud/dialogflow/cx/v3beta1/security_settings.proto") +public final class SecuritySettingsServiceGrpc { + + private SecuritySettingsServiceGrpc() {} + + public static final String SERVICE_NAME = + "google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService"; + + // Static method descriptors that strictly reflect the proto. + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getCreateSecuritySettingsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "CreateSecuritySettings", + requestType = com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getCreateSecuritySettingsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getCreateSecuritySettingsMethod; + if ((getCreateSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getCreateSecuritySettingsMethod) + == null) { + synchronized (SecuritySettingsServiceGrpc.class) { + if ((getCreateSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getCreateSecuritySettingsMethod) + == null) { + SecuritySettingsServiceGrpc.getCreateSecuritySettingsMethod = + getCreateSecuritySettingsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "CreateSecuritySettings")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings + .getDefaultInstance())) + .setSchemaDescriptor( + new SecuritySettingsServiceMethodDescriptorSupplier( + "CreateSecuritySettings")) + .build(); + } + } + } + return getCreateSecuritySettingsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getGetSecuritySettingsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetSecuritySettings", + requestType = com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getGetSecuritySettingsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getGetSecuritySettingsMethod; + if ((getGetSecuritySettingsMethod = SecuritySettingsServiceGrpc.getGetSecuritySettingsMethod) + == null) { + synchronized (SecuritySettingsServiceGrpc.class) { + if ((getGetSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getGetSecuritySettingsMethod) + == null) { + SecuritySettingsServiceGrpc.getGetSecuritySettingsMethod = + getGetSecuritySettingsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "GetSecuritySettings")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings + .getDefaultInstance())) + .setSchemaDescriptor( + new SecuritySettingsServiceMethodDescriptorSupplier( + "GetSecuritySettings")) + .build(); + } + } + } + return getGetSecuritySettingsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getUpdateSecuritySettingsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "UpdateSecuritySettings", + requestType = com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getUpdateSecuritySettingsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getUpdateSecuritySettingsMethod; + if ((getUpdateSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getUpdateSecuritySettingsMethod) + == null) { + synchronized (SecuritySettingsServiceGrpc.class) { + if ((getUpdateSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getUpdateSecuritySettingsMethod) + == null) { + SecuritySettingsServiceGrpc.getUpdateSecuritySettingsMethod = + getUpdateSecuritySettingsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "UpdateSecuritySettings")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings + .getDefaultInstance())) + .setSchemaDescriptor( + new SecuritySettingsServiceMethodDescriptorSupplier( + "UpdateSecuritySettings")) + .build(); + } + } + } + return getUpdateSecuritySettingsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse> + getListSecuritySettingsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "ListSecuritySettings", + requestType = com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest.class, + responseType = com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse> + getListSecuritySettingsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse> + getListSecuritySettingsMethod; + if ((getListSecuritySettingsMethod = SecuritySettingsServiceGrpc.getListSecuritySettingsMethod) + == null) { + synchronized (SecuritySettingsServiceGrpc.class) { + if ((getListSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getListSecuritySettingsMethod) + == null) { + SecuritySettingsServiceGrpc.getListSecuritySettingsMethod = + getListSecuritySettingsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "ListSecuritySettings")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + .getDefaultInstance())) + .setSchemaDescriptor( + new SecuritySettingsServiceMethodDescriptorSupplier( + "ListSecuritySettings")) + .build(); + } + } + } + return getListSecuritySettingsMethod; + } + + private static volatile io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest, + com.google.protobuf.Empty> + getDeleteSecuritySettingsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "DeleteSecuritySettings", + requestType = com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest.class, + responseType = com.google.protobuf.Empty.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest, + com.google.protobuf.Empty> + getDeleteSecuritySettingsMethod() { + io.grpc.MethodDescriptor< + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest, + com.google.protobuf.Empty> + getDeleteSecuritySettingsMethod; + if ((getDeleteSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getDeleteSecuritySettingsMethod) + == null) { + synchronized (SecuritySettingsServiceGrpc.class) { + if ((getDeleteSecuritySettingsMethod = + SecuritySettingsServiceGrpc.getDeleteSecuritySettingsMethod) + == null) { + SecuritySettingsServiceGrpc.getDeleteSecuritySettingsMethod = + getDeleteSecuritySettingsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName( + generateFullMethodName(SERVICE_NAME, "DeleteSecuritySettings")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + .getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.protobuf.Empty.getDefaultInstance())) + .setSchemaDescriptor( + new SecuritySettingsServiceMethodDescriptorSupplier( + "DeleteSecuritySettings")) + .build(); + } + } + } + return getDeleteSecuritySettingsMethod; + } + + /** Creates a new async stub that supports all call types for the service */ + public static SecuritySettingsServiceStub newStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecuritySettingsServiceStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecuritySettingsServiceStub(channel, callOptions); + } + }; + return SecuritySettingsServiceStub.newStub(factory, channel); + } + + /** + * Creates a new blocking-style stub that supports unary and streaming output calls on the service + */ + public static SecuritySettingsServiceBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecuritySettingsServiceBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecuritySettingsServiceBlockingStub(channel, callOptions); + } + }; + return SecuritySettingsServiceBlockingStub.newStub(factory, channel); + } + + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static SecuritySettingsServiceFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public SecuritySettingsServiceFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecuritySettingsServiceFutureStub(channel, callOptions); + } + }; + return SecuritySettingsServiceFutureStub.newStub(factory, channel); + } + + /** + * + * + *
+   * Service for managing security settings for Dialogflow.
+   * 
+ */ + public abstract static class SecuritySettingsServiceImplBase implements io.grpc.BindableService { + + /** + * + * + *
+     * Create security settings in the specified location.
+     * 
+ */ + public void createSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getCreateSecuritySettingsMethod(), responseObserver); + } + + /** + * + * + *
+     * Retrieves the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * The returned settings may be stale by up to 1 minute.
+     * 
+ */ + public void getSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getGetSecuritySettingsMethod(), responseObserver); + } + + /** + * + * + *
+     * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public void updateSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getUpdateSecuritySettingsMethod(), responseObserver); + } + + /** + * + * + *
+     * Returns the list of all security settings in the specified location.
+     * 
+ */ + public void listSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse> + responseObserver) { + asyncUnimplementedUnaryCall(getListSecuritySettingsMethod(), responseObserver); + } + + /** + * + * + *
+     * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public void deleteSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getDeleteSecuritySettingsMethod(), responseObserver); + } + + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { + return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) + .addMethod( + getCreateSecuritySettingsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings>( + this, METHODID_CREATE_SECURITY_SETTINGS))) + .addMethod( + getGetSecuritySettingsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings>( + this, METHODID_GET_SECURITY_SETTINGS))) + .addMethod( + getUpdateSecuritySettingsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings>( + this, METHODID_UPDATE_SECURITY_SETTINGS))) + .addMethod( + getListSecuritySettingsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse>( + this, METHODID_LIST_SECURITY_SETTINGS))) + .addMethod( + getDeleteSecuritySettingsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest, + com.google.protobuf.Empty>(this, METHODID_DELETE_SECURITY_SETTINGS))) + .build(); + } + } + + /** + * + * + *
+   * Service for managing security settings for Dialogflow.
+   * 
+ */ + public static final class SecuritySettingsServiceStub + extends io.grpc.stub.AbstractAsyncStub { + private SecuritySettingsServiceStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecuritySettingsServiceStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecuritySettingsServiceStub(channel, callOptions); + } + + /** + * + * + *
+     * Create security settings in the specified location.
+     * 
+ */ + public void createSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getCreateSecuritySettingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Retrieves the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * The returned settings may be stale by up to 1 minute.
+     * 
+ */ + public void getSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getGetSecuritySettingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public void updateSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getUpdateSecuritySettingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Returns the list of all security settings in the specified location.
+     * 
+ */ + public void listSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest request, + io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse> + responseObserver) { + asyncUnaryCall( + getChannel().newCall(getListSecuritySettingsMethod(), getCallOptions()), + request, + responseObserver); + } + + /** + * + * + *
+     * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public void deleteSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnaryCall( + getChannel().newCall(getDeleteSecuritySettingsMethod(), getCallOptions()), + request, + responseObserver); + } + } + + /** + * + * + *
+   * Service for managing security settings for Dialogflow.
+   * 
+ */ + public static final class SecuritySettingsServiceBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private SecuritySettingsServiceBlockingStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecuritySettingsServiceBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecuritySettingsServiceBlockingStub(channel, callOptions); + } + + /** + * + * + *
+     * Create security settings in the specified location.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings createSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest request) { + return blockingUnaryCall( + getChannel(), getCreateSecuritySettingsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Retrieves the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * The returned settings may be stale by up to 1 minute.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest request) { + return blockingUnaryCall( + getChannel(), getGetSecuritySettingsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings updateSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest request) { + return blockingUnaryCall( + getChannel(), getUpdateSecuritySettingsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Returns the list of all security settings in the specified location.
+     * 
+ */ + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse listSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest request) { + return blockingUnaryCall( + getChannel(), getListSecuritySettingsMethod(), getCallOptions(), request); + } + + /** + * + * + *
+     * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public com.google.protobuf.Empty deleteSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest request) { + return blockingUnaryCall( + getChannel(), getDeleteSecuritySettingsMethod(), getCallOptions(), request); + } + } + + /** + * + * + *
+   * Service for managing security settings for Dialogflow.
+   * 
+ */ + public static final class SecuritySettingsServiceFutureStub + extends io.grpc.stub.AbstractFutureStub { + private SecuritySettingsServiceFutureStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + super(channel, callOptions); + } + + @java.lang.Override + protected SecuritySettingsServiceFutureStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new SecuritySettingsServiceFutureStub(channel, callOptions); + } + + /** + * + * + *
+     * Create security settings in the specified location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + createSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest request) { + return futureUnaryCall( + getChannel().newCall(getCreateSecuritySettingsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Retrieves the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * The returned settings may be stale by up to 1 minute.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + getSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest request) { + return futureUnaryCall( + getChannel().newCall(getGetSecuritySettingsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings> + updateSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest request) { + return futureUnaryCall( + getChannel().newCall(getUpdateSecuritySettingsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Returns the list of all security settings in the specified location.
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse> + listSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest request) { + return futureUnaryCall( + getChannel().newCall(getListSecuritySettingsMethod(), getCallOptions()), request); + } + + /** + * + * + *
+     * Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings].
+     * 
+ */ + public com.google.common.util.concurrent.ListenableFuture + deleteSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest request) { + return futureUnaryCall( + getChannel().newCall(getDeleteSecuritySettingsMethod(), getCallOptions()), request); + } + } + + private static final int METHODID_CREATE_SECURITY_SETTINGS = 0; + private static final int METHODID_GET_SECURITY_SETTINGS = 1; + private static final int METHODID_UPDATE_SECURITY_SETTINGS = 2; + private static final int METHODID_LIST_SECURITY_SETTINGS = 3; + private static final int METHODID_DELETE_SECURITY_SETTINGS = 4; + + 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 SecuritySettingsServiceImplBase serviceImpl; + private final int methodId; + + MethodHandlers(SecuritySettingsServiceImplBase 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_SECURITY_SETTINGS: + serviceImpl.createSecuritySettings( + (com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_GET_SECURITY_SETTINGS: + serviceImpl.getSecuritySettings( + (com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_UPDATE_SECURITY_SETTINGS: + serviceImpl.updateSecuritySettings( + (com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); + break; + case METHODID_LIST_SECURITY_SETTINGS: + serviceImpl.listSecuritySettings( + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) request, + (io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse>) + responseObserver); + break; + case METHODID_DELETE_SECURITY_SETTINGS: + serviceImpl.deleteSecuritySettings( + (com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) 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(); + } + } + } + + private abstract static class SecuritySettingsServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { + SecuritySettingsServiceBaseDescriptorSupplier() {} + + @java.lang.Override + public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto.getDescriptor(); + } + + @java.lang.Override + public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { + return getFileDescriptor().findServiceByName("SecuritySettingsService"); + } + } + + private static final class SecuritySettingsServiceFileDescriptorSupplier + extends SecuritySettingsServiceBaseDescriptorSupplier { + SecuritySettingsServiceFileDescriptorSupplier() {} + } + + private static final class SecuritySettingsServiceMethodDescriptorSupplier + extends SecuritySettingsServiceBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { + private final String methodName; + + SecuritySettingsServiceMethodDescriptorSupplier(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 (SecuritySettingsServiceGrpc.class) { + result = serviceDescriptor; + if (result == null) { + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new SecuritySettingsServiceFileDescriptorSupplier()) + .addMethod(getCreateSecuritySettingsMethod()) + .addMethod(getGetSecuritySettingsMethod()) + .addMethod(getUpdateSecuritySettingsMethod()) + .addMethod(getListSecuritySettingsMethod()) + .addMethod(getDeleteSecuritySettingsMethod()) + .build(); + } + } + } + return result; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequest.java new file mode 100644 index 000000000..5a4f5cc03 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequest.java @@ -0,0 +1,967 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.CreateExperiment][google.cloud.dialogflow.cx.v3.Experiments.CreateExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.CreateExperimentRequest} + */ +public final class CreateExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.CreateExperimentRequest) + CreateExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use CreateExperimentRequest.newBuilder() to construct. + private CreateExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateExperimentRequest() { + parent_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private CreateExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 18: + { + com.google.cloud.dialogflow.cx.v3.Experiment.Builder subBuilder = null; + if (experiment_ != null) { + subBuilder = experiment_.toBuilder(); + } + experiment_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(experiment_); + experiment_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 EXPERIMENT_FIELD_NUMBER = 2; + private com.google.cloud.dialogflow.cx.v3.Experiment experiment_; + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + @java.lang.Override + public boolean hasExperiment() { + return experiment_ != null; + } + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiment() { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance() + : experiment_; + } + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentOrBuilder() { + return getExperiment(); + } + + 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 (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (experiment_ != null) { + output.writeMessage(2, getExperiment()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (experiment_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getExperiment()); + } + size += unknownFields.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.dialogflow.cx.v3.CreateExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasExperiment() != other.hasExperiment()) return false; + if (hasExperiment()) { + if (!getExperiment().equals(other.getExperiment())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasExperiment()) { + hash = (37 * hash) + EXPERIMENT_FIELD_NUMBER; + hash = (53 * hash) + getExperiment().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest 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.dialogflow.cx.v3.CreateExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest 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.dialogflow.cx.v3.CreateExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest 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.dialogflow.cx.v3.CreateExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest 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.dialogflow.cx.v3.CreateExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest 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.dialogflow.cx.v3.CreateExperimentRequest 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 request message for [Experiments.CreateExperiment][google.cloud.dialogflow.cx.v3.Experiments.CreateExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.CreateExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.CreateExperimentRequest) + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + if (experimentBuilder_ == null) { + experiment_ = null; + } else { + experiment_ = null; + experimentBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest(this); + result.parent_ = parent_; + if (experimentBuilder_ == null) { + result.experiment_ = experiment_; + } else { + result.experiment_ = experimentBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.CreateExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.hasExperiment()) { + mergeExperiment(other.getExperiment()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + + private com.google.cloud.dialogflow.cx.v3.Experiment experiment_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder> + experimentBuilder_; + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + public boolean hasExperiment() { + return experimentBuilder_ != null || experiment_ != null; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiment() { + if (experimentBuilder_ == null) { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance() + : experiment_; + } else { + return experimentBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment(com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + experiment_ = value; + onChanged(); + } else { + experimentBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment( + com.google.cloud.dialogflow.cx.v3.Experiment.Builder builderForValue) { + if (experimentBuilder_ == null) { + experiment_ = builderForValue.build(); + onChanged(); + } else { + experimentBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeExperiment(com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentBuilder_ == null) { + if (experiment_ != null) { + experiment_ = + com.google.cloud.dialogflow.cx.v3.Experiment.newBuilder(experiment_) + .mergeFrom(value) + .buildPartial(); + } else { + experiment_ = value; + } + onChanged(); + } else { + experimentBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearExperiment() { + if (experimentBuilder_ == null) { + experiment_ = null; + onChanged(); + } else { + experiment_ = null; + experimentBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Builder getExperimentBuilder() { + + onChanged(); + return getExperimentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentOrBuilder() { + if (experimentBuilder_ != null) { + return experimentBuilder_.getMessageOrBuilder(); + } else { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance() + : experiment_; + } + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder> + getExperimentFieldBuilder() { + if (experimentBuilder_ == null) { + experimentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder>( + getExperiment(), getParentForChildren(), isClean()); + experiment_ = null; + } + return experimentBuilder_; + } + + @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.dialogflow.cx.v3.CreateExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.CreateExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.CreateExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new CreateExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.CreateExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequestOrBuilder.java new file mode 100644 index 000000000..4c293ace0 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequestOrBuilder.java @@ -0,0 +1,99 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface CreateExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.CreateExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + boolean hasExperiment(); + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + com.google.cloud.dialogflow.cx.v3.Experiment getExperiment(); + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentOrBuilder(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequest.java new file mode 100644 index 000000000..453bc158a --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequest.java @@ -0,0 +1,665 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.DeleteExperiment][google.cloud.dialogflow.cx.v3.Experiments.DeleteExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.DeleteExperimentRequest} + */ +public final class DeleteExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) + DeleteExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use DeleteExperimentRequest.newBuilder() to construct. + private DeleteExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DeleteExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3.DeleteExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest 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.dialogflow.cx.v3.DeleteExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest 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.dialogflow.cx.v3.DeleteExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest 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.dialogflow.cx.v3.DeleteExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest 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.dialogflow.cx.v3.DeleteExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest 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.dialogflow.cx.v3.DeleteExperimentRequest 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 request message for [Experiments.DeleteExperiment][google.cloud.dialogflow.cx.v3.Experiments.DeleteExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.DeleteExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.DeleteExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3.DeleteExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.DeleteExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DeleteExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.DeleteExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequestOrBuilder.java new file mode 100644 index 000000000..e4f3d2f3a --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface DeleteExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.DeleteExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequest.java index c75899910..1d9119871 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequest.java @@ -178,6 +178,9 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -213,6 +216,9 @@ public java.lang.String getSession() { * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -804,6 +810,9 @@ public Builder mergeFrom( * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -838,6 +847,9 @@ public java.lang.String getSession() { * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -872,6 +884,9 @@ public com.google.protobuf.ByteString getSessionBytes() { * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -905,6 +920,9 @@ public Builder setSession(java.lang.String value) { * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -934,6 +952,9 @@ public Builder clearSession() { * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequestOrBuilder.java index 4285e4825..7a46a29bc 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequestOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DetectIntentRequestOrBuilder.java @@ -38,6 +38,9 @@ public interface DetectIntentRequestOrBuilder * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * @@ -62,6 +65,9 @@ public interface DetectIntentRequestOrBuilder * The length of the `Session ID` must not exceed 36 characters. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Experiment.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Experiment.java new file mode 100644 index 000000000..9f2d6f7cc --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Experiment.java @@ -0,0 +1,10084 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * Represents an experiment in an environment.
+ * Next ID: 13
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment} + */ +public final class Experiment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.Experiment) + ExperimentOrBuilder { + private static final long serialVersionUID = 0L; + // Use Experiment.newBuilder() to construct. + private Experiment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Experiment() { + name_ = ""; + displayName_ = ""; + description_ = ""; + state_ = 0; + variantsHistory_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Experiment(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Experiment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + displayName_ = s; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + description_ = s; + break; + } + case 32: + { + int rawValue = input.readEnum(); + + state_ = rawValue; + break; + } + case 42: + { + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder subBuilder = null; + if (definition_ != null) { + subBuilder = definition_.toBuilder(); + } + definition_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(definition_); + definition_ = subBuilder.buildPartial(); + } + + break; + } + case 50: + { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder subBuilder = null; + if (result_ != null) { + subBuilder = result_.toBuilder(); + } + result_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(result_); + result_ = subBuilder.buildPartial(); + } + + break; + } + case 58: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 66: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (startTime_ != null) { + subBuilder = startTime_.toBuilder(); + } + startTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(startTime_); + startTime_ = subBuilder.buildPartial(); + } + + break; + } + case 74: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (endTime_ != null) { + subBuilder = endTime_.toBuilder(); + } + endTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(endTime_); + endTime_ = subBuilder.buildPartial(); + } + + break; + } + case 82: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (lastUpdateTime_ != null) { + subBuilder = lastUpdateTime_.toBuilder(); + } + lastUpdateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(lastUpdateTime_); + lastUpdateTime_ = subBuilder.buildPartial(); + } + + break; + } + case 90: + { + com.google.protobuf.Duration.Builder subBuilder = null; + if (experimentLength_ != null) { + subBuilder = experimentLength_.toBuilder(); + } + experimentLength_ = + input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(experimentLength_); + experimentLength_ = subBuilder.buildPartial(); + } + + break; + } + case 98: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + variantsHistory_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3.VariantsHistory.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = java.util.Collections.unmodifiableList(variantsHistory_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder.class); + } + + /** + * + * + *
+   * The state of the experiment.
+   * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3.Experiment.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * State unspecified.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The experiment is created but not started yet.
+     * 
+ * + * DRAFT = 1; + */ + DRAFT(1), + /** + * + * + *
+     * The experiment is running.
+     * 
+ * + * RUNNING = 2; + */ + RUNNING(2), + /** + * + * + *
+     * The experiment is done.
+     * 
+ * + * DONE = 3; + */ + DONE(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * State unspecified.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * The experiment is created but not started yet.
+     * 
+ * + * DRAFT = 1; + */ + public static final int DRAFT_VALUE = 1; + /** + * + * + *
+     * The experiment is running.
+     * 
+ * + * RUNNING = 2; + */ + public static final int RUNNING_VALUE = 2; + /** + * + * + *
+     * The experiment is done.
+     * 
+ * + * DONE = 3; + */ + public static final int DONE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return DRAFT; + case 2: + return RUNNING; + case 3: + return DONE; + 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.dialogflow.cx.v3.Experiment.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.dialogflow.cx.v3.Experiment.State) + } + + public interface DefinitionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.Experiment.Definition) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The condition. + */ + java.lang.String getCondition(); + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The bytes for condition. + */ + com.google.protobuf.ByteString getConditionBytes(); + + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + * + * @return Whether the versionVariants field is set. + */ + boolean hasVersionVariants(); + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + * + * @return The versionVariants. + */ + com.google.cloud.dialogflow.cx.v3.VersionVariants getVersionVariants(); + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder getVersionVariantsOrBuilder(); + + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition.VariantsCase getVariantsCase(); + } + /** + * + * + *
+   * Definition of the experiment.
+   * Next ID: 3
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Definition} + */ + public static final class Definition extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.Experiment.Definition) + DefinitionOrBuilder { + private static final long serialVersionUID = 0L; + // Use Definition.newBuilder() to construct. + private Definition(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Definition() { + condition_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Definition(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Definition( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + condition_ = s; + break; + } + case 18: + { + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder subBuilder = null; + if (variantsCase_ == 2) { + subBuilder = + ((com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_).toBuilder(); + } + variants_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.VersionVariants.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_); + variants_ = subBuilder.buildPartial(); + } + variantsCase_ = 2; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder.class); + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public enum VariantsCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + VERSION_VARIANTS(2), + VARIANTS_NOT_SET(0); + private final int value; + + private VariantsCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static VariantsCase valueOf(int value) { + return forNumber(value); + } + + public static VariantsCase forNumber(int value) { + switch (value) { + case 2: + return VERSION_VARIANTS; + case 0: + return VARIANTS_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public static final int CONDITION_FIELD_NUMBER = 1; + private volatile java.lang.Object condition_; + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The condition. + */ + @java.lang.Override + public java.lang.String getCondition() { + java.lang.Object ref = condition_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + condition_ = s; + return s; + } + } + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The bytes for condition. + */ + @java.lang.Override + public com.google.protobuf.ByteString getConditionBytes() { + java.lang.Object ref = condition_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + condition_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VERSION_VARIANTS_FIELD_NUMBER = 2; + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 2; + } + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants getVersionVariants() { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getConditionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, condition_); + } + if (variantsCase_ == 2) { + output.writeMessage(2, (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getConditionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, condition_); + } + if (variantsCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_); + } + size += unknownFields.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.dialogflow.cx.v3.Experiment.Definition)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.Experiment.Definition other = + (com.google.cloud.dialogflow.cx.v3.Experiment.Definition) obj; + + if (!getCondition().equals(other.getCondition())) return false; + if (!getVariantsCase().equals(other.getVariantsCase())) return false; + switch (variantsCase_) { + case 2: + if (!getVersionVariants().equals(other.getVersionVariants())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + CONDITION_FIELD_NUMBER; + hash = (53 * hash) + getCondition().hashCode(); + switch (variantsCase_) { + case 2: + hash = (37 * hash) + VERSION_VARIANTS_FIELD_NUMBER; + hash = (53 * hash) + getVersionVariants().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition 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.dialogflow.cx.v3.Experiment.Definition parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition 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.dialogflow.cx.v3.Experiment.Definition parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition 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.dialogflow.cx.v3.Experiment.Definition parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition 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.dialogflow.cx.v3.Experiment.Definition parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition 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.dialogflow.cx.v3.Experiment.Definition 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; + } + /** + * + * + *
+     * Definition of the experiment.
+     * Next ID: 3
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Definition} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.Experiment.Definition) + com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.Experiment.Definition.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + condition_ = ""; + + variantsCase_ = 0; + variants_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.Experiment.Definition.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition build() { + com.google.cloud.dialogflow.cx.v3.Experiment.Definition result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition buildPartial() { + com.google.cloud.dialogflow.cx.v3.Experiment.Definition result = + new com.google.cloud.dialogflow.cx.v3.Experiment.Definition(this); + result.condition_ = condition_; + if (variantsCase_ == 2) { + if (versionVariantsBuilder_ == null) { + result.variants_ = variants_; + } else { + result.variants_ = versionVariantsBuilder_.build(); + } + } + result.variantsCase_ = variantsCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.Experiment.Definition) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.Experiment.Definition) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.Experiment.Definition other) { + if (other == com.google.cloud.dialogflow.cx.v3.Experiment.Definition.getDefaultInstance()) + return this; + if (!other.getCondition().isEmpty()) { + condition_ = other.condition_; + onChanged(); + } + switch (other.getVariantsCase()) { + case VERSION_VARIANTS: + { + mergeVersionVariants(other.getVersionVariants()); + break; + } + case VARIANTS_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.Experiment.Definition parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.Experiment.Definition) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public Builder clearVariants() { + variantsCase_ = 0; + variants_ = null; + onChanged(); + return this; + } + + private java.lang.Object condition_ = ""; + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @return The condition. + */ + public java.lang.String getCondition() { + java.lang.Object ref = condition_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + condition_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @return The bytes for condition. + */ + public com.google.protobuf.ByteString getConditionBytes() { + java.lang.Object ref = condition_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + condition_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @param value The condition to set. + * @return This builder for chaining. + */ + public Builder setCondition(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + condition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @return This builder for chaining. + */ + public Builder clearCondition() { + + condition_ = getDefaultInstance().getCondition(); + onChanged(); + return this; + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @param value The bytes for condition to set. + * @return This builder for chaining. + */ + public Builder setConditionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + condition_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder> + versionVariantsBuilder_; + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 2; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants getVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } else { + if (variantsCase_ == 2) { + return versionVariantsBuilder_.getMessage(); + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + public Builder setVersionVariants(com.google.cloud.dialogflow.cx.v3.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + variants_ = value; + onChanged(); + } else { + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 2; + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + public Builder setVersionVariants( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder builderForValue) { + if (versionVariantsBuilder_ == null) { + variants_ = builderForValue.build(); + onChanged(); + } else { + versionVariantsBuilder_.setMessage(builderForValue.build()); + } + variantsCase_ = 2; + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + public Builder mergeVersionVariants(com.google.cloud.dialogflow.cx.v3.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 2 + && variants_ + != com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance()) { + variants_ = + com.google.cloud.dialogflow.cx.v3.VersionVariants.newBuilder( + (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_) + .mergeFrom(value) + .buildPartial(); + } else { + variants_ = value; + } + onChanged(); + } else { + if (variantsCase_ == 2) { + versionVariantsBuilder_.mergeFrom(value); + } + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 2; + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + public Builder clearVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 2) { + variantsCase_ = 0; + variants_ = null; + onChanged(); + } + } else { + if (variantsCase_ == 2) { + variantsCase_ = 0; + variants_ = null; + } + versionVariantsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder getVersionVariantsBuilder() { + return getVersionVariantsFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if ((variantsCase_ == 2) && (versionVariantsBuilder_ != null)) { + return versionVariantsBuilder_.getMessageOrBuilder(); + } else { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder> + getVersionVariantsFieldBuilder() { + if (versionVariantsBuilder_ == null) { + if (!(variantsCase_ == 2)) { + variants_ = com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + versionVariantsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder>( + (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_, + getParentForChildren(), + isClean()); + variants_ = null; + } + variantsCase_ = 2; + onChanged(); + ; + return versionVariantsBuilder_; + } + + @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.dialogflow.cx.v3.Experiment.Definition) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.Experiment.Definition) + private static final com.google.cloud.dialogflow.cx.v3.Experiment.Definition DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.Experiment.Definition(); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Definition getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Definition parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Definition(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.Experiment.Definition getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ResultOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.Experiment.Result) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + java.util.List + getVersionMetricsList(); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics getVersionMetrics(int index); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + int getVersionMetricsCount(); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsOrBuilderList(); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder + getVersionMetricsOrBuilder(int index); + + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return Whether the lastUpdateTime field is set. + */ + boolean hasLastUpdateTime(); + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return The lastUpdateTime. + */ + com.google.protobuf.Timestamp getLastUpdateTime(); + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder(); + } + /** + * + * + *
+   * The inference result which includes an objective metric to optimize and the
+   * confidence interval.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result} + */ + public static final class Result extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.Experiment.Result) + ResultOrBuilder { + private static final long serialVersionUID = 0L; + // Use Result.newBuilder() to construct. + private Result(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Result() { + versionMetrics_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Result(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Result( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics>(); + mutable_bitField0_ |= 0x00000001; + } + versionMetrics_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.parser(), + extensionRegistry)); + break; + } + case 18: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (lastUpdateTime_ != null) { + subBuilder = lastUpdateTime_.toBuilder(); + } + lastUpdateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(lastUpdateTime_); + lastUpdateTime_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = java.util.Collections.unmodifiableList(versionMetrics_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder.class); + } + + /** + * + * + *
+     * Types of metric for Dialogflow experiment.
+     * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType} + */ + public enum MetricType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Metric unspecified.
+       * 
+ * + * METRIC_UNSPECIFIED = 0; + */ + METRIC_UNSPECIFIED(0), + /** + * + * + *
+       * Percentage of contained sessions without user calling back in 24 hours.
+       * 
+ * + * CONTAINED_SESSION_NO_CALLBACK_RATE = 1; + */ + CONTAINED_SESSION_NO_CALLBACK_RATE(1), + /** + * + * + *
+       * Percentage of sessions that were handed to a human agent.
+       * 
+ * + * LIVE_AGENT_HANDOFF_RATE = 2; + */ + LIVE_AGENT_HANDOFF_RATE(2), + /** + * + * + *
+       * Percentage of sessions with the same user calling back.
+       * 
+ * + * CALLBACK_SESSION_RATE = 3; + */ + CALLBACK_SESSION_RATE(3), + /** + * + * + *
+       * Percentage of sessions where user hung up.
+       * 
+ * + * ABANDONED_SESSION_RATE = 4; + */ + ABANDONED_SESSION_RATE(4), + /** + * + * + *
+       * Percentage of sessions reached Dialogflow 'END_PAGE' or
+       * 'END_SESSION'.
+       * 
+ * + * SESSION_END_RATE = 5; + */ + SESSION_END_RATE(5), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Metric unspecified.
+       * 
+ * + * METRIC_UNSPECIFIED = 0; + */ + public static final int METRIC_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Percentage of contained sessions without user calling back in 24 hours.
+       * 
+ * + * CONTAINED_SESSION_NO_CALLBACK_RATE = 1; + */ + public static final int CONTAINED_SESSION_NO_CALLBACK_RATE_VALUE = 1; + /** + * + * + *
+       * Percentage of sessions that were handed to a human agent.
+       * 
+ * + * LIVE_AGENT_HANDOFF_RATE = 2; + */ + public static final int LIVE_AGENT_HANDOFF_RATE_VALUE = 2; + /** + * + * + *
+       * Percentage of sessions with the same user calling back.
+       * 
+ * + * CALLBACK_SESSION_RATE = 3; + */ + public static final int CALLBACK_SESSION_RATE_VALUE = 3; + /** + * + * + *
+       * Percentage of sessions where user hung up.
+       * 
+ * + * ABANDONED_SESSION_RATE = 4; + */ + public static final int ABANDONED_SESSION_RATE_VALUE = 4; + /** + * + * + *
+       * Percentage of sessions reached Dialogflow 'END_PAGE' or
+       * 'END_SESSION'.
+       * 
+ * + * SESSION_END_RATE = 5; + */ + public static final int SESSION_END_RATE_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static MetricType 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 MetricType forNumber(int value) { + switch (value) { + case 0: + return METRIC_UNSPECIFIED; + case 1: + return CONTAINED_SESSION_NO_CALLBACK_RATE; + case 2: + return LIVE_AGENT_HANDOFF_RATE; + case 3: + return CALLBACK_SESSION_RATE; + case 4: + return ABANDONED_SESSION_RATE; + case 5: + return SESSION_END_RATE; + 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 MetricType findValueByNumber(int number) { + return MetricType.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.dialogflow.cx.v3.Experiment.Result.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final MetricType[] VALUES = values(); + + public static MetricType 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 MetricType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType) + } + + public interface ConfidenceIntervalOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The confidence level used to construct the interval, i.e. there is X%
+       * chance that the true value is within this interval.
+       * 
+ * + * double confidence_level = 1; + * + * @return The confidenceLevel. + */ + double getConfidenceLevel(); + + /** + * + * + *
+       * The percent change between an experiment metric's value and the value
+       * for its control.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + double getRatio(); + + /** + * + * + *
+       * Lower bound of the interval.
+       * 
+ * + * double lower_bound = 3; + * + * @return The lowerBound. + */ + double getLowerBound(); + + /** + * + * + *
+       * Upper bound of the interval.
+       * 
+ * + * double upper_bound = 4; + * + * @return The upperBound. + */ + double getUpperBound(); + } + /** + * + * + *
+     * A confidence interval is a range of possible values for the experiment
+     * objective you are trying to measure.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval} + */ + public static final class ConfidenceInterval extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) + ConfidenceIntervalOrBuilder { + private static final long serialVersionUID = 0L; + // Use ConfidenceInterval.newBuilder() to construct. + private ConfidenceInterval(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ConfidenceInterval() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ConfidenceInterval(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ConfidenceInterval( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 9: + { + confidenceLevel_ = input.readDouble(); + break; + } + case 17: + { + ratio_ = input.readDouble(); + break; + } + case 25: + { + lowerBound_ = input.readDouble(); + break; + } + case 33: + { + upperBound_ = input.readDouble(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder + .class); + } + + public static final int CONFIDENCE_LEVEL_FIELD_NUMBER = 1; + private double confidenceLevel_; + /** + * + * + *
+       * The confidence level used to construct the interval, i.e. there is X%
+       * chance that the true value is within this interval.
+       * 
+ * + * double confidence_level = 1; + * + * @return The confidenceLevel. + */ + @java.lang.Override + public double getConfidenceLevel() { + return confidenceLevel_; + } + + public static final int RATIO_FIELD_NUMBER = 2; + private double ratio_; + /** + * + * + *
+       * The percent change between an experiment metric's value and the value
+       * for its control.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + @java.lang.Override + public double getRatio() { + return ratio_; + } + + public static final int LOWER_BOUND_FIELD_NUMBER = 3; + private double lowerBound_; + /** + * + * + *
+       * Lower bound of the interval.
+       * 
+ * + * double lower_bound = 3; + * + * @return The lowerBound. + */ + @java.lang.Override + public double getLowerBound() { + return lowerBound_; + } + + public static final int UPPER_BOUND_FIELD_NUMBER = 4; + private double upperBound_; + /** + * + * + *
+       * Upper bound of the interval.
+       * 
+ * + * double upper_bound = 4; + * + * @return The upperBound. + */ + @java.lang.Override + public double getUpperBound() { + return upperBound_; + } + + 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 (confidenceLevel_ != 0D) { + output.writeDouble(1, confidenceLevel_); + } + if (ratio_ != 0D) { + output.writeDouble(2, ratio_); + } + if (lowerBound_ != 0D) { + output.writeDouble(3, lowerBound_); + } + if (upperBound_ != 0D) { + output.writeDouble(4, upperBound_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (confidenceLevel_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(1, confidenceLevel_); + } + if (ratio_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(2, ratio_); + } + if (lowerBound_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(3, lowerBound_); + } + if (upperBound_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(4, upperBound_); + } + size += unknownFields.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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval other = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) obj; + + if (java.lang.Double.doubleToLongBits(getConfidenceLevel()) + != java.lang.Double.doubleToLongBits(other.getConfidenceLevel())) return false; + if (java.lang.Double.doubleToLongBits(getRatio()) + != java.lang.Double.doubleToLongBits(other.getRatio())) return false; + if (java.lang.Double.doubleToLongBits(getLowerBound()) + != java.lang.Double.doubleToLongBits(other.getLowerBound())) return false; + if (java.lang.Double.doubleToLongBits(getUpperBound()) + != java.lang.Double.doubleToLongBits(other.getUpperBound())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + CONFIDENCE_LEVEL_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getConfidenceLevel())); + hash = (37 * hash) + RATIO_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getRatio())); + hash = (37 * hash) + LOWER_BOUND_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getLowerBound())); + hash = (37 * hash) + UPPER_BOUND_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getUpperBound())); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval 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 confidence interval is a range of possible values for the experiment
+       * objective you are trying to measure.
+       * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceIntervalOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder + .class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + confidenceLevel_ = 0D; + + ratio_ = 0D; + + lowerBound_ = 0D; + + upperBound_ = 0D; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval build() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + buildPartial() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval result = + new com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval(this); + result.confidenceLevel_ = confidenceLevel_; + result.ratio_ = ratio_; + result.lowerBound_ = lowerBound_; + result.upperBound_ = upperBound_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval other) { + if (other + == com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + .getDefaultInstance()) return this; + if (other.getConfidenceLevel() != 0D) { + setConfidenceLevel(other.getConfidenceLevel()); + } + if (other.getRatio() != 0D) { + setRatio(other.getRatio()); + } + if (other.getLowerBound() != 0D) { + setLowerBound(other.getLowerBound()); + } + if (other.getUpperBound() != 0D) { + setUpperBound(other.getUpperBound()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval parsedMessage = + null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private double confidenceLevel_; + /** + * + * + *
+         * The confidence level used to construct the interval, i.e. there is X%
+         * chance that the true value is within this interval.
+         * 
+ * + * double confidence_level = 1; + * + * @return The confidenceLevel. + */ + @java.lang.Override + public double getConfidenceLevel() { + return confidenceLevel_; + } + /** + * + * + *
+         * The confidence level used to construct the interval, i.e. there is X%
+         * chance that the true value is within this interval.
+         * 
+ * + * double confidence_level = 1; + * + * @param value The confidenceLevel to set. + * @return This builder for chaining. + */ + public Builder setConfidenceLevel(double value) { + + confidenceLevel_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The confidence level used to construct the interval, i.e. there is X%
+         * chance that the true value is within this interval.
+         * 
+ * + * double confidence_level = 1; + * + * @return This builder for chaining. + */ + public Builder clearConfidenceLevel() { + + confidenceLevel_ = 0D; + onChanged(); + return this; + } + + private double ratio_; + /** + * + * + *
+         * The percent change between an experiment metric's value and the value
+         * for its control.
+         * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + @java.lang.Override + public double getRatio() { + return ratio_; + } + /** + * + * + *
+         * The percent change between an experiment metric's value and the value
+         * for its control.
+         * 
+ * + * double ratio = 2; + * + * @param value The ratio to set. + * @return This builder for chaining. + */ + public Builder setRatio(double value) { + + ratio_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The percent change between an experiment metric's value and the value
+         * for its control.
+         * 
+ * + * double ratio = 2; + * + * @return This builder for chaining. + */ + public Builder clearRatio() { + + ratio_ = 0D; + onChanged(); + return this; + } + + private double lowerBound_; + /** + * + * + *
+         * Lower bound of the interval.
+         * 
+ * + * double lower_bound = 3; + * + * @return The lowerBound. + */ + @java.lang.Override + public double getLowerBound() { + return lowerBound_; + } + /** + * + * + *
+         * Lower bound of the interval.
+         * 
+ * + * double lower_bound = 3; + * + * @param value The lowerBound to set. + * @return This builder for chaining. + */ + public Builder setLowerBound(double value) { + + lowerBound_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Lower bound of the interval.
+         * 
+ * + * double lower_bound = 3; + * + * @return This builder for chaining. + */ + public Builder clearLowerBound() { + + lowerBound_ = 0D; + onChanged(); + return this; + } + + private double upperBound_; + /** + * + * + *
+         * Upper bound of the interval.
+         * 
+ * + * double upper_bound = 4; + * + * @return The upperBound. + */ + @java.lang.Override + public double getUpperBound() { + return upperBound_; + } + /** + * + * + *
+         * Upper bound of the interval.
+         * 
+ * + * double upper_bound = 4; + * + * @param value The upperBound to set. + * @return This builder for chaining. + */ + public Builder setUpperBound(double value) { + + upperBound_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Upper bound of the interval.
+         * 
+ * + * double upper_bound = 4; + * + * @return This builder for chaining. + */ + public Builder clearUpperBound() { + + upperBound_ = 0D; + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval) + private static final com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval(); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ConfidenceInterval parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ConfidenceInterval(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface MetricOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return The type. + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType getType(); + + /** + * + * + *
+       * Ratio value of a metric.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + double getRatio(); + + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return Whether the confidenceInterval field is set. + */ + boolean hasConfidenceInterval(); + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return The confidenceInterval. + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + getConfidenceInterval(); + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceIntervalOrBuilder + getConfidenceIntervalOrBuilder(); + + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.ValueCase getValueCase(); + } + /** + * + * + *
+     * Metric and corresponding confidence intervals.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result.Metric} + */ + public static final class Metric extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) + MetricOrBuilder { + private static final long serialVersionUID = 0L; + // Use Metric.newBuilder() to construct. + private Metric(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Metric() { + type_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Metric(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Metric( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + type_ = rawValue; + break; + } + case 17: + { + valueCase_ = 2; + value_ = input.readDouble(); + break; + } + case 26: + { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder + subBuilder = null; + if (confidenceInterval_ != null) { + subBuilder = confidenceInterval_.toBuilder(); + } + confidenceInterval_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + .parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(confidenceInterval_); + confidenceInterval_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder.class); + } + + private int valueCase_ = 0; + private java.lang.Object value_; + + public enum ValueCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + RATIO(2), + VALUE_NOT_SET(0); + private final int value; + + private ValueCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ValueCase valueOf(int value) { + return forNumber(value); + } + + public static ValueCase forNumber(int value) { + switch (value) { + case 2: + return RATIO; + case 0: + return VALUE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ValueCase getValueCase() { + return ValueCase.forNumber(valueCase_); + } + + public static final int TYPE_FIELD_NUMBER = 1; + private int type_; + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType getType() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType result = + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType.valueOf(type_); + return result == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType.UNRECOGNIZED + : result; + } + + public static final int RATIO_FIELD_NUMBER = 2; + /** + * + * + *
+       * Ratio value of a metric.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + @java.lang.Override + public double getRatio() { + if (valueCase_ == 2) { + return (java.lang.Double) value_; + } + return 0D; + } + + public static final int CONFIDENCE_INTERVAL_FIELD_NUMBER = 3; + private com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + confidenceInterval_; + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return Whether the confidenceInterval field is set. + */ + @java.lang.Override + public boolean hasConfidenceInterval() { + return confidenceInterval_ != null; + } + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return The confidenceInterval. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + getConfidenceInterval() { + return confidenceInterval_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + .getDefaultInstance() + : confidenceInterval_; + } + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceIntervalOrBuilder + getConfidenceIntervalOrBuilder() { + return getConfidenceInterval(); + } + + 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 (type_ + != com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType.METRIC_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, type_); + } + if (valueCase_ == 2) { + output.writeDouble(2, (double) ((java.lang.Double) value_)); + } + if (confidenceInterval_ != null) { + output.writeMessage(3, getConfidenceInterval()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (type_ + != com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType.METRIC_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); + } + if (valueCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeDoubleSize( + 2, (double) ((java.lang.Double) value_)); + } + if (confidenceInterval_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, getConfidenceInterval()); + } + size += unknownFields.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.dialogflow.cx.v3.Experiment.Result.Metric)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric other = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) obj; + + if (type_ != other.type_) return false; + if (hasConfidenceInterval() != other.hasConfidenceInterval()) return false; + if (hasConfidenceInterval()) { + if (!getConfidenceInterval().equals(other.getConfidenceInterval())) return false; + } + if (!getValueCase().equals(other.getValueCase())) return false; + switch (valueCase_) { + case 2: + if (java.lang.Double.doubleToLongBits(getRatio()) + != java.lang.Double.doubleToLongBits(other.getRatio())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + if (hasConfidenceInterval()) { + hash = (37 * hash) + CONFIDENCE_INTERVAL_FIELD_NUMBER; + hash = (53 * hash) + getConfidenceInterval().hashCode(); + } + switch (valueCase_) { + case 2: + hash = (37 * hash) + RATIO_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getRatio())); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric 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.dialogflow.cx.v3.Experiment.Result.Metric parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric 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.dialogflow.cx.v3.Experiment.Result.Metric parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric 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.dialogflow.cx.v3.Experiment.Result.Metric parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric 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.dialogflow.cx.v3.Experiment.Result.Metric parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric 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.dialogflow.cx.v3.Experiment.Result.Metric 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; + } + /** + * + * + *
+       * Metric and corresponding confidence intervals.
+       * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result.Metric} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + type_ = 0; + + if (confidenceIntervalBuilder_ == null) { + confidenceInterval_ = null; + } else { + confidenceInterval_ = null; + confidenceIntervalBuilder_ = null; + } + valueCase_ = 0; + value_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric build() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric buildPartial() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric result = + new com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric(this); + result.type_ = type_; + if (valueCase_ == 2) { + result.value_ = value_; + } + if (confidenceIntervalBuilder_ == null) { + result.confidenceInterval_ = confidenceInterval_; + } else { + result.confidenceInterval_ = confidenceIntervalBuilder_.build(); + } + result.valueCase_ = valueCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.Experiment.Result.Metric) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric other) { + if (other + == com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.getDefaultInstance()) + return this; + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + if (other.hasConfidenceInterval()) { + mergeConfidenceInterval(other.getConfidenceInterval()); + } + switch (other.getValueCase()) { + case RATIO: + { + setRatio(other.getRatio()); + break; + } + case VALUE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int valueCase_ = 0; + private java.lang.Object value_; + + public ValueCase getValueCase() { + return ValueCase.forNumber(valueCase_); + } + + public Builder clearValue() { + valueCase_ = 0; + value_ = null; + onChanged(); + return this; + } + + private int type_ = 0; + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType getType() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType result = + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType.valueOf(type_); + return result == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType value) { + if (value == null) { + throw new NullPointerException(); + } + + type_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.MetricType type = 1; + * + * @return This builder for chaining. + */ + public Builder clearType() { + + type_ = 0; + onChanged(); + return this; + } + + /** + * + * + *
+         * Ratio value of a metric.
+         * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + public double getRatio() { + if (valueCase_ == 2) { + return (java.lang.Double) value_; + } + return 0D; + } + /** + * + * + *
+         * Ratio value of a metric.
+         * 
+ * + * double ratio = 2; + * + * @param value The ratio to set. + * @return This builder for chaining. + */ + public Builder setRatio(double value) { + valueCase_ = 2; + value_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Ratio value of a metric.
+         * 
+ * + * double ratio = 2; + * + * @return This builder for chaining. + */ + public Builder clearRatio() { + if (valueCase_ == 2) { + valueCase_ = 0; + value_ = null; + onChanged(); + } + return this; + } + + private com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + confidenceInterval_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceIntervalOrBuilder> + confidenceIntervalBuilder_; + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return Whether the confidenceInterval field is set. + */ + public boolean hasConfidenceInterval() { + return confidenceIntervalBuilder_ != null || confidenceInterval_ != null; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return The confidenceInterval. + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + getConfidenceInterval() { + if (confidenceIntervalBuilder_ == null) { + return confidenceInterval_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + .getDefaultInstance() + : confidenceInterval_; + } else { + return confidenceIntervalBuilder_.getMessage(); + } + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder setConfidenceInterval( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval value) { + if (confidenceIntervalBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + confidenceInterval_ = value; + onChanged(); + } else { + confidenceIntervalBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder setConfidenceInterval( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder + builderForValue) { + if (confidenceIntervalBuilder_ == null) { + confidenceInterval_ = builderForValue.build(); + onChanged(); + } else { + confidenceIntervalBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder mergeConfidenceInterval( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval value) { + if (confidenceIntervalBuilder_ == null) { + if (confidenceInterval_ != null) { + confidenceInterval_ = + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.newBuilder( + confidenceInterval_) + .mergeFrom(value) + .buildPartial(); + } else { + confidenceInterval_ = value; + } + onChanged(); + } else { + confidenceIntervalBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder clearConfidenceInterval() { + if (confidenceIntervalBuilder_ == null) { + confidenceInterval_ = null; + onChanged(); + } else { + confidenceInterval_ = null; + confidenceIntervalBuilder_ = null; + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder + getConfidenceIntervalBuilder() { + + onChanged(); + return getConfidenceIntervalFieldBuilder().getBuilder(); + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceIntervalOrBuilder + getConfidenceIntervalOrBuilder() { + if (confidenceIntervalBuilder_ != null) { + return confidenceIntervalBuilder_.getMessageOrBuilder(); + } else { + return confidenceInterval_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval + .getDefaultInstance() + : confidenceInterval_; + } + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceIntervalOrBuilder> + getConfidenceIntervalFieldBuilder() { + if (confidenceIntervalBuilder_ == null) { + confidenceIntervalBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.ConfidenceInterval.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result + .ConfidenceIntervalOrBuilder>( + getConfidenceInterval(), getParentForChildren(), isClean()); + confidenceInterval_ = null; + } + return confidenceIntervalBuilder_; + } + + @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.dialogflow.cx.v3.Experiment.Result.Metric) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.Experiment.Result.Metric) + private static final com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric(); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Metric parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Metric(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.Experiment.Result.Metric + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface VersionMetricsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The version. + */ + java.lang.String getVersion(); + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for version. + */ + com.google.protobuf.ByteString getVersionBytes(); + + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + java.util.List getMetricsList(); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric getMetrics(int index); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + int getMetricsCount(); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + java.util.List + getMetricsOrBuilderList(); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder getMetricsOrBuilder( + int index); + + /** + * + * + *
+       * Number of sessions that were allocated to this version.
+       * 
+ * + * int32 session_count = 3; + * + * @return The sessionCount. + */ + int getSessionCount(); + } + /** + * + * + *
+     * Version variant and associated metrics.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics} + */ + public static final class VersionMetrics extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) + VersionMetricsOrBuilder { + private static final long serialVersionUID = 0L; + // Use VersionMetrics.newBuilder() to construct. + private VersionMetrics(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private VersionMetrics() { + version_ = ""; + metrics_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new VersionMetrics(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private VersionMetrics( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + version_ = s; + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + metrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric>(); + mutable_bitField0_ |= 0x00000001; + } + metrics_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.parser(), + extensionRegistry)); + break; + } + case 24: + { + sessionCount_ = input.readInt32(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + metrics_ = java.util.Collections.unmodifiableList(metrics_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder.class); + } + + public static final int VERSION_FIELD_NUMBER = 1; + private volatile java.lang.Object version_; + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The version. + */ + @java.lang.Override + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } + } + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for version. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int METRICS_FIELD_NUMBER = 2; + private java.util.List metrics_; + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + @java.lang.Override + public java.util.List + getMetricsList() { + return metrics_; + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder> + getMetricsOrBuilderList() { + return metrics_; + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + @java.lang.Override + public int getMetricsCount() { + return metrics_.size(); + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric getMetrics(int index) { + return metrics_.get(index); + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder + getMetricsOrBuilder(int index) { + return metrics_.get(index); + } + + public static final int SESSION_COUNT_FIELD_NUMBER = 3; + private int sessionCount_; + /** + * + * + *
+       * Number of sessions that were allocated to this version.
+       * 
+ * + * int32 session_count = 3; + * + * @return The sessionCount. + */ + @java.lang.Override + public int getSessionCount() { + return sessionCount_; + } + + 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 (!getVersionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_); + } + for (int i = 0; i < metrics_.size(); i++) { + output.writeMessage(2, metrics_.get(i)); + } + if (sessionCount_ != 0) { + output.writeInt32(3, sessionCount_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getVersionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_); + } + for (int i = 0; i < metrics_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, metrics_.get(i)); + } + if (sessionCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, sessionCount_); + } + size += unknownFields.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.dialogflow.cx.v3.Experiment.Result.VersionMetrics)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics other = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) obj; + + if (!getVersion().equals(other.getVersion())) return false; + if (!getMetricsList().equals(other.getMetricsList())) return false; + if (getSessionCount() != other.getSessionCount()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + if (getMetricsCount() > 0) { + hash = (37 * hash) + METRICS_FIELD_NUMBER; + hash = (53 * hash) + getMetricsList().hashCode(); + } + hash = (37 * hash) + SESSION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getSessionCount(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics 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; + } + /** + * + * + *
+       * Version variant and associated metrics.
+       * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getMetricsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + version_ = ""; + + if (metricsBuilder_ == null) { + metrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + metricsBuilder_.clear(); + } + sessionCount_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics build() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics buildPartial() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics result = + new com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics(this); + int from_bitField0_ = bitField0_; + result.version_ = version_; + if (metricsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + metrics_ = java.util.Collections.unmodifiableList(metrics_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.metrics_ = metrics_; + } else { + result.metrics_ = metricsBuilder_.build(); + } + result.sessionCount_ = sessionCount_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.Experiment.Result.VersionMetrics) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics other) { + if (other + == com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + .getDefaultInstance()) return this; + if (!other.getVersion().isEmpty()) { + version_ = other.version_; + onChanged(); + } + if (metricsBuilder_ == null) { + if (!other.metrics_.isEmpty()) { + if (metrics_.isEmpty()) { + metrics_ = other.metrics_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureMetricsIsMutable(); + metrics_.addAll(other.metrics_); + } + onChanged(); + } + } else { + if (!other.metrics_.isEmpty()) { + if (metricsBuilder_.isEmpty()) { + metricsBuilder_.dispose(); + metricsBuilder_ = null; + metrics_ = other.metrics_; + bitField0_ = (bitField0_ & ~0x00000001); + metricsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getMetricsFieldBuilder() + : null; + } else { + metricsBuilder_.addAllMessages(other.metrics_); + } + } + } + if (other.getSessionCount() != 0) { + setSessionCount(other.getSessionCount()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object version_ = ""; + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The version. + */ + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for version. + */ + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The version to set. + * @return This builder for chaining. + */ + public Builder setVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + version_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearVersion() { + + version_ = getDefaultInstance().getVersion(); + onChanged(); + return this; + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for version to set. + * @return This builder for chaining. + */ + public Builder setVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + version_ = value; + onChanged(); + return this; + } + + private java.util.List + metrics_ = java.util.Collections.emptyList(); + + private void ensureMetricsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + metrics_ = + new java.util.ArrayList( + metrics_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder> + metricsBuilder_; + + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public java.util.List + getMetricsList() { + if (metricsBuilder_ == null) { + return java.util.Collections.unmodifiableList(metrics_); + } else { + return metricsBuilder_.getMessageList(); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public int getMetricsCount() { + if (metricsBuilder_ == null) { + return metrics_.size(); + } else { + return metricsBuilder_.getCount(); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric getMetrics(int index) { + if (metricsBuilder_ == null) { + return metrics_.get(index); + } else { + return metricsBuilder_.getMessage(index); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder setMetrics( + int index, com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric value) { + if (metricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricsIsMutable(); + metrics_.set(index, value); + onChanged(); + } else { + metricsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder setMetrics( + int index, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder builderForValue) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.set(index, builderForValue.build()); + onChanged(); + } else { + metricsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric value) { + if (metricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricsIsMutable(); + metrics_.add(value); + onChanged(); + } else { + metricsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + int index, com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric value) { + if (metricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricsIsMutable(); + metrics_.add(index, value); + onChanged(); + } else { + metricsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder builderForValue) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.add(builderForValue.build()); + onChanged(); + } else { + metricsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + int index, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder builderForValue) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.add(index, builderForValue.build()); + onChanged(); + } else { + metricsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addAllMetrics( + java.lang.Iterable + values) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, metrics_); + onChanged(); + } else { + metricsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder clearMetrics() { + if (metricsBuilder_ == null) { + metrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + metricsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public Builder removeMetrics(int index) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.remove(index); + onChanged(); + } else { + metricsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder getMetricsBuilder( + int index) { + return getMetricsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder + getMetricsOrBuilder(int index) { + if (metricsBuilder_ == null) { + return metrics_.get(index); + } else { + return metricsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder> + getMetricsOrBuilderList() { + if (metricsBuilder_ != null) { + return metricsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(metrics_); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder + addMetricsBuilder() { + return getMetricsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.getDefaultInstance()); + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder addMetricsBuilder( + int index) { + return getMetricsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.getDefaultInstance()); + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.Metric metrics = 2; + * + */ + public java.util.List + getMetricsBuilderList() { + return getMetricsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder> + getMetricsFieldBuilder() { + if (metricsBuilder_ == null) { + metricsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Metric.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.MetricOrBuilder>( + metrics_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + metrics_ = null; + } + return metricsBuilder_; + } + + private int sessionCount_; + /** + * + * + *
+         * Number of sessions that were allocated to this version.
+         * 
+ * + * int32 session_count = 3; + * + * @return The sessionCount. + */ + @java.lang.Override + public int getSessionCount() { + return sessionCount_; + } + /** + * + * + *
+         * Number of sessions that were allocated to this version.
+         * 
+ * + * int32 session_count = 3; + * + * @param value The sessionCount to set. + * @return This builder for chaining. + */ + public Builder setSessionCount(int value) { + + sessionCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Number of sessions that were allocated to this version.
+         * 
+ * + * int32 session_count = 3; + * + * @return This builder for chaining. + */ + public Builder clearSessionCount() { + + sessionCount_ = 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics) + private static final com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics(); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VersionMetrics parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new VersionMetrics(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.Experiment.Result.VersionMetrics + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int VERSION_METRICS_FIELD_NUMBER = 1; + private java.util.List + versionMetrics_; + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public java.util.List + getVersionMetricsList() { + return versionMetrics_; + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsOrBuilderList() { + return versionMetrics_; + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public int getVersionMetricsCount() { + return versionMetrics_.size(); + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics getVersionMetrics( + int index) { + return versionMetrics_.get(index); + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder + getVersionMetricsOrBuilder(int index) { + return versionMetrics_.get(index); + } + + public static final int LAST_UPDATE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp lastUpdateTime_; + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return Whether the lastUpdateTime field is set. + */ + @java.lang.Override + public boolean hasLastUpdateTime() { + return lastUpdateTime_ != null; + } + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return The lastUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastUpdateTime() { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + return getLastUpdateTime(); + } + + 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 < versionMetrics_.size(); i++) { + output.writeMessage(1, versionMetrics_.get(i)); + } + if (lastUpdateTime_ != null) { + output.writeMessage(2, getLastUpdateTime()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < versionMetrics_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, versionMetrics_.get(i)); + } + if (lastUpdateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getLastUpdateTime()); + } + size += unknownFields.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.dialogflow.cx.v3.Experiment.Result)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.Experiment.Result other = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result) obj; + + if (!getVersionMetricsList().equals(other.getVersionMetricsList())) return false; + if (hasLastUpdateTime() != other.hasLastUpdateTime()) return false; + if (hasLastUpdateTime()) { + if (!getLastUpdateTime().equals(other.getLastUpdateTime())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getVersionMetricsCount() > 0) { + hash = (37 * hash) + VERSION_METRICS_FIELD_NUMBER; + hash = (53 * hash) + getVersionMetricsList().hashCode(); + } + if (hasLastUpdateTime()) { + hash = (37 * hash) + LAST_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastUpdateTime().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result 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.dialogflow.cx.v3.Experiment.Result parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result 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.dialogflow.cx.v3.Experiment.Result parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result 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.dialogflow.cx.v3.Experiment.Result parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result 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.dialogflow.cx.v3.Experiment.Result parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result 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.dialogflow.cx.v3.Experiment.Result 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 inference result which includes an objective metric to optimize and the
+     * confidence interval.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment.Result} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.Experiment.Result) + com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.Experiment.Result.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getVersionMetricsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (versionMetricsBuilder_ == null) { + versionMetrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + versionMetricsBuilder_.clear(); + } + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.Experiment.Result.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result build() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result buildPartial() { + com.google.cloud.dialogflow.cx.v3.Experiment.Result result = + new com.google.cloud.dialogflow.cx.v3.Experiment.Result(this); + int from_bitField0_ = bitField0_; + if (versionMetricsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = java.util.Collections.unmodifiableList(versionMetrics_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.versionMetrics_ = versionMetrics_; + } else { + result.versionMetrics_ = versionMetricsBuilder_.build(); + } + if (lastUpdateTimeBuilder_ == null) { + result.lastUpdateTime_ = lastUpdateTime_; + } else { + result.lastUpdateTime_ = lastUpdateTimeBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.Experiment.Result) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.Experiment.Result) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.Experiment.Result other) { + if (other == com.google.cloud.dialogflow.cx.v3.Experiment.Result.getDefaultInstance()) + return this; + if (versionMetricsBuilder_ == null) { + if (!other.versionMetrics_.isEmpty()) { + if (versionMetrics_.isEmpty()) { + versionMetrics_ = other.versionMetrics_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureVersionMetricsIsMutable(); + versionMetrics_.addAll(other.versionMetrics_); + } + onChanged(); + } + } else { + if (!other.versionMetrics_.isEmpty()) { + if (versionMetricsBuilder_.isEmpty()) { + versionMetricsBuilder_.dispose(); + versionMetricsBuilder_ = null; + versionMetrics_ = other.versionMetrics_; + bitField0_ = (bitField0_ & ~0x00000001); + versionMetricsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getVersionMetricsFieldBuilder() + : null; + } else { + versionMetricsBuilder_.addAllMessages(other.versionMetrics_); + } + } + } + if (other.hasLastUpdateTime()) { + mergeLastUpdateTime(other.getLastUpdateTime()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.Experiment.Result parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.Experiment.Result) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + versionMetrics_ = java.util.Collections.emptyList(); + + private void ensureVersionMetricsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics>( + versionMetrics_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder> + versionMetricsBuilder_; + + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public java.util.List + getVersionMetricsList() { + if (versionMetricsBuilder_ == null) { + return java.util.Collections.unmodifiableList(versionMetrics_); + } else { + return versionMetricsBuilder_.getMessageList(); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public int getVersionMetricsCount() { + if (versionMetricsBuilder_ == null) { + return versionMetrics_.size(); + } else { + return versionMetricsBuilder_.getCount(); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics getVersionMetrics( + int index) { + if (versionMetricsBuilder_ == null) { + return versionMetrics_.get(index); + } else { + return versionMetricsBuilder_.getMessage(index); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder setVersionMetrics( + int index, com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics value) { + if (versionMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVersionMetricsIsMutable(); + versionMetrics_.set(index, value); + onChanged(); + } else { + versionMetricsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder setVersionMetrics( + int index, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder + builderForValue) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.set(index, builderForValue.build()); + onChanged(); + } else { + versionMetricsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics value) { + if (versionMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVersionMetricsIsMutable(); + versionMetrics_.add(value); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + int index, com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics value) { + if (versionMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVersionMetricsIsMutable(); + versionMetrics_.add(index, value); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder + builderForValue) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.add(builderForValue.build()); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + int index, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder + builderForValue) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.add(index, builderForValue.build()); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addAllVersionMetrics( + java.lang.Iterable< + ? extends com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics> + values) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, versionMetrics_); + onChanged(); + } else { + versionMetricsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder clearVersionMetrics() { + if (versionMetricsBuilder_ == null) { + versionMetrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + versionMetricsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder removeVersionMetrics(int index) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.remove(index); + onChanged(); + } else { + versionMetricsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder + getVersionMetricsBuilder(int index) { + return getVersionMetricsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder + getVersionMetricsOrBuilder(int index) { + if (versionMetricsBuilder_ == null) { + return versionMetrics_.get(index); + } else { + return versionMetricsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsOrBuilderList() { + if (versionMetricsBuilder_ != null) { + return versionMetricsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(versionMetrics_); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder + addVersionMetricsBuilder() { + return getVersionMetricsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + .getDefaultInstance()); + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder + addVersionMetricsBuilder(int index) { + return getVersionMetricsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics + .getDefaultInstance()); + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public java.util.List< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder> + getVersionMetricsBuilderList() { + return getVersionMetricsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsFieldBuilder() { + if (versionMetricsBuilder_ == null) { + versionMetricsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetrics.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.VersionMetricsOrBuilder>( + versionMetrics_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + versionMetrics_ = null; + } + return versionMetricsBuilder_; + } + + private com.google.protobuf.Timestamp lastUpdateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastUpdateTimeBuilder_; + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return Whether the lastUpdateTime field is set. + */ + public boolean hasLastUpdateTime() { + return lastUpdateTimeBuilder_ != null || lastUpdateTime_ != null; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return The lastUpdateTime. + */ + public com.google.protobuf.Timestamp getLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } else { + return lastUpdateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastUpdateTime_ = value; + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = builderForValue.build(); + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder mergeLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (lastUpdateTime_ != null) { + lastUpdateTime_ = + com.google.protobuf.Timestamp.newBuilder(lastUpdateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + lastUpdateTime_ = value; + } + onChanged(); + } else { + lastUpdateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder clearLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + onChanged(); + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getLastUpdateTimeBuilder() { + + onChanged(); + return getLastUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + if (lastUpdateTimeBuilder_ != null) { + return lastUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getLastUpdateTimeFieldBuilder() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastUpdateTime(), getParentForChildren(), isClean()); + lastUpdateTime_ = null; + } + return lastUpdateTimeBuilder_; + } + + @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.dialogflow.cx.v3.Experiment.Result) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.Experiment.Result) + private static final com.google.cloud.dialogflow.cx.v3.Experiment.Result DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.Experiment.Result(); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment.Result getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Result parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Result(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.Experiment.Result getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * 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 name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * 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 DISPLAY_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object displayName_; + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 3; + private volatile java.lang.Object description_; + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @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; + } + } + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 4; + private int state_; + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.State getState() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3.Experiment.State result = + com.google.cloud.dialogflow.cx.v3.Experiment.State.valueOf(state_); + return result == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.State.UNRECOGNIZED + : result; + } + + public static final int DEFINITION_FIELD_NUMBER = 5; + private com.google.cloud.dialogflow.cx.v3.Experiment.Definition definition_; + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + * + * @return Whether the definition field is set. + */ + @java.lang.Override + public boolean hasDefinition() { + return definition_ != null; + } + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + * + * @return The definition. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition getDefinition() { + return definition_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Definition.getDefaultInstance() + : definition_; + } + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder getDefinitionOrBuilder() { + return getDefinition(); + } + + public static final int RESULT_FIELD_NUMBER = 6; + private com.google.cloud.dialogflow.cx.v3.Experiment.Result result_; + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + * + * @return Whether the result field is set. + */ + @java.lang.Override + public boolean hasResult() { + return result_ != null; + } + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + * + * @return The result. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.Result getResult() { + return result_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.getDefaultInstance() + : result_; + } + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder getResultOrBuilder() { + return getResult(); + } + + public static final int CREATE_TIME_FIELD_NUMBER = 7; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int START_TIME_FIELD_NUMBER = 8; + private com.google.protobuf.Timestamp startTime_; + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return Whether the startTime field is set. + */ + @java.lang.Override + public boolean hasStartTime() { + return startTime_ != null; + } + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return The startTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getStartTime() { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + return getStartTime(); + } + + public static final int END_TIME_FIELD_NUMBER = 9; + private com.google.protobuf.Timestamp endTime_; + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return Whether the endTime field is set. + */ + @java.lang.Override + public boolean hasEndTime() { + return endTime_ != null; + } + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return The endTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getEndTime() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + return getEndTime(); + } + + public static final int LAST_UPDATE_TIME_FIELD_NUMBER = 10; + private com.google.protobuf.Timestamp lastUpdateTime_; + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return Whether the lastUpdateTime field is set. + */ + @java.lang.Override + public boolean hasLastUpdateTime() { + return lastUpdateTime_ != null; + } + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return The lastUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastUpdateTime() { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + return getLastUpdateTime(); + } + + public static final int EXPERIMENT_LENGTH_FIELD_NUMBER = 11; + private com.google.protobuf.Duration experimentLength_; + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return Whether the experimentLength field is set. + */ + @java.lang.Override + public boolean hasExperimentLength() { + return experimentLength_ != null; + } + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return The experimentLength. + */ + @java.lang.Override + public com.google.protobuf.Duration getExperimentLength() { + return experimentLength_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : experimentLength_; + } + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getExperimentLengthOrBuilder() { + return getExperimentLength(); + } + + public static final int VARIANTS_HISTORY_FIELD_NUMBER = 12; + private java.util.List variantsHistory_; + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + @java.lang.Override + public java.util.List + getVariantsHistoryList() { + return variantsHistory_; + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + @java.lang.Override + public java.util.List + getVariantsHistoryOrBuilderList() { + return variantsHistory_; + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + @java.lang.Override + public int getVariantsHistoryCount() { + return variantsHistory_.size(); + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VariantsHistory getVariantsHistory(int index) { + return variantsHistory_.get(index); + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder getVariantsHistoryOrBuilder( + int index) { + return variantsHistory_.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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!getDisplayNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); + } + if (!getDescriptionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, description_); + } + if (state_ + != com.google.cloud.dialogflow.cx.v3.Experiment.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(4, state_); + } + if (definition_ != null) { + output.writeMessage(5, getDefinition()); + } + if (result_ != null) { + output.writeMessage(6, getResult()); + } + if (createTime_ != null) { + output.writeMessage(7, getCreateTime()); + } + if (startTime_ != null) { + output.writeMessage(8, getStartTime()); + } + if (endTime_ != null) { + output.writeMessage(9, getEndTime()); + } + if (lastUpdateTime_ != null) { + output.writeMessage(10, getLastUpdateTime()); + } + if (experimentLength_ != null) { + output.writeMessage(11, getExperimentLength()); + } + for (int i = 0; i < variantsHistory_.size(); i++) { + output.writeMessage(12, variantsHistory_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!getDisplayNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); + } + if (!getDescriptionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, description_); + } + if (state_ + != com.google.cloud.dialogflow.cx.v3.Experiment.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); + } + if (definition_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getDefinition()); + } + if (result_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getResult()); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getCreateTime()); + } + if (startTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getStartTime()); + } + if (endTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getEndTime()); + } + if (lastUpdateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getLastUpdateTime()); + } + if (experimentLength_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getExperimentLength()); + } + for (int i = 0; i < variantsHistory_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, variantsHistory_.get(i)); + } + size += unknownFields.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.dialogflow.cx.v3.Experiment)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.Experiment other = + (com.google.cloud.dialogflow.cx.v3.Experiment) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (state_ != other.state_) return false; + if (hasDefinition() != other.hasDefinition()) return false; + if (hasDefinition()) { + if (!getDefinition().equals(other.getDefinition())) return false; + } + if (hasResult() != other.hasResult()) return false; + if (hasResult()) { + if (!getResult().equals(other.getResult())) return false; + } + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasStartTime() != other.hasStartTime()) return false; + if (hasStartTime()) { + if (!getStartTime().equals(other.getStartTime())) return false; + } + if (hasEndTime() != other.hasEndTime()) return false; + if (hasEndTime()) { + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (hasLastUpdateTime() != other.hasLastUpdateTime()) return false; + if (hasLastUpdateTime()) { + if (!getLastUpdateTime().equals(other.getLastUpdateTime())) return false; + } + if (hasExperimentLength() != other.hasExperimentLength()) return false; + if (hasExperimentLength()) { + if (!getExperimentLength().equals(other.getExperimentLength())) return false; + } + if (!getVariantsHistoryList().equals(other.getVariantsHistoryList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + if (hasDefinition()) { + hash = (37 * hash) + DEFINITION_FIELD_NUMBER; + hash = (53 * hash) + getDefinition().hashCode(); + } + if (hasResult()) { + hash = (37 * hash) + RESULT_FIELD_NUMBER; + hash = (53 * hash) + getResult().hashCode(); + } + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasStartTime()) { + hash = (37 * hash) + START_TIME_FIELD_NUMBER; + hash = (53 * hash) + getStartTime().hashCode(); + } + if (hasEndTime()) { + hash = (37 * hash) + END_TIME_FIELD_NUMBER; + hash = (53 * hash) + getEndTime().hashCode(); + } + if (hasLastUpdateTime()) { + hash = (37 * hash) + LAST_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastUpdateTime().hashCode(); + } + if (hasExperimentLength()) { + hash = (37 * hash) + EXPERIMENT_LENGTH_FIELD_NUMBER; + hash = (53 * hash) + getExperimentLength().hashCode(); + } + if (getVariantsHistoryCount() > 0) { + hash = (37 * hash) + VARIANTS_HISTORY_FIELD_NUMBER; + hash = (53 * hash) + getVariantsHistoryList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment 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.dialogflow.cx.v3.Experiment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment 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.dialogflow.cx.v3.Experiment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment parseFrom(java.io.InputStream input) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment 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.dialogflow.cx.v3.Experiment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment 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.dialogflow.cx.v3.Experiment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment 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.dialogflow.cx.v3.Experiment 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; + } + /** + * + * + *
+   * Represents an experiment in an environment.
+   * Next ID: 13
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.Experiment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.Experiment) + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.Experiment.class, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.Experiment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getVariantsHistoryFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + displayName_ = ""; + + description_ = ""; + + state_ = 0; + + if (definitionBuilder_ == null) { + definition_ = null; + } else { + definition_ = null; + definitionBuilder_ = null; + } + if (resultBuilder_ == null) { + result_ = null; + } else { + result_ = null; + resultBuilder_ = null; + } + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (startTimeBuilder_ == null) { + startTime_ = null; + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + if (endTimeBuilder_ == null) { + endTime_ = null; + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + if (experimentLengthBuilder_ == null) { + experimentLength_ = null; + } else { + experimentLength_ = null; + experimentLengthBuilder_ = null; + } + if (variantsHistoryBuilder_ == null) { + variantsHistory_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + variantsHistoryBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment build() { + com.google.cloud.dialogflow.cx.v3.Experiment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment buildPartial() { + com.google.cloud.dialogflow.cx.v3.Experiment result = + new com.google.cloud.dialogflow.cx.v3.Experiment(this); + int from_bitField0_ = bitField0_; + result.name_ = name_; + result.displayName_ = displayName_; + result.description_ = description_; + result.state_ = state_; + if (definitionBuilder_ == null) { + result.definition_ = definition_; + } else { + result.definition_ = definitionBuilder_.build(); + } + if (resultBuilder_ == null) { + result.result_ = result_; + } else { + result.result_ = resultBuilder_.build(); + } + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (startTimeBuilder_ == null) { + result.startTime_ = startTime_; + } else { + result.startTime_ = startTimeBuilder_.build(); + } + if (endTimeBuilder_ == null) { + result.endTime_ = endTime_; + } else { + result.endTime_ = endTimeBuilder_.build(); + } + if (lastUpdateTimeBuilder_ == null) { + result.lastUpdateTime_ = lastUpdateTime_; + } else { + result.lastUpdateTime_ = lastUpdateTimeBuilder_.build(); + } + if (experimentLengthBuilder_ == null) { + result.experimentLength_ = experimentLength_; + } else { + result.experimentLength_ = experimentLengthBuilder_.build(); + } + if (variantsHistoryBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = java.util.Collections.unmodifiableList(variantsHistory_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.variantsHistory_ = variantsHistory_; + } else { + result.variantsHistory_ = variantsHistoryBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.Experiment) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.Experiment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.Experiment other) { + if (other == com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (other.hasDefinition()) { + mergeDefinition(other.getDefinition()); + } + if (other.hasResult()) { + mergeResult(other.getResult()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasStartTime()) { + mergeStartTime(other.getStartTime()); + } + if (other.hasEndTime()) { + mergeEndTime(other.getEndTime()); + } + if (other.hasLastUpdateTime()) { + mergeLastUpdateTime(other.getLastUpdateTime()); + } + if (other.hasExperimentLength()) { + mergeExperimentLength(other.getExperimentLength()); + } + if (variantsHistoryBuilder_ == null) { + if (!other.variantsHistory_.isEmpty()) { + if (variantsHistory_.isEmpty()) { + variantsHistory_ = other.variantsHistory_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureVariantsHistoryIsMutable(); + variantsHistory_.addAll(other.variantsHistory_); + } + onChanged(); + } + } else { + if (!other.variantsHistory_.isEmpty()) { + if (variantsHistoryBuilder_.isEmpty()) { + variantsHistoryBuilder_.dispose(); + variantsHistoryBuilder_ = null; + variantsHistory_ = other.variantsHistory_; + bitField0_ = (bitField0_ & ~0x00000001); + variantsHistoryBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getVariantsHistoryFieldBuilder() + : null; + } else { + variantsHistoryBuilder_.addAllMessages(other.variantsHistory_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.Experiment parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (com.google.cloud.dialogflow.cx.v3.Experiment) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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 name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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 name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + displayName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + + displayName_ = getDefaultInstance().getDisplayName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + displayName_ = value; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + } + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + } + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + + description_ = getDefaultInstance().getDescription(); + onChanged(); + return this; + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + onChanged(); + return this; + } + + private int state_ = 0; + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment.State getState() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3.Experiment.State result = + com.google.cloud.dialogflow.cx.v3.Experiment.State.valueOf(state_); + return result == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.State.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.dialogflow.cx.v3.Experiment.State value) { + if (value == null) { + throw new NullPointerException(); + } + + state_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return This builder for chaining. + */ + public Builder clearState() { + + state_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.dialogflow.cx.v3.Experiment.Definition definition_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Definition, + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder> + definitionBuilder_; + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + * + * @return Whether the definition field is set. + */ + public boolean hasDefinition() { + return definitionBuilder_ != null || definition_ != null; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + * + * @return The definition. + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition getDefinition() { + if (definitionBuilder_ == null) { + return definition_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Definition.getDefaultInstance() + : definition_; + } else { + return definitionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + public Builder setDefinition(com.google.cloud.dialogflow.cx.v3.Experiment.Definition value) { + if (definitionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + definition_ = value; + onChanged(); + } else { + definitionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + public Builder setDefinition( + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder builderForValue) { + if (definitionBuilder_ == null) { + definition_ = builderForValue.build(); + onChanged(); + } else { + definitionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + public Builder mergeDefinition(com.google.cloud.dialogflow.cx.v3.Experiment.Definition value) { + if (definitionBuilder_ == null) { + if (definition_ != null) { + definition_ = + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.newBuilder(definition_) + .mergeFrom(value) + .buildPartial(); + } else { + definition_ = value; + } + onChanged(); + } else { + definitionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + public Builder clearDefinition() { + if (definitionBuilder_ == null) { + definition_ = null; + onChanged(); + } else { + definition_ = null; + definitionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder getDefinitionBuilder() { + + onChanged(); + return getDefinitionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder + getDefinitionOrBuilder() { + if (definitionBuilder_ != null) { + return definitionBuilder_.getMessageOrBuilder(); + } else { + return definition_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Definition.getDefaultInstance() + : definition_; + } + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Definition, + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder> + getDefinitionFieldBuilder() { + if (definitionBuilder_ == null) { + definitionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Definition, + com.google.cloud.dialogflow.cx.v3.Experiment.Definition.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder>( + getDefinition(), getParentForChildren(), isClean()); + definition_ = null; + } + return definitionBuilder_; + } + + private com.google.cloud.dialogflow.cx.v3.Experiment.Result result_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder> + resultBuilder_; + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + * + * @return Whether the result field is set. + */ + public boolean hasResult() { + return resultBuilder_ != null || result_ != null; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + * + * @return The result. + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result getResult() { + if (resultBuilder_ == null) { + return result_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.getDefaultInstance() + : result_; + } else { + return resultBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + public Builder setResult(com.google.cloud.dialogflow.cx.v3.Experiment.Result value) { + if (resultBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + result_ = value; + onChanged(); + } else { + resultBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + public Builder setResult( + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder builderForValue) { + if (resultBuilder_ == null) { + result_ = builderForValue.build(); + onChanged(); + } else { + resultBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + public Builder mergeResult(com.google.cloud.dialogflow.cx.v3.Experiment.Result value) { + if (resultBuilder_ == null) { + if (result_ != null) { + result_ = + com.google.cloud.dialogflow.cx.v3.Experiment.Result.newBuilder(result_) + .mergeFrom(value) + .buildPartial(); + } else { + result_ = value; + } + onChanged(); + } else { + resultBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + public Builder clearResult() { + if (resultBuilder_ == null) { + result_ = null; + onChanged(); + } else { + result_ = null; + resultBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder getResultBuilder() { + + onChanged(); + return getResultFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder getResultOrBuilder() { + if (resultBuilder_ != null) { + return resultBuilder_.getMessageOrBuilder(); + } else { + return result_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.Result.getDefaultInstance() + : result_; + } + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder> + getResultFieldBuilder() { + if (resultBuilder_ == null) { + resultBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment.Result, + com.google.cloud.dialogflow.cx.v3.Experiment.Result.Builder, + com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder>( + getResult(), getParentForChildren(), isClean()); + result_ = null; + } + return resultBuilder_; + } + + 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_; + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @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(); + } + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + 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 startTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + startTimeBuilder_; + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return Whether the startTime field is set. + */ + public boolean hasStartTime() { + return startTimeBuilder_ != null || startTime_ != null; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return The startTime. + */ + public com.google.protobuf.Timestamp getStartTime() { + if (startTimeBuilder_ == null) { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } else { + return startTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder setStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + startTime_ = value; + onChanged(); + } else { + startTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (startTimeBuilder_ == null) { + startTime_ = builderForValue.build(); + onChanged(); + } else { + startTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder mergeStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (startTime_ != null) { + startTime_ = + com.google.protobuf.Timestamp.newBuilder(startTime_).mergeFrom(value).buildPartial(); + } else { + startTime_ = value; + } + onChanged(); + } else { + startTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder clearStartTime() { + if (startTimeBuilder_ == null) { + startTime_ = null; + onChanged(); + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { + + onChanged(); + return getStartTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + if (startTimeBuilder_ != null) { + return startTimeBuilder_.getMessageOrBuilder(); + } else { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getStartTimeFieldBuilder() { + if (startTimeBuilder_ == null) { + startTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getStartTime(), getParentForChildren(), isClean()); + startTime_ = null; + } + return startTimeBuilder_; + } + + private com.google.protobuf.Timestamp endTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return Whether the endTime field is set. + */ + public boolean hasEndTime() { + return endTimeBuilder_ != null || endTime_ != null; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return The endTime. + */ + public com.google.protobuf.Timestamp getEndTime() { + if (endTimeBuilder_ == null) { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } else { + return endTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder setEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + endTime_ = value; + onChanged(); + } else { + endTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (endTimeBuilder_ == null) { + endTime_ = builderForValue.build(); + onChanged(); + } else { + endTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder mergeEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (endTime_ != null) { + endTime_ = + com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); + } else { + endTime_ = value; + } + onChanged(); + } else { + endTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder clearEndTime() { + if (endTimeBuilder_ == null) { + endTime_ = null; + onChanged(); + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { + + onChanged(); + return getEndTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + if (endTimeBuilder_ != null) { + return endTimeBuilder_.getMessageOrBuilder(); + } else { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getEndTimeFieldBuilder() { + if (endTimeBuilder_ == null) { + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); + endTime_ = null; + } + return endTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastUpdateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastUpdateTimeBuilder_; + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return Whether the lastUpdateTime field is set. + */ + public boolean hasLastUpdateTime() { + return lastUpdateTimeBuilder_ != null || lastUpdateTime_ != null; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return The lastUpdateTime. + */ + public com.google.protobuf.Timestamp getLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } else { + return lastUpdateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastUpdateTime_ = value; + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = builderForValue.build(); + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder mergeLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (lastUpdateTime_ != null) { + lastUpdateTime_ = + com.google.protobuf.Timestamp.newBuilder(lastUpdateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + lastUpdateTime_ = value; + } + onChanged(); + } else { + lastUpdateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder clearLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + onChanged(); + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public com.google.protobuf.Timestamp.Builder getLastUpdateTimeBuilder() { + + onChanged(); + return getLastUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + if (lastUpdateTimeBuilder_ != null) { + return lastUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getLastUpdateTimeFieldBuilder() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastUpdateTime(), getParentForChildren(), isClean()); + lastUpdateTime_ = null; + } + return lastUpdateTimeBuilder_; + } + + private com.google.protobuf.Duration experimentLength_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + experimentLengthBuilder_; + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return Whether the experimentLength field is set. + */ + public boolean hasExperimentLength() { + return experimentLengthBuilder_ != null || experimentLength_ != null; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return The experimentLength. + */ + public com.google.protobuf.Duration getExperimentLength() { + if (experimentLengthBuilder_ == null) { + return experimentLength_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : experimentLength_; + } else { + return experimentLengthBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder setExperimentLength(com.google.protobuf.Duration value) { + if (experimentLengthBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + experimentLength_ = value; + onChanged(); + } else { + experimentLengthBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder setExperimentLength(com.google.protobuf.Duration.Builder builderForValue) { + if (experimentLengthBuilder_ == null) { + experimentLength_ = builderForValue.build(); + onChanged(); + } else { + experimentLengthBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder mergeExperimentLength(com.google.protobuf.Duration value) { + if (experimentLengthBuilder_ == null) { + if (experimentLength_ != null) { + experimentLength_ = + com.google.protobuf.Duration.newBuilder(experimentLength_) + .mergeFrom(value) + .buildPartial(); + } else { + experimentLength_ = value; + } + onChanged(); + } else { + experimentLengthBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder clearExperimentLength() { + if (experimentLengthBuilder_ == null) { + experimentLength_ = null; + onChanged(); + } else { + experimentLength_ = null; + experimentLengthBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public com.google.protobuf.Duration.Builder getExperimentLengthBuilder() { + + onChanged(); + return getExperimentLengthFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public com.google.protobuf.DurationOrBuilder getExperimentLengthOrBuilder() { + if (experimentLengthBuilder_ != null) { + return experimentLengthBuilder_.getMessageOrBuilder(); + } else { + return experimentLength_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : experimentLength_; + } + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + getExperimentLengthFieldBuilder() { + if (experimentLengthBuilder_ == null) { + experimentLengthBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getExperimentLength(), getParentForChildren(), isClean()); + experimentLength_ = null; + } + return experimentLengthBuilder_; + } + + private java.util.List variantsHistory_ = + java.util.Collections.emptyList(); + + private void ensureVariantsHistoryIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = + new java.util.ArrayList( + variantsHistory_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VariantsHistory, + com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder, + com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder> + variantsHistoryBuilder_; + + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public java.util.List + getVariantsHistoryList() { + if (variantsHistoryBuilder_ == null) { + return java.util.Collections.unmodifiableList(variantsHistory_); + } else { + return variantsHistoryBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public int getVariantsHistoryCount() { + if (variantsHistoryBuilder_ == null) { + return variantsHistory_.size(); + } else { + return variantsHistoryBuilder_.getCount(); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public com.google.cloud.dialogflow.cx.v3.VariantsHistory getVariantsHistory(int index) { + if (variantsHistoryBuilder_ == null) { + return variantsHistory_.get(index); + } else { + return variantsHistoryBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder setVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3.VariantsHistory value) { + if (variantsHistoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsHistoryIsMutable(); + variantsHistory_.set(index, value); + onChanged(); + } else { + variantsHistoryBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder setVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder builderForValue) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.set(index, builderForValue.build()); + onChanged(); + } else { + variantsHistoryBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder addVariantsHistory(com.google.cloud.dialogflow.cx.v3.VariantsHistory value) { + if (variantsHistoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(value); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder addVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3.VariantsHistory value) { + if (variantsHistoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(index, value); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder addVariantsHistory( + com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder builderForValue) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(builderForValue.build()); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder addVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder builderForValue) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(index, builderForValue.build()); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder addAllVariantsHistory( + java.lang.Iterable values) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, variantsHistory_); + onChanged(); + } else { + variantsHistoryBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder clearVariantsHistory() { + if (variantsHistoryBuilder_ == null) { + variantsHistory_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + variantsHistoryBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public Builder removeVariantsHistory(int index) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.remove(index); + onChanged(); + } else { + variantsHistoryBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder getVariantsHistoryBuilder( + int index) { + return getVariantsHistoryFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder getVariantsHistoryOrBuilder( + int index) { + if (variantsHistoryBuilder_ == null) { + return variantsHistory_.get(index); + } else { + return variantsHistoryBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public java.util.List + getVariantsHistoryOrBuilderList() { + if (variantsHistoryBuilder_ != null) { + return variantsHistoryBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(variantsHistory_); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder addVariantsHistoryBuilder() { + return getVariantsHistoryFieldBuilder() + .addBuilder(com.google.cloud.dialogflow.cx.v3.VariantsHistory.getDefaultInstance()); + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder addVariantsHistoryBuilder( + int index) { + return getVariantsHistoryFieldBuilder() + .addBuilder( + index, com.google.cloud.dialogflow.cx.v3.VariantsHistory.getDefaultInstance()); + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + public java.util.List + getVariantsHistoryBuilderList() { + return getVariantsHistoryFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VariantsHistory, + com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder, + com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder> + getVariantsHistoryFieldBuilder() { + if (variantsHistoryBuilder_ == null) { + variantsHistoryBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VariantsHistory, + com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder, + com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder>( + variantsHistory_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + variantsHistory_ = null; + } + return variantsHistoryBuilder_; + } + + @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.dialogflow.cx.v3.Experiment) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.Experiment) + private static final com.google.cloud.dialogflow.cx.v3.Experiment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.Experiment(); + } + + public static com.google.cloud.dialogflow.cx.v3.Experiment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Experiment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Experiment(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.Experiment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentName.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentName.java new file mode 100644 index 000000000..2f8bac421 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentName.java @@ -0,0 +1,298 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3; + +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 ExperimentName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/agents/{agent}/environments/{environment}/experiments/{experiment}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String agent; + private final String environment; + private final String experiment; + + @Deprecated + protected ExperimentName() { + project = null; + location = null; + agent = null; + environment = null; + experiment = null; + } + + private ExperimentName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + agent = Preconditions.checkNotNull(builder.getAgent()); + environment = Preconditions.checkNotNull(builder.getEnvironment()); + experiment = Preconditions.checkNotNull(builder.getExperiment()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAgent() { + return agent; + } + + public String getEnvironment() { + return environment; + } + + public String getExperiment() { + return experiment; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static ExperimentName of( + String project, String location, String agent, String environment, String experiment) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgent(agent) + .setEnvironment(environment) + .setExperiment(experiment) + .build(); + } + + public static String format( + String project, String location, String agent, String environment, String experiment) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgent(agent) + .setEnvironment(environment) + .setExperiment(experiment) + .build() + .toString(); + } + + public static ExperimentName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT.validatedMatch( + formattedString, "ExperimentName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("agent"), + matchMap.get("environment"), + matchMap.get("experiment")); + } + + 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 (ExperimentName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT.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 (agent != null) { + fieldMapBuilder.put("agent", agent); + } + if (environment != null) { + fieldMapBuilder.put("environment", environment); + } + if (experiment != null) { + fieldMapBuilder.put("experiment", experiment); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT.instantiate( + "project", + project, + "location", + location, + "agent", + agent, + "environment", + environment, + "experiment", + experiment); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + ExperimentName that = ((ExperimentName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.agent, that.agent) + && Objects.equals(this.environment, that.environment) + && Objects.equals(this.experiment, that.experiment); + } + 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(agent); + h *= 1000003; + h ^= Objects.hashCode(environment); + h *= 1000003; + h ^= Objects.hashCode(experiment); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/agents/{agent}/environments/{environment}/experiments/{experiment}. + */ + public static class Builder { + private String project; + private String location; + private String agent; + private String environment; + private String experiment; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAgent() { + return agent; + } + + public String getEnvironment() { + return environment; + } + + public String getExperiment() { + return experiment; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setAgent(String agent) { + this.agent = agent; + return this; + } + + public Builder setEnvironment(String environment) { + this.environment = environment; + return this; + } + + public Builder setExperiment(String experiment) { + this.experiment = experiment; + return this; + } + + private Builder(ExperimentName experimentName) { + project = experimentName.project; + location = experimentName.location; + agent = experimentName.agent; + environment = experimentName.environment; + experiment = experimentName.experiment; + } + + public ExperimentName build() { + return new ExperimentName(this); + } + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentOrBuilder.java new file mode 100644 index 000000000..82bf5eeae --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentOrBuilder.java @@ -0,0 +1,434 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface ExperimentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.Experiment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @return The description. + */ + java.lang.String getDescription(); + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.State state = 4; + * + * @return The state. + */ + com.google.cloud.dialogflow.cx.v3.Experiment.State getState(); + + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + * + * @return Whether the definition field is set. + */ + boolean hasDefinition(); + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + * + * @return The definition. + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Definition getDefinition(); + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Definition definition = 5; + */ + com.google.cloud.dialogflow.cx.v3.Experiment.DefinitionOrBuilder getDefinitionOrBuilder(); + + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + * + * @return Whether the result field is set. + */ + boolean hasResult(); + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + * + * @return The result. + */ + com.google.cloud.dialogflow.cx.v3.Experiment.Result getResult(); + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.Experiment.Result result = 6; + */ + com.google.cloud.dialogflow.cx.v3.Experiment.ResultOrBuilder getResultOrBuilder(); + + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return Whether the startTime field is set. + */ + boolean hasStartTime(); + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return The startTime. + */ + com.google.protobuf.Timestamp getStartTime(); + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); + + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return Whether the endTime field is set. + */ + boolean hasEndTime(); + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return The endTime. + */ + com.google.protobuf.Timestamp getEndTime(); + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); + + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return Whether the lastUpdateTime field is set. + */ + boolean hasLastUpdateTime(); + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return The lastUpdateTime. + */ + com.google.protobuf.Timestamp getLastUpdateTime(); + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return Whether the experimentLength field is set. + */ + boolean hasExperimentLength(); + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return The experimentLength. + */ + com.google.protobuf.Duration getExperimentLength(); + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + com.google.protobuf.DurationOrBuilder getExperimentLengthOrBuilder(); + + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + java.util.List getVariantsHistoryList(); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + com.google.cloud.dialogflow.cx.v3.VariantsHistory getVariantsHistory(int index); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + int getVariantsHistoryCount(); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + java.util.List + getVariantsHistoryOrBuilderList(); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VariantsHistory variants_history = 12; + */ + com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder getVariantsHistoryOrBuilder(int index); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentProto.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentProto.java new file mode 100644 index 000000000..d94e541a6 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentProto.java @@ -0,0 +1,427 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public final class ExperimentProto { + private ExperimentProto() {} + + 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_dialogflow_cx_v3_Experiment_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_Experiment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_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/dialogflow/cx/v3/experime" + + "nt.proto\022\035google.cloud.dialogflow.cx.v3\032" + + "\034google/api/annotations.proto\032\027google/ap" + + "i/client.proto\032\037google/api/field_behavio" + + "r.proto\032\031google/api/resource.proto\032\036goog" + + "le/protobuf/duration.proto\032\033google/proto" + + "buf/empty.proto\032 google/protobuf/field_m" + + "ask.proto\032\037google/protobuf/timestamp.pro" + + "to\"\353\r\n\nExperiment\022\014\n\004name\030\001 \001(\t\022\031\n\014displ" + + "ay_name\030\002 \001(\tB\003\340A\002\022\023\n\013description\030\003 \001(\t\022" + + ">\n\005state\030\004 \001(\0162/.google.cloud.dialogflow" + + ".cx.v3.Experiment.State\022H\n\ndefinition\030\005 " + + "\001(\01324.google.cloud.dialogflow.cx.v3.Expe" + + "riment.Definition\022@\n\006result\030\006 \001(\01320.goog" + + "le.cloud.dialogflow.cx.v3.Experiment.Res" + + "ult\022/\n\013create_time\030\007 \001(\0132\032.google.protob" + + "uf.Timestamp\022.\n\nstart_time\030\010 \001(\0132\032.googl" + + "e.protobuf.Timestamp\022,\n\010end_time\030\t \001(\0132\032" + + ".google.protobuf.Timestamp\0224\n\020last_updat" + + "e_time\030\n \001(\0132\032.google.protobuf.Timestamp" + + "\0224\n\021experiment_length\030\013 \001(\0132\031.google.pro" + + "tobuf.Duration\022H\n\020variants_history\030\014 \003(\013" + + "2..google.cloud.dialogflow.cx.v3.Variant" + + "sHistory\032w\n\nDefinition\022\021\n\tcondition\030\001 \001(" + + "\t\022J\n\020version_variants\030\002 \001(\0132..google.clo" + + "ud.dialogflow.cx.v3.VersionVariantsH\000B\n\n" + + "\010variants\032\271\006\n\006Result\022X\n\017version_metrics\030" + + "\001 \003(\0132?.google.cloud.dialogflow.cx.v3.Ex" + + "periment.Result.VersionMetrics\0224\n\020last_u" + + "pdate_time\030\002 \001(\0132\032.google.protobuf.Times" + + "tamp\032g\n\022ConfidenceInterval\022\030\n\020confidence" + + "_level\030\001 \001(\001\022\r\n\005ratio\030\002 \001(\001\022\023\n\013lower_bou" + + "nd\030\003 \001(\001\022\023\n\013upper_bound\030\004 \001(\001\032\317\001\n\006Metric" + + "\022I\n\004type\030\001 \001(\0162;.google.cloud.dialogflow" + + ".cx.v3.Experiment.Result.MetricType\022\017\n\005r" + + "atio\030\002 \001(\001H\000\022`\n\023confidence_interval\030\003 \001(" + + "\0132C.google.cloud.dialogflow.cx.v3.Experi" + + "ment.Result.ConfidenceIntervalB\007\n\005value\032" + + "\252\001\n\016VersionMetrics\0227\n\007version\030\001 \001(\tB&\372A#" + + "\n!dialogflow.googleapis.com/Version\022H\n\007m" + + "etrics\030\002 \003(\01327.google.cloud.dialogflow.c" + + "x.v3.Experiment.Result.Metric\022\025\n\rsession" + + "_count\030\003 \001(\005\"\266\001\n\nMetricType\022\026\n\022METRIC_UN" + + "SPECIFIED\020\000\022&\n\"CONTAINED_SESSION_NO_CALL" + + "BACK_RATE\020\001\022\033\n\027LIVE_AGENT_HANDOFF_RATE\020\002" + + "\022\031\n\025CALLBACK_SESSION_RATE\020\003\022\032\n\026ABANDONED" + + "_SESSION_RATE\020\004\022\024\n\020SESSION_END_RATE\020\005\"@\n" + + "\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\t\n\005DRAFT\020\001" + + "\022\013\n\007RUNNING\020\002\022\010\n\004DONE\020\003:\226\001\352A\222\001\n$dialogfl" + + "ow.googleapis.com/Experiment\022jprojects/{" + + "project}/locations/{location}/agents/{ag" + + "ent}/environments/{environment}/experime" + + "nts/{experiment}\"\255\001\n\017VersionVariants\022H\n\010" + + "variants\030\001 \003(\01326.google.cloud.dialogflow" + + ".cx.v3.VersionVariants.Variant\032P\n\007Varian" + + "t\022\017\n\007version\030\001 \001(\t\022\032\n\022traffic_allocation" + + "\030\002 \001(\002\022\030\n\020is_control_group\030\003 \001(\010\"\232\001\n\017Var" + + "iantsHistory\022J\n\020version_variants\030\001 \001(\0132." + + ".google.cloud.dialogflow.cx.v3.VersionVa" + + "riantsH\000\022/\n\013update_time\030\002 \001(\0132\032.google.p" + + "rotobuf.TimestampB\n\n\010variants\"}\n\026ListExp" + + "erimentsRequest\022<\n\006parent\030\001 \001(\tB,\340A\002\372A&\022" + + "$dialogflow.googleapis.com/Experiment\022\021\n" + + "\tpage_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"r\n\027" + + "ListExperimentsResponse\022>\n\013experiments\030\001" + + " \003(\0132).google.cloud.dialogflow.cx.v3.Exp" + + "eriment\022\027\n\017next_page_token\030\002 \001(\t\"R\n\024GetE" + + "xperimentRequest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n$" + + "dialogflow.googleapis.com/Experiment\"\233\001\n" + + "\027CreateExperimentRequest\022<\n\006parent\030\001 \001(\t" + + "B,\340A\002\372A&\022$dialogflow.googleapis.com/Expe" + + "riment\022B\n\nexperiment\030\002 \001(\0132).google.clou" + + "d.dialogflow.cx.v3.ExperimentB\003\340A\002\"\223\001\n\027U" + + "pdateExperimentRequest\022B\n\nexperiment\030\001 \001" + + "(\0132).google.cloud.dialogflow.cx.v3.Exper" + + "imentB\003\340A\002\0224\n\013update_mask\030\002 \001(\0132\032.google" + + ".protobuf.FieldMaskB\003\340A\002\"U\n\027DeleteExperi" + + "mentRequest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n$dialo" + + "gflow.googleapis.com/Experiment\"T\n\026Start" + + "ExperimentRequest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n" + + "$dialogflow.googleapis.com/Experiment\"S\n" + + "\025StopExperimentRequest\022:\n\004name\030\001 \001(\tB,\340A" + + "\002\372A&\n$dialogflow.googleapis.com/Experime" + + "nt2\370\014\n\013Experiments\022\332\001\n\017ListExperiments\0225" + + ".google.cloud.dialogflow.cx.v3.ListExper" + + "imentsRequest\0326.google.cloud.dialogflow." + + "cx.v3.ListExperimentsResponse\"X\202\323\344\223\002I\022G/" + + "v3/{parent=projects/*/locations/*/agents" + + "/*/environments/*}/experiments\332A\006parent\022" + + "\307\001\n\rGetExperiment\0223.google.cloud.dialogf" + + "low.cx.v3.GetExperimentRequest\032).google." + + "cloud.dialogflow.cx.v3.Experiment\"V\202\323\344\223\002" + + "I\022G/v3/{name=projects/*/locations/*/agen" + + "ts/*/environments/*/experiments/*}\332A\004nam" + + "e\022\346\001\n\020CreateExperiment\0226.google.cloud.di" + + "alogflow.cx.v3.CreateExperimentRequest\032)" + + ".google.cloud.dialogflow.cx.v3.Experimen" + + "t\"o\202\323\344\223\002U\"G/v3/{parent=projects/*/locati" + + "ons/*/agents/*/environments/*}/experimen" + + "ts:\nexperiment\332A\021parent,experiment\022\366\001\n\020U" + + "pdateExperiment\0226.google.cloud.dialogflo" + + "w.cx.v3.UpdateExperimentRequest\032).google" + + ".cloud.dialogflow.cx.v3.Experiment\"\177\202\323\344\223" + + "\002`2R/v3/{experiment.name=projects/*/loca" + + "tions/*/agents/*/environments/*/experime" + + "nts/*}:\nexperiment\332A\026experiment,update_m" + + "ask\022\272\001\n\020DeleteExperiment\0226.google.cloud." + + "dialogflow.cx.v3.DeleteExperimentRequest" + + "\032\026.google.protobuf.Empty\"V\202\323\344\223\002I*G/v3/{n" + + "ame=projects/*/locations/*/agents/*/envi" + + "ronments/*/experiments/*}\332A\004name\022\324\001\n\017Sta" + + "rtExperiment\0225.google.cloud.dialogflow.c" + + "x.v3.StartExperimentRequest\032).google.clo" + + "ud.dialogflow.cx.v3.Experiment\"_\202\323\344\223\002R\"M" + + "/v3/{name=projects/*/locations/*/agents/" + + "*/environments/*/experiments/*}:start:\001*" + + "\332A\004name\022\321\001\n\016StopExperiment\0224.google.clou" + + "d.dialogflow.cx.v3.StopExperimentRequest" + + "\032).google.cloud.dialogflow.cx.v3.Experim" + + "ent\"^\202\323\344\223\002Q\"L/v3/{name=projects/*/locati" + + "ons/*/agents/*/environments/*/experiment" + + "s/*}:stop:\001*\332A\004name\032x\312A\031dialogflow.googl" + + "eapis.com\322AYhttps://www.googleapis.com/a" + + "uth/cloud-platform,https://www.googleapi" + + "s.com/auth/dialogflowB\237\001\n!com.google.clo" + + "ud.dialogflow.cx.v3B\017ExperimentProtoP\001Z?" + + "google.golang.org/genproto/googleapis/cl" + + "oud/dialogflow/cx/v3;cx\370\001\001\242\002\002DF\252\002\035Google" + + ".Cloud.Dialogflow.Cx.V3b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.DurationProto.getDescriptor(), + com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "Description", + "State", + "Definition", + "Result", + "CreateTime", + "StartTime", + "EndTime", + "LastUpdateTime", + "ExperimentLength", + "VariantsHistory", + }); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor.getNestedTypes().get(0); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Definition_descriptor, + new java.lang.String[] { + "Condition", "VersionVariants", "Variants", + }); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_Experiment_descriptor.getNestedTypes().get(1); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor, + new java.lang.String[] { + "VersionMetrics", "LastUpdateTime", + }); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_ConfidenceInterval_descriptor, + new java.lang.String[] { + "ConfidenceLevel", "Ratio", "LowerBound", "UpperBound", + }); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_Metric_descriptor, + new java.lang.String[] { + "Type", "Ratio", "ConfidenceInterval", "Value", + }); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_descriptor + .getNestedTypes() + .get(2); + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_Experiment_Result_VersionMetrics_descriptor, + new java.lang.String[] { + "Version", "Metrics", "SessionCount", + }); + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor, + new java.lang.String[] { + "Variants", + }); + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_descriptor, + new java.lang.String[] { + "Version", "TrafficAllocation", "IsControlGroup", + }); + internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_descriptor, + new java.lang.String[] { + "VersionVariants", "UpdateTime", "Variants", + }); + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_descriptor, + new java.lang.String[] { + "Experiments", "NextPageToken", + }); + internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_CreateExperimentRequest_descriptor, + new java.lang.String[] { + "Parent", "Experiment", + }); + internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(7); + internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_descriptor, + new java.lang.String[] { + "Experiment", "UpdateMask", + }); + internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(8); + internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_DeleteExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(9); + internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + 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.ResourceProto.getDescriptor(); + com.google.protobuf.DurationProto.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/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequest.java new file mode 100644 index 000000000..5a7f0cdee --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequest.java @@ -0,0 +1,665 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.GetExperiment][google.cloud.dialogflow.cx.v3.Experiments.GetExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.GetExperimentRequest} + */ +public final class GetExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.GetExperimentRequest) + GetExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetExperimentRequest.newBuilder() to construct. + private GetExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private GetExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3.GetExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3.GetExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest 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.dialogflow.cx.v3.GetExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest 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.dialogflow.cx.v3.GetExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest 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.dialogflow.cx.v3.GetExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest 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.dialogflow.cx.v3.GetExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest 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.dialogflow.cx.v3.GetExperimentRequest 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 request message for [Experiments.GetExperiment][google.cloud.dialogflow.cx.v3.Experiments.GetExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.GetExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.GetExperimentRequest) + com.google.cloud.dialogflow.cx.v3.GetExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_GetExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.GetExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.GetExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.GetExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3.GetExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.GetExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.GetExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.GetExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.GetExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.GetExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.GetExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3.GetExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.GetExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3.GetExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.GetExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.GetExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new GetExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.GetExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequestOrBuilder.java new file mode 100644 index 000000000..539db127a --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface GetExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.GetExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequest.java new file mode 100644 index 000000000..ab70e7930 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequest.java @@ -0,0 +1,938 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3.Experiments.ListExperiments].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.ListExperimentsRequest} + */ +public final class ListExperimentsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.ListExperimentsRequest) + ListExperimentsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListExperimentsRequest.newBuilder() to construct. + private ListExperimentsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListExperimentsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListExperimentsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ListExperimentsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 16: + { + pageSize_ = input.readInt32(); + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + pageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.class, + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of items to return in a single page. By default 20 and
+   * at most 100.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!getPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!getPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + size += unknownFields.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.dialogflow.cx.v3.ListExperimentsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest other = + (com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest 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.dialogflow.cx.v3.ListExperimentsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest 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.dialogflow.cx.v3.ListExperimentsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest 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.dialogflow.cx.v3.ListExperimentsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest 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.dialogflow.cx.v3.ListExperimentsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest 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.dialogflow.cx.v3.ListExperimentsRequest 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 request message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3.Experiments.ListExperiments].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.ListExperimentsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.ListExperimentsRequest) + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.class, + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest build() { + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest result = + new com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.ListExperimentsRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + 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.dialogflow.cx.v3.ListExperimentsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.ListExperimentsRequest) + private static final com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListExperimentsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListExperimentsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.ListExperimentsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequestOrBuilder.java new file mode 100644 index 000000000..fc5ffe75b --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequestOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface ListExperimentsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.ListExperimentsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of items to return in a single page. By default 20 and
+   * at most 100.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponse.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponse.java new file mode 100644 index 000000000..a9458ea36 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponse.java @@ -0,0 +1,1209 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The response message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3.Experiments.ListExperiments].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.ListExperimentsResponse} + */ +public final class ListExperimentsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.ListExperimentsResponse) + ListExperimentsResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListExperimentsResponse.newBuilder() to construct. + private ListExperimentsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListExperimentsResponse() { + experiments_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListExperimentsResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ListExperimentsResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + experiments_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + experiments_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.parser(), extensionRegistry)); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + nextPageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + experiments_ = java.util.Collections.unmodifiableList(experiments_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.class, + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.Builder.class); + } + + public static final int EXPERIMENTS_FIELD_NUMBER = 1; + private java.util.List experiments_; + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + @java.lang.Override + public java.util.List getExperimentsList() { + return experiments_; + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + @java.lang.Override + public java.util.List + getExperimentsOrBuilderList() { + return experiments_; + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + @java.lang.Override + public int getExperimentsCount() { + return experiments_.size(); + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiments(int index) { + return experiments_.get(index); + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentsOrBuilder(int index) { + return experiments_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < experiments_.size(); i++) { + output.writeMessage(1, experiments_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < experiments_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, experiments_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + size += unknownFields.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.dialogflow.cx.v3.ListExperimentsResponse)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse other = + (com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse) obj; + + if (!getExperimentsList().equals(other.getExperimentsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExperimentsCount() > 0) { + hash = (37 * hash) + EXPERIMENTS_FIELD_NUMBER; + hash = (53 * hash) + getExperimentsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse 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.dialogflow.cx.v3.ListExperimentsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse 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.dialogflow.cx.v3.ListExperimentsResponse parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse 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.dialogflow.cx.v3.ListExperimentsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse 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.dialogflow.cx.v3.ListExperimentsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse 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.dialogflow.cx.v3.ListExperimentsResponse 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 response message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3.Experiments.ListExperiments].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.ListExperimentsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.ListExperimentsResponse) + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.class, + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExperimentsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (experimentsBuilder_ == null) { + experiments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + experimentsBuilder_.clear(); + } + nextPageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_ListExperimentsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse build() { + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse buildPartial() { + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse result = + new com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse(this); + int from_bitField0_ = bitField0_; + if (experimentsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + experiments_ = java.util.Collections.unmodifiableList(experiments_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.experiments_ = experiments_; + } else { + result.experiments_ = experimentsBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.ListExperimentsResponse) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse other) { + if (other == com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse.getDefaultInstance()) + return this; + if (experimentsBuilder_ == null) { + if (!other.experiments_.isEmpty()) { + if (experiments_.isEmpty()) { + experiments_ = other.experiments_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExperimentsIsMutable(); + experiments_.addAll(other.experiments_); + } + onChanged(); + } + } else { + if (!other.experiments_.isEmpty()) { + if (experimentsBuilder_.isEmpty()) { + experimentsBuilder_.dispose(); + experimentsBuilder_ = null; + experiments_ = other.experiments_; + bitField0_ = (bitField0_ & ~0x00000001); + experimentsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExperimentsFieldBuilder() + : null; + } else { + experimentsBuilder_.addAllMessages(other.experiments_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List experiments_ = + java.util.Collections.emptyList(); + + private void ensureExperimentsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + experiments_ = + new java.util.ArrayList(experiments_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder> + experimentsBuilder_; + + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public java.util.List getExperimentsList() { + if (experimentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(experiments_); + } else { + return experimentsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public int getExperimentsCount() { + if (experimentsBuilder_ == null) { + return experiments_.size(); + } else { + return experimentsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiments(int index) { + if (experimentsBuilder_ == null) { + return experiments_.get(index); + } else { + return experimentsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder setExperiments(int index, com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExperimentsIsMutable(); + experiments_.set(index, value); + onChanged(); + } else { + experimentsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder setExperiments( + int index, com.google.cloud.dialogflow.cx.v3.Experiment.Builder builderForValue) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.set(index, builderForValue.build()); + onChanged(); + } else { + experimentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder addExperiments(com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExperimentsIsMutable(); + experiments_.add(value); + onChanged(); + } else { + experimentsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder addExperiments(int index, com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExperimentsIsMutable(); + experiments_.add(index, value); + onChanged(); + } else { + experimentsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder addExperiments( + com.google.cloud.dialogflow.cx.v3.Experiment.Builder builderForValue) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.add(builderForValue.build()); + onChanged(); + } else { + experimentsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder addExperiments( + int index, com.google.cloud.dialogflow.cx.v3.Experiment.Builder builderForValue) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.add(index, builderForValue.build()); + onChanged(); + } else { + experimentsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder addAllExperiments( + java.lang.Iterable values) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, experiments_); + onChanged(); + } else { + experimentsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder clearExperiments() { + if (experimentsBuilder_ == null) { + experiments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + experimentsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public Builder removeExperiments(int index) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.remove(index); + onChanged(); + } else { + experimentsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Builder getExperimentsBuilder(int index) { + return getExperimentsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentsOrBuilder( + int index) { + if (experimentsBuilder_ == null) { + return experiments_.get(index); + } else { + return experimentsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public java.util.List + getExperimentsOrBuilderList() { + if (experimentsBuilder_ != null) { + return experimentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(experiments_); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Builder addExperimentsBuilder() { + return getExperimentsFieldBuilder() + .addBuilder(com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance()); + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Builder addExperimentsBuilder(int index) { + return getExperimentsFieldBuilder() + .addBuilder(index, com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance()); + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + public java.util.List + getExperimentsBuilderList() { + return getExperimentsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder> + getExperimentsFieldBuilder() { + if (experimentsBuilder_ == null) { + experimentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder>( + experiments_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + experiments_ = null; + } + return experimentsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + 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.dialogflow.cx.v3.ListExperimentsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.ListExperimentsResponse) + private static final com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse(); + } + + public static com.google.cloud.dialogflow.cx.v3.ListExperimentsResponse getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListExperimentsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListExperimentsResponse(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.ListExperimentsResponse getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponseOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponseOrBuilder.java new file mode 100644 index 000000000..38837a57b --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponseOrBuilder.java @@ -0,0 +1,119 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface ListExperimentsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.ListExperimentsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + java.util.List getExperimentsList(); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + com.google.cloud.dialogflow.cx.v3.Experiment getExperiments(int index); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + int getExperimentsCount(); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + java.util.List + getExperimentsOrBuilderList(); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.Experiment experiments = 1; + */ + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentsOrBuilder(int index); + + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Match.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Match.java index 9bb1d9fd9..cede0d489 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Match.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Match.java @@ -527,7 +527,8 @@ public com.google.protobuf.ByteString getEventBytes() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -554,7 +555,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -581,7 +583,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1459,7 +1462,8 @@ public Builder setEventBytes(com.google.protobuf.ByteString value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1485,7 +1489,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1515,7 +1520,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1549,7 +1555,8 @@ public Builder setParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1580,7 +1587,8 @@ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1616,7 +1624,8 @@ public Builder mergeParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1648,7 +1657,8 @@ public Builder clearParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1674,7 +1684,8 @@ public com.google.protobuf.Struct.Builder getParametersBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1702,7 +1713,8 @@ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/MatchOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/MatchOrBuilder.java index b954410e0..30ddca277 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/MatchOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/MatchOrBuilder.java @@ -103,7 +103,8 @@ public interface MatchOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -127,7 +128,8 @@ public interface MatchOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -151,7 +153,8 @@ public interface MatchOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParameters.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParameters.java index 66c3d7a81..8beba634a 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParameters.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParameters.java @@ -140,6 +140,23 @@ private QueryParameters( analyzeQueryTextSentiment_ = input.readBool(); break; } + case 82: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + webhookHeaders_ = + com.google.protobuf.MapField.newMapField( + WebhookHeadersDefaultEntryHolder.defaultEntry); + mutable_bitField0_ |= 0x00000002; + } + com.google.protobuf.MapEntry webhookHeaders__ = + input.readMessage( + WebhookHeadersDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + webhookHeaders_ + .getMutableMap() + .put(webhookHeaders__.getKey(), webhookHeaders__.getValue()); + break; + } default: { if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { @@ -167,6 +184,17 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { .internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_descriptor; } + @SuppressWarnings({"rawtypes"}) + @java.lang.Override + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 10: + return internalGetWebhookHeaders(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { @@ -430,7 +458,8 @@ public com.google.protobuf.StructOrBuilder getPayloadOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -460,7 +489,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -490,7 +520,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -523,6 +554,135 @@ public boolean getAnalyzeQueryTextSentiment() { return analyzeQueryTextSentiment_; } + public static final int WEBHOOK_HEADERS_FIELD_NUMBER = 10; + + private static final class WebhookHeadersDefaultEntryHolder { + static final com.google.protobuf.MapEntry defaultEntry = + com.google.protobuf.MapEntry.newDefaultInstance( + com.google.cloud.dialogflow.cx.v3.SessionProto + .internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_WebhookHeadersEntry_descriptor, + com.google.protobuf.WireFormat.FieldType.STRING, + "", + com.google.protobuf.WireFormat.FieldType.STRING, + ""); + } + + private com.google.protobuf.MapField webhookHeaders_; + + private com.google.protobuf.MapField + internalGetWebhookHeaders() { + if (webhookHeaders_ == null) { + return com.google.protobuf.MapField.emptyMapField( + WebhookHeadersDefaultEntryHolder.defaultEntry); + } + return webhookHeaders_; + } + + public int getWebhookHeadersCount() { + return internalGetWebhookHeaders().getMap().size(); + } + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public boolean containsWebhookHeaders(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetWebhookHeaders().getMap().containsKey(key); + } + /** Use {@link #getWebhookHeadersMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getWebhookHeaders() { + return getWebhookHeadersMap(); + } + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public java.util.Map getWebhookHeadersMap() { + return internalGetWebhookHeaders().getMap(); + } + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public java.lang.String getWebhookHeadersOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetWebhookHeaders().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public java.lang.String getWebhookHeadersOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetWebhookHeaders().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + private byte memoizedIsInitialized = -1; @java.lang.Override @@ -555,6 +715,8 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (analyzeQueryTextSentiment_ != false) { output.writeBool(8, analyzeQueryTextSentiment_); } + com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( + output, internalGetWebhookHeaders(), WebhookHeadersDefaultEntryHolder.defaultEntry, 10); unknownFields.writeTo(output); } @@ -583,6 +745,16 @@ public int getSerializedSize() { if (analyzeQueryTextSentiment_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, analyzeQueryTextSentiment_); } + for (java.util.Map.Entry entry : + internalGetWebhookHeaders().getMap().entrySet()) { + com.google.protobuf.MapEntry webhookHeaders__ = + WebhookHeadersDefaultEntryHolder.defaultEntry + .newBuilderForType() + .setKey(entry.getKey()) + .setValue(entry.getValue()) + .build(); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, webhookHeaders__); + } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; @@ -614,6 +786,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParameters().equals(other.getParameters())) return false; } if (getAnalyzeQueryTextSentiment() != other.getAnalyzeQueryTextSentiment()) return false; + if (!internalGetWebhookHeaders().equals(other.internalGetWebhookHeaders())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @@ -645,6 +818,10 @@ public int hashCode() { } hash = (37 * hash) + ANALYZE_QUERY_TEXT_SENTIMENT_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAnalyzeQueryTextSentiment()); + if (!internalGetWebhookHeaders().getMap().isEmpty()) { + hash = (37 * hash) + WEBHOOK_HEADERS_FIELD_NUMBER; + hash = (53 * hash) + internalGetWebhookHeaders().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; @@ -763,6 +940,26 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { .internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_descriptor; } + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMapField(int number) { + switch (number) { + case 10: + return internalGetWebhookHeaders(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + + @SuppressWarnings({"rawtypes"}) + protected com.google.protobuf.MapField internalGetMutableMapField(int number) { + switch (number) { + case 10: + return internalGetMutableWebhookHeaders(); + default: + throw new RuntimeException("Invalid map field number: " + number); + } + } + @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { @@ -820,6 +1017,7 @@ public Builder clear() { } analyzeQueryTextSentiment_ = false; + internalGetMutableWebhookHeaders().clear(); return this; } @@ -874,6 +1072,8 @@ public com.google.cloud.dialogflow.cx.v3.QueryParameters buildPartial() { result.parameters_ = parametersBuilder_.build(); } result.analyzeQueryTextSentiment_ = analyzeQueryTextSentiment_; + result.webhookHeaders_ = internalGetWebhookHeaders(); + result.webhookHeaders_.makeImmutable(); onBuilt(); return result; } @@ -967,6 +1167,7 @@ public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.QueryParameters other if (other.getAnalyzeQueryTextSentiment() != false) { setAnalyzeQueryTextSentiment(other.getAnalyzeQueryTextSentiment()); } + internalGetMutableWebhookHeaders().mergeFrom(other.internalGetWebhookHeaders()); this.mergeUnknownFields(other.unknownFields); onChanged(); return this; @@ -1922,7 +2123,8 @@ public com.google.protobuf.StructOrBuilder getPayloadOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1951,7 +2153,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1984,7 +2187,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2021,7 +2225,8 @@ public Builder setParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2055,7 +2260,8 @@ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2094,7 +2300,8 @@ public Builder mergeParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2129,7 +2336,8 @@ public Builder clearParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2158,7 +2366,8 @@ public com.google.protobuf.Struct.Builder getParametersBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2189,7 +2398,8 @@ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2270,6 +2480,215 @@ public Builder clearAnalyzeQueryTextSentiment() { return this; } + private com.google.protobuf.MapField webhookHeaders_; + + private com.google.protobuf.MapField + internalGetWebhookHeaders() { + if (webhookHeaders_ == null) { + return com.google.protobuf.MapField.emptyMapField( + WebhookHeadersDefaultEntryHolder.defaultEntry); + } + return webhookHeaders_; + } + + private com.google.protobuf.MapField + internalGetMutableWebhookHeaders() { + onChanged(); + ; + if (webhookHeaders_ == null) { + webhookHeaders_ = + com.google.protobuf.MapField.newMapField(WebhookHeadersDefaultEntryHolder.defaultEntry); + } + if (!webhookHeaders_.isMutable()) { + webhookHeaders_ = webhookHeaders_.copy(); + } + return webhookHeaders_; + } + + public int getWebhookHeadersCount() { + return internalGetWebhookHeaders().getMap().size(); + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public boolean containsWebhookHeaders(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + return internalGetWebhookHeaders().getMap().containsKey(key); + } + /** Use {@link #getWebhookHeadersMap()} instead. */ + @java.lang.Override + @java.lang.Deprecated + public java.util.Map getWebhookHeaders() { + return getWebhookHeadersMap(); + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public java.util.Map getWebhookHeadersMap() { + return internalGetWebhookHeaders().getMap(); + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public java.lang.String getWebhookHeadersOrDefault( + java.lang.String key, java.lang.String defaultValue) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetWebhookHeaders().getMap(); + return map.containsKey(key) ? map.get(key) : defaultValue; + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + @java.lang.Override + public java.lang.String getWebhookHeadersOrThrow(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + java.util.Map map = internalGetWebhookHeaders().getMap(); + if (!map.containsKey(key)) { + throw new java.lang.IllegalArgumentException(); + } + return map.get(key); + } + + public Builder clearWebhookHeaders() { + internalGetMutableWebhookHeaders().getMutableMap().clear(); + return this; + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + public Builder removeWebhookHeaders(java.lang.String key) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableWebhookHeaders().getMutableMap().remove(key); + return this; + } + /** Use alternate mutation accessors instead. */ + @java.lang.Deprecated + public java.util.Map getMutableWebhookHeaders() { + return internalGetMutableWebhookHeaders().getMutableMap(); + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + public Builder putWebhookHeaders(java.lang.String key, java.lang.String value) { + if (key == null) { + throw new java.lang.NullPointerException(); + } + if (value == null) { + throw new java.lang.NullPointerException(); + } + internalGetMutableWebhookHeaders().getMutableMap().put(key, value); + return this; + } + /** + * + * + *
+     * This field can be used to pass HTTP headers for a webhook
+     * call. These headers will be sent to webhook along with the headers that
+     * have been configured through Dialogflow web console. The headers defined
+     * within this field will overwrite the headers configured through Dialogflow
+     * console if there is a conflict. Header names are case-insensitive.
+     * Google's specified headers are not allowed. Including: "Host",
+     * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+     * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+     * 
+ * + * map<string, string> webhook_headers = 10; + */ + public Builder putAllWebhookHeaders(java.util.Map values) { + internalGetMutableWebhookHeaders().getMutableMap().putAll(values); + return this; + } + @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParametersOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParametersOrBuilder.java index 5a4ded877..37ce2709c 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParametersOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryParametersOrBuilder.java @@ -210,7 +210,8 @@ com.google.cloud.dialogflow.cx.v3.SessionEntityTypeOrBuilder getSessionEntityTyp * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -237,7 +238,8 @@ com.google.cloud.dialogflow.cx.v3.SessionEntityTypeOrBuilder getSessionEntityTyp * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -264,7 +266,8 @@ com.google.cloud.dialogflow.cx.v3.SessionEntityTypeOrBuilder getSessionEntityTyp * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -288,4 +291,93 @@ com.google.cloud.dialogflow.cx.v3.SessionEntityTypeOrBuilder getSessionEntityTyp * @return The analyzeQueryTextSentiment. */ boolean getAnalyzeQueryTextSentiment(); + + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + int getWebhookHeadersCount(); + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + boolean containsWebhookHeaders(java.lang.String key); + /** Use {@link #getWebhookHeadersMap()} instead. */ + @java.lang.Deprecated + java.util.Map getWebhookHeaders(); + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + java.util.Map getWebhookHeadersMap(); + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + java.lang.String getWebhookHeadersOrDefault(java.lang.String key, java.lang.String defaultValue); + /** + * + * + *
+   * This field can be used to pass HTTP headers for a webhook
+   * call. These headers will be sent to webhook along with the headers that
+   * have been configured through Dialogflow web console. The headers defined
+   * within this field will overwrite the headers configured through Dialogflow
+   * console if there is a conflict. Header names are case-insensitive.
+   * Google's specified headers are not allowed. Including: "Host",
+   * "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding",
+   * "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc.
+   * 
+ * + * map<string, string> webhook_headers = 10; + */ + java.lang.String getWebhookHeadersOrThrow(java.lang.String key); } diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResult.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResult.java index f37293f18..509992e7b 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResult.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResult.java @@ -639,7 +639,8 @@ public com.google.protobuf.ByteString getLanguageCodeBytes() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -666,7 +667,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -693,7 +695,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2657,7 +2660,8 @@ public Builder setLanguageCodeBytes(com.google.protobuf.ByteString value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2683,7 +2687,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2713,7 +2718,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2747,7 +2753,8 @@ public Builder setParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2778,7 +2785,8 @@ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2814,7 +2822,8 @@ public Builder mergeParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2846,7 +2855,8 @@ public Builder clearParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2872,7 +2882,8 @@ public com.google.protobuf.Struct.Builder getParametersBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2900,7 +2911,8 @@ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResultOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResultOrBuilder.java index d94255e71..582d50a36 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResultOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/QueryResultOrBuilder.java @@ -174,7 +174,8 @@ public interface QueryResultOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -198,7 +199,8 @@ public interface QueryResultOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -222,7 +224,8 @@ public interface QueryResultOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionProto.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionProto.java index 5753d554e..377ecdd10 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionProto.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SessionProto.java @@ -51,6 +51,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_WebhookHeadersEntry_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_WebhookHeadersEntry_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_dialogflow_cx_v3_QueryInput_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -163,121 +167,125 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "ch_end_offset\030\010 \001(\0132\031.google.protobuf.Du" + "ration\"X\n\013MessageType\022\034\n\030MESSAGE_TYPE_UN" + "SPECIFIED\020\000\022\016\n\nTRANSCRIPT\020\001\022\033\n\027END_OF_SI" - + "NGLE_UTTERANCE\020\002\"\234\002\n\017QueryParameters\022\021\n\t" + + "NGLE_UTTERANCE\020\002\"\260\003\n\017QueryParameters\022\021\n\t" + "time_zone\030\001 \001(\t\022)\n\014geo_location\030\002 \001(\0132\023." + "google.type.LatLng\022N\n\024session_entity_typ" + "es\030\003 \003(\01320.google.cloud.dialogflow.cx.v3" + ".SessionEntityType\022(\n\007payload\030\004 \001(\0132\027.go" + "ogle.protobuf.Struct\022+\n\nparameters\030\005 \001(\013" + "2\027.google.protobuf.Struct\022$\n\034analyze_que" - + "ry_text_sentiment\030\010 \001(\010\"\333\002\n\nQueryInput\0228" - + "\n\004text\030\002 \001(\0132(.google.cloud.dialogflow.c" - + "x.v3.TextInputH\000\022<\n\006intent\030\003 \001(\0132*.googl" - + "e.cloud.dialogflow.cx.v3.IntentInputH\000\022:" - + "\n\005audio\030\005 \001(\0132).google.cloud.dialogflow." - + "cx.v3.AudioInputH\000\022:\n\005event\030\006 \001(\0132).goog" - + "le.cloud.dialogflow.cx.v3.EventInputH\000\0228" - + "\n\004dtmf\030\007 \001(\0132(.google.cloud.dialogflow.c" - + "x.v3.DtmfInputH\000\022\032\n\rlanguage_code\030\004 \001(\tB" - + "\003\340A\002B\007\n\005input\"\300\005\n\013QueryResult\022\016\n\004text\030\001 " - + "\001(\tH\000\022\030\n\016trigger_intent\030\013 \001(\tH\000\022\024\n\ntrans" - + "cript\030\014 \001(\tH\000\022\027\n\rtrigger_event\030\016 \001(\tH\000\022\025" - + "\n\rlanguage_code\030\002 \001(\t\022+\n\nparameters\030\003 \001(" - + "\0132\027.google.protobuf.Struct\022I\n\021response_m" - + "essages\030\004 \003(\0132..google.cloud.dialogflow." - + "cx.v3.ResponseMessage\022,\n\020webhook_statuse" - + "s\030\r \003(\0132\022.google.rpc.Status\0221\n\020webhook_p" - + "ayloads\030\006 \003(\0132\027.google.protobuf.Struct\0229" - + "\n\014current_page\030\007 \001(\0132#.google.cloud.dial" - + "ogflow.cx.v3.Page\0229\n\006intent\030\010 \001(\0132%.goog" - + "le.cloud.dialogflow.cx.v3.IntentB\002\030\001\022\'\n\033" - + "intent_detection_confidence\030\t \001(\002B\002\030\001\0223\n" - + "\005match\030\017 \001(\0132$.google.cloud.dialogflow.c" - + "x.v3.Match\0220\n\017diagnostic_info\030\n \001(\0132\027.go" - + "ogle.protobuf.Struct\022Y\n\031sentiment_analys" - + "is_result\030\021 \001(\01326.google.cloud.dialogflo" - + "w.cx.v3.SentimentAnalysisResultB\007\n\005query" - + "\"\036\n\tTextInput\022\021\n\004text\030\001 \001(\tB\003\340A\002\"G\n\013Inte" - + "ntInput\0228\n\006intent\030\001 \001(\tB(\340A\002\372A\"\n dialogf" - + "low.googleapis.com/Intent\"a\n\nAudioInput\022" - + "D\n\006config\030\001 \001(\0132/.google.cloud.dialogflo" - + "w.cx.v3.InputAudioConfigB\003\340A\002\022\r\n\005audio\030\002" - + " \001(\014\"\033\n\nEventInput\022\r\n\005event\030\001 \001(\t\"1\n\tDtm" - + "fInput\022\016\n\006digits\030\001 \001(\t\022\024\n\014finish_digit\030\002" - + " \001(\t\"\361\002\n\005Match\0225\n\006intent\030\001 \001(\0132%.google." - + "cloud.dialogflow.cx.v3.Intent\022\r\n\005event\030\006" - + " \001(\t\022+\n\nparameters\030\002 \001(\0132\027.google.protob" - + "uf.Struct\022\026\n\016resolved_input\030\003 \001(\t\022B\n\nmat" - + "ch_type\030\004 \001(\0162..google.cloud.dialogflow." - + "cx.v3.Match.MatchType\022\022\n\nconfidence\030\005 \001(" - + "\002\"\204\001\n\tMatchType\022\032\n\026MATCH_TYPE_UNSPECIFIE" - + "D\020\000\022\n\n\006INTENT\020\001\022\021\n\rDIRECT_INTENT\020\002\022\025\n\021PA" - + "RAMETER_FILLING\020\003\022\014\n\010NO_MATCH\020\004\022\014\n\010NO_IN" - + "PUT\020\005\022\t\n\005EVENT\020\006\"\333\001\n\022MatchIntentRequest\022" - + ":\n\007session\030\001 \001(\tB)\340A\002\372A#\n!dialogflow.goo" - + "gleapis.com/Session\022D\n\014query_params\030\002 \001(" - + "\0132..google.cloud.dialogflow.cx.v3.QueryP" - + "arameters\022C\n\013query_input\030\003 \001(\0132).google." - + "cloud.dialogflow.cx.v3.QueryInputB\003\340A\002\"\351" - + "\001\n\023MatchIntentResponse\022\016\n\004text\030\001 \001(\tH\000\022\030" - + "\n\016trigger_intent\030\002 \001(\tH\000\022\024\n\ntranscript\030\003" - + " \001(\tH\000\022\027\n\rtrigger_event\030\006 \001(\tH\000\0225\n\007match" - + "es\030\004 \003(\0132$.google.cloud.dialogflow.cx.v3" - + ".Match\0229\n\014current_page\030\005 \001(\0132#.google.cl" - + "oud.dialogflow.cx.v3.PageB\007\n\005query\"\353\001\n\024F" - + "ulfillIntentRequest\022O\n\024match_intent_requ" - + "est\030\001 \001(\01321.google.cloud.dialogflow.cx.v" - + "3.MatchIntentRequest\0223\n\005match\030\002 \001(\0132$.go" - + "ogle.cloud.dialogflow.cx.v3.Match\022M\n\023out" - + "put_audio_config\030\003 \001(\01320.google.cloud.di" - + "alogflow.cx.v3.OutputAudioConfig\"\323\001\n\025Ful" - + "fillIntentResponse\022\023\n\013response_id\030\001 \001(\t\022" - + "@\n\014query_result\030\002 \001(\0132*.google.cloud.dia" - + "logflow.cx.v3.QueryResult\022\024\n\014output_audi" - + "o\030\003 \001(\014\022M\n\023output_audio_config\030\004 \001(\01320.g" - + "oogle.cloud.dialogflow.cx.v3.OutputAudio" - + "Config\";\n\027SentimentAnalysisResult\022\r\n\005sco" - + "re\030\001 \001(\002\022\021\n\tmagnitude\030\002 \001(\0022\304\t\n\010Sessions" - + "\022\246\002\n\014DetectIntent\0222.google.cloud.dialogf" - + "low.cx.v3.DetectIntentRequest\0323.google.c" - + "loud.dialogflow.cx.v3.DetectIntentRespon" - + "se\"\254\001\202\323\344\223\002\245\001\"E/v3/{session=projects/*/lo" - + "cations/*/agents/*/sessions/*}:detectInt" - + "ent:\001*ZY\"T/v3/{session=projects/*/locati" - + "ons/*/agents/*/environments/*/sessions/*" - + "}:detectIntent:\001*\022\230\001\n\025StreamingDetectInt" - + "ent\022;.google.cloud.dialogflow.cx.v3.Stre" - + "amingDetectIntentRequest\032<.google.cloud." - + "dialogflow.cx.v3.StreamingDetectIntentRe" - + "sponse\"\000(\0010\001\022\241\002\n\013MatchIntent\0221.google.cl" - + "oud.dialogflow.cx.v3.MatchIntentRequest\032" - + "2.google.cloud.dialogflow.cx.v3.MatchInt" - + "entResponse\"\252\001\202\323\344\223\002\243\001\"D/v3/{session=proj" - + "ects/*/locations/*/agents/*/sessions/*}:" - + "matchIntent:\001*ZX\"S/v3/{session=projects/" - + "*/locations/*/agents/*/environments/*/se" - + "ssions/*}:matchIntent:\001*\022\325\002\n\rFulfillInte" - + "nt\0223.google.cloud.dialogflow.cx.v3.Fulfi" - + "llIntentRequest\0324.google.cloud.dialogflo" - + "w.cx.v3.FulfillIntentResponse\"\330\001\202\323\344\223\002\321\001\"" - + "[/v3/{match_intent_request.session=proje" - + "cts/*/locations/*/agents/*/sessions/*}:f" - + "ulfillIntent:\001*Zo\"j/v3/{match_intent_req" - + "uest.session=projects/*/locations/*/agen" - + "ts/*/environments/*/sessions/*}:fulfillI" - + "ntent:\001*\032x\312A\031dialogflow.googleapis.com\322A" - + "Yhttps://www.googleapis.com/auth/cloud-p" - + "latform,https://www.googleapis.com/auth/" - + "dialogflowB\364\002\n!com.google.cloud.dialogfl" - + "ow.cx.v3B\014SessionProtoP\001Z?google.golang." - + "org/genproto/googleapis/cloud/dialogflow" - + "/cx/v3;cx\370\001\001\242\002\002DF\252\002\035Google.Cloud.Dialogf" - + "low.Cx.V3\352A\324\001\n!dialogflow.googleapis.com" - + "/Session\022Iprojects/{project}/locations/{" - + "location}/agents/{agent}/sessions/{sessi" - + "on}\022dprojects/{project}/locations/{locat" - + "ion}/agents/{agent}/environments/{enviro" - + "nment}/sessions/{session}b\006proto3" + + "ry_text_sentiment\030\010 \001(\010\022[\n\017webhook_heade" + + "rs\030\n \003(\0132B.google.cloud.dialogflow.cx.v3" + + ".QueryParameters.WebhookHeadersEntry\0325\n\023" + + "WebhookHeadersEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005valu" + + "e\030\002 \001(\t:\0028\001\"\333\002\n\nQueryInput\0228\n\004text\030\002 \001(\013" + + "2(.google.cloud.dialogflow.cx.v3.TextInp" + + "utH\000\022<\n\006intent\030\003 \001(\0132*.google.cloud.dial" + + "ogflow.cx.v3.IntentInputH\000\022:\n\005audio\030\005 \001(" + + "\0132).google.cloud.dialogflow.cx.v3.AudioI" + + "nputH\000\022:\n\005event\030\006 \001(\0132).google.cloud.dia" + + "logflow.cx.v3.EventInputH\000\0228\n\004dtmf\030\007 \001(\013" + + "2(.google.cloud.dialogflow.cx.v3.DtmfInp" + + "utH\000\022\032\n\rlanguage_code\030\004 \001(\tB\003\340A\002B\007\n\005inpu" + + "t\"\300\005\n\013QueryResult\022\016\n\004text\030\001 \001(\tH\000\022\030\n\016tri" + + "gger_intent\030\013 \001(\tH\000\022\024\n\ntranscript\030\014 \001(\tH" + + "\000\022\027\n\rtrigger_event\030\016 \001(\tH\000\022\025\n\rlanguage_c" + + "ode\030\002 \001(\t\022+\n\nparameters\030\003 \001(\0132\027.google.p" + + "rotobuf.Struct\022I\n\021response_messages\030\004 \003(" + + "\0132..google.cloud.dialogflow.cx.v3.Respon" + + "seMessage\022,\n\020webhook_statuses\030\r \003(\0132\022.go" + + "ogle.rpc.Status\0221\n\020webhook_payloads\030\006 \003(" + + "\0132\027.google.protobuf.Struct\0229\n\014current_pa" + + "ge\030\007 \001(\0132#.google.cloud.dialogflow.cx.v3" + + ".Page\0229\n\006intent\030\010 \001(\0132%.google.cloud.dia" + + "logflow.cx.v3.IntentB\002\030\001\022\'\n\033intent_detec" + + "tion_confidence\030\t \001(\002B\002\030\001\0223\n\005match\030\017 \001(\013" + + "2$.google.cloud.dialogflow.cx.v3.Match\0220" + + "\n\017diagnostic_info\030\n \001(\0132\027.google.protobu" + + "f.Struct\022Y\n\031sentiment_analysis_result\030\021 " + + "\001(\01326.google.cloud.dialogflow.cx.v3.Sent" + + "imentAnalysisResultB\007\n\005query\"\036\n\tTextInpu" + + "t\022\021\n\004text\030\001 \001(\tB\003\340A\002\"G\n\013IntentInput\0228\n\006i" + + "ntent\030\001 \001(\tB(\340A\002\372A\"\n dialogflow.googleap" + + "is.com/Intent\"a\n\nAudioInput\022D\n\006config\030\001 " + + "\001(\0132/.google.cloud.dialogflow.cx.v3.Inpu" + + "tAudioConfigB\003\340A\002\022\r\n\005audio\030\002 \001(\014\"\033\n\nEven" + + "tInput\022\r\n\005event\030\001 \001(\t\"1\n\tDtmfInput\022\016\n\006di" + + "gits\030\001 \001(\t\022\024\n\014finish_digit\030\002 \001(\t\"\361\002\n\005Mat" + + "ch\0225\n\006intent\030\001 \001(\0132%.google.cloud.dialog" + + "flow.cx.v3.Intent\022\r\n\005event\030\006 \001(\t\022+\n\npara" + + "meters\030\002 \001(\0132\027.google.protobuf.Struct\022\026\n" + + "\016resolved_input\030\003 \001(\t\022B\n\nmatch_type\030\004 \001(" + + "\0162..google.cloud.dialogflow.cx.v3.Match." + + "MatchType\022\022\n\nconfidence\030\005 \001(\002\"\204\001\n\tMatchT" + + "ype\022\032\n\026MATCH_TYPE_UNSPECIFIED\020\000\022\n\n\006INTEN" + + "T\020\001\022\021\n\rDIRECT_INTENT\020\002\022\025\n\021PARAMETER_FILL" + + "ING\020\003\022\014\n\010NO_MATCH\020\004\022\014\n\010NO_INPUT\020\005\022\t\n\005EVE" + + "NT\020\006\"\333\001\n\022MatchIntentRequest\022:\n\007session\030\001" + + " \001(\tB)\340A\002\372A#\n!dialogflow.googleapis.com/" + + "Session\022D\n\014query_params\030\002 \001(\0132..google.c" + + "loud.dialogflow.cx.v3.QueryParameters\022C\n" + + "\013query_input\030\003 \001(\0132).google.cloud.dialog" + + "flow.cx.v3.QueryInputB\003\340A\002\"\351\001\n\023MatchInte" + + "ntResponse\022\016\n\004text\030\001 \001(\tH\000\022\030\n\016trigger_in" + + "tent\030\002 \001(\tH\000\022\024\n\ntranscript\030\003 \001(\tH\000\022\027\n\rtr" + + "igger_event\030\006 \001(\tH\000\0225\n\007matches\030\004 \003(\0132$.g" + + "oogle.cloud.dialogflow.cx.v3.Match\0229\n\014cu" + + "rrent_page\030\005 \001(\0132#.google.cloud.dialogfl" + + "ow.cx.v3.PageB\007\n\005query\"\353\001\n\024FulfillIntent" + + "Request\022O\n\024match_intent_request\030\001 \001(\01321." + + "google.cloud.dialogflow.cx.v3.MatchInten" + + "tRequest\0223\n\005match\030\002 \001(\0132$.google.cloud.d" + + "ialogflow.cx.v3.Match\022M\n\023output_audio_co" + + "nfig\030\003 \001(\01320.google.cloud.dialogflow.cx." + + "v3.OutputAudioConfig\"\323\001\n\025FulfillIntentRe" + + "sponse\022\023\n\013response_id\030\001 \001(\t\022@\n\014query_res" + + "ult\030\002 \001(\0132*.google.cloud.dialogflow.cx.v" + + "3.QueryResult\022\024\n\014output_audio\030\003 \001(\014\022M\n\023o" + + "utput_audio_config\030\004 \001(\01320.google.cloud." + + "dialogflow.cx.v3.OutputAudioConfig\";\n\027Se" + + "ntimentAnalysisResult\022\r\n\005score\030\001 \001(\002\022\021\n\t" + + "magnitude\030\002 \001(\0022\304\t\n\010Sessions\022\246\002\n\014DetectI" + + "ntent\0222.google.cloud.dialogflow.cx.v3.De" + + "tectIntentRequest\0323.google.cloud.dialogf" + + "low.cx.v3.DetectIntentResponse\"\254\001\202\323\344\223\002\245\001" + + "\"E/v3/{session=projects/*/locations/*/ag" + + "ents/*/sessions/*}:detectIntent:\001*ZY\"T/v" + + "3/{session=projects/*/locations/*/agents" + + "/*/environments/*/sessions/*}:detectInte" + + "nt:\001*\022\230\001\n\025StreamingDetectIntent\022;.google" + + ".cloud.dialogflow.cx.v3.StreamingDetectI" + + "ntentRequest\032<.google.cloud.dialogflow.c" + + "x.v3.StreamingDetectIntentResponse\"\000(\0010\001" + + "\022\241\002\n\013MatchIntent\0221.google.cloud.dialogfl" + + "ow.cx.v3.MatchIntentRequest\0322.google.clo" + + "ud.dialogflow.cx.v3.MatchIntentResponse\"" + + "\252\001\202\323\344\223\002\243\001\"D/v3/{session=projects/*/locat" + + "ions/*/agents/*/sessions/*}:matchIntent:" + + "\001*ZX\"S/v3/{session=projects/*/locations/" + + "*/agents/*/environments/*/sessions/*}:ma" + + "tchIntent:\001*\022\325\002\n\rFulfillIntent\0223.google." + + "cloud.dialogflow.cx.v3.FulfillIntentRequ" + + "est\0324.google.cloud.dialogflow.cx.v3.Fulf" + + "illIntentResponse\"\330\001\202\323\344\223\002\321\001\"[/v3/{match_" + + "intent_request.session=projects/*/locati" + + "ons/*/agents/*/sessions/*}:fulfillIntent" + + ":\001*Zo\"j/v3/{match_intent_request.session" + + "=projects/*/locations/*/agents/*/environ" + + "ments/*/sessions/*}:fulfillIntent:\001*\032x\312A" + + "\031dialogflow.googleapis.com\322AYhttps://www" + + ".googleapis.com/auth/cloud-platform,http" + + "s://www.googleapis.com/auth/dialogflowB\364" + + "\002\n!com.google.cloud.dialogflow.cx.v3B\014Se" + + "ssionProtoP\001Z?google.golang.org/genproto" + + "/googleapis/cloud/dialogflow/cx/v3;cx\370\001\001" + + "\242\002\002DF\252\002\035Google.Cloud.Dialogflow.Cx.V3\352A\324" + + "\001\n!dialogflow.googleapis.com/Session\022Ipr" + + "ojects/{project}/locations/{location}/ag" + + "ents/{agent}/sessions/{session}\022dproject" + + "s/{project}/locations/{location}/agents/" + + "{agent}/environments/{environment}/sessi" + + "ons/{session}b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -356,6 +364,17 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { "Payload", "Parameters", "AnalyzeQueryTextSentiment", + "WebhookHeaders", + }); + internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_WebhookHeadersEntry_descriptor = + internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_WebhookHeadersEntry_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3_QueryParameters_WebhookHeadersEntry_descriptor, + new java.lang.String[] { + "Key", "Value", }); internal_static_google_cloud_dialogflow_cx_v3_QueryInput_descriptor = getDescriptor().getMessageTypes().get(6); diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequest.java new file mode 100644 index 000000000..9239e124f --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequest.java @@ -0,0 +1,665 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.StartExperiment][google.cloud.dialogflow.cx.v3.Experiments.StartExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.StartExperimentRequest} + */ +public final class StartExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.StartExperimentRequest) + StartExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use StartExperimentRequest.newBuilder() to construct. + private StartExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private StartExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StartExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private StartExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3.StartExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3.StartExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest 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.dialogflow.cx.v3.StartExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest 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.dialogflow.cx.v3.StartExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest 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.dialogflow.cx.v3.StartExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest 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.dialogflow.cx.v3.StartExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest 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.dialogflow.cx.v3.StartExperimentRequest 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 request message for [Experiments.StartExperiment][google.cloud.dialogflow.cx.v3.Experiments.StartExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.StartExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.StartExperimentRequest) + com.google.cloud.dialogflow.cx.v3.StartExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StartExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.StartExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.StartExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.StartExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3.StartExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.StartExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.StartExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.StartExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.StartExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.StartExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.StartExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3.StartExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.StartExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3.StartExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.StartExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.StartExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StartExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new StartExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.StartExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequestOrBuilder.java new file mode 100644 index 000000000..543e2dd5f --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface StartExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.StartExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequest.java new file mode 100644 index 000000000..bca0d3e01 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequest.java @@ -0,0 +1,665 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.StopExperiment][google.cloud.dialogflow.cx.v3.Experiments.StopExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.StopExperimentRequest} + */ +public final class StopExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.StopExperimentRequest) + StopExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use StopExperimentRequest.newBuilder() to construct. + private StopExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private StopExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StopExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private StopExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3.StopExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3.StopExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest 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.dialogflow.cx.v3.StopExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest 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.dialogflow.cx.v3.StopExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest 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.dialogflow.cx.v3.StopExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest 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.dialogflow.cx.v3.StopExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest 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.dialogflow.cx.v3.StopExperimentRequest 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 request message for [Experiments.StopExperiment][google.cloud.dialogflow.cx.v3.Experiments.StopExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.StopExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.StopExperimentRequest) + com.google.cloud.dialogflow.cx.v3.StopExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_StopExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.StopExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.StopExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.StopExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3.StopExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.StopExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.StopExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.StopExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.StopExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.StopExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.StopExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3.StopExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.StopExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3.StopExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.StopExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.StopExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StopExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new StopExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.StopExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequestOrBuilder.java new file mode 100644 index 000000000..263361f38 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface StopExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.StopExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequest.java index e67441799..07ce37ea6 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequest.java @@ -200,6 +200,9 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -234,6 +237,9 @@ public java.lang.String getSession() { * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -848,6 +854,9 @@ public Builder mergeFrom( * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -881,6 +890,9 @@ public java.lang.String getSession() { * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -914,6 +926,9 @@ public com.google.protobuf.ByteString getSessionBytes() { * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -946,6 +961,9 @@ public Builder setSession(java.lang.String value) { * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -974,6 +992,9 @@ public Builder clearSession() { * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequestOrBuilder.java index 573f97bbd..f63c285a7 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequestOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequestOrBuilder.java @@ -39,6 +39,9 @@ public interface StreamingDetectIntentRequestOrBuilder * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } @@ -62,6 +65,9 @@ public interface StreamingDetectIntentRequestOrBuilder * Note: session must be set in the first request. * For more information, see the [sessions * guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + * Note: Always use agent versions for production traffic. + * See [Versions and + * environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). * * * string session = 1 [(.google.api.resource_reference) = { ... } diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequest.java new file mode 100644 index 000000000..659984826 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequest.java @@ -0,0 +1,1043 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The request message for [Experiments.UpdateExperiment][google.cloud.dialogflow.cx.v3.Experiments.UpdateExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.UpdateExperimentRequest} + */ +public final class UpdateExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) + UpdateExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateExperimentRequest.newBuilder() to construct. + private UpdateExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateExperimentRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UpdateExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.dialogflow.cx.v3.Experiment.Builder subBuilder = null; + if (experiment_ != null) { + subBuilder = experiment_.toBuilder(); + } + experiment_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.Experiment.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(experiment_); + experiment_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.protobuf.FieldMask.Builder subBuilder = null; + if (updateMask_ != null) { + subBuilder = updateMask_.toBuilder(); + } + updateMask_ = + input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateMask_); + updateMask_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.Builder.class); + } + + public static final int EXPERIMENT_FIELD_NUMBER = 1; + private com.google.cloud.dialogflow.cx.v3.Experiment experiment_; + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + @java.lang.Override + public boolean hasExperiment() { + return experiment_ != null; + } + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiment() { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance() + : experiment_; + } + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentOrBuilder() { + return getExperiment(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .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 updateMask_ != null; + } + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .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 mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + 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 (experiment_ != null) { + output.writeMessage(1, getExperiment()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (experiment_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getExperiment()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += unknownFields.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.dialogflow.cx.v3.UpdateExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) obj; + + if (hasExperiment() != other.hasExperiment()) return false; + if (hasExperiment()) { + if (!getExperiment().equals(other.getExperiment())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasExperiment()) { + hash = (37 * hash) + EXPERIMENT_FIELD_NUMBER; + hash = (53 * hash) + getExperiment().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest 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.dialogflow.cx.v3.UpdateExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest 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.dialogflow.cx.v3.UpdateExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest 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.dialogflow.cx.v3.UpdateExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest 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.dialogflow.cx.v3.UpdateExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest 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.dialogflow.cx.v3.UpdateExperimentRequest 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 request message for [Experiments.UpdateExperiment][google.cloud.dialogflow.cx.v3.Experiments.UpdateExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.UpdateExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (experimentBuilder_ == null) { + experiment_ = null; + } else { + experiment_ = null; + experimentBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_UpdateExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest(this); + if (experimentBuilder_ == null) { + result.experiment_ = experiment_; + } else { + result.experiment_ = experimentBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.UpdateExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest.getDefaultInstance()) + return this; + if (other.hasExperiment()) { + mergeExperiment(other.getExperiment()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.dialogflow.cx.v3.Experiment experiment_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder> + experimentBuilder_; + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + public boolean hasExperiment() { + return experimentBuilder_ != null || experiment_ != null; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + public com.google.cloud.dialogflow.cx.v3.Experiment getExperiment() { + if (experimentBuilder_ == null) { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance() + : experiment_; + } else { + return experimentBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment(com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + experiment_ = value; + onChanged(); + } else { + experimentBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment( + com.google.cloud.dialogflow.cx.v3.Experiment.Builder builderForValue) { + if (experimentBuilder_ == null) { + experiment_ = builderForValue.build(); + onChanged(); + } else { + experimentBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeExperiment(com.google.cloud.dialogflow.cx.v3.Experiment value) { + if (experimentBuilder_ == null) { + if (experiment_ != null) { + experiment_ = + com.google.cloud.dialogflow.cx.v3.Experiment.newBuilder(experiment_) + .mergeFrom(value) + .buildPartial(); + } else { + experiment_ = value; + } + onChanged(); + } else { + experimentBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearExperiment() { + if (experimentBuilder_ == null) { + experiment_ = null; + onChanged(); + } else { + experiment_ = null; + experimentBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3.Experiment.Builder getExperimentBuilder() { + + onChanged(); + return getExperimentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentOrBuilder() { + if (experimentBuilder_ != null) { + return experimentBuilder_.getMessageOrBuilder(); + } else { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3.Experiment.getDefaultInstance() + : experiment_; + } + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder> + getExperimentFieldBuilder() { + if (experimentBuilder_ == null) { + experimentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.Experiment, + com.google.cloud.dialogflow.cx.v3.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder>( + getExperiment(), getParentForChildren(), isClean()); + experiment_ = null; + } + return experimentBuilder_; + } + + 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 mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .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 mask to control which fields get updated.
+     * 
+ * + * .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; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .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(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .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 mask to control which fields get updated.
+     * 
+ * + * .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.dialogflow.cx.v3.UpdateExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3.UpdateExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UpdateExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.UpdateExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequestOrBuilder.java new file mode 100644 index 000000000..0cc72b00a --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequestOrBuilder.java @@ -0,0 +1,104 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface UpdateExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.UpdateExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + boolean hasExperiment(); + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + com.google.cloud.dialogflow.cx.v3.Experiment getExperiment(); + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dialogflow.cx.v3.ExperimentOrBuilder getExperimentOrBuilder(); + + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistory.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistory.java new file mode 100644 index 000000000..db5e15059 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistory.java @@ -0,0 +1,1111 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * The history of variants update.
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.VariantsHistory} + */ +public final class VariantsHistory extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.VariantsHistory) + VariantsHistoryOrBuilder { + private static final long serialVersionUID = 0L; + // Use VariantsHistory.newBuilder() to construct. + private VariantsHistory(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private VariantsHistory() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new VariantsHistory(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private VariantsHistory( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder subBuilder = null; + if (variantsCase_ == 1) { + subBuilder = + ((com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_).toBuilder(); + } + variants_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3.VersionVariants.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom((com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_); + variants_ = subBuilder.buildPartial(); + } + variantsCase_ = 1; + break; + } + case 18: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (updateTime_ != null) { + subBuilder = updateTime_.toBuilder(); + } + updateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateTime_); + updateTime_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.VariantsHistory.class, + com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder.class); + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public enum VariantsCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + VERSION_VARIANTS(1), + VARIANTS_NOT_SET(0); + private final int value; + + private VariantsCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static VariantsCase valueOf(int value) { + return forNumber(value); + } + + public static VariantsCase forNumber(int value) { + switch (value) { + case 1: + return VERSION_VARIANTS; + case 0: + return VARIANTS_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public static final int VERSION_VARIANTS_FIELD_NUMBER = 1; + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 1; + } + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants getVersionVariants() { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder getVersionVariantsOrBuilder() { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + 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 (variantsCase_ == 1) { + output.writeMessage(1, (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_); + } + if (updateTime_ != null) { + output.writeMessage(2, getUpdateTime()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (variantsCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateTime()); + } + size += unknownFields.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.dialogflow.cx.v3.VariantsHistory)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.VariantsHistory other = + (com.google.cloud.dialogflow.cx.v3.VariantsHistory) obj; + + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getVariantsCase().equals(other.getVariantsCase())) return false; + switch (variantsCase_) { + case 1: + if (!getVersionVariants().equals(other.getVersionVariants())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + switch (variantsCase_) { + case 1: + hash = (37 * hash) + VERSION_VARIANTS_FIELD_NUMBER; + hash = (53 * hash) + getVersionVariants().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory 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.dialogflow.cx.v3.VariantsHistory parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory 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.dialogflow.cx.v3.VariantsHistory parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory 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.dialogflow.cx.v3.VariantsHistory parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory 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.dialogflow.cx.v3.VariantsHistory parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory 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.dialogflow.cx.v3.VariantsHistory 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 history of variants update.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.VariantsHistory} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.VariantsHistory) + com.google.cloud.dialogflow.cx.v3.VariantsHistoryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.VariantsHistory.class, + com.google.cloud.dialogflow.cx.v3.VariantsHistory.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.VariantsHistory.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + variantsCase_ = 0; + variants_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VariantsHistory_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VariantsHistory getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.VariantsHistory.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VariantsHistory build() { + com.google.cloud.dialogflow.cx.v3.VariantsHistory result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VariantsHistory buildPartial() { + com.google.cloud.dialogflow.cx.v3.VariantsHistory result = + new com.google.cloud.dialogflow.cx.v3.VariantsHistory(this); + if (variantsCase_ == 1) { + if (versionVariantsBuilder_ == null) { + result.variants_ = variants_; + } else { + result.variants_ = versionVariantsBuilder_.build(); + } + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + result.variantsCase_ = variantsCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.VariantsHistory) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.VariantsHistory) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.VariantsHistory other) { + if (other == com.google.cloud.dialogflow.cx.v3.VariantsHistory.getDefaultInstance()) + return this; + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + switch (other.getVariantsCase()) { + case VERSION_VARIANTS: + { + mergeVersionVariants(other.getVersionVariants()); + break; + } + case VARIANTS_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.VariantsHistory parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.VariantsHistory) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public Builder clearVariants() { + variantsCase_ = 0; + variants_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder> + versionVariantsBuilder_; + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 1; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants getVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } else { + if (variantsCase_ == 1) { + return versionVariantsBuilder_.getMessage(); + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + public Builder setVersionVariants(com.google.cloud.dialogflow.cx.v3.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + variants_ = value; + onChanged(); + } else { + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 1; + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + public Builder setVersionVariants( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder builderForValue) { + if (versionVariantsBuilder_ == null) { + variants_ = builderForValue.build(); + onChanged(); + } else { + versionVariantsBuilder_.setMessage(builderForValue.build()); + } + variantsCase_ = 1; + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + public Builder mergeVersionVariants(com.google.cloud.dialogflow.cx.v3.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 1 + && variants_ + != com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance()) { + variants_ = + com.google.cloud.dialogflow.cx.v3.VersionVariants.newBuilder( + (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_) + .mergeFrom(value) + .buildPartial(); + } else { + variants_ = value; + } + onChanged(); + } else { + if (variantsCase_ == 1) { + versionVariantsBuilder_.mergeFrom(value); + } + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 1; + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + public Builder clearVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 1) { + variantsCase_ = 0; + variants_ = null; + onChanged(); + } + } else { + if (variantsCase_ == 1) { + variantsCase_ = 0; + variants_ = null; + } + versionVariantsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder getVersionVariantsBuilder() { + return getVersionVariantsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if ((variantsCase_ == 1) && (versionVariantsBuilder_ != null)) { + return versionVariantsBuilder_.getMessageOrBuilder(); + } else { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder> + getVersionVariantsFieldBuilder() { + if (versionVariantsBuilder_ == null) { + if (!(variantsCase_ == 1)) { + variants_ = com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + versionVariantsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder>( + (com.google.cloud.dialogflow.cx.v3.VersionVariants) variants_, + getParentForChildren(), + isClean()); + variants_ = null; + } + variantsCase_ = 1; + onChanged(); + ; + return versionVariantsBuilder_; + } + + 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_; + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @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(); + } + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + 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_; + } + + @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.dialogflow.cx.v3.VariantsHistory) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.VariantsHistory) + private static final com.google.cloud.dialogflow.cx.v3.VariantsHistory DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.VariantsHistory(); + } + + public static com.google.cloud.dialogflow.cx.v3.VariantsHistory getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VariantsHistory parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new VariantsHistory(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.VariantsHistory getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistoryOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistoryOrBuilder.java new file mode 100644 index 000000000..ef8cc5f7f --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistoryOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface VariantsHistoryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.VariantsHistory) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + * + * @return Whether the versionVariants field is set. + */ + boolean hasVersionVariants(); + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + * + * @return The versionVariants. + */ + com.google.cloud.dialogflow.cx.v3.VersionVariants getVersionVariants(); + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3.VersionVariants version_variants = 1; + */ + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder getVersionVariantsOrBuilder(); + + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + public com.google.cloud.dialogflow.cx.v3.VariantsHistory.VariantsCase getVariantsCase(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariants.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariants.java new file mode 100644 index 000000000..8724079e6 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariants.java @@ -0,0 +1,1854 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +/** + * + * + *
+ * A list of flow version variants.
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.VersionVariants} + */ +public final class VersionVariants extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.VersionVariants) + VersionVariantsOrBuilder { + private static final long serialVersionUID = 0L; + // Use VersionVariants.newBuilder() to construct. + private VersionVariants(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private VersionVariants() { + variants_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new VersionVariants(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private VersionVariants( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + variants_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant>(); + mutable_bitField0_ |= 0x00000001; + } + variants_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + variants_ = java.util.Collections.unmodifiableList(variants_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.VersionVariants.class, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder.class); + } + + public interface VariantOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.VersionVariants.Variant) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The version. + */ + java.lang.String getVersion(); + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + com.google.protobuf.ByteString getVersionBytes(); + + /** + * + * + *
+     * Percentage of the traffic which should be routed to this
+     * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+     * 
+ * + * float traffic_allocation = 2; + * + * @return The trafficAllocation. + */ + float getTrafficAllocation(); + + /** + * + * + *
+     * Whether the variant is for the control group.
+     * 
+ * + * bool is_control_group = 3; + * + * @return The isControlGroup. + */ + boolean getIsControlGroup(); + } + /** + * + * + *
+   * A single flow version with specified traffic allocation.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.VersionVariants.Variant} + */ + public static final class Variant extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.VersionVariants.Variant) + VariantOrBuilder { + private static final long serialVersionUID = 0L; + // Use Variant.newBuilder() to construct. + private Variant(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Variant() { + version_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Variant(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Variant( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + version_ = s; + break; + } + case 21: + { + trafficAllocation_ = input.readFloat(); + break; + } + case 24: + { + isControlGroup_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.class, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder.class); + } + + public static final int VERSION_FIELD_NUMBER = 1; + private volatile java.lang.Object version_; + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The version. + */ + @java.lang.Override + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } + } + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TRAFFIC_ALLOCATION_FIELD_NUMBER = 2; + private float trafficAllocation_; + /** + * + * + *
+     * Percentage of the traffic which should be routed to this
+     * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+     * 
+ * + * float traffic_allocation = 2; + * + * @return The trafficAllocation. + */ + @java.lang.Override + public float getTrafficAllocation() { + return trafficAllocation_; + } + + public static final int IS_CONTROL_GROUP_FIELD_NUMBER = 3; + private boolean isControlGroup_; + /** + * + * + *
+     * Whether the variant is for the control group.
+     * 
+ * + * bool is_control_group = 3; + * + * @return The isControlGroup. + */ + @java.lang.Override + public boolean getIsControlGroup() { + return isControlGroup_; + } + + 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 (!getVersionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_); + } + if (trafficAllocation_ != 0F) { + output.writeFloat(2, trafficAllocation_); + } + if (isControlGroup_ != false) { + output.writeBool(3, isControlGroup_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getVersionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_); + } + if (trafficAllocation_ != 0F) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, trafficAllocation_); + } + if (isControlGroup_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, isControlGroup_); + } + size += unknownFields.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.dialogflow.cx.v3.VersionVariants.Variant)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant other = + (com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant) obj; + + if (!getVersion().equals(other.getVersion())) return false; + if (java.lang.Float.floatToIntBits(getTrafficAllocation()) + != java.lang.Float.floatToIntBits(other.getTrafficAllocation())) return false; + if (getIsControlGroup() != other.getIsControlGroup()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + hash = (37 * hash) + TRAFFIC_ALLOCATION_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getTrafficAllocation()); + hash = (37 * hash) + IS_CONTROL_GROUP_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIsControlGroup()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant 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.dialogflow.cx.v3.VersionVariants.Variant parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant 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.dialogflow.cx.v3.VersionVariants.Variant parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant 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.dialogflow.cx.v3.VersionVariants.Variant parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant 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.dialogflow.cx.v3.VersionVariants.Variant parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant 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.dialogflow.cx.v3.VersionVariants.Variant 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 single flow version with specified traffic allocation.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.VersionVariants.Variant} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.VersionVariants.Variant) + com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.class, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + version_ = ""; + + trafficAllocation_ = 0F; + + isControlGroup_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_Variant_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant build() { + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant buildPartial() { + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant result = + new com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant(this); + result.version_ = version_; + result.trafficAllocation_ = trafficAllocation_; + result.isControlGroup_ = isControlGroup_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.VersionVariants.Variant) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant other) { + if (other == com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.getDefaultInstance()) + return this; + if (!other.getVersion().isEmpty()) { + version_ = other.version_; + onChanged(); + } + if (other.getTrafficAllocation() != 0F) { + setTrafficAllocation(other.getTrafficAllocation()); + } + if (other.getIsControlGroup() != false) { + setIsControlGroup(other.getIsControlGroup()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object version_ = ""; + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @return The version. + */ + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @param value The version to set. + * @return This builder for chaining. + */ + public Builder setVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + version_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @return This builder for chaining. + */ + public Builder clearVersion() { + + version_ = getDefaultInstance().getVersion(); + onChanged(); + return this; + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @param value The bytes for version to set. + * @return This builder for chaining. + */ + public Builder setVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + version_ = value; + onChanged(); + return this; + } + + private float trafficAllocation_; + /** + * + * + *
+       * Percentage of the traffic which should be routed to this
+       * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+       * 
+ * + * float traffic_allocation = 2; + * + * @return The trafficAllocation. + */ + @java.lang.Override + public float getTrafficAllocation() { + return trafficAllocation_; + } + /** + * + * + *
+       * Percentage of the traffic which should be routed to this
+       * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+       * 
+ * + * float traffic_allocation = 2; + * + * @param value The trafficAllocation to set. + * @return This builder for chaining. + */ + public Builder setTrafficAllocation(float value) { + + trafficAllocation_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Percentage of the traffic which should be routed to this
+       * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+       * 
+ * + * float traffic_allocation = 2; + * + * @return This builder for chaining. + */ + public Builder clearTrafficAllocation() { + + trafficAllocation_ = 0F; + onChanged(); + return this; + } + + private boolean isControlGroup_; + /** + * + * + *
+       * Whether the variant is for the control group.
+       * 
+ * + * bool is_control_group = 3; + * + * @return The isControlGroup. + */ + @java.lang.Override + public boolean getIsControlGroup() { + return isControlGroup_; + } + /** + * + * + *
+       * Whether the variant is for the control group.
+       * 
+ * + * bool is_control_group = 3; + * + * @param value The isControlGroup to set. + * @return This builder for chaining. + */ + public Builder setIsControlGroup(boolean value) { + + isControlGroup_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Whether the variant is for the control group.
+       * 
+ * + * bool is_control_group = 3; + * + * @return This builder for chaining. + */ + public Builder clearIsControlGroup() { + + isControlGroup_ = 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.dialogflow.cx.v3.VersionVariants.Variant) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.VersionVariants.Variant) + private static final com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant(); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Variant parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Variant(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.VersionVariants.Variant getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int VARIANTS_FIELD_NUMBER = 1; + private java.util.List variants_; + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public java.util.List + getVariantsList() { + return variants_; + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder> + getVariantsOrBuilderList() { + return variants_; + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public int getVariantsCount() { + return variants_.size(); + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant getVariants(int index) { + return variants_.get(index); + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder getVariantsOrBuilder( + int index) { + return variants_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < variants_.size(); i++) { + output.writeMessage(1, variants_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < variants_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, variants_.get(i)); + } + size += unknownFields.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.dialogflow.cx.v3.VersionVariants)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3.VersionVariants other = + (com.google.cloud.dialogflow.cx.v3.VersionVariants) obj; + + if (!getVariantsList().equals(other.getVariantsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getVariantsCount() > 0) { + hash = (37 * hash) + VARIANTS_FIELD_NUMBER; + hash = (53 * hash) + getVariantsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants 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.dialogflow.cx.v3.VersionVariants parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants 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.dialogflow.cx.v3.VersionVariants parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants 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.dialogflow.cx.v3.VersionVariants parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants 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.dialogflow.cx.v3.VersionVariants parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants 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.dialogflow.cx.v3.VersionVariants 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 list of flow version variants.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3.VersionVariants} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.VersionVariants) + com.google.cloud.dialogflow.cx.v3.VersionVariantsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3.VersionVariants.class, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3.VersionVariants.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getVariantsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (variantsBuilder_ == null) { + variants_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + variantsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3_VersionVariants_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants build() { + com.google.cloud.dialogflow.cx.v3.VersionVariants result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3.VersionVariants buildPartial() { + com.google.cloud.dialogflow.cx.v3.VersionVariants result = + new com.google.cloud.dialogflow.cx.v3.VersionVariants(this); + int from_bitField0_ = bitField0_; + if (variantsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + variants_ = java.util.Collections.unmodifiableList(variants_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.variants_ = variants_; + } else { + result.variants_ = variantsBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3.VersionVariants) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3.VersionVariants) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.VersionVariants other) { + if (other == com.google.cloud.dialogflow.cx.v3.VersionVariants.getDefaultInstance()) + return this; + if (variantsBuilder_ == null) { + if (!other.variants_.isEmpty()) { + if (variants_.isEmpty()) { + variants_ = other.variants_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureVariantsIsMutable(); + variants_.addAll(other.variants_); + } + onChanged(); + } + } else { + if (!other.variants_.isEmpty()) { + if (variantsBuilder_.isEmpty()) { + variantsBuilder_.dispose(); + variantsBuilder_ = null; + variants_ = other.variants_; + bitField0_ = (bitField0_ & ~0x00000001); + variantsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getVariantsFieldBuilder() + : null; + } else { + variantsBuilder_.addAllMessages(other.variants_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3.VersionVariants parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3.VersionVariants) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List variants_ = + java.util.Collections.emptyList(); + + private void ensureVariantsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + variants_ = + new java.util.ArrayList( + variants_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder> + variantsBuilder_; + + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public java.util.List + getVariantsList() { + if (variantsBuilder_ == null) { + return java.util.Collections.unmodifiableList(variants_); + } else { + return variantsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public int getVariantsCount() { + if (variantsBuilder_ == null) { + return variants_.size(); + } else { + return variantsBuilder_.getCount(); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant getVariants(int index) { + if (variantsBuilder_ == null) { + return variants_.get(index); + } else { + return variantsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder setVariants( + int index, com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant value) { + if (variantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsIsMutable(); + variants_.set(index, value); + onChanged(); + } else { + variantsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder setVariants( + int index, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder builderForValue) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.set(index, builderForValue.build()); + onChanged(); + } else { + variantsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder addVariants(com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant value) { + if (variantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsIsMutable(); + variants_.add(value); + onChanged(); + } else { + variantsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder addVariants( + int index, com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant value) { + if (variantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsIsMutable(); + variants_.add(index, value); + onChanged(); + } else { + variantsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder addVariants( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder builderForValue) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.add(builderForValue.build()); + onChanged(); + } else { + variantsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder addVariants( + int index, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder builderForValue) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.add(index, builderForValue.build()); + onChanged(); + } else { + variantsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder addAllVariants( + java.lang.Iterable + values) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, variants_); + onChanged(); + } else { + variantsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder clearVariants() { + if (variantsBuilder_ == null) { + variants_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + variantsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public Builder removeVariants(int index) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.remove(index); + onChanged(); + } else { + variantsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder getVariantsBuilder( + int index) { + return getVariantsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder getVariantsOrBuilder( + int index) { + if (variantsBuilder_ == null) { + return variants_.get(index); + } else { + return variantsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder> + getVariantsOrBuilderList() { + if (variantsBuilder_ != null) { + return variantsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(variants_); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder addVariantsBuilder() { + return getVariantsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.getDefaultInstance()); + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder addVariantsBuilder( + int index) { + return getVariantsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.getDefaultInstance()); + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + public java.util.List + getVariantsBuilderList() { + return getVariantsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder> + getVariantsFieldBuilder() { + if (variantsBuilder_ == null) { + variantsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant, + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant.Builder, + com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder>( + variants_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + variants_ = null; + } + return variantsBuilder_; + } + + @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.dialogflow.cx.v3.VersionVariants) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.VersionVariants) + private static final com.google.cloud.dialogflow.cx.v3.VersionVariants DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.VersionVariants(); + } + + public static com.google.cloud.dialogflow.cx.v3.VersionVariants getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VersionVariants parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new VersionVariants(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3.VersionVariants getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariantsOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariantsOrBuilder.java new file mode 100644 index 000000000..11dfaea8f --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariantsOrBuilder.java @@ -0,0 +1,78 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3/experiment.proto + +package com.google.cloud.dialogflow.cx.v3; + +public interface VersionVariantsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3.VersionVariants) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + java.util.List getVariantsList(); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + com.google.cloud.dialogflow.cx.v3.VersionVariants.Variant getVariants(int index); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + int getVariantsCount(); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + java.util.List + getVariantsOrBuilderList(); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3.VersionVariants.Variant variants = 1; + */ + com.google.cloud.dialogflow.cx.v3.VersionVariants.VariantOrBuilder getVariantsOrBuilder( + int index); +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/experiment.proto b/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/experiment.proto new file mode 100644 index 000000000..92f48189b --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/experiment.proto @@ -0,0 +1,415 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.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.dialogflow.cx.v3; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/duration.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; +import "google/protobuf/timestamp.proto"; + +option cc_enable_arenas = true; +option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3"; +option go_package = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3;cx"; +option java_multiple_files = true; +option java_outer_classname = "ExperimentProto"; +option java_package = "com.google.cloud.dialogflow.cx.v3"; +option objc_class_prefix = "DF"; + +// Service for managing [Experiments][google.cloud.dialogflow.cx.v3.Experiment]. +service Experiments { + option (google.api.default_host) = "dialogflow.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform," + "https://www.googleapis.com/auth/dialogflow"; + + // Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment]. + rpc ListExperiments(ListExperimentsRequest) returns (ListExperimentsResponse) { + option (google.api.http) = { + get: "/v3/{parent=projects/*/locations/*/agents/*/environments/*}/experiments" + }; + option (google.api.method_signature) = "parent"; + } + + // Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + rpc GetExperiment(GetExperimentRequest) returns (Experiment) { + option (google.api.http) = { + get: "/v3/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Creates an [Experiment][google.cloud.dialogflow.cx.v3.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3.Environment]. + rpc CreateExperiment(CreateExperimentRequest) returns (Experiment) { + option (google.api.http) = { + post: "/v3/{parent=projects/*/locations/*/agents/*/environments/*}/experiments" + body: "experiment" + }; + option (google.api.method_signature) = "parent,experiment"; + } + + // Updates the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + rpc UpdateExperiment(UpdateExperimentRequest) returns (Experiment) { + option (google.api.http) = { + patch: "/v3/{experiment.name=projects/*/locations/*/agents/*/environments/*/experiments/*}" + body: "experiment" + }; + option (google.api.method_signature) = "experiment,update_mask"; + } + + // Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. + rpc DeleteExperiment(DeleteExperimentRequest) returns (google.protobuf.Empty) { + option (google.api.http) = { + delete: "/v3/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Starts the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of + // experiment from PENDING to RUNNING. + rpc StartExperiment(StartExperimentRequest) returns (Experiment) { + option (google.api.http) = { + post: "/v3/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}:start" + body: "*" + }; + option (google.api.method_signature) = "name"; + } + + // Stops the specified [Experiment][google.cloud.dialogflow.cx.v3.Experiment]. This rpc only changes the state of + // experiment from RUNNING to DONE. + rpc StopExperiment(StopExperimentRequest) returns (Experiment) { + option (google.api.http) = { + post: "/v3/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}:stop" + body: "*" + }; + option (google.api.method_signature) = "name"; + } +} + +// Represents an experiment in an environment. +// Next ID: 13 +message Experiment { + option (google.api.resource) = { + type: "dialogflow.googleapis.com/Experiment" + pattern: "projects/{project}/locations/{location}/agents/{agent}/environments/{environment}/experiments/{experiment}" + }; + + // Definition of the experiment. + // Next ID: 3 + message Definition { + // The condition defines which subset of sessions are selected for + // this experiment. If not specified, all sessions are eligible. E.g. + // "query_input.language_code=en" See the [conditions + // reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition). + string condition = 1; + + // The variants of the experiment. We currently only support single variant + // experiment. + oneof variants { + // The flow versions as the variants of this experiment. + VersionVariants version_variants = 2; + } + } + + // The inference result which includes an objective metric to optimize and the + // confidence interval. + message Result { + // A confidence interval is a range of possible values for the experiment + // objective you are trying to measure. + message ConfidenceInterval { + // The confidence level used to construct the interval, i.e. there is X% + // chance that the true value is within this interval. + double confidence_level = 1; + + // The percent change between an experiment metric's value and the value + // for its control. + double ratio = 2; + + // Lower bound of the interval. + double lower_bound = 3; + + // Upper bound of the interval. + double upper_bound = 4; + } + + // Metric and corresponding confidence intervals. + message Metric { + // The type of the metric. + MetricType type = 1; + + // The actual value of the metric. + oneof value { + // Ratio value of a metric. + double ratio = 2; + } + + // The probability that the treatment is better than all other treatments + // in the experiment + ConfidenceInterval confidence_interval = 3; + } + + // Version variant and associated metrics. + message VersionMetrics { + // The name of the flow [Version][google.cloud.dialogflow.cx.v3.Version]. + // Format: `projects//locations//agents//flows//versions/`. + string version = 1 [(google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Version" + }]; + + // The metrics and corresponding confidence intervals in the inference + // result. + repeated Metric metrics = 2; + + // Number of sessions that were allocated to this version. + int32 session_count = 3; + } + + // Types of metric for Dialogflow experiment. + enum MetricType { + // Metric unspecified. + METRIC_UNSPECIFIED = 0; + + // Percentage of contained sessions without user calling back in 24 hours. + CONTAINED_SESSION_NO_CALLBACK_RATE = 1; + + // Percentage of sessions that were handed to a human agent. + LIVE_AGENT_HANDOFF_RATE = 2; + + // Percentage of sessions with the same user calling back. + CALLBACK_SESSION_RATE = 3; + + // Percentage of sessions where user hung up. + ABANDONED_SESSION_RATE = 4; + + // Percentage of sessions reached Dialogflow 'END_PAGE' or + // 'END_SESSION'. + SESSION_END_RATE = 5; + } + + // Version variants and metrics. + repeated VersionMetrics version_metrics = 1; + + // The last time the experiment's stats data was updated. Will have default + // value if stats have never been computed for this experiment. + google.protobuf.Timestamp last_update_time = 2; + } + + // The state of the experiment. + enum State { + // State unspecified. + STATE_UNSPECIFIED = 0; + + // The experiment is created but not started yet. + DRAFT = 1; + + // The experiment is running. + RUNNING = 2; + + // The experiment is done. + DONE = 3; + } + + // The name of the experiment. + // Format: projects//locations//agents//environments//experiments/.. + string name = 1; + + // Required. The human-readable name of the experiment (unique in an environment). Limit + // of 64 characters. + string display_name = 2 [(google.api.field_behavior) = REQUIRED]; + + // The human-readable description of the experiment. + string description = 3; + + // The current state of the experiment. + // Transition triggered by Expriments.StartExperiment: PENDING->RUNNING. + // Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or + // RUNNING->CANCELLED. + State state = 4; + + // The definition of the experiment. + Definition definition = 5; + + // Inference result of the experiment. + Result result = 6; + + // Creation time of this experiment. + google.protobuf.Timestamp create_time = 7; + + // Start time of this experiment. + google.protobuf.Timestamp start_time = 8; + + // End time of this experiment. + google.protobuf.Timestamp end_time = 9; + + // Last update time of this experiment. + google.protobuf.Timestamp last_update_time = 10; + + // Maximum number of days to run the experiment. + google.protobuf.Duration experiment_length = 11; + + // The history of updates to the experiment variants. + repeated VariantsHistory variants_history = 12; +} + +// A list of flow version variants. +message VersionVariants { + // A single flow version with specified traffic allocation. + message Variant { + // The name of the flow version. + // Format: `projects//locations//agents//flows//versions/`. + string version = 1; + + // Percentage of the traffic which should be routed to this + // version of flow. Traffic allocation for a single flow must sum up to 1.0. + float traffic_allocation = 2; + + // Whether the variant is for the control group. + bool is_control_group = 3; + } + + // A list of flow version variants. + repeated Variant variants = 1; +} + +// The history of variants update. +message VariantsHistory { + // The variants updated. We currently only support single variant + // experiment. + oneof variants { + // The flow versions as the variants. + VersionVariants version_variants = 1; + } + + // Update time of the variants. + google.protobuf.Timestamp update_time = 2; +} + +// The request message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3.Experiments.ListExperiments]. +message ListExperimentsRequest { + // Required. The [Environment][google.cloud.dialogflow.cx.v3.Environment] to list all environments for. + // Format: `projects//locations//agents//environments/`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "dialogflow.googleapis.com/Experiment" + } + ]; + + // The maximum number of items to return in a single page. By default 20 and + // at most 100. + int32 page_size = 2; + + // The next_page_token value returned from a previous list request. + string page_token = 3; +} + +// The response message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3.Experiments.ListExperiments]. +message ListExperimentsResponse { + // The list of experiments. There will be a maximum number of items + // returned based on the page_size field in the request. The list may in some + // cases be empty or contain fewer entries than page_size even if this isn't + // the last page. + repeated Experiment experiments = 1; + + // Token to retrieve the next page of results, or empty if there are no more + // results in the list. + string next_page_token = 2; +} + +// The request message for [Experiments.GetExperiment][google.cloud.dialogflow.cx.v3.Experiments.GetExperiment]. +message GetExperimentRequest { + // Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment]. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} + +// The request message for [Experiments.CreateExperiment][google.cloud.dialogflow.cx.v3.Experiments.CreateExperiment]. +message CreateExperimentRequest { + // Required. The [Agent][google.cloud.dialogflow.cx.v3.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3.Environment] for. + // Format: `projects//locations//agents//environments/`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "dialogflow.googleapis.com/Experiment" + } + ]; + + // Required. The experiment to create. + Experiment experiment = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for [Experiments.UpdateExperiment][google.cloud.dialogflow.cx.v3.Experiments.UpdateExperiment]. +message UpdateExperimentRequest { + // Required. The experiment to update. + Experiment experiment = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The mask to control which fields get updated. + google.protobuf.FieldMask update_mask = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for [Experiments.DeleteExperiment][google.cloud.dialogflow.cx.v3.Experiments.DeleteExperiment]. +message DeleteExperimentRequest { + // Required. The name of the [Environment][google.cloud.dialogflow.cx.v3.Environment] to delete. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} + +// The request message for [Experiments.StartExperiment][google.cloud.dialogflow.cx.v3.Experiments.StartExperiment]. +message StartExperimentRequest { + // Required. Resource name of the experiment to start. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} + +// The request message for [Experiments.StopExperiment][google.cloud.dialogflow.cx.v3.Experiments.StopExperiment]. +message StopExperimentRequest { + // Required. Resource name of the experiment to stop. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} diff --git a/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/session.proto b/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/session.proto index f2e8968b7..55de80b91 100644 --- a/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/session.proto +++ b/proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/session.proto @@ -57,6 +57,10 @@ service Sessions { // as a result. This method is not idempotent, because it may cause session // entity types to be updated, which in turn might affect results of future // queries. + // + // Note: Always use agent versions for production traffic. + // See [Versions and + // environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). rpc DetectIntent(DetectIntentRequest) returns (DetectIntentResponse) { option (google.api.http) = { post: "/v3/{session=projects/*/locations/*/agents/*/sessions/*}:detectIntent" @@ -71,6 +75,10 @@ service Sessions { // Processes a natural language query in audio format in a streaming fashion // and returns structured, actionable data as a result. This method is only // available via the gRPC API (not REST). + // + // Note: Always use agent versions for production traffic. + // See [Versions and + // environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). rpc StreamingDetectIntent(stream StreamingDetectIntentRequest) returns (stream StreamingDetectIntentResponse) { } @@ -116,6 +124,10 @@ message DetectIntentRequest { // // For more information, see the [sessions // guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + // + // Note: Always use agent versions for production traffic. + // See [Versions and + // environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). string session = 1 [ (google.api.field_behavior) = REQUIRED, (google.api.resource_reference) = { @@ -201,6 +213,10 @@ message StreamingDetectIntentRequest { // // For more information, see the [sessions // guide](https://cloud.google.com/dialogflow/cx/docs/concept/session). + // + // Note: Always use agent versions for production traffic. + // See [Versions and + // environments](https://cloud.google.com/dialogflow/cx/docs/concept/version). string session = 1 [(google.api.resource_reference) = { type: "dialogflow.googleapis.com/Session" }]; @@ -364,7 +380,8 @@ message QueryParameters { // - MapKey value: parameter name // - MapValue type: // - If parameter's entity type is a composite entity: map - // - Else: string or number, depending on parameter value type + // - Else: depending on parameter value type, could be one of string, + // number, boolean, null, list or map // - MapValue value: // - If parameter's entity type is a composite entity: // map from composite entity property names to property values @@ -374,6 +391,16 @@ message QueryParameters { // Configures whether sentiment analysis should be performed. If not // provided, sentiment analysis is not performed. bool analyze_query_text_sentiment = 8; + + // This field can be used to pass HTTP headers for a webhook + // call. These headers will be sent to webhook along with the headers that + // have been configured through Dialogflow web console. The headers defined + // within this field will overwrite the headers configured through Dialogflow + // console if there is a conflict. Header names are case-insensitive. + // Google's specified headers are not allowed. Including: "Host", + // "Content-Length", "Connection", "From", "User-Agent", "Accept-Encoding", + // "If-Modified-Since", "If-None-Match", "X-Forwarded-For", etc. + map webhook_headers = 10; } // Represents the query input. It can contain one of: @@ -449,7 +476,8 @@ message QueryResult { // - MapKey value: parameter name // - MapValue type: // - If parameter's entity type is a composite entity: map - // - Else: string or number, depending on parameter value type + // - Else: depending on parameter value type, could be one of string, + // number, boolean, null, list or map // - MapValue value: // - If parameter's entity type is a composite entity: // map from composite entity property names to property values @@ -600,7 +628,8 @@ message Match { // - MapKey value: parameter name // - MapValue type: // - If parameter's entity type is a composite entity: map - // - Else: string or number, depending on parameter value type + // - Else: depending on parameter value type, could be one of string, + // number, boolean, null, list or map // - MapValue value: // - If parameter's entity type is a composite entity: // map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Agent.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Agent.java index 99ed32dc1..277f6c0b9 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Agent.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Agent.java @@ -26,9 +26,13 @@ * that transform user requests into actionable data. You can include agents * in your app, product, or service to determine user intent and respond to the * user in a natural way. - * After you create an agent, you can add [Intents][google.cloud.dialogflow.cx.v3beta1.Intent], - * [Entity Types][google.cloud.dialogflow.cx.v3beta1.EntityType], [Flows][google.cloud.dialogflow.cx.v3beta1.Flow], [Fulfillments][google.cloud.dialogflow.cx.v3beta1.Fulfillment], - * [Webhooks][google.cloud.dialogflow.cx.v3beta1.Webhook], and so on to manage the conversation flows.. + * After you create an agent, you can add + * [Intents][google.cloud.dialogflow.cx.v3beta1.Intent], [Entity + * Types][google.cloud.dialogflow.cx.v3beta1.EntityType], + * [Flows][google.cloud.dialogflow.cx.v3beta1.Flow], + * [Fulfillments][google.cloud.dialogflow.cx.v3beta1.Fulfillment], + * [Webhooks][google.cloud.dialogflow.cx.v3beta1.Webhook], and so on to manage + * the conversation flows.. * * * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Agent} @@ -199,7 +203,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { * *
    * The unique identifier of the agent.
-   * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+   * Required for the
+   * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+   * method.
+   * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
    * populates the name automatically.
    * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
    * 
@@ -225,7 +232,10 @@ public java.lang.String getName() { * *
    * The unique identifier of the agent.
-   * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+   * Required for the
+   * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+   * method.
+   * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
    * populates the name automatically.
    * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
    * 
@@ -306,7 +316,9 @@ public com.google.protobuf.ByteString getDisplayNameBytes() { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -333,7 +345,9 @@ public java.lang.String getDefaultLanguageCode() { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -570,11 +584,10 @@ public com.google.cloud.dialogflow.cx.v3beta1.SpeechToTextSettings getSpeechToTe * * *
-   * Immutable. Name of the start flow in this agent. A start flow will be automatically
-   * created when the agent is created, and can only be deleted by deleting the
-   * agent.
-   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-   * ID>/flows/<Flow ID>`.
+   * Immutable. Name of the start flow in this agent. A start flow will be
+   * automatically created when the agent is created, and can only be deleted by
+   * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+   * ID>/agents/<Agent ID>/flows/<Flow ID>`.
    * 
* * @@ -599,11 +612,10 @@ public java.lang.String getStartFlow() { * * *
-   * Immutable. Name of the start flow in this agent. A start flow will be automatically
-   * created when the agent is created, and can only be deleted by deleting the
-   * agent.
-   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-   * ID>/flows/<Flow ID>`.
+   * Immutable. Name of the start flow in this agent. A start flow will be
+   * automatically created when the agent is created, and can only be deleted by
+   * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+   * ID>/agents/<Agent ID>/flows/<Flow ID>`.
    * 
* * @@ -916,9 +928,13 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * that transform user requests into actionable data. You can include agents * in your app, product, or service to determine user intent and respond to the * user in a natural way. - * After you create an agent, you can add [Intents][google.cloud.dialogflow.cx.v3beta1.Intent], - * [Entity Types][google.cloud.dialogflow.cx.v3beta1.EntityType], [Flows][google.cloud.dialogflow.cx.v3beta1.Flow], [Fulfillments][google.cloud.dialogflow.cx.v3beta1.Fulfillment], - * [Webhooks][google.cloud.dialogflow.cx.v3beta1.Webhook], and so on to manage the conversation flows.. + * After you create an agent, you can add + * [Intents][google.cloud.dialogflow.cx.v3beta1.Intent], [Entity + * Types][google.cloud.dialogflow.cx.v3beta1.EntityType], + * [Flows][google.cloud.dialogflow.cx.v3beta1.Flow], + * [Fulfillments][google.cloud.dialogflow.cx.v3beta1.Fulfillment], + * [Webhooks][google.cloud.dialogflow.cx.v3beta1.Webhook], and so on to manage + * the conversation flows.. * * * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Agent} @@ -1145,7 +1161,10 @@ public Builder mergeFrom( * *
      * The unique identifier of the agent.
-     * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+     * Required for the
+     * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+     * method.
+     * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
      * populates the name automatically.
      * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
      * 
@@ -1170,7 +1189,10 @@ public java.lang.String getName() { * *
      * The unique identifier of the agent.
-     * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+     * Required for the
+     * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+     * method.
+     * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
      * populates the name automatically.
      * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
      * 
@@ -1195,7 +1217,10 @@ public com.google.protobuf.ByteString getNameBytes() { * *
      * The unique identifier of the agent.
-     * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+     * Required for the
+     * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+     * method.
+     * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
      * populates the name automatically.
      * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
      * 
@@ -1219,7 +1244,10 @@ public Builder setName(java.lang.String value) { * *
      * The unique identifier of the agent.
-     * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+     * Required for the
+     * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+     * method.
+     * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
      * populates the name automatically.
      * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
      * 
@@ -1239,7 +1267,10 @@ public Builder clearName() { * *
      * The unique identifier of the agent.
-     * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+     * Required for the
+     * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+     * method.
+     * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
      * populates the name automatically.
      * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
      * 
@@ -1375,7 +1406,9 @@ public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1401,7 +1434,9 @@ public java.lang.String getDefaultLanguageCode() { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1427,7 +1462,9 @@ public com.google.protobuf.ByteString getDefaultLanguageCodeBytes() { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1452,7 +1489,9 @@ public Builder setDefaultLanguageCode(java.lang.String value) { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -1473,7 +1512,9 @@ public Builder clearDefaultLanguageCode() { * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -2045,11 +2086,10 @@ public Builder clearSpeechToTextSettings() { * * *
-     * Immutable. Name of the start flow in this agent. A start flow will be automatically
-     * created when the agent is created, and can only be deleted by deleting the
-     * agent.
-     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-     * ID>/flows/<Flow ID>`.
+     * Immutable. Name of the start flow in this agent. A start flow will be
+     * automatically created when the agent is created, and can only be deleted by
+     * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+     * ID>/agents/<Agent ID>/flows/<Flow ID>`.
      * 
* * @@ -2073,11 +2113,10 @@ public java.lang.String getStartFlow() { * * *
-     * Immutable. Name of the start flow in this agent. A start flow will be automatically
-     * created when the agent is created, and can only be deleted by deleting the
-     * agent.
-     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-     * ID>/flows/<Flow ID>`.
+     * Immutable. Name of the start flow in this agent. A start flow will be
+     * automatically created when the agent is created, and can only be deleted by
+     * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+     * ID>/agents/<Agent ID>/flows/<Flow ID>`.
      * 
* * @@ -2101,11 +2140,10 @@ public com.google.protobuf.ByteString getStartFlowBytes() { * * *
-     * Immutable. Name of the start flow in this agent. A start flow will be automatically
-     * created when the agent is created, and can only be deleted by deleting the
-     * agent.
-     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-     * ID>/flows/<Flow ID>`.
+     * Immutable. Name of the start flow in this agent. A start flow will be
+     * automatically created when the agent is created, and can only be deleted by
+     * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+     * ID>/agents/<Agent ID>/flows/<Flow ID>`.
      * 
* * @@ -2128,11 +2166,10 @@ public Builder setStartFlow(java.lang.String value) { * * *
-     * Immutable. Name of the start flow in this agent. A start flow will be automatically
-     * created when the agent is created, and can only be deleted by deleting the
-     * agent.
-     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-     * ID>/flows/<Flow ID>`.
+     * Immutable. Name of the start flow in this agent. A start flow will be
+     * automatically created when the agent is created, and can only be deleted by
+     * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+     * ID>/agents/<Agent ID>/flows/<Flow ID>`.
      * 
* * @@ -2151,11 +2188,10 @@ public Builder clearStartFlow() { * * *
-     * Immutable. Name of the start flow in this agent. A start flow will be automatically
-     * created when the agent is created, and can only be deleted by deleting the
-     * agent.
-     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-     * ID>/flows/<Flow ID>`.
+     * Immutable. Name of the start flow in this agent. A start flow will be
+     * automatically created when the agent is created, and can only be deleted by
+     * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+     * ID>/agents/<Agent ID>/flows/<Flow ID>`.
      * 
* * diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentOrBuilder.java index 10b3e8539..c5b313aea 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentOrBuilder.java @@ -28,7 +28,10 @@ public interface AgentOrBuilder * *
    * The unique identifier of the agent.
-   * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+   * Required for the
+   * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+   * method.
+   * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
    * populates the name automatically.
    * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
    * 
@@ -43,7 +46,10 @@ public interface AgentOrBuilder * *
    * The unique identifier of the agent.
-   * Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
+   * Required for the
+   * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]
+   * method.
+   * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]
    * populates the name automatically.
    * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent ID>`.
    * 
@@ -87,7 +93,9 @@ public interface AgentOrBuilder * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -103,7 +111,9 @@ public interface AgentOrBuilder * See [Language * Support](https://cloud.google.com/dialogflow/docs/reference/language) * for a list of the currently supported language codes. - * This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + * This field cannot be set by the + * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + * method. * * * string default_language_code = 3 [(.google.api.field_behavior) = IMMUTABLE]; @@ -242,11 +252,10 @@ public interface AgentOrBuilder * * *
-   * Immutable. Name of the start flow in this agent. A start flow will be automatically
-   * created when the agent is created, and can only be deleted by deleting the
-   * agent.
-   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-   * ID>/flows/<Flow ID>`.
+   * Immutable. Name of the start flow in this agent. A start flow will be
+   * automatically created when the agent is created, and can only be deleted by
+   * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+   * ID>/agents/<Agent ID>/flows/<Flow ID>`.
    * 
* * @@ -260,11 +269,10 @@ public interface AgentOrBuilder * * *
-   * Immutable. Name of the start flow in this agent. A start flow will be automatically
-   * created when the agent is created, and can only be deleted by deleting the
-   * agent.
-   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
-   * ID>/flows/<Flow ID>`.
+   * Immutable. Name of the start flow in this agent. A start flow will be
+   * automatically created when the agent is created, and can only be deleted by
+   * deleting the agent. Format: `projects/<Project ID>/locations/<Location
+   * ID>/agents/<Agent ID>/flows/<Flow ID>`.
    * 
* * diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentProto.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentProto.java index ee7514b79..fe5e0b201 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentProto.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentProto.java @@ -86,88 +86,90 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "le/api/client.proto\032\037google/api/field_be" + "havior.proto\032\031google/api/resource.proto\032" + "-google/cloud/dialogflow/cx/v3beta1/flow" - + ".proto\032#google/longrunning/operations.pr" - + "oto\032\033google/protobuf/empty.proto\032 google" - + "/protobuf/field_mask.proto\"8\n\024SpeechToTe" - + "xtSettings\022 \n\030enable_speech_adaptation\030\001" - + " \001(\010\"\317\003\n\005Agent\022\014\n\004name\030\001 \001(\t\022\031\n\014display_" - + "name\030\002 \001(\tB\003\340A\002\022\"\n\025default_language_code" - + "\030\003 \001(\tB\003\340A\005\022\026\n\ttime_zone\030\005 \001(\tB\003\340A\002\022\023\n\013d" - + "escription\030\006 \001(\t\022\022\n\navatar_uri\030\007 \001(\t\022Y\n\027" - + "speech_to_text_settings\030\r \001(\01328.google.c" - + "loud.dialogflow.cx.v3beta1.SpeechToTextS" - + "ettings\022:\n\nstart_flow\030\020 \001(\tB&\340A\005\372A \n\036dia" - + "logflow.googleapis.com/Flow\022\"\n\032enable_st" - + "ackdriver_logging\030\022 \001(\010\022\037\n\027enable_spell_" - + "correction\030\024 \001(\010:\\\352AY\n\037dialogflow.google" - + "apis.com/Agent\0226projects/{project}/locat" - + "ions/{location}/agents/{agent}\"s\n\021ListAg" - + "entsRequest\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037dia" - + "logflow.googleapis.com/Agent\022\021\n\tpage_siz" - + "e\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"h\n\022ListAgent" - + "sResponse\0229\n\006agents\030\001 \003(\0132).google.cloud" - + ".dialogflow.cx.v3beta1.Agent\022\027\n\017next_pag" - + "e_token\030\002 \001(\t\"H\n\017GetAgentRequest\0225\n\004name" - + "\030\001 \001(\tB\'\340A\002\372A!\n\037dialogflow.googleapis.co" - + "m/Agent\"\214\001\n\022CreateAgentRequest\0227\n\006parent" - + "\030\001 \001(\tB\'\340A\002\372A!\022\037dialogflow.googleapis.co" - + "m/Agent\022=\n\005agent\030\002 \001(\0132).google.cloud.di" - + "alogflow.cx.v3beta1.AgentB\003\340A\002\"\204\001\n\022Updat" - + "eAgentRequest\022=\n\005agent\030\001 \001(\0132).google.cl" - + "oud.dialogflow.cx.v3beta1.AgentB\003\340A\002\022/\n\013" - + "update_mask\030\002 \001(\0132\032.google.protobuf.Fiel" - + "dMask\"K\n\022DeleteAgentRequest\0225\n\004name\030\001 \001(" - + "\tB\'\340A\002\372A!\n\037dialogflow.googleapis.com/Age" - + "nt\"c\n\022ExportAgentRequest\0225\n\004name\030\001 \001(\tB\'" - + "\340A\002\372A!\n\037dialogflow.googleapis.com/Agent\022" - + "\026\n\tagent_uri\030\002 \001(\tB\003\340A\001\"L\n\023ExportAgentRe" - + "sponse\022\023\n\tagent_uri\030\001 \001(\tH\000\022\027\n\ragent_con" - + "tent\030\002 \001(\014H\000B\007\n\005agent\"\203\001\n\023RestoreAgentRe" - + "quest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037dialogflow." - + "googleapis.com/Agent\022\023\n\tagent_uri\030\002 \001(\tH" - + "\000\022\027\n\ragent_content\030\003 \001(\014H\000B\007\n\005agent2\327\013\n\006" - + "Agents\022\275\001\n\nListAgents\0225.google.cloud.dia" - + "logflow.cx.v3beta1.ListAgentsRequest\0326.g" - + "oogle.cloud.dialogflow.cx.v3beta1.ListAg" - + "entsResponse\"@\202\323\344\223\0021\022//v3beta1/{parent=p" - + "rojects/*/locations/*}/agents\332A\006parent\022\252" - + "\001\n\010GetAgent\0223.google.cloud.dialogflow.cx" - + ".v3beta1.GetAgentRequest\032).google.cloud." - + "dialogflow.cx.v3beta1.Agent\">\202\323\344\223\0021\022//v3" - + "beta1/{name=projects/*/locations/*/agent" - + "s/*}\332A\004name\022\277\001\n\013CreateAgent\0226.google.clo" - + "ud.dialogflow.cx.v3beta1.CreateAgentRequ" - + "est\032).google.cloud.dialogflow.cx.v3beta1" - + ".Agent\"M\202\323\344\223\0028\"//v3beta1/{parent=project" - + "s/*/locations/*}/agents:\005agent\332A\014parent," - + "agent\022\312\001\n\013UpdateAgent\0226.google.cloud.dia" - + "logflow.cx.v3beta1.UpdateAgentRequest\032)." - + "google.cloud.dialogflow.cx.v3beta1.Agent" - + "\"X\202\323\344\223\002>25/v3beta1/{agent.name=projects/" - + "*/locations/*/agents/*}:\005agent\332A\021agent,u" - + "pdate_mask\022\235\001\n\013DeleteAgent\0226.google.clou" - + "d.dialogflow.cx.v3beta1.DeleteAgentReque" - + "st\032\026.google.protobuf.Empty\">\202\323\344\223\0021*//v3b" - + "eta1/{name=projects/*/locations/*/agents" - + "/*}\332A\004name\022\327\001\n\013ExportAgent\0226.google.clou" - + "d.dialogflow.cx.v3beta1.ExportAgentReque" - + "st\032\035.google.longrunning.Operation\"q\202\323\344\223\002" - + ";\"6/v3beta1/{name=projects/*/locations/*" - + "/agents/*}:export:\001*\312A-\n\023ExportAgentResp" - + "onse\022\026google.protobuf.Struct\022\334\001\n\014Restore" - + "Agent\0227.google.cloud.dialogflow.cx.v3bet" - + "a1.RestoreAgentRequest\032\035.google.longrunn" - + "ing.Operation\"t\202\323\344\223\002<\"7/v3beta1/{name=pr" - + "ojects/*/locations/*/agents/*}:restore:\001" - + "*\312A/\n\025google.protobuf.Empty\022\026google.prot" - + "obuf.Struct\032x\312A\031dialogflow.googleapis.co" - + "m\322AYhttps://www.googleapis.com/auth/clou" - + "d-platform,https://www.googleapis.com/au" - + "th/dialogflowB\251\001\n&com.google.cloud.dialo" - + "gflow.cx.v3beta1B\nAgentProtoP\001ZDgoogle.g" - + "olang.org/genproto/googleapis/cloud/dial" - + "ogflow/cx/v3beta1;cx\370\001\001\242\002\002DF\252\002\"Google.Cl" - + "oud.Dialogflow.Cx.V3Beta1b\006proto3" + + ".proto\032:google/cloud/dialogflow/cx/v3bet" + + "a1/security_settings.proto\032#google/longr" + + "unning/operations.proto\032\033google/protobuf" + + "/empty.proto\032 google/protobuf/field_mask" + + ".proto\"8\n\024SpeechToTextSettings\022 \n\030enable" + + "_speech_adaptation\030\001 \001(\010\"\317\003\n\005Agent\022\014\n\004na" + + "me\030\001 \001(\t\022\031\n\014display_name\030\002 \001(\tB\003\340A\002\022\"\n\025d" + + "efault_language_code\030\003 \001(\tB\003\340A\005\022\026\n\ttime_" + + "zone\030\005 \001(\tB\003\340A\002\022\023\n\013description\030\006 \001(\t\022\022\n\n" + + "avatar_uri\030\007 \001(\t\022Y\n\027speech_to_text_setti" + + "ngs\030\r \001(\01328.google.cloud.dialogflow.cx.v" + + "3beta1.SpeechToTextSettings\022:\n\nstart_flo" + + "w\030\020 \001(\tB&\340A\005\372A \n\036dialogflow.googleapis.c" + + "om/Flow\022\"\n\032enable_stackdriver_logging\030\022 " + + "\001(\010\022\037\n\027enable_spell_correction\030\024 \001(\010:\\\352A" + + "Y\n\037dialogflow.googleapis.com/Agent\0226proj" + + "ects/{project}/locations/{location}/agen" + + "ts/{agent}\"s\n\021ListAgentsRequest\0227\n\006paren" + + "t\030\001 \001(\tB\'\340A\002\372A!\022\037dialogflow.googleapis.c" + + "om/Agent\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_toke" + + "n\030\003 \001(\t\"h\n\022ListAgentsResponse\0229\n\006agents\030" + + "\001 \003(\0132).google.cloud.dialogflow.cx.v3bet" + + "a1.Agent\022\027\n\017next_page_token\030\002 \001(\t\"H\n\017Get" + + "AgentRequest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037dial" + + "ogflow.googleapis.com/Agent\"\214\001\n\022CreateAg" + + "entRequest\0227\n\006parent\030\001 \001(\tB\'\340A\002\372A!\022\037dial" + + "ogflow.googleapis.com/Agent\022=\n\005agent\030\002 \001" + + "(\0132).google.cloud.dialogflow.cx.v3beta1." + + "AgentB\003\340A\002\"\204\001\n\022UpdateAgentRequest\022=\n\005age" + + "nt\030\001 \001(\0132).google.cloud.dialogflow.cx.v3" + + "beta1.AgentB\003\340A\002\022/\n\013update_mask\030\002 \001(\0132\032." + + "google.protobuf.FieldMask\"K\n\022DeleteAgent" + + "Request\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037dialogflo" + + "w.googleapis.com/Agent\"c\n\022ExportAgentReq" + + "uest\0225\n\004name\030\001 \001(\tB\'\340A\002\372A!\n\037dialogflow.g" + + "oogleapis.com/Agent\022\026\n\tagent_uri\030\002 \001(\tB\003" + + "\340A\001\"L\n\023ExportAgentResponse\022\023\n\tagent_uri\030" + + "\001 \001(\tH\000\022\027\n\ragent_content\030\002 \001(\014H\000B\007\n\005agen" + + "t\"\203\001\n\023RestoreAgentRequest\0225\n\004name\030\001 \001(\tB" + + "\'\340A\002\372A!\n\037dialogflow.googleapis.com/Agent" + + "\022\023\n\tagent_uri\030\002 \001(\tH\000\022\027\n\ragent_content\030\003" + + " \001(\014H\000B\007\n\005agent2\327\013\n\006Agents\022\275\001\n\nListAgent" + + "s\0225.google.cloud.dialogflow.cx.v3beta1.L" + + "istAgentsRequest\0326.google.cloud.dialogfl" + + "ow.cx.v3beta1.ListAgentsResponse\"@\202\323\344\223\0021" + + "\022//v3beta1/{parent=projects/*/locations/" + + "*}/agents\332A\006parent\022\252\001\n\010GetAgent\0223.google" + + ".cloud.dialogflow.cx.v3beta1.GetAgentReq" + + "uest\032).google.cloud.dialogflow.cx.v3beta" + + "1.Agent\">\202\323\344\223\0021\022//v3beta1/{name=projects" + + "/*/locations/*/agents/*}\332A\004name\022\277\001\n\013Crea" + + "teAgent\0226.google.cloud.dialogflow.cx.v3b" + + "eta1.CreateAgentRequest\032).google.cloud.d" + + "ialogflow.cx.v3beta1.Agent\"M\202\323\344\223\0028\"//v3b" + + "eta1/{parent=projects/*/locations/*}/age" + + "nts:\005agent\332A\014parent,agent\022\312\001\n\013UpdateAgen" + + "t\0226.google.cloud.dialogflow.cx.v3beta1.U" + + "pdateAgentRequest\032).google.cloud.dialogf" + + "low.cx.v3beta1.Agent\"X\202\323\344\223\002>25/v3beta1/{" + + "agent.name=projects/*/locations/*/agents" + + "/*}:\005agent\332A\021agent,update_mask\022\235\001\n\013Delet" + + "eAgent\0226.google.cloud.dialogflow.cx.v3be" + + "ta1.DeleteAgentRequest\032\026.google.protobuf" + + ".Empty\">\202\323\344\223\0021*//v3beta1/{name=projects/" + + "*/locations/*/agents/*}\332A\004name\022\327\001\n\013Expor" + + "tAgent\0226.google.cloud.dialogflow.cx.v3be" + + "ta1.ExportAgentRequest\032\035.google.longrunn" + + "ing.Operation\"q\202\323\344\223\002;\"6/v3beta1/{name=pr" + + "ojects/*/locations/*/agents/*}:export:\001*" + + "\312A-\n\023ExportAgentResponse\022\026google.protobu" + + "f.Struct\022\334\001\n\014RestoreAgent\0227.google.cloud" + + ".dialogflow.cx.v3beta1.RestoreAgentReque" + + "st\032\035.google.longrunning.Operation\"t\202\323\344\223\002" + + "<\"7/v3beta1/{name=projects/*/locations/*" + + "/agents/*}:restore:\001*\312A/\n\025google.protobu" + + "f.Empty\022\026google.protobuf.Struct\032x\312A\031dial" + + "ogflow.googleapis.com\322AYhttps://www.goog" + + "leapis.com/auth/cloud-platform,https://w" + + "ww.googleapis.com/auth/dialogflowB\251\001\n&co" + + "m.google.cloud.dialogflow.cx.v3beta1B\nAg" + + "entProtoP\001ZDgoogle.golang.org/genproto/g" + + "oogleapis/cloud/dialogflow/cx/v3beta1;cx" + + "\370\001\001\242\002\002DF\252\002\"Google.Cloud.Dialogflow.Cx.V3" + + "Beta1b\006proto3" }; descriptor = com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( @@ -178,6 +180,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.FieldBehaviorProto.getDescriptor(), com.google.api.ResourceProto.getDescriptor(), com.google.cloud.dialogflow.cx.v3beta1.FlowProto.getDescriptor(), + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto.getDescriptor(), com.google.longrunning.OperationsProto.getDescriptor(), com.google.protobuf.EmptyProto.getDescriptor(), com.google.protobuf.FieldMaskProto.getDescriptor(), @@ -296,6 +299,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { com.google.api.FieldBehaviorProto.getDescriptor(); com.google.api.ResourceProto.getDescriptor(); com.google.cloud.dialogflow.cx.v3beta1.FlowProto.getDescriptor(); + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto.getDescriptor(); com.google.longrunning.OperationsProto.getDescriptor(); com.google.protobuf.EmptyProto.getDescriptor(); com.google.protobuf.FieldMaskProto.getDescriptor(); diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateAgentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateAgentRequest.java index 49e2bf107..fca7fde9a 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateAgentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateAgentRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent].
+ * The request message for
+ * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.CreateAgentRequest} @@ -414,7 +415,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent].
+   * The request message for
+   * [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.CreateAgentRequest} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequest.java new file mode 100644 index 000000000..9cb624c62 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequest.java @@ -0,0 +1,974 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.CreateExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.CreateExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest} + */ +public final class CreateExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) + CreateExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use CreateExperimentRequest.newBuilder() to construct. + private CreateExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateExperimentRequest() { + parent_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private CreateExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 18: + { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder subBuilder = null; + if (experiment_ != null) { + subBuilder = experiment_.toBuilder(); + } + experiment_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(experiment_); + experiment_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 EXPERIMENT_FIELD_NUMBER = 2; + private com.google.cloud.dialogflow.cx.v3beta1.Experiment experiment_; + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + @java.lang.Override + public boolean hasExperiment() { + return experiment_ != null; + } + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment() { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance() + : experiment_; + } + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentOrBuilder() { + return getExperiment(); + } + + 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 (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (experiment_ != null) { + output.writeMessage(2, getExperiment()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (experiment_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getExperiment()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.CreateExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasExperiment() != other.hasExperiment()) return false; + if (hasExperiment()) { + if (!getExperiment().equals(other.getExperiment())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasExperiment()) { + hash = (37 * hash) + EXPERIMENT_FIELD_NUMBER; + hash = (53 * hash) + getExperiment().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest 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.dialogflow.cx.v3beta1.CreateExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest 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.dialogflow.cx.v3beta1.CreateExperimentRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest 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.dialogflow.cx.v3beta1.CreateExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest 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.dialogflow.cx.v3beta1.CreateExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest 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.dialogflow.cx.v3beta1.CreateExperimentRequest 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 request message for [Experiments.CreateExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.CreateExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + if (experimentBuilder_ == null) { + experiment_ = null; + } else { + experiment_ = null; + experimentBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest(this); + result.parent_ = parent_; + if (experimentBuilder_ == null) { + result.experiment_ = experiment_; + } else { + result.experiment_ = experimentBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.CreateExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.hasExperiment()) { + mergeExperiment(other.getExperiment()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + + private com.google.cloud.dialogflow.cx.v3beta1.Experiment experiment_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder> + experimentBuilder_; + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + public boolean hasExperiment() { + return experimentBuilder_ != null || experiment_ != null; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment() { + if (experimentBuilder_ == null) { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance() + : experiment_; + } else { + return experimentBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment(com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + experiment_ = value; + onChanged(); + } else { + experimentBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder builderForValue) { + if (experimentBuilder_ == null) { + experiment_ = builderForValue.build(); + onChanged(); + } else { + experimentBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeExperiment(com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentBuilder_ == null) { + if (experiment_ != null) { + experiment_ = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.newBuilder(experiment_) + .mergeFrom(value) + .buildPartial(); + } else { + experiment_ = value; + } + onChanged(); + } else { + experimentBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearExperiment() { + if (experimentBuilder_ == null) { + experiment_ = null; + onChanged(); + } else { + experiment_ = null; + experimentBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder getExperimentBuilder() { + + onChanged(); + return getExperimentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentOrBuilder() { + if (experimentBuilder_ != null) { + return experimentBuilder_.getMessageOrBuilder(); + } else { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance() + : experiment_; + } + } + /** + * + * + *
+     * Required. The experiment to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder> + getExperimentFieldBuilder() { + if (experimentBuilder_ == null) { + experimentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder>( + getExperiment(), getParentForChildren(), isClean()); + experiment_ = null; + } + return experimentBuilder_; + } + + @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.dialogflow.cx.v3beta1.CreateExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new CreateExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.CreateExperimentRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequestOrBuilder.java new file mode 100644 index 000000000..64f53e840 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequestOrBuilder.java @@ -0,0 +1,99 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface CreateExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.CreateExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + boolean hasExperiment(); + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment(); + /** + * + * + *
+   * Required. The experiment to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentOrBuilder(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequest.java new file mode 100644 index 000000000..444aad2e2 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequest.java @@ -0,0 +1,977 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [SecuritySettings.CreateSecuritySettings][].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest} + */ +public final class CreateSecuritySettingsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) + CreateSecuritySettingsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use CreateSecuritySettingsRequest.newBuilder() to construct. + private CreateSecuritySettingsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private CreateSecuritySettingsRequest() { + parent_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new CreateSecuritySettingsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private CreateSecuritySettingsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 18: + { + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder subBuilder = null; + if (securitySettings_ != null) { + subBuilder = securitySettings_.toBuilder(); + } + securitySettings_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(securitySettings_); + securitySettings_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+   * Format: `projects/<Project ID>/locations/<Location 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 location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+   * Format: `projects/<Project ID>/locations/<Location 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 SECURITY_SETTINGS_FIELD_NUMBER = 2; + private com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings securitySettings_; + /** + * + * + *
+   * Required. The security settings to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the securitySettings field is set. + */ + @java.lang.Override + public boolean hasSecuritySettings() { + return securitySettings_ != null; + } + /** + * + * + *
+   * Required. The security settings to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The securitySettings. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings() { + return securitySettings_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance() + : securitySettings_; + } + /** + * + * + *
+   * Required. The security settings to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder + getSecuritySettingsOrBuilder() { + return getSecuritySettings(); + } + + 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 (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (securitySettings_ != null) { + output.writeMessage(2, getSecuritySettings()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (securitySettings_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getSecuritySettings()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (hasSecuritySettings() != other.hasSecuritySettings()) return false; + if (hasSecuritySettings()) { + if (!getSecuritySettings().equals(other.getSecuritySettings())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + if (hasSecuritySettings()) { + hash = (37 * hash) + SECURITY_SETTINGS_FIELD_NUMBER; + hash = (53 * hash) + getSecuritySettings().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + 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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest 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 request message for [SecuritySettings.CreateSecuritySettings][].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + if (securitySettingsBuilder_ == null) { + securitySettings_ = null; + } else { + securitySettings_ = null; + securitySettingsBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest(this); + result.parent_ = parent_; + if (securitySettingsBuilder_ == null) { + result.securitySettings_ = securitySettings_; + } else { + result.securitySettings_ = securitySettingsBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.hasSecuritySettings()) { + mergeSecuritySettings(other.getSecuritySettings()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+     * Format: `projects/<Project ID>/locations/<Location 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 location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+     * Format: `projects/<Project ID>/locations/<Location 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 location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+     * Format: `projects/<Project ID>/locations/<Location 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+     * Format: `projects/<Project ID>/locations/<Location ID>`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+     * Format: `projects/<Project ID>/locations/<Location 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; + onChanged(); + return this; + } + + private com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings securitySettings_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + securitySettingsBuilder_; + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the securitySettings field is set. + */ + public boolean hasSecuritySettings() { + return securitySettingsBuilder_ != null || securitySettings_ != null; + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The securitySettings. + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings() { + if (securitySettingsBuilder_ == null) { + return securitySettings_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance() + : securitySettings_; + } else { + return securitySettingsBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + securitySettings_ = value; + onChanged(); + } else { + securitySettingsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder builderForValue) { + if (securitySettingsBuilder_ == null) { + securitySettings_ = builderForValue.build(); + onChanged(); + } else { + securitySettingsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (securitySettings_ != null) { + securitySettings_ = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.newBuilder(securitySettings_) + .mergeFrom(value) + .buildPartial(); + } else { + securitySettings_ = value; + } + onChanged(); + } else { + securitySettingsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearSecuritySettings() { + if (securitySettingsBuilder_ == null) { + securitySettings_ = null; + onChanged(); + } else { + securitySettings_ = null; + securitySettingsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder + getSecuritySettingsBuilder() { + + onChanged(); + return getSecuritySettingsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder + getSecuritySettingsOrBuilder() { + if (securitySettingsBuilder_ != null) { + return securitySettingsBuilder_.getMessageOrBuilder(); + } else { + return securitySettings_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance() + : securitySettings_; + } + } + /** + * + * + *
+     * Required. The security settings to create.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + getSecuritySettingsFieldBuilder() { + if (securitySettingsBuilder_ == null) { + securitySettingsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder>( + getSecuritySettings(), getParentForChildren(), isClean()); + securitySettings_ = null; + } + return securitySettingsBuilder_; + } + + @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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public CreateSecuritySettingsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new CreateSecuritySettingsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequestOrBuilder.java new file mode 100644 index 000000000..dce9a49ff --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequestOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface CreateSecuritySettingsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.CreateSecuritySettingsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for.
+   * Format: `projects/<Project ID>/locations/<Location ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * Required. The security settings to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the securitySettings field is set. + */ + boolean hasSecuritySettings(); + /** + * + * + *
+   * Required. The security settings to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The securitySettings. + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings(); + /** + * + * + *
+   * Required. The security settings to create.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder getSecuritySettingsOrBuilder(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteAgentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteAgentRequest.java index 24112eae0..ff42f882a 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteAgentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteAgentRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3beta1.Agents.DeleteAgent].
+ * The request message for
+ * [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3beta1.Agents.DeleteAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.DeleteAgentRequest} @@ -330,7 +331,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3beta1.Agents.DeleteAgent].
+   * The request message for
+   * [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3beta1.Agents.DeleteAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.DeleteAgentRequest} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequest.java new file mode 100644 index 000000000..281aebe81 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequest.java @@ -0,0 +1,671 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.DeleteExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.DeleteExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest} + */ +public final class DeleteExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) + DeleteExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use DeleteExperimentRequest.newBuilder() to construct. + private DeleteExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DeleteExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.DeleteExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest 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.dialogflow.cx.v3beta1.DeleteExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest 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.dialogflow.cx.v3beta1.DeleteExperimentRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest 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.dialogflow.cx.v3beta1.DeleteExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest 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.dialogflow.cx.v3beta1.DeleteExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest 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.dialogflow.cx.v3beta1.DeleteExperimentRequest 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 request message for [Experiments.DeleteExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.DeleteExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.DeleteExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3beta1.DeleteExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DeleteExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.DeleteExperimentRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequestOrBuilder.java new file mode 100644 index 000000000..a9b954549 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface DeleteExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.DeleteExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequest.java new file mode 100644 index 000000000..c6afdcfce --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequest.java @@ -0,0 +1,676 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [SecuritySettings.DeleteSecuritySettings][].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest} + */ +public final class DeleteSecuritySettingsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) + DeleteSecuritySettingsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use DeleteSecuritySettingsRequest.newBuilder() to construct. + private DeleteSecuritySettingsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private DeleteSecuritySettingsRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new DeleteSecuritySettingsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private DeleteSecuritySettingsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings 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 [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest 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 request message for [SecuritySettings.DeleteSecuritySettings][].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + .getDefaultInstance()) return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings 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 [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings 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 [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings 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; + 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public DeleteSecuritySettingsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new DeleteSecuritySettingsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequestOrBuilder.java new file mode 100644 index 000000000..8dc98985e --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface DeleteSecuritySettingsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.DeleteSecuritySettingsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings 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 [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings 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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Experiment.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Experiment.java new file mode 100644 index 000000000..7ff72ae15 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Experiment.java @@ -0,0 +1,10192 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * Represents an experiment in an environment.
+ * Next ID: 13
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment} + */ +public final class Experiment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.Experiment) + ExperimentOrBuilder { + private static final long serialVersionUID = 0L; + // Use Experiment.newBuilder() to construct. + private Experiment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Experiment() { + name_ = ""; + displayName_ = ""; + description_ = ""; + state_ = 0; + variantsHistory_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Experiment(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Experiment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + displayName_ = s; + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + description_ = s; + break; + } + case 32: + { + int rawValue = input.readEnum(); + + state_ = rawValue; + break; + } + case 42: + { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder subBuilder = + null; + if (definition_ != null) { + subBuilder = definition_.toBuilder(); + } + definition_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(definition_); + definition_ = subBuilder.buildPartial(); + } + + break; + } + case 50: + { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder subBuilder = null; + if (result_ != null) { + subBuilder = result_.toBuilder(); + } + result_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(result_); + result_ = subBuilder.buildPartial(); + } + + break; + } + case 58: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (createTime_ != null) { + subBuilder = createTime_.toBuilder(); + } + createTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(createTime_); + createTime_ = subBuilder.buildPartial(); + } + + break; + } + case 66: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (startTime_ != null) { + subBuilder = startTime_.toBuilder(); + } + startTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(startTime_); + startTime_ = subBuilder.buildPartial(); + } + + break; + } + case 74: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (endTime_ != null) { + subBuilder = endTime_.toBuilder(); + } + endTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(endTime_); + endTime_ = subBuilder.buildPartial(); + } + + break; + } + case 82: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (lastUpdateTime_ != null) { + subBuilder = lastUpdateTime_.toBuilder(); + } + lastUpdateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(lastUpdateTime_); + lastUpdateTime_ = subBuilder.buildPartial(); + } + + break; + } + case 90: + { + com.google.protobuf.Duration.Builder subBuilder = null; + if (experimentLength_ != null) { + subBuilder = experimentLength_.toBuilder(); + } + experimentLength_ = + input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(experimentLength_); + experimentLength_ = subBuilder.buildPartial(); + } + + break; + } + case 98: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory>(); + mutable_bitField0_ |= 0x00000001; + } + variantsHistory_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = java.util.Collections.unmodifiableList(variantsHistory_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder.class); + } + + /** + * + * + *
+   * The state of the experiment.
+   * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3beta1.Experiment.State} + */ + public enum State implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * State unspecified.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + STATE_UNSPECIFIED(0), + /** + * + * + *
+     * The experiment is created but not started yet.
+     * 
+ * + * DRAFT = 1; + */ + DRAFT(1), + /** + * + * + *
+     * The experiment is running.
+     * 
+ * + * RUNNING = 2; + */ + RUNNING(2), + /** + * + * + *
+     * The experiment is done.
+     * 
+ * + * DONE = 3; + */ + DONE(3), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * State unspecified.
+     * 
+ * + * STATE_UNSPECIFIED = 0; + */ + public static final int STATE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * The experiment is created but not started yet.
+     * 
+ * + * DRAFT = 1; + */ + public static final int DRAFT_VALUE = 1; + /** + * + * + *
+     * The experiment is running.
+     * 
+ * + * RUNNING = 2; + */ + public static final int RUNNING_VALUE = 2; + /** + * + * + *
+     * The experiment is done.
+     * 
+ * + * DONE = 3; + */ + public static final int DONE_VALUE = 3; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static State valueOf(int value) { + return forNumber(value); + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + */ + public static State forNumber(int value) { + switch (value) { + case 0: + return STATE_UNSPECIFIED; + case 1: + return DRAFT; + case 2: + return RUNNING; + case 3: + return DONE; + 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.dialogflow.cx.v3beta1.Experiment.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.dialogflow.cx.v3beta1.Experiment.State) + } + + public interface DefinitionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The condition. + */ + java.lang.String getCondition(); + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The bytes for condition. + */ + com.google.protobuf.ByteString getConditionBytes(); + + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + * + * @return Whether the versionVariants field is set. + */ + boolean hasVersionVariants(); + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + * + * @return The versionVariants. + */ + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getVersionVariants(); + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder getVersionVariantsOrBuilder(); + + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.VariantsCase + getVariantsCase(); + } + /** + * + * + *
+   * Definition of the experiment.
+   * Next ID: 3
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Definition} + */ + public static final class Definition extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) + DefinitionOrBuilder { + private static final long serialVersionUID = 0L; + // Use Definition.newBuilder() to construct. + private Definition(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Definition() { + condition_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Definition(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Definition( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + condition_ = s; + break; + } + case 18: + { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder subBuilder = null; + if (variantsCase_ == 2) { + subBuilder = + ((com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_) + .toBuilder(); + } + variants_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_); + variants_ = subBuilder.buildPartial(); + } + variantsCase_ = 2; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder.class); + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public enum VariantsCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + VERSION_VARIANTS(2), + VARIANTS_NOT_SET(0); + private final int value; + + private VariantsCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static VariantsCase valueOf(int value) { + return forNumber(value); + } + + public static VariantsCase forNumber(int value) { + switch (value) { + case 2: + return VERSION_VARIANTS; + case 0: + return VARIANTS_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public static final int CONDITION_FIELD_NUMBER = 1; + private volatile java.lang.Object condition_; + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The condition. + */ + @java.lang.Override + public java.lang.String getCondition() { + java.lang.Object ref = condition_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + condition_ = s; + return s; + } + } + /** + * + * + *
+     * The condition defines which subset of sessions are selected for
+     * this experiment. If not specified, all sessions are eligible. E.g.
+     * "query_input.language_code=en" See the [conditions
+     * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+     * 
+ * + * string condition = 1; + * + * @return The bytes for condition. + */ + @java.lang.Override + public com.google.protobuf.ByteString getConditionBytes() { + java.lang.Object ref = condition_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + condition_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int VERSION_VARIANTS_FIELD_NUMBER = 2; + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 2; + } + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getVersionVariants() { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + /** + * + * + *
+     * The flow versions as the variants of this experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getConditionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, condition_); + } + if (variantsCase_ == 2) { + output.writeMessage(2, (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getConditionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, condition_); + } + if (variantsCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 2, (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.Experiment.Definition)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition other = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) obj; + + if (!getCondition().equals(other.getCondition())) return false; + if (!getVariantsCase().equals(other.getVariantsCase())) return false; + switch (variantsCase_) { + case 2: + if (!getVersionVariants().equals(other.getVersionVariants())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + CONDITION_FIELD_NUMBER; + hash = (53 * hash) + getCondition().hashCode(); + switch (variantsCase_) { + case 2: + hash = (37 * hash) + VERSION_VARIANTS_FIELD_NUMBER; + hash = (53 * hash) + getVersionVariants().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition 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.dialogflow.cx.v3beta1.Experiment.Definition parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition 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.dialogflow.cx.v3beta1.Experiment.Definition parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition 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.dialogflow.cx.v3beta1.Experiment.Definition parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition 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.dialogflow.cx.v3beta1.Experiment.Definition parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition 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.dialogflow.cx.v3beta1.Experiment.Definition 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; + } + /** + * + * + *
+     * Definition of the experiment.
+     * Next ID: 3
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Definition} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) + com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + condition_ = ""; + + variantsCase_ = 0; + variants_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition build() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition result = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition(this); + result.condition_ = condition_; + if (variantsCase_ == 2) { + if (versionVariantsBuilder_ == null) { + result.variants_ = variants_; + } else { + result.variants_ = versionVariantsBuilder_.build(); + } + } + result.variantsCase_ = variantsCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.Experiment.Definition) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.getDefaultInstance()) + return this; + if (!other.getCondition().isEmpty()) { + condition_ = other.condition_; + onChanged(); + } + switch (other.getVariantsCase()) { + case VERSION_VARIANTS: + { + mergeVersionVariants(other.getVersionVariants()); + break; + } + case VARIANTS_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public Builder clearVariants() { + variantsCase_ = 0; + variants_ = null; + onChanged(); + return this; + } + + private java.lang.Object condition_ = ""; + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @return The condition. + */ + public java.lang.String getCondition() { + java.lang.Object ref = condition_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + condition_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @return The bytes for condition. + */ + public com.google.protobuf.ByteString getConditionBytes() { + java.lang.Object ref = condition_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + condition_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @param value The condition to set. + * @return This builder for chaining. + */ + public Builder setCondition(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + condition_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @return This builder for chaining. + */ + public Builder clearCondition() { + + condition_ = getDefaultInstance().getCondition(); + onChanged(); + return this; + } + /** + * + * + *
+       * The condition defines which subset of sessions are selected for
+       * this experiment. If not specified, all sessions are eligible. E.g.
+       * "query_input.language_code=en" See the [conditions
+       * reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition).
+       * 
+ * + * string condition = 1; + * + * @param value The bytes for condition to set. + * @return This builder for chaining. + */ + public Builder setConditionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + condition_ = value; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder> + versionVariantsBuilder_; + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 2; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } else { + if (variantsCase_ == 2) { + return versionVariantsBuilder_.getMessage(); + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + public Builder setVersionVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + variants_ = value; + onChanged(); + } else { + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 2; + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + public Builder setVersionVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder builderForValue) { + if (versionVariantsBuilder_ == null) { + variants_ = builderForValue.build(); + onChanged(); + } else { + versionVariantsBuilder_.setMessage(builderForValue.build()); + } + variantsCase_ = 2; + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + public Builder mergeVersionVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 2 + && variants_ + != com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance()) { + variants_ = + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.newBuilder( + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_) + .mergeFrom(value) + .buildPartial(); + } else { + variants_ = value; + } + onChanged(); + } else { + if (variantsCase_ == 2) { + versionVariantsBuilder_.mergeFrom(value); + } + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 2; + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + public Builder clearVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 2) { + variantsCase_ = 0; + variants_ = null; + onChanged(); + } + } else { + if (variantsCase_ == 2) { + variantsCase_ = 0; + variants_ = null; + } + versionVariantsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder + getVersionVariantsBuilder() { + return getVersionVariantsFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if ((variantsCase_ == 2) && (versionVariantsBuilder_ != null)) { + return versionVariantsBuilder_.getMessageOrBuilder(); + } else { + if (variantsCase_ == 2) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+       * The flow versions as the variants of this experiment.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder> + getVersionVariantsFieldBuilder() { + if (versionVariantsBuilder_ == null) { + if (!(variantsCase_ == 2)) { + variants_ = com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + versionVariantsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder>( + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_, + getParentForChildren(), + isClean()); + variants_ = null; + } + variantsCase_ = 2; + onChanged(); + ; + return versionVariantsBuilder_; + } + + @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.dialogflow.cx.v3beta1.Experiment.Definition) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.Experiment.Definition) + private static final com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Definition parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Definition(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.Experiment.Definition + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface ResultOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.Experiment.Result) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + java.util.List + getVersionMetricsList(); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics getVersionMetrics( + int index); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + int getVersionMetricsCount(); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + java.util.List< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsOrBuilderList(); + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder + getVersionMetricsOrBuilder(int index); + + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return Whether the lastUpdateTime field is set. + */ + boolean hasLastUpdateTime(); + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return The lastUpdateTime. + */ + com.google.protobuf.Timestamp getLastUpdateTime(); + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder(); + } + /** + * + * + *
+   * The inference result which includes an objective metric to optimize and the
+   * confidence interval.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result} + */ + public static final class Result extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result) + ResultOrBuilder { + private static final long serialVersionUID = 0L; + // Use Result.newBuilder() to construct. + private Result(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Result() { + versionMetrics_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Result(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Result( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result + .VersionMetrics>(); + mutable_bitField0_ |= 0x00000001; + } + versionMetrics_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + .parser(), + extensionRegistry)); + break; + } + case 18: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (lastUpdateTime_ != null) { + subBuilder = lastUpdateTime_.toBuilder(); + } + lastUpdateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(lastUpdateTime_); + lastUpdateTime_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = java.util.Collections.unmodifiableList(versionMetrics_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder.class); + } + + /** + * + * + *
+     * Types of metric for Dialogflow experiment.
+     * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType} + */ + public enum MetricType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+       * Metric unspecified.
+       * 
+ * + * METRIC_UNSPECIFIED = 0; + */ + METRIC_UNSPECIFIED(0), + /** + * + * + *
+       * Percentage of contained sessions without user calling back in 24 hours.
+       * 
+ * + * CONTAINED_SESSION_NO_CALLBACK_RATE = 1; + */ + CONTAINED_SESSION_NO_CALLBACK_RATE(1), + /** + * + * + *
+       * Percentage of sessions that were handed to a human agent.
+       * 
+ * + * LIVE_AGENT_HANDOFF_RATE = 2; + */ + LIVE_AGENT_HANDOFF_RATE(2), + /** + * + * + *
+       * Percentage of sessions with the same user calling back.
+       * 
+ * + * CALLBACK_SESSION_RATE = 3; + */ + CALLBACK_SESSION_RATE(3), + /** + * + * + *
+       * Percentage of sessions where user hung up.
+       * 
+ * + * ABANDONED_SESSION_RATE = 4; + */ + ABANDONED_SESSION_RATE(4), + /** + * + * + *
+       * Percentage of sessions reached Dialogflow 'END_PAGE' or
+       * 'END_SESSION'.
+       * 
+ * + * SESSION_END_RATE = 5; + */ + SESSION_END_RATE(5), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+       * Metric unspecified.
+       * 
+ * + * METRIC_UNSPECIFIED = 0; + */ + public static final int METRIC_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+       * Percentage of contained sessions without user calling back in 24 hours.
+       * 
+ * + * CONTAINED_SESSION_NO_CALLBACK_RATE = 1; + */ + public static final int CONTAINED_SESSION_NO_CALLBACK_RATE_VALUE = 1; + /** + * + * + *
+       * Percentage of sessions that were handed to a human agent.
+       * 
+ * + * LIVE_AGENT_HANDOFF_RATE = 2; + */ + public static final int LIVE_AGENT_HANDOFF_RATE_VALUE = 2; + /** + * + * + *
+       * Percentage of sessions with the same user calling back.
+       * 
+ * + * CALLBACK_SESSION_RATE = 3; + */ + public static final int CALLBACK_SESSION_RATE_VALUE = 3; + /** + * + * + *
+       * Percentage of sessions where user hung up.
+       * 
+ * + * ABANDONED_SESSION_RATE = 4; + */ + public static final int ABANDONED_SESSION_RATE_VALUE = 4; + /** + * + * + *
+       * Percentage of sessions reached Dialogflow 'END_PAGE' or
+       * 'END_SESSION'.
+       * 
+ * + * SESSION_END_RATE = 5; + */ + public static final int SESSION_END_RATE_VALUE = 5; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static MetricType 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 MetricType forNumber(int value) { + switch (value) { + case 0: + return METRIC_UNSPECIFIED; + case 1: + return CONTAINED_SESSION_NO_CALLBACK_RATE; + case 2: + return LIVE_AGENT_HANDOFF_RATE; + case 3: + return CALLBACK_SESSION_RATE; + case 4: + return ABANDONED_SESSION_RATE; + case 5: + return SESSION_END_RATE; + 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 MetricType findValueByNumber(int number) { + return MetricType.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.dialogflow.cx.v3beta1.Experiment.Result.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final MetricType[] VALUES = values(); + + public static MetricType 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 MetricType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType) + } + + public interface ConfidenceIntervalOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The confidence level used to construct the interval, i.e. there is X%
+       * chance that the true value is within this interval.
+       * 
+ * + * double confidence_level = 1; + * + * @return The confidenceLevel. + */ + double getConfidenceLevel(); + + /** + * + * + *
+       * The percent change between an experiment metric's value and the value
+       * for its control.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + double getRatio(); + + /** + * + * + *
+       * Lower bound of the interval.
+       * 
+ * + * double lower_bound = 3; + * + * @return The lowerBound. + */ + double getLowerBound(); + + /** + * + * + *
+       * Upper bound of the interval.
+       * 
+ * + * double upper_bound = 4; + * + * @return The upperBound. + */ + double getUpperBound(); + } + /** + * + * + *
+     * A confidence interval is a range of possible values for the experiment
+     * objective you are trying to measure.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval} + */ + public static final class ConfidenceInterval extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + ConfidenceIntervalOrBuilder { + private static final long serialVersionUID = 0L; + // Use ConfidenceInterval.newBuilder() to construct. + private ConfidenceInterval(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ConfidenceInterval() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ConfidenceInterval(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ConfidenceInterval( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 9: + { + confidenceLevel_ = input.readDouble(); + break; + } + case 17: + { + ratio_ = input.readDouble(); + break; + } + case 25: + { + lowerBound_ = input.readDouble(); + break; + } + case 33: + { + upperBound_ = input.readDouble(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.Builder + .class); + } + + public static final int CONFIDENCE_LEVEL_FIELD_NUMBER = 1; + private double confidenceLevel_; + /** + * + * + *
+       * The confidence level used to construct the interval, i.e. there is X%
+       * chance that the true value is within this interval.
+       * 
+ * + * double confidence_level = 1; + * + * @return The confidenceLevel. + */ + @java.lang.Override + public double getConfidenceLevel() { + return confidenceLevel_; + } + + public static final int RATIO_FIELD_NUMBER = 2; + private double ratio_; + /** + * + * + *
+       * The percent change between an experiment metric's value and the value
+       * for its control.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + @java.lang.Override + public double getRatio() { + return ratio_; + } + + public static final int LOWER_BOUND_FIELD_NUMBER = 3; + private double lowerBound_; + /** + * + * + *
+       * Lower bound of the interval.
+       * 
+ * + * double lower_bound = 3; + * + * @return The lowerBound. + */ + @java.lang.Override + public double getLowerBound() { + return lowerBound_; + } + + public static final int UPPER_BOUND_FIELD_NUMBER = 4; + private double upperBound_; + /** + * + * + *
+       * Upper bound of the interval.
+       * 
+ * + * double upper_bound = 4; + * + * @return The upperBound. + */ + @java.lang.Override + public double getUpperBound() { + return upperBound_; + } + + 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 (confidenceLevel_ != 0D) { + output.writeDouble(1, confidenceLevel_); + } + if (ratio_ != 0D) { + output.writeDouble(2, ratio_); + } + if (lowerBound_ != 0D) { + output.writeDouble(3, lowerBound_); + } + if (upperBound_ != 0D) { + output.writeDouble(4, upperBound_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (confidenceLevel_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(1, confidenceLevel_); + } + if (ratio_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(2, ratio_); + } + if (lowerBound_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(3, lowerBound_); + } + if (upperBound_ != 0D) { + size += com.google.protobuf.CodedOutputStream.computeDoubleSize(4, upperBound_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval other = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) obj; + + if (java.lang.Double.doubleToLongBits(getConfidenceLevel()) + != java.lang.Double.doubleToLongBits(other.getConfidenceLevel())) return false; + if (java.lang.Double.doubleToLongBits(getRatio()) + != java.lang.Double.doubleToLongBits(other.getRatio())) return false; + if (java.lang.Double.doubleToLongBits(getLowerBound()) + != java.lang.Double.doubleToLongBits(other.getLowerBound())) return false; + if (java.lang.Double.doubleToLongBits(getUpperBound()) + != java.lang.Double.doubleToLongBits(other.getUpperBound())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + CONFIDENCE_LEVEL_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getConfidenceLevel())); + hash = (37 * hash) + RATIO_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getRatio())); + hash = (37 * hash) + LOWER_BOUND_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getLowerBound())); + hash = (37 * hash) + UPPER_BOUND_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getUpperBound())); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval 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 confidence interval is a range of possible values for the experiment
+       * objective you are trying to measure.
+       * 
+ * + * Protobuf type {@code + * google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceIntervalOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + confidenceLevel_ = 0D; + + ratio_ = 0D; + + lowerBound_ = 0D; + + upperBound_ = 0D; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval build() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval result = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval(this); + result.confidenceLevel_ = confidenceLevel_; + result.ratio_ = ratio_; + result.lowerBound_ = lowerBound_; + result.upperBound_ = upperBound_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .getDefaultInstance()) return this; + if (other.getConfidenceLevel() != 0D) { + setConfidenceLevel(other.getConfidenceLevel()); + } + if (other.getRatio() != 0D) { + setRatio(other.getRatio()); + } + if (other.getLowerBound() != 0D) { + setLowerBound(other.getLowerBound()); + } + if (other.getUpperBound() != 0D) { + setUpperBound(other.getUpperBound()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private double confidenceLevel_; + /** + * + * + *
+         * The confidence level used to construct the interval, i.e. there is X%
+         * chance that the true value is within this interval.
+         * 
+ * + * double confidence_level = 1; + * + * @return The confidenceLevel. + */ + @java.lang.Override + public double getConfidenceLevel() { + return confidenceLevel_; + } + /** + * + * + *
+         * The confidence level used to construct the interval, i.e. there is X%
+         * chance that the true value is within this interval.
+         * 
+ * + * double confidence_level = 1; + * + * @param value The confidenceLevel to set. + * @return This builder for chaining. + */ + public Builder setConfidenceLevel(double value) { + + confidenceLevel_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The confidence level used to construct the interval, i.e. there is X%
+         * chance that the true value is within this interval.
+         * 
+ * + * double confidence_level = 1; + * + * @return This builder for chaining. + */ + public Builder clearConfidenceLevel() { + + confidenceLevel_ = 0D; + onChanged(); + return this; + } + + private double ratio_; + /** + * + * + *
+         * The percent change between an experiment metric's value and the value
+         * for its control.
+         * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + @java.lang.Override + public double getRatio() { + return ratio_; + } + /** + * + * + *
+         * The percent change between an experiment metric's value and the value
+         * for its control.
+         * 
+ * + * double ratio = 2; + * + * @param value The ratio to set. + * @return This builder for chaining. + */ + public Builder setRatio(double value) { + + ratio_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The percent change between an experiment metric's value and the value
+         * for its control.
+         * 
+ * + * double ratio = 2; + * + * @return This builder for chaining. + */ + public Builder clearRatio() { + + ratio_ = 0D; + onChanged(); + return this; + } + + private double lowerBound_; + /** + * + * + *
+         * Lower bound of the interval.
+         * 
+ * + * double lower_bound = 3; + * + * @return The lowerBound. + */ + @java.lang.Override + public double getLowerBound() { + return lowerBound_; + } + /** + * + * + *
+         * Lower bound of the interval.
+         * 
+ * + * double lower_bound = 3; + * + * @param value The lowerBound to set. + * @return This builder for chaining. + */ + public Builder setLowerBound(double value) { + + lowerBound_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Lower bound of the interval.
+         * 
+ * + * double lower_bound = 3; + * + * @return This builder for chaining. + */ + public Builder clearLowerBound() { + + lowerBound_ = 0D; + onChanged(); + return this; + } + + private double upperBound_; + /** + * + * + *
+         * Upper bound of the interval.
+         * 
+ * + * double upper_bound = 4; + * + * @return The upperBound. + */ + @java.lang.Override + public double getUpperBound() { + return upperBound_; + } + /** + * + * + *
+         * Upper bound of the interval.
+         * 
+ * + * double upper_bound = 4; + * + * @param value The upperBound to set. + * @return This builder for chaining. + */ + public Builder setUpperBound(double value) { + + upperBound_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Upper bound of the interval.
+         * 
+ * + * double upper_bound = 4; + * + * @return This builder for chaining. + */ + public Builder clearUpperBound() { + + upperBound_ = 0D; + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval) + private static final com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result + .ConfidenceInterval + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ConfidenceInterval parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ConfidenceInterval(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface MetricOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + int getTypeValue(); + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return The type. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType getType(); + + /** + * + * + *
+       * Ratio value of a metric.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + double getRatio(); + + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return Whether the confidenceInterval field is set. + */ + boolean hasConfidenceInterval(); + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return The confidenceInterval. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + getConfidenceInterval(); + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceIntervalOrBuilder + getConfidenceIntervalOrBuilder(); + + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.ValueCase + getValueCase(); + } + /** + * + * + *
+     * Metric and corresponding confidence intervals.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric} + */ + public static final class Metric extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) + MetricOrBuilder { + private static final long serialVersionUID = 0L; + // Use Metric.newBuilder() to construct. + private Metric(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Metric() { + type_ = 0; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Metric(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Metric( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int rawValue = input.readEnum(); + + type_ = rawValue; + break; + } + case 17: + { + valueCase_ = 2; + value_ = input.readDouble(); + break; + } + case 26: + { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .Builder + subBuilder = null; + if (confidenceInterval_ != null) { + subBuilder = confidenceInterval_.toBuilder(); + } + confidenceInterval_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result + .ConfidenceInterval.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(confidenceInterval_); + confidenceInterval_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder.class); + } + + private int valueCase_ = 0; + private java.lang.Object value_; + + public enum ValueCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + RATIO(2), + VALUE_NOT_SET(0); + private final int value; + + private ValueCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ValueCase valueOf(int value) { + return forNumber(value); + } + + public static ValueCase forNumber(int value) { + switch (value) { + case 2: + return RATIO; + case 0: + return VALUE_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ValueCase getValueCase() { + return ValueCase.forNumber(valueCase_); + } + + public static final int TYPE_FIELD_NUMBER = 1; + private int type_; + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+       * The type of the metric.
+       * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType getType() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType result = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType.valueOf(type_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType.UNRECOGNIZED + : result; + } + + public static final int RATIO_FIELD_NUMBER = 2; + /** + * + * + *
+       * Ratio value of a metric.
+       * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + @java.lang.Override + public double getRatio() { + if (valueCase_ == 2) { + return (java.lang.Double) value_; + } + return 0D; + } + + public static final int CONFIDENCE_INTERVAL_FIELD_NUMBER = 3; + private com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + confidenceInterval_; + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return Whether the confidenceInterval field is set. + */ + @java.lang.Override + public boolean hasConfidenceInterval() { + return confidenceInterval_ != null; + } + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return The confidenceInterval. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + getConfidenceInterval() { + return confidenceInterval_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .getDefaultInstance() + : confidenceInterval_; + } + /** + * + * + *
+       * The probability that the treatment is better than all other treatments
+       * in the experiment
+       * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceIntervalOrBuilder + getConfidenceIntervalOrBuilder() { + return getConfidenceInterval(); + } + + 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 (type_ + != com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType + .METRIC_UNSPECIFIED + .getNumber()) { + output.writeEnum(1, type_); + } + if (valueCase_ == 2) { + output.writeDouble(2, (double) ((java.lang.Double) value_)); + } + if (confidenceInterval_ != null) { + output.writeMessage(3, getConfidenceInterval()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (type_ + != com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType + .METRIC_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); + } + if (valueCase_ == 2) { + size += + com.google.protobuf.CodedOutputStream.computeDoubleSize( + 2, (double) ((java.lang.Double) value_)); + } + if (confidenceInterval_ != null) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(3, getConfidenceInterval()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.Experiment.Result.Metric)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric other = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) obj; + + if (type_ != other.type_) return false; + if (hasConfidenceInterval() != other.hasConfidenceInterval()) return false; + if (hasConfidenceInterval()) { + if (!getConfidenceInterval().equals(other.getConfidenceInterval())) return false; + } + if (!getValueCase().equals(other.getValueCase())) return false; + switch (valueCase_) { + case 2: + if (java.lang.Double.doubleToLongBits(getRatio()) + != java.lang.Double.doubleToLongBits(other.getRatio())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) 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) + TYPE_FIELD_NUMBER; + hash = (53 * hash) + type_; + if (hasConfidenceInterval()) { + hash = (37 * hash) + CONFIDENCE_INTERVAL_FIELD_NUMBER; + hash = (53 * hash) + getConfidenceInterval().hashCode(); + } + switch (valueCase_) { + case 2: + hash = (37 * hash) + RATIO_FIELD_NUMBER; + hash = + (53 * hash) + + com.google.protobuf.Internal.hashLong( + java.lang.Double.doubleToLongBits(getRatio())); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric 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.dialogflow.cx.v3beta1.Experiment.Result.Metric parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric 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.dialogflow.cx.v3beta1.Experiment.Result.Metric parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric 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.dialogflow.cx.v3beta1.Experiment.Result.Metric + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + 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.dialogflow.cx.v3beta1.Experiment.Result.Metric parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric 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.dialogflow.cx.v3beta1.Experiment.Result.Metric 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; + } + /** + * + * + *
+       * Metric and corresponding confidence intervals.
+       * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + type_ = 0; + + if (confidenceIntervalBuilder_ == null) { + confidenceInterval_ = null; + } else { + confidenceInterval_ = null; + confidenceIntervalBuilder_ = null; + } + valueCase_ = 0; + value_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric build() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric result = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric(this); + result.type_ = type_; + if (valueCase_ == 2) { + result.value_ = value_; + } + if (confidenceIntervalBuilder_ == null) { + result.confidenceInterval_ = confidenceInterval_; + } else { + result.confidenceInterval_ = confidenceIntervalBuilder_.build(); + } + result.valueCase_ = valueCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.Experiment.Result.Metric) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + .getDefaultInstance()) return this; + if (other.type_ != 0) { + setTypeValue(other.getTypeValue()); + } + if (other.hasConfidenceInterval()) { + mergeConfidenceInterval(other.getConfidenceInterval()); + } + switch (other.getValueCase()) { + case RATIO: + { + setRatio(other.getRatio()); + break; + } + case VALUE_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int valueCase_ = 0; + private java.lang.Object value_; + + public ValueCase getValueCase() { + return ValueCase.forNumber(valueCase_); + } + + public Builder clearValue() { + valueCase_ = 0; + value_ = null; + onChanged(); + return this; + } + + private int type_ = 0; + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return The enum numeric value on the wire for type. + */ + @java.lang.Override + public int getTypeValue() { + return type_; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return The type. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType getType() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType result = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType.valueOf(type_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType.UNRECOGNIZED + : result; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @param value The type to set. + * @return This builder for chaining. + */ + public Builder setType( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType value) { + if (value == null) { + throw new NullPointerException(); + } + + type_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+         * The type of the metric.
+         * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricType type = 1; + * + * @return This builder for chaining. + */ + public Builder clearType() { + + type_ = 0; + onChanged(); + return this; + } + + /** + * + * + *
+         * Ratio value of a metric.
+         * 
+ * + * double ratio = 2; + * + * @return The ratio. + */ + public double getRatio() { + if (valueCase_ == 2) { + return (java.lang.Double) value_; + } + return 0D; + } + /** + * + * + *
+         * Ratio value of a metric.
+         * 
+ * + * double ratio = 2; + * + * @param value The ratio to set. + * @return This builder for chaining. + */ + public Builder setRatio(double value) { + valueCase_ = 2; + value_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Ratio value of a metric.
+         * 
+ * + * double ratio = 2; + * + * @return This builder for chaining. + */ + public Builder clearRatio() { + if (valueCase_ == 2) { + valueCase_ = 0; + value_ = null; + onChanged(); + } + return this; + } + + private com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + confidenceInterval_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result + .ConfidenceIntervalOrBuilder> + confidenceIntervalBuilder_; + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return Whether the confidenceInterval field is set. + */ + public boolean hasConfidenceInterval() { + return confidenceIntervalBuilder_ != null || confidenceInterval_ != null; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + * + * @return The confidenceInterval. + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + getConfidenceInterval() { + if (confidenceIntervalBuilder_ == null) { + return confidenceInterval_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .getDefaultInstance() + : confidenceInterval_; + } else { + return confidenceIntervalBuilder_.getMessage(); + } + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder setConfidenceInterval( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval value) { + if (confidenceIntervalBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + confidenceInterval_ = value; + onChanged(); + } else { + confidenceIntervalBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder setConfidenceInterval( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.Builder + builderForValue) { + if (confidenceIntervalBuilder_ == null) { + confidenceInterval_ = builderForValue.build(); + onChanged(); + } else { + confidenceIntervalBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder mergeConfidenceInterval( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval value) { + if (confidenceIntervalBuilder_ == null) { + if (confidenceInterval_ != null) { + confidenceInterval_ = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .newBuilder(confidenceInterval_) + .mergeFrom(value) + .buildPartial(); + } else { + confidenceInterval_ = value; + } + onChanged(); + } else { + confidenceIntervalBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public Builder clearConfidenceInterval() { + if (confidenceIntervalBuilder_ == null) { + confidenceInterval_ = null; + onChanged(); + } else { + confidenceInterval_ = null; + confidenceIntervalBuilder_ = null; + } + + return this; + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.Builder + getConfidenceIntervalBuilder() { + + onChanged(); + return getConfidenceIntervalFieldBuilder().getBuilder(); + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceIntervalOrBuilder + getConfidenceIntervalOrBuilder() { + if (confidenceIntervalBuilder_ != null) { + return confidenceIntervalBuilder_.getMessageOrBuilder(); + } else { + return confidenceInterval_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .getDefaultInstance() + : confidenceInterval_; + } + } + /** + * + * + *
+         * The probability that the treatment is better than all other treatments
+         * in the experiment
+         * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval confidence_interval = 3; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result + .ConfidenceIntervalOrBuilder> + getConfidenceIntervalFieldBuilder() { + if (confidenceIntervalBuilder_ == null) { + confidenceIntervalBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.ConfidenceInterval + .Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result + .ConfidenceIntervalOrBuilder>( + getConfidenceInterval(), getParentForChildren(), isClean()); + confidenceInterval_ = null; + } + return confidenceIntervalBuilder_; + } + + @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.dialogflow.cx.v3beta1.Experiment.Result.Metric) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric) + private static final com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Metric parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Metric(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.Experiment.Result.Metric + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface VersionMetricsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The version. + */ + java.lang.String getVersion(); + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for version. + */ + com.google.protobuf.ByteString getVersionBytes(); + + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + java.util.List + getMetricsList(); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric getMetrics(int index); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + int getMetricsCount(); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder> + getMetricsOrBuilderList(); + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder getMetricsOrBuilder( + int index); + + /** + * + * + *
+       * Number of sessions that were allocated to this version.
+       * 
+ * + * int32 session_count = 3; + * + * @return The sessionCount. + */ + int getSessionCount(); + } + /** + * + * + *
+     * Version variant and associated metrics.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics} + */ + public static final class VersionMetrics extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) + VersionMetricsOrBuilder { + private static final long serialVersionUID = 0L; + // Use VersionMetrics.newBuilder() to construct. + private VersionMetrics(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private VersionMetrics() { + version_ = ""; + metrics_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new VersionMetrics(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private VersionMetrics( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + version_ = s; + break; + } + case 18: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + metrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric>(); + mutable_bitField0_ |= 0x00000001; + } + metrics_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.parser(), + extensionRegistry)); + break; + } + case 24: + { + sessionCount_ = input.readInt32(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + metrics_ = java.util.Collections.unmodifiableList(metrics_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + .class); + } + + public static final int VERSION_FIELD_NUMBER = 1; + private volatile java.lang.Object version_; + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The version. + */ + @java.lang.Override + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } + } + /** + * + * + *
+       * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+       * Format: `projects/<Project Number>/locations/<Location
+       * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for version. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int METRICS_FIELD_NUMBER = 2; + private java.util.List + metrics_; + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + @java.lang.Override + public java.util.List + getMetricsList() { + return metrics_; + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder> + getMetricsOrBuilderList() { + return metrics_; + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + @java.lang.Override + public int getMetricsCount() { + return metrics_.size(); + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric getMetrics(int index) { + return metrics_.get(index); + } + /** + * + * + *
+       * The metrics and corresponding confidence intervals in the inference
+       * result.
+       * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder + getMetricsOrBuilder(int index) { + return metrics_.get(index); + } + + public static final int SESSION_COUNT_FIELD_NUMBER = 3; + private int sessionCount_; + /** + * + * + *
+       * Number of sessions that were allocated to this version.
+       * 
+ * + * int32 session_count = 3; + * + * @return The sessionCount. + */ + @java.lang.Override + public int getSessionCount() { + return sessionCount_; + } + + 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 (!getVersionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_); + } + for (int i = 0; i < metrics_.size(); i++) { + output.writeMessage(2, metrics_.get(i)); + } + if (sessionCount_ != 0) { + output.writeInt32(3, sessionCount_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getVersionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_); + } + for (int i = 0; i < metrics_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, metrics_.get(i)); + } + if (sessionCount_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(3, sessionCount_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics other = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) obj; + + if (!getVersion().equals(other.getVersion())) return false; + if (!getMetricsList().equals(other.getMetricsList())) return false; + if (getSessionCount() != other.getSessionCount()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + if (getMetricsCount() > 0) { + hash = (37 * hash) + METRICS_FIELD_NUMBER; + hash = (53 * hash) + getMetricsList().hashCode(); + } + hash = (37 * hash) + SESSION_COUNT_FIELD_NUMBER; + hash = (53 * hash) + getSessionCount(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics 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; + } + /** + * + * + *
+       * Version variant and associated metrics.
+       * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + .class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getMetricsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + version_ = ""; + + if (metricsBuilder_ == null) { + metrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + metricsBuilder_.clear(); + } + sessionCount_ = 0; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics build() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics result = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics(this); + int from_bitField0_ = bitField0_; + result.version_ = version_; + if (metricsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + metrics_ = java.util.Collections.unmodifiableList(metrics_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.metrics_ = metrics_; + } else { + result.metrics_ = metricsBuilder_.build(); + } + result.sessionCount_ = sessionCount_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + .getDefaultInstance()) return this; + if (!other.getVersion().isEmpty()) { + version_ = other.version_; + onChanged(); + } + if (metricsBuilder_ == null) { + if (!other.metrics_.isEmpty()) { + if (metrics_.isEmpty()) { + metrics_ = other.metrics_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureMetricsIsMutable(); + metrics_.addAll(other.metrics_); + } + onChanged(); + } + } else { + if (!other.metrics_.isEmpty()) { + if (metricsBuilder_.isEmpty()) { + metricsBuilder_.dispose(); + metricsBuilder_ = null; + metrics_ = other.metrics_; + bitField0_ = (bitField0_ & ~0x00000001); + metricsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getMetricsFieldBuilder() + : null; + } else { + metricsBuilder_.addAllMessages(other.metrics_); + } + } + } + if (other.getSessionCount() != 0) { + setSessionCount(other.getSessionCount()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics parsedMessage = + null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object version_ = ""; + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The version. + */ + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return The bytes for version. + */ + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The version to set. + * @return This builder for chaining. + */ + public Builder setVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + version_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @return This builder for chaining. + */ + public Builder clearVersion() { + + version_ = getDefaultInstance().getVersion(); + onChanged(); + return this; + } + /** + * + * + *
+         * The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version].
+         * Format: `projects/<Project Number>/locations/<Location
+         * ID>/agents/<Agent ID>/flows/<Flow ID>/versions/<Version ID>`.
+         * 
+ * + * string version = 1 [(.google.api.resource_reference) = { ... } + * + * @param value The bytes for version to set. + * @return This builder for chaining. + */ + public Builder setVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + version_ = value; + onChanged(); + return this; + } + + private java.util.List + metrics_ = java.util.Collections.emptyList(); + + private void ensureMetricsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + metrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric>(metrics_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder> + metricsBuilder_; + + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public java.util.List + getMetricsList() { + if (metricsBuilder_ == null) { + return java.util.Collections.unmodifiableList(metrics_); + } else { + return metricsBuilder_.getMessageList(); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public int getMetricsCount() { + if (metricsBuilder_ == null) { + return metrics_.size(); + } else { + return metricsBuilder_.getCount(); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric getMetrics( + int index) { + if (metricsBuilder_ == null) { + return metrics_.get(index); + } else { + return metricsBuilder_.getMessage(index); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder setMetrics( + int index, com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric value) { + if (metricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricsIsMutable(); + metrics_.set(index, value); + onChanged(); + } else { + metricsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder setMetrics( + int index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder + builderForValue) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.set(index, builderForValue.build()); + onChanged(); + } else { + metricsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric value) { + if (metricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricsIsMutable(); + metrics_.add(value); + onChanged(); + } else { + metricsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + int index, com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric value) { + if (metricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureMetricsIsMutable(); + metrics_.add(index, value); + onChanged(); + } else { + metricsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder + builderForValue) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.add(builderForValue.build()); + onChanged(); + } else { + metricsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addMetrics( + int index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder + builderForValue) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.add(index, builderForValue.build()); + onChanged(); + } else { + metricsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder addAllMetrics( + java.lang.Iterable< + ? extends com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric> + values) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, metrics_); + onChanged(); + } else { + metricsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder clearMetrics() { + if (metricsBuilder_ == null) { + metrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + metricsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public Builder removeMetrics(int index) { + if (metricsBuilder_ == null) { + ensureMetricsIsMutable(); + metrics_.remove(index); + onChanged(); + } else { + metricsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder + getMetricsBuilder(int index) { + return getMetricsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder + getMetricsOrBuilder(int index) { + if (metricsBuilder_ == null) { + return metrics_.get(index); + } else { + return metricsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder> + getMetricsOrBuilderList() { + if (metricsBuilder_ != null) { + return metricsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(metrics_); + } + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder + addMetricsBuilder() { + return getMetricsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + .getDefaultInstance()); + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder + addMetricsBuilder(int index) { + return getMetricsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric + .getDefaultInstance()); + } + /** + * + * + *
+         * The metrics and corresponding confidence intervals in the inference
+         * result.
+         * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric metrics = 2; + * + */ + public java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder> + getMetricsBuilderList() { + return getMetricsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder> + getMetricsFieldBuilder() { + if (metricsBuilder_ == null) { + metricsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Metric.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.MetricOrBuilder>( + metrics_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + metrics_ = null; + } + return metricsBuilder_; + } + + private int sessionCount_; + /** + * + * + *
+         * Number of sessions that were allocated to this version.
+         * 
+ * + * int32 session_count = 3; + * + * @return The sessionCount. + */ + @java.lang.Override + public int getSessionCount() { + return sessionCount_; + } + /** + * + * + *
+         * Number of sessions that were allocated to this version.
+         * 
+ * + * int32 session_count = 3; + * + * @param value The sessionCount to set. + * @return This builder for chaining. + */ + public Builder setSessionCount(int value) { + + sessionCount_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Number of sessions that were allocated to this version.
+         * 
+ * + * int32 session_count = 3; + * + * @return This builder for chaining. + */ + public Builder clearSessionCount() { + + sessionCount_ = 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics) + private static final com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VersionMetrics parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new VersionMetrics(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int VERSION_METRICS_FIELD_NUMBER = 1; + private java.util.List + versionMetrics_; + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public java.util.List + getVersionMetricsList() { + return versionMetrics_; + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsOrBuilderList() { + return versionMetrics_; + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public int getVersionMetricsCount() { + return versionMetrics_.size(); + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + getVersionMetrics(int index) { + return versionMetrics_.get(index); + } + /** + * + * + *
+     * Version variants and metrics.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder + getVersionMetricsOrBuilder(int index) { + return versionMetrics_.get(index); + } + + public static final int LAST_UPDATE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp lastUpdateTime_; + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return Whether the lastUpdateTime field is set. + */ + @java.lang.Override + public boolean hasLastUpdateTime() { + return lastUpdateTime_ != null; + } + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return The lastUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastUpdateTime() { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + /** + * + * + *
+     * The last time the experiment's stats data was updated. Will have default
+     * value if stats have never been computed for this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + return getLastUpdateTime(); + } + + 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 < versionMetrics_.size(); i++) { + output.writeMessage(1, versionMetrics_.get(i)); + } + if (lastUpdateTime_ != null) { + output.writeMessage(2, getLastUpdateTime()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < versionMetrics_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, versionMetrics_.get(i)); + } + if (lastUpdateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getLastUpdateTime()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.Experiment.Result)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result other = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result) obj; + + if (!getVersionMetricsList().equals(other.getVersionMetricsList())) return false; + if (hasLastUpdateTime() != other.hasLastUpdateTime()) return false; + if (hasLastUpdateTime()) { + if (!getLastUpdateTime().equals(other.getLastUpdateTime())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getVersionMetricsCount() > 0) { + hash = (37 * hash) + VERSION_METRICS_FIELD_NUMBER; + hash = (53 * hash) + getVersionMetricsList().hashCode(); + } + if (hasLastUpdateTime()) { + hash = (37 * hash) + LAST_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastUpdateTime().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result 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.dialogflow.cx.v3beta1.Experiment.Result parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result 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.dialogflow.cx.v3beta1.Experiment.Result parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result 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.dialogflow.cx.v3beta1.Experiment.Result parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result 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.dialogflow.cx.v3beta1.Experiment.Result parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result 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.dialogflow.cx.v3beta1.Experiment.Result 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 inference result which includes an objective metric to optimize and the
+     * confidence interval.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment.Result} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.Experiment.Result) + com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getVersionMetricsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (versionMetricsBuilder_ == null) { + versionMetrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + versionMetricsBuilder_.clear(); + } + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result build() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result(this); + int from_bitField0_ = bitField0_; + if (versionMetricsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = java.util.Collections.unmodifiableList(versionMetrics_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.versionMetrics_ = versionMetrics_; + } else { + result.versionMetrics_ = versionMetricsBuilder_.build(); + } + if (lastUpdateTimeBuilder_ == null) { + result.lastUpdateTime_ = lastUpdateTime_; + } else { + result.lastUpdateTime_ = lastUpdateTimeBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.Experiment.Result) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result other) { + if (other == com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.getDefaultInstance()) + return this; + if (versionMetricsBuilder_ == null) { + if (!other.versionMetrics_.isEmpty()) { + if (versionMetrics_.isEmpty()) { + versionMetrics_ = other.versionMetrics_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureVersionMetricsIsMutable(); + versionMetrics_.addAll(other.versionMetrics_); + } + onChanged(); + } + } else { + if (!other.versionMetrics_.isEmpty()) { + if (versionMetricsBuilder_.isEmpty()) { + versionMetricsBuilder_.dispose(); + versionMetricsBuilder_ = null; + versionMetrics_ = other.versionMetrics_; + bitField0_ = (bitField0_ & ~0x00000001); + versionMetricsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getVersionMetricsFieldBuilder() + : null; + } else { + versionMetricsBuilder_.addAllMessages(other.versionMetrics_); + } + } + } + if (other.hasLastUpdateTime()) { + mergeLastUpdateTime(other.getLastUpdateTime()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics> + versionMetrics_ = java.util.Collections.emptyList(); + + private void ensureVersionMetricsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + versionMetrics_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics>( + versionMetrics_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder> + versionMetricsBuilder_; + + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public java.util.List + getVersionMetricsList() { + if (versionMetricsBuilder_ == null) { + return java.util.Collections.unmodifiableList(versionMetrics_); + } else { + return versionMetricsBuilder_.getMessageList(); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public int getVersionMetricsCount() { + if (versionMetricsBuilder_ == null) { + return versionMetrics_.size(); + } else { + return versionMetricsBuilder_.getCount(); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + getVersionMetrics(int index) { + if (versionMetricsBuilder_ == null) { + return versionMetrics_.get(index); + } else { + return versionMetricsBuilder_.getMessage(index); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder setVersionMetrics( + int index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics value) { + if (versionMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVersionMetricsIsMutable(); + versionMetrics_.set(index, value); + onChanged(); + } else { + versionMetricsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder setVersionMetrics( + int index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + builderForValue) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.set(index, builderForValue.build()); + onChanged(); + } else { + versionMetricsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics value) { + if (versionMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVersionMetricsIsMutable(); + versionMetrics_.add(value); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + int index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics value) { + if (versionMetricsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVersionMetricsIsMutable(); + versionMetrics_.add(index, value); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + builderForValue) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.add(builderForValue.build()); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addVersionMetrics( + int index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + builderForValue) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.add(index, builderForValue.build()); + onChanged(); + } else { + versionMetricsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder addAllVersionMetrics( + java.lang.Iterable< + ? extends com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics> + values) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, versionMetrics_); + onChanged(); + } else { + versionMetricsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder clearVersionMetrics() { + if (versionMetricsBuilder_ == null) { + versionMetrics_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + versionMetricsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public Builder removeVersionMetrics(int index) { + if (versionMetricsBuilder_ == null) { + ensureVersionMetricsIsMutable(); + versionMetrics_.remove(index); + onChanged(); + } else { + versionMetricsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + getVersionMetricsBuilder(int index) { + return getVersionMetricsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder + getVersionMetricsOrBuilder(int index) { + if (versionMetricsBuilder_ == null) { + return versionMetrics_.get(index); + } else { + return versionMetricsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public java.util.List< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsOrBuilderList() { + if (versionMetricsBuilder_ != null) { + return versionMetricsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(versionMetrics_); + } + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + addVersionMetricsBuilder() { + return getVersionMetricsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + .getDefaultInstance()); + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder + addVersionMetricsBuilder(int index) { + return getVersionMetricsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics + .getDefaultInstance()); + } + /** + * + * + *
+       * Version variants and metrics.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics version_metrics = 1; + * + */ + public java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder> + getVersionMetricsBuilderList() { + return getVersionMetricsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder> + getVersionMetricsFieldBuilder() { + if (versionMetricsBuilder_ == null) { + versionMetricsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetrics.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.VersionMetricsOrBuilder>( + versionMetrics_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + versionMetrics_ = null; + } + return versionMetricsBuilder_; + } + + private com.google.protobuf.Timestamp lastUpdateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastUpdateTimeBuilder_; + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return Whether the lastUpdateTime field is set. + */ + public boolean hasLastUpdateTime() { + return lastUpdateTimeBuilder_ != null || lastUpdateTime_ != null; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + * + * @return The lastUpdateTime. + */ + public com.google.protobuf.Timestamp getLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } else { + return lastUpdateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastUpdateTime_ = value; + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = builderForValue.build(); + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder mergeLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (lastUpdateTime_ != null) { + lastUpdateTime_ = + com.google.protobuf.Timestamp.newBuilder(lastUpdateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + lastUpdateTime_ = value; + } + onChanged(); + } else { + lastUpdateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public Builder clearLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + onChanged(); + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getLastUpdateTimeBuilder() { + + onChanged(); + return getLastUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + if (lastUpdateTimeBuilder_ != null) { + return lastUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + } + /** + * + * + *
+       * The last time the experiment's stats data was updated. Will have default
+       * value if stats have never been computed for this experiment.
+       * 
+ * + * .google.protobuf.Timestamp last_update_time = 2; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getLastUpdateTimeFieldBuilder() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastUpdateTime(), getParentForChildren(), isClean()); + lastUpdateTime_ = null; + } + return lastUpdateTimeBuilder_; + } + + @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.dialogflow.cx.v3beta1.Experiment.Result) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.Experiment.Result) + private static final com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Result parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Result(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.Experiment.Result getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * The name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * 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 name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * 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 DISPLAY_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object displayName_; + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DESCRIPTION_FIELD_NUMBER = 3; + private volatile java.lang.Object description_; + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @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; + } + } + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @return The bytes for description. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDescriptionBytes() { + java.lang.Object ref = description_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + description_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int STATE_FIELD_NUMBER = 4; + private int state_; + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.State getState() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.Experiment.State result = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.State.valueOf(state_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.State.UNRECOGNIZED + : result; + } + + public static final int DEFINITION_FIELD_NUMBER = 5; + private com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition_; + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + * + * @return Whether the definition field is set. + */ + @java.lang.Override + public boolean hasDefinition() { + return definition_ != null; + } + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + * + * @return The definition. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition getDefinition() { + return definition_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.getDefaultInstance() + : definition_; + } + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder + getDefinitionOrBuilder() { + return getDefinition(); + } + + public static final int RESULT_FIELD_NUMBER = 6; + private com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result result_; + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + * + * @return Whether the result field is set. + */ + @java.lang.Override + public boolean hasResult() { + return result_ != null; + } + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + * + * @return The result. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result getResult() { + return result_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.getDefaultInstance() + : result_; + } + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder getResultOrBuilder() { + return getResult(); + } + + public static final int CREATE_TIME_FIELD_NUMBER = 7; + private com.google.protobuf.Timestamp createTime_; + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return Whether the createTime field is set. + */ + @java.lang.Override + public boolean hasCreateTime() { + return createTime_ != null; + } + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return The createTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getCreateTime() { + return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; + } + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + return getCreateTime(); + } + + public static final int START_TIME_FIELD_NUMBER = 8; + private com.google.protobuf.Timestamp startTime_; + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return Whether the startTime field is set. + */ + @java.lang.Override + public boolean hasStartTime() { + return startTime_ != null; + } + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return The startTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getStartTime() { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + return getStartTime(); + } + + public static final int END_TIME_FIELD_NUMBER = 9; + private com.google.protobuf.Timestamp endTime_; + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return Whether the endTime field is set. + */ + @java.lang.Override + public boolean hasEndTime() { + return endTime_ != null; + } + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return The endTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getEndTime() { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + return getEndTime(); + } + + public static final int LAST_UPDATE_TIME_FIELD_NUMBER = 10; + private com.google.protobuf.Timestamp lastUpdateTime_; + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return Whether the lastUpdateTime field is set. + */ + @java.lang.Override + public boolean hasLastUpdateTime() { + return lastUpdateTime_ != null; + } + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return The lastUpdateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getLastUpdateTime() { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + return getLastUpdateTime(); + } + + public static final int EXPERIMENT_LENGTH_FIELD_NUMBER = 11; + private com.google.protobuf.Duration experimentLength_; + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return Whether the experimentLength field is set. + */ + @java.lang.Override + public boolean hasExperimentLength() { + return experimentLength_ != null; + } + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return The experimentLength. + */ + @java.lang.Override + public com.google.protobuf.Duration getExperimentLength() { + return experimentLength_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : experimentLength_; + } + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + @java.lang.Override + public com.google.protobuf.DurationOrBuilder getExperimentLengthOrBuilder() { + return getExperimentLength(); + } + + public static final int VARIANTS_HISTORY_FIELD_NUMBER = 12; + private java.util.List variantsHistory_; + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + @java.lang.Override + public java.util.List + getVariantsHistoryList() { + return variantsHistory_; + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + @java.lang.Override + public java.util.List + getVariantsHistoryOrBuilderList() { + return variantsHistory_; + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + @java.lang.Override + public int getVariantsHistoryCount() { + return variantsHistory_.size(); + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory getVariantsHistory(int index) { + return variantsHistory_.get(index); + } + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder + getVariantsHistoryOrBuilder(int index) { + return variantsHistory_.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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!getDisplayNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); + } + if (!getDescriptionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, description_); + } + if (state_ + != com.google.cloud.dialogflow.cx.v3beta1.Experiment.State.STATE_UNSPECIFIED.getNumber()) { + output.writeEnum(4, state_); + } + if (definition_ != null) { + output.writeMessage(5, getDefinition()); + } + if (result_ != null) { + output.writeMessage(6, getResult()); + } + if (createTime_ != null) { + output.writeMessage(7, getCreateTime()); + } + if (startTime_ != null) { + output.writeMessage(8, getStartTime()); + } + if (endTime_ != null) { + output.writeMessage(9, getEndTime()); + } + if (lastUpdateTime_ != null) { + output.writeMessage(10, getLastUpdateTime()); + } + if (experimentLength_ != null) { + output.writeMessage(11, getExperimentLength()); + } + for (int i = 0; i < variantsHistory_.size(); i++) { + output.writeMessage(12, variantsHistory_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!getDisplayNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); + } + if (!getDescriptionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, description_); + } + if (state_ + != com.google.cloud.dialogflow.cx.v3beta1.Experiment.State.STATE_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); + } + if (definition_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getDefinition()); + } + if (result_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getResult()); + } + if (createTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getCreateTime()); + } + if (startTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getStartTime()); + } + if (endTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, getEndTime()); + } + if (lastUpdateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getLastUpdateTime()); + } + if (experimentLength_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getExperimentLength()); + } + for (int i = 0; i < variantsHistory_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, variantsHistory_.get(i)); + } + size += unknownFields.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.dialogflow.cx.v3beta1.Experiment)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.Experiment other = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (!getDescription().equals(other.getDescription())) return false; + if (state_ != other.state_) return false; + if (hasDefinition() != other.hasDefinition()) return false; + if (hasDefinition()) { + if (!getDefinition().equals(other.getDefinition())) return false; + } + if (hasResult() != other.hasResult()) return false; + if (hasResult()) { + if (!getResult().equals(other.getResult())) return false; + } + if (hasCreateTime() != other.hasCreateTime()) return false; + if (hasCreateTime()) { + if (!getCreateTime().equals(other.getCreateTime())) return false; + } + if (hasStartTime() != other.hasStartTime()) return false; + if (hasStartTime()) { + if (!getStartTime().equals(other.getStartTime())) return false; + } + if (hasEndTime() != other.hasEndTime()) return false; + if (hasEndTime()) { + if (!getEndTime().equals(other.getEndTime())) return false; + } + if (hasLastUpdateTime() != other.hasLastUpdateTime()) return false; + if (hasLastUpdateTime()) { + if (!getLastUpdateTime().equals(other.getLastUpdateTime())) return false; + } + if (hasExperimentLength() != other.hasExperimentLength()) return false; + if (hasExperimentLength()) { + if (!getExperimentLength().equals(other.getExperimentLength())) return false; + } + if (!getVariantsHistoryList().equals(other.getVariantsHistoryList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; + hash = (53 * hash) + getDescription().hashCode(); + hash = (37 * hash) + STATE_FIELD_NUMBER; + hash = (53 * hash) + state_; + if (hasDefinition()) { + hash = (37 * hash) + DEFINITION_FIELD_NUMBER; + hash = (53 * hash) + getDefinition().hashCode(); + } + if (hasResult()) { + hash = (37 * hash) + RESULT_FIELD_NUMBER; + hash = (53 * hash) + getResult().hashCode(); + } + if (hasCreateTime()) { + hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getCreateTime().hashCode(); + } + if (hasStartTime()) { + hash = (37 * hash) + START_TIME_FIELD_NUMBER; + hash = (53 * hash) + getStartTime().hashCode(); + } + if (hasEndTime()) { + hash = (37 * hash) + END_TIME_FIELD_NUMBER; + hash = (53 * hash) + getEndTime().hashCode(); + } + if (hasLastUpdateTime()) { + hash = (37 * hash) + LAST_UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getLastUpdateTime().hashCode(); + } + if (hasExperimentLength()) { + hash = (37 * hash) + EXPERIMENT_LENGTH_FIELD_NUMBER; + hash = (53 * hash) + getExperimentLength().hashCode(); + } + if (getVariantsHistoryCount() > 0) { + hash = (37 * hash) + VARIANTS_HISTORY_FIELD_NUMBER; + hash = (53 * hash) + getVariantsHistoryList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment 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.dialogflow.cx.v3beta1.Experiment parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment 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.dialogflow.cx.v3beta1.Experiment parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment 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.dialogflow.cx.v3beta1.Experiment parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment 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.dialogflow.cx.v3beta1.Experiment parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment 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.dialogflow.cx.v3beta1.Experiment 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; + } + /** + * + * + *
+   * Represents an experiment in an environment.
+   * Next ID: 13
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.Experiment} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.Experiment) + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.class, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.Experiment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getVariantsHistoryFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + displayName_ = ""; + + description_ = ""; + + state_ = 0; + + if (definitionBuilder_ == null) { + definition_ = null; + } else { + definition_ = null; + definitionBuilder_ = null; + } + if (resultBuilder_ == null) { + result_ = null; + } else { + result_ = null; + resultBuilder_ = null; + } + if (createTimeBuilder_ == null) { + createTime_ = null; + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + if (startTimeBuilder_ == null) { + startTime_ = null; + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + if (endTimeBuilder_ == null) { + endTime_ = null; + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + if (experimentLengthBuilder_ == null) { + experimentLength_ = null; + } else { + experimentLength_ = null; + experimentLengthBuilder_ = null; + } + if (variantsHistoryBuilder_ == null) { + variantsHistory_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + variantsHistoryBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment build() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.Experiment result = + new com.google.cloud.dialogflow.cx.v3beta1.Experiment(this); + int from_bitField0_ = bitField0_; + result.name_ = name_; + result.displayName_ = displayName_; + result.description_ = description_; + result.state_ = state_; + if (definitionBuilder_ == null) { + result.definition_ = definition_; + } else { + result.definition_ = definitionBuilder_.build(); + } + if (resultBuilder_ == null) { + result.result_ = result_; + } else { + result.result_ = resultBuilder_.build(); + } + if (createTimeBuilder_ == null) { + result.createTime_ = createTime_; + } else { + result.createTime_ = createTimeBuilder_.build(); + } + if (startTimeBuilder_ == null) { + result.startTime_ = startTime_; + } else { + result.startTime_ = startTimeBuilder_.build(); + } + if (endTimeBuilder_ == null) { + result.endTime_ = endTime_; + } else { + result.endTime_ = endTimeBuilder_.build(); + } + if (lastUpdateTimeBuilder_ == null) { + result.lastUpdateTime_ = lastUpdateTime_; + } else { + result.lastUpdateTime_ = lastUpdateTimeBuilder_.build(); + } + if (experimentLengthBuilder_ == null) { + result.experimentLength_ = experimentLength_; + } else { + result.experimentLength_ = experimentLengthBuilder_.build(); + } + if (variantsHistoryBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = java.util.Collections.unmodifiableList(variantsHistory_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.variantsHistory_ = variantsHistory_; + } else { + result.variantsHistory_ = variantsHistoryBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.Experiment) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.Experiment) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.Experiment other) { + if (other == com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + onChanged(); + } + if (!other.getDescription().isEmpty()) { + description_ = other.description_; + onChanged(); + } + if (other.state_ != 0) { + setStateValue(other.getStateValue()); + } + if (other.hasDefinition()) { + mergeDefinition(other.getDefinition()); + } + if (other.hasResult()) { + mergeResult(other.getResult()); + } + if (other.hasCreateTime()) { + mergeCreateTime(other.getCreateTime()); + } + if (other.hasStartTime()) { + mergeStartTime(other.getStartTime()); + } + if (other.hasEndTime()) { + mergeEndTime(other.getEndTime()); + } + if (other.hasLastUpdateTime()) { + mergeLastUpdateTime(other.getLastUpdateTime()); + } + if (other.hasExperimentLength()) { + mergeExperimentLength(other.getExperimentLength()); + } + if (variantsHistoryBuilder_ == null) { + if (!other.variantsHistory_.isEmpty()) { + if (variantsHistory_.isEmpty()) { + variantsHistory_ = other.variantsHistory_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureVariantsHistoryIsMutable(); + variantsHistory_.addAll(other.variantsHistory_); + } + onChanged(); + } + } else { + if (!other.variantsHistory_.isEmpty()) { + if (variantsHistoryBuilder_.isEmpty()) { + variantsHistoryBuilder_.dispose(); + variantsHistoryBuilder_ = null; + variantsHistory_ = other.variantsHistory_; + bitField0_ = (bitField0_ & ~0x00000001); + variantsHistoryBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getVariantsHistoryFieldBuilder() + : null; + } else { + variantsHistoryBuilder_.addAllMessages(other.variantsHistory_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.Experiment parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.Experiment) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * The name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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 name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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 name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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; + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * string name = 1; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * The name of the experiment.
+     * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+     * 
+ * + * 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; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + displayName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + + displayName_ = getDefaultInstance().getDisplayName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The human-readable name of the experiment (unique in an environment). Limit
+     * of 64 characters.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + displayName_ = value; + onChanged(); + return this; + } + + private java.lang.Object description_ = ""; + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + } + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + } + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @return This builder for chaining. + */ + public Builder clearDescription() { + + description_ = getDefaultInstance().getDescription(); + onChanged(); + return this; + } + /** + * + * + *
+     * The human-readable description of the experiment.
+     * 
+ * + * string description = 3; + * + * @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; + onChanged(); + return this; + } + + private int state_ = 0; + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return The enum numeric value on the wire for state. + */ + @java.lang.Override + public int getStateValue() { + return state_; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return The state. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.State getState() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.Experiment.State result = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.State.valueOf(state_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.State.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @param value The state to set. + * @return This builder for chaining. + */ + public Builder setState(com.google.cloud.dialogflow.cx.v3beta1.Experiment.State value) { + if (value == null) { + throw new NullPointerException(); + } + + state_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * The current state of the experiment.
+     * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+     * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+     * RUNNING->CANCELLED.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return This builder for chaining. + */ + public Builder clearState() { + + state_ = 0; + onChanged(); + return this; + } + + private com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder> + definitionBuilder_; + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + * + * @return Whether the definition field is set. + */ + public boolean hasDefinition() { + return definitionBuilder_ != null || definition_ != null; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + * + * @return The definition. + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition getDefinition() { + if (definitionBuilder_ == null) { + return definition_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.getDefaultInstance() + : definition_; + } else { + return definitionBuilder_.getMessage(); + } + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + public Builder setDefinition( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition value) { + if (definitionBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + definition_ = value; + onChanged(); + } else { + definitionBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + public Builder setDefinition( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder builderForValue) { + if (definitionBuilder_ == null) { + definition_ = builderForValue.build(); + onChanged(); + } else { + definitionBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + public Builder mergeDefinition( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition value) { + if (definitionBuilder_ == null) { + if (definition_ != null) { + definition_ = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.newBuilder(definition_) + .mergeFrom(value) + .buildPartial(); + } else { + definition_ = value; + } + onChanged(); + } else { + definitionBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + public Builder clearDefinition() { + if (definitionBuilder_ == null) { + definition_ = null; + onChanged(); + } else { + definition_ = null; + definitionBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder + getDefinitionBuilder() { + + onChanged(); + return getDefinitionFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder + getDefinitionOrBuilder() { + if (definitionBuilder_ != null) { + return definitionBuilder_.getMessageOrBuilder(); + } else { + return definition_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.getDefaultInstance() + : definition_; + } + } + /** + * + * + *
+     * The definition of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder> + getDefinitionFieldBuilder() { + if (definitionBuilder_ == null) { + definitionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder>( + getDefinition(), getParentForChildren(), isClean()); + definition_ = null; + } + return definitionBuilder_; + } + + private com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result result_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder> + resultBuilder_; + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + * + * @return Whether the result field is set. + */ + public boolean hasResult() { + return resultBuilder_ != null || result_ != null; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + * + * @return The result. + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result getResult() { + if (resultBuilder_ == null) { + return result_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.getDefaultInstance() + : result_; + } else { + return resultBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + public Builder setResult(com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result value) { + if (resultBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + result_ = value; + onChanged(); + } else { + resultBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + public Builder setResult( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder builderForValue) { + if (resultBuilder_ == null) { + result_ = builderForValue.build(); + onChanged(); + } else { + resultBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + public Builder mergeResult(com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result value) { + if (resultBuilder_ == null) { + if (result_ != null) { + result_ = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.newBuilder(result_) + .mergeFrom(value) + .buildPartial(); + } else { + result_ = value; + } + onChanged(); + } else { + resultBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + public Builder clearResult() { + if (resultBuilder_ == null) { + result_ = null; + onChanged(); + } else { + result_ = null; + resultBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder getResultBuilder() { + + onChanged(); + return getResultFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder getResultOrBuilder() { + if (resultBuilder_ != null) { + return resultBuilder_.getMessageOrBuilder(); + } else { + return result_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.getDefaultInstance() + : result_; + } + } + /** + * + * + *
+     * Inference result of the experiment.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder> + getResultFieldBuilder() { + if (resultBuilder_ == null) { + resultBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result.Builder, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder>( + getResult(), getParentForChildren(), isClean()); + result_ = null; + } + return resultBuilder_; + } + + 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_; + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return Whether the createTime field is set. + */ + public boolean hasCreateTime() { + return createTimeBuilder_ != null || createTime_ != null; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @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(); + } + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + createTime_ = value; + onChanged(); + } else { + createTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (createTimeBuilder_ == null) { + createTime_ = builderForValue.build(); + onChanged(); + } else { + createTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { + if (createTimeBuilder_ == null) { + if (createTime_ != null) { + createTime_ = + com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); + } else { + createTime_ = value; + } + onChanged(); + } else { + createTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public Builder clearCreateTime() { + if (createTimeBuilder_ == null) { + createTime_ = null; + onChanged(); + } else { + createTime_ = null; + createTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { + + onChanged(); + return getCreateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { + if (createTimeBuilder_ != null) { + return createTimeBuilder_.getMessageOrBuilder(); + } else { + return createTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : createTime_; + } + } + /** + * + * + *
+     * Creation time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + 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 startTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + startTimeBuilder_; + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return Whether the startTime field is set. + */ + public boolean hasStartTime() { + return startTimeBuilder_ != null || startTime_ != null; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return The startTime. + */ + public com.google.protobuf.Timestamp getStartTime() { + if (startTimeBuilder_ == null) { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } else { + return startTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder setStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + startTime_ = value; + onChanged(); + } else { + startTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (startTimeBuilder_ == null) { + startTime_ = builderForValue.build(); + onChanged(); + } else { + startTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder mergeStartTime(com.google.protobuf.Timestamp value) { + if (startTimeBuilder_ == null) { + if (startTime_ != null) { + startTime_ = + com.google.protobuf.Timestamp.newBuilder(startTime_).mergeFrom(value).buildPartial(); + } else { + startTime_ = value; + } + onChanged(); + } else { + startTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public Builder clearStartTime() { + if (startTimeBuilder_ == null) { + startTime_ = null; + onChanged(); + } else { + startTime_ = null; + startTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { + + onChanged(); + return getStartTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { + if (startTimeBuilder_ != null) { + return startTimeBuilder_.getMessageOrBuilder(); + } else { + return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; + } + } + /** + * + * + *
+     * Start time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getStartTimeFieldBuilder() { + if (startTimeBuilder_ == null) { + startTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getStartTime(), getParentForChildren(), isClean()); + startTime_ = null; + } + return startTimeBuilder_; + } + + private com.google.protobuf.Timestamp endTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + endTimeBuilder_; + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return Whether the endTime field is set. + */ + public boolean hasEndTime() { + return endTimeBuilder_ != null || endTime_ != null; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return The endTime. + */ + public com.google.protobuf.Timestamp getEndTime() { + if (endTimeBuilder_ == null) { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } else { + return endTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder setEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + endTime_ = value; + onChanged(); + } else { + endTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (endTimeBuilder_ == null) { + endTime_ = builderForValue.build(); + onChanged(); + } else { + endTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder mergeEndTime(com.google.protobuf.Timestamp value) { + if (endTimeBuilder_ == null) { + if (endTime_ != null) { + endTime_ = + com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); + } else { + endTime_ = value; + } + onChanged(); + } else { + endTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public Builder clearEndTime() { + if (endTimeBuilder_ == null) { + endTime_ = null; + onChanged(); + } else { + endTime_ = null; + endTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { + + onChanged(); + return getEndTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { + if (endTimeBuilder_ != null) { + return endTimeBuilder_.getMessageOrBuilder(); + } else { + return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; + } + } + /** + * + * + *
+     * End time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getEndTimeFieldBuilder() { + if (endTimeBuilder_ == null) { + endTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getEndTime(), getParentForChildren(), isClean()); + endTime_ = null; + } + return endTimeBuilder_; + } + + private com.google.protobuf.Timestamp lastUpdateTime_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + lastUpdateTimeBuilder_; + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return Whether the lastUpdateTime field is set. + */ + public boolean hasLastUpdateTime() { + return lastUpdateTimeBuilder_ != null || lastUpdateTime_ != null; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return The lastUpdateTime. + */ + public com.google.protobuf.Timestamp getLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } else { + return lastUpdateTimeBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + lastUpdateTime_ = value; + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder setLastUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = builderForValue.build(); + onChanged(); + } else { + lastUpdateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder mergeLastUpdateTime(com.google.protobuf.Timestamp value) { + if (lastUpdateTimeBuilder_ == null) { + if (lastUpdateTime_ != null) { + lastUpdateTime_ = + com.google.protobuf.Timestamp.newBuilder(lastUpdateTime_) + .mergeFrom(value) + .buildPartial(); + } else { + lastUpdateTime_ = value; + } + onChanged(); + } else { + lastUpdateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public Builder clearLastUpdateTime() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTime_ = null; + onChanged(); + } else { + lastUpdateTime_ = null; + lastUpdateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public com.google.protobuf.Timestamp.Builder getLastUpdateTimeBuilder() { + + onChanged(); + return getLastUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + public com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder() { + if (lastUpdateTimeBuilder_ != null) { + return lastUpdateTimeBuilder_.getMessageOrBuilder(); + } else { + return lastUpdateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : lastUpdateTime_; + } + } + /** + * + * + *
+     * Last update time of this experiment.
+     * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder> + getLastUpdateTimeFieldBuilder() { + if (lastUpdateTimeBuilder_ == null) { + lastUpdateTimeBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Timestamp, + com.google.protobuf.Timestamp.Builder, + com.google.protobuf.TimestampOrBuilder>( + getLastUpdateTime(), getParentForChildren(), isClean()); + lastUpdateTime_ = null; + } + return lastUpdateTimeBuilder_; + } + + private com.google.protobuf.Duration experimentLength_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + experimentLengthBuilder_; + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return Whether the experimentLength field is set. + */ + public boolean hasExperimentLength() { + return experimentLengthBuilder_ != null || experimentLength_ != null; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return The experimentLength. + */ + public com.google.protobuf.Duration getExperimentLength() { + if (experimentLengthBuilder_ == null) { + return experimentLength_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : experimentLength_; + } else { + return experimentLengthBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder setExperimentLength(com.google.protobuf.Duration value) { + if (experimentLengthBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + experimentLength_ = value; + onChanged(); + } else { + experimentLengthBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder setExperimentLength(com.google.protobuf.Duration.Builder builderForValue) { + if (experimentLengthBuilder_ == null) { + experimentLength_ = builderForValue.build(); + onChanged(); + } else { + experimentLengthBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder mergeExperimentLength(com.google.protobuf.Duration value) { + if (experimentLengthBuilder_ == null) { + if (experimentLength_ != null) { + experimentLength_ = + com.google.protobuf.Duration.newBuilder(experimentLength_) + .mergeFrom(value) + .buildPartial(); + } else { + experimentLength_ = value; + } + onChanged(); + } else { + experimentLengthBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public Builder clearExperimentLength() { + if (experimentLengthBuilder_ == null) { + experimentLength_ = null; + onChanged(); + } else { + experimentLength_ = null; + experimentLengthBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public com.google.protobuf.Duration.Builder getExperimentLengthBuilder() { + + onChanged(); + return getExperimentLengthFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + public com.google.protobuf.DurationOrBuilder getExperimentLengthOrBuilder() { + if (experimentLengthBuilder_ != null) { + return experimentLengthBuilder_.getMessageOrBuilder(); + } else { + return experimentLength_ == null + ? com.google.protobuf.Duration.getDefaultInstance() + : experimentLength_; + } + } + /** + * + * + *
+     * Maximum number of days to run the experiment.
+     * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder> + getExperimentLengthFieldBuilder() { + if (experimentLengthBuilder_ == null) { + experimentLengthBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.protobuf.Duration, + com.google.protobuf.Duration.Builder, + com.google.protobuf.DurationOrBuilder>( + getExperimentLength(), getParentForChildren(), isClean()); + experimentLength_ = null; + } + return experimentLengthBuilder_; + } + + private java.util.List + variantsHistory_ = java.util.Collections.emptyList(); + + private void ensureVariantsHistoryIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + variantsHistory_ = + new java.util.ArrayList( + variantsHistory_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder> + variantsHistoryBuilder_; + + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public java.util.List + getVariantsHistoryList() { + if (variantsHistoryBuilder_ == null) { + return java.util.Collections.unmodifiableList(variantsHistory_); + } else { + return variantsHistoryBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public int getVariantsHistoryCount() { + if (variantsHistoryBuilder_ == null) { + return variantsHistory_.size(); + } else { + return variantsHistoryBuilder_.getCount(); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory getVariantsHistory(int index) { + if (variantsHistoryBuilder_ == null) { + return variantsHistory_.get(index); + } else { + return variantsHistoryBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder setVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory value) { + if (variantsHistoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsHistoryIsMutable(); + variantsHistory_.set(index, value); + onChanged(); + } else { + variantsHistoryBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder setVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder builderForValue) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.set(index, builderForValue.build()); + onChanged(); + } else { + variantsHistoryBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder addVariantsHistory( + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory value) { + if (variantsHistoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(value); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder addVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory value) { + if (variantsHistoryBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(index, value); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder addVariantsHistory( + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder builderForValue) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(builderForValue.build()); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder addVariantsHistory( + int index, com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder builderForValue) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.add(index, builderForValue.build()); + onChanged(); + } else { + variantsHistoryBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder addAllVariantsHistory( + java.lang.Iterable + values) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, variantsHistory_); + onChanged(); + } else { + variantsHistoryBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder clearVariantsHistory() { + if (variantsHistoryBuilder_ == null) { + variantsHistory_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + variantsHistoryBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public Builder removeVariantsHistory(int index) { + if (variantsHistoryBuilder_ == null) { + ensureVariantsHistoryIsMutable(); + variantsHistory_.remove(index); + onChanged(); + } else { + variantsHistoryBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder getVariantsHistoryBuilder( + int index) { + return getVariantsHistoryFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder + getVariantsHistoryOrBuilder(int index) { + if (variantsHistoryBuilder_ == null) { + return variantsHistory_.get(index); + } else { + return variantsHistoryBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public java.util.List + getVariantsHistoryOrBuilderList() { + if (variantsHistoryBuilder_ != null) { + return variantsHistoryBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(variantsHistory_); + } + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder + addVariantsHistoryBuilder() { + return getVariantsHistoryFieldBuilder() + .addBuilder(com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.getDefaultInstance()); + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder addVariantsHistoryBuilder( + int index) { + return getVariantsHistoryFieldBuilder() + .addBuilder( + index, com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.getDefaultInstance()); + } + /** + * + * + *
+     * The history of updates to the experiment variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + public java.util.List + getVariantsHistoryBuilderList() { + return getVariantsHistoryFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder> + getVariantsHistoryFieldBuilder() { + if (variantsHistoryBuilder_ == null) { + variantsHistoryBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder>( + variantsHistory_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + variantsHistory_ = null; + } + return variantsHistoryBuilder_; + } + + @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.dialogflow.cx.v3beta1.Experiment) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.Experiment) + private static final com.google.cloud.dialogflow.cx.v3beta1.Experiment DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.Experiment(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.Experiment getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Experiment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Experiment(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.Experiment getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentName.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentName.java new file mode 100644 index 000000000..fc6750c8a --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentName.java @@ -0,0 +1,298 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +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 ExperimentName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/agents/{agent}/environments/{environment}/experiments/{experiment}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String agent; + private final String environment; + private final String experiment; + + @Deprecated + protected ExperimentName() { + project = null; + location = null; + agent = null; + environment = null; + experiment = null; + } + + private ExperimentName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + agent = Preconditions.checkNotNull(builder.getAgent()); + environment = Preconditions.checkNotNull(builder.getEnvironment()); + experiment = Preconditions.checkNotNull(builder.getExperiment()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAgent() { + return agent; + } + + public String getEnvironment() { + return environment; + } + + public String getExperiment() { + return experiment; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static ExperimentName of( + String project, String location, String agent, String environment, String experiment) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgent(agent) + .setEnvironment(environment) + .setExperiment(experiment) + .build(); + } + + public static String format( + String project, String location, String agent, String environment, String experiment) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setAgent(agent) + .setEnvironment(environment) + .setExperiment(experiment) + .build() + .toString(); + } + + public static ExperimentName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT.validatedMatch( + formattedString, "ExperimentName.parse: formattedString not in valid format"); + return of( + matchMap.get("project"), + matchMap.get("location"), + matchMap.get("agent"), + matchMap.get("environment"), + matchMap.get("experiment")); + } + + 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 (ExperimentName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT.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 (agent != null) { + fieldMapBuilder.put("agent", agent); + } + if (environment != null) { + fieldMapBuilder.put("environment", environment); + } + if (experiment != null) { + fieldMapBuilder.put("experiment", experiment); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_AGENT_ENVIRONMENT_EXPERIMENT.instantiate( + "project", + project, + "location", + location, + "agent", + agent, + "environment", + environment, + "experiment", + experiment); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + ExperimentName that = ((ExperimentName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.agent, that.agent) + && Objects.equals(this.environment, that.environment) + && Objects.equals(this.experiment, that.experiment); + } + 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(agent); + h *= 1000003; + h ^= Objects.hashCode(environment); + h *= 1000003; + h ^= Objects.hashCode(experiment); + return h; + } + + /** + * Builder for + * projects/{project}/locations/{location}/agents/{agent}/environments/{environment}/experiments/{experiment}. + */ + public static class Builder { + private String project; + private String location; + private String agent; + private String environment; + private String experiment; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getAgent() { + return agent; + } + + public String getEnvironment() { + return environment; + } + + public String getExperiment() { + return experiment; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setAgent(String agent) { + this.agent = agent; + return this; + } + + public Builder setEnvironment(String environment) { + this.environment = environment; + return this; + } + + public Builder setExperiment(String experiment) { + this.experiment = experiment; + return this; + } + + private Builder(ExperimentName experimentName) { + project = experimentName.project; + location = experimentName.location; + agent = experimentName.agent; + environment = experimentName.environment; + experiment = experimentName.experiment; + } + + public ExperimentName build() { + return new ExperimentName(this); + } + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentOrBuilder.java new file mode 100644 index 000000000..16ff2aa8c --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentOrBuilder.java @@ -0,0 +1,440 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface ExperimentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.Experiment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * string name = 1; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * The name of the experiment.
+   * Format: projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>..
+   * 
+ * + * string name = 1; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + /** + * + * + *
+   * Required. The human-readable name of the experiment (unique in an environment). Limit
+   * of 64 characters.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @return The description. + */ + java.lang.String getDescription(); + /** + * + * + *
+   * The human-readable description of the experiment.
+   * 
+ * + * string description = 3; + * + * @return The bytes for description. + */ + com.google.protobuf.ByteString getDescriptionBytes(); + + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return The enum numeric value on the wire for state. + */ + int getStateValue(); + /** + * + * + *
+   * The current state of the experiment.
+   * Transition triggered by Expriments.StartExperiment: PENDING->RUNNING.
+   * Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or
+   * RUNNING->CANCELLED.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.State state = 4; + * + * @return The state. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.State getState(); + + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + * + * @return Whether the definition field is set. + */ + boolean hasDefinition(); + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + * + * @return The definition. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Definition getDefinition(); + /** + * + * + *
+   * The definition of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Definition definition = 5; + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.DefinitionOrBuilder getDefinitionOrBuilder(); + + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + * + * @return Whether the result field is set. + */ + boolean hasResult(); + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + * + * @return The result. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Result getResult(); + /** + * + * + *
+   * Inference result of the experiment.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.Experiment.Result result = 6; + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment.ResultOrBuilder getResultOrBuilder(); + + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return Whether the createTime field is set. + */ + boolean hasCreateTime(); + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + * + * @return The createTime. + */ + com.google.protobuf.Timestamp getCreateTime(); + /** + * + * + *
+   * Creation time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp create_time = 7; + */ + com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); + + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return Whether the startTime field is set. + */ + boolean hasStartTime(); + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + * + * @return The startTime. + */ + com.google.protobuf.Timestamp getStartTime(); + /** + * + * + *
+   * Start time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp start_time = 8; + */ + com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); + + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return Whether the endTime field is set. + */ + boolean hasEndTime(); + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + * + * @return The endTime. + */ + com.google.protobuf.Timestamp getEndTime(); + /** + * + * + *
+   * End time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp end_time = 9; + */ + com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); + + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return Whether the lastUpdateTime field is set. + */ + boolean hasLastUpdateTime(); + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + * + * @return The lastUpdateTime. + */ + com.google.protobuf.Timestamp getLastUpdateTime(); + /** + * + * + *
+   * Last update time of this experiment.
+   * 
+ * + * .google.protobuf.Timestamp last_update_time = 10; + */ + com.google.protobuf.TimestampOrBuilder getLastUpdateTimeOrBuilder(); + + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return Whether the experimentLength field is set. + */ + boolean hasExperimentLength(); + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + * + * @return The experimentLength. + */ + com.google.protobuf.Duration getExperimentLength(); + /** + * + * + *
+   * Maximum number of days to run the experiment.
+   * 
+ * + * .google.protobuf.Duration experiment_length = 11; + */ + com.google.protobuf.DurationOrBuilder getExperimentLengthOrBuilder(); + + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + java.util.List getVariantsHistoryList(); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory getVariantsHistory(int index); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + int getVariantsHistoryCount(); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + java.util.List + getVariantsHistoryOrBuilderList(); + /** + * + * + *
+   * The history of updates to the experiment variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VariantsHistory variants_history = 12; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder getVariantsHistoryOrBuilder( + int index); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentProto.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentProto.java new file mode 100644 index 000000000..2df16da30 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentProto.java @@ -0,0 +1,436 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public final class ExperimentProto { + private ExperimentProto() {} + + 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_dialogflow_cx_v3beta1_Experiment_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_fieldAccessorTable; + + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + return descriptor; + } + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + + static { + java.lang.String[] descriptorData = { + "\n3google/cloud/dialogflow/cx/v3beta1/exp" + + "eriment.proto\022\"google.cloud.dialogflow.c" + + "x.v3beta1\032\034google/api/annotations.proto\032" + + "\027google/api/client.proto\032\037google/api/fie" + + "ld_behavior.proto\032\031google/api/resource.p" + + "roto\032\036google/protobuf/duration.proto\032\033go" + + "ogle/protobuf/empty.proto\032 google/protob" + + "uf/field_mask.proto\032\037google/protobuf/tim" + + "estamp.proto\"\230\016\n\nExperiment\022\014\n\004name\030\001 \001(" + + "\t\022\031\n\014display_name\030\002 \001(\tB\003\340A\002\022\023\n\013descript" + + "ion\030\003 \001(\t\022C\n\005state\030\004 \001(\01624.google.cloud." + + "dialogflow.cx.v3beta1.Experiment.State\022M" + + "\n\ndefinition\030\005 \001(\01329.google.cloud.dialog" + + "flow.cx.v3beta1.Experiment.Definition\022E\n" + + "\006result\030\006 \001(\01325.google.cloud.dialogflow." + + "cx.v3beta1.Experiment.Result\022/\n\013create_t" + + "ime\030\007 \001(\0132\032.google.protobuf.Timestamp\022.\n" + + "\nstart_time\030\010 \001(\0132\032.google.protobuf.Time" + + "stamp\022,\n\010end_time\030\t \001(\0132\032.google.protobu" + + "f.Timestamp\0224\n\020last_update_time\030\n \001(\0132\032." + + "google.protobuf.Timestamp\0224\n\021experiment_" + + "length\030\013 \001(\0132\031.google.protobuf.Duration\022" + + "M\n\020variants_history\030\014 \003(\01323.google.cloud" + + ".dialogflow.cx.v3beta1.VariantsHistory\032|" + + "\n\nDefinition\022\021\n\tcondition\030\001 \001(\t\022O\n\020versi" + + "on_variants\030\002 \001(\01323.google.cloud.dialogf" + + "low.cx.v3beta1.VersionVariantsH\000B\n\n\010vari" + + "ants\032\315\006\n\006Result\022]\n\017version_metrics\030\001 \003(\013" + + "2D.google.cloud.dialogflow.cx.v3beta1.Ex" + + "periment.Result.VersionMetrics\0224\n\020last_u" + + "pdate_time\030\002 \001(\0132\032.google.protobuf.Times" + + "tamp\032g\n\022ConfidenceInterval\022\030\n\020confidence" + + "_level\030\001 \001(\001\022\r\n\005ratio\030\002 \001(\001\022\023\n\013lower_bou" + + "nd\030\003 \001(\001\022\023\n\013upper_bound\030\004 \001(\001\032\331\001\n\006Metric" + + "\022N\n\004type\030\001 \001(\0162@.google.cloud.dialogflow" + + ".cx.v3beta1.Experiment.Result.MetricType" + + "\022\017\n\005ratio\030\002 \001(\001H\000\022e\n\023confidence_interval" + + "\030\003 \001(\0132H.google.cloud.dialogflow.cx.v3be" + + "ta1.Experiment.Result.ConfidenceInterval" + + "B\007\n\005value\032\257\001\n\016VersionMetrics\0227\n\007version\030" + + "\001 \001(\tB&\372A#\n!dialogflow.googleapis.com/Ve" + + "rsion\022M\n\007metrics\030\002 \003(\0132<.google.cloud.di" + + "alogflow.cx.v3beta1.Experiment.Result.Me" + + "tric\022\025\n\rsession_count\030\003 \001(\005\"\266\001\n\nMetricTy" + + "pe\022\026\n\022METRIC_UNSPECIFIED\020\000\022&\n\"CONTAINED_" + + "SESSION_NO_CALLBACK_RATE\020\001\022\033\n\027LIVE_AGENT" + + "_HANDOFF_RATE\020\002\022\031\n\025CALLBACK_SESSION_RATE" + + "\020\003\022\032\n\026ABANDONED_SESSION_RATE\020\004\022\024\n\020SESSIO" + + "N_END_RATE\020\005\"@\n\005State\022\025\n\021STATE_UNSPECIFI" + + "ED\020\000\022\t\n\005DRAFT\020\001\022\013\n\007RUNNING\020\002\022\010\n\004DONE\020\003:\226" + + "\001\352A\222\001\n$dialogflow.googleapis.com/Experim" + + "ent\022jprojects/{project}/locations/{locat" + + "ion}/agents/{agent}/environments/{enviro" + + "nment}/experiments/{experiment}\"\262\001\n\017Vers" + + "ionVariants\022M\n\010variants\030\001 \003(\0132;.google.c" + + "loud.dialogflow.cx.v3beta1.VersionVarian" + + "ts.Variant\032P\n\007Variant\022\017\n\007version\030\001 \001(\t\022\032" + + "\n\022traffic_allocation\030\002 \001(\002\022\030\n\020is_control" + + "_group\030\003 \001(\010\"\237\001\n\017VariantsHistory\022O\n\020vers" + + "ion_variants\030\001 \001(\01323.google.cloud.dialog" + + "flow.cx.v3beta1.VersionVariantsH\000\022/\n\013upd" + + "ate_time\030\002 \001(\0132\032.google.protobuf.Timesta" + + "mpB\n\n\010variants\"}\n\026ListExperimentsRequest" + + "\022<\n\006parent\030\001 \001(\tB,\340A\002\372A&\022$dialogflow.goo" + + "gleapis.com/Experiment\022\021\n\tpage_size\030\002 \001(" + + "\005\022\022\n\npage_token\030\003 \001(\t\"w\n\027ListExperiments" + + "Response\022C\n\013experiments\030\001 \003(\0132..google.c" + + "loud.dialogflow.cx.v3beta1.Experiment\022\027\n" + + "\017next_page_token\030\002 \001(\t\"R\n\024GetExperimentR" + + "equest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n$dialogflow" + + ".googleapis.com/Experiment\"\240\001\n\027CreateExp" + + "erimentRequest\022<\n\006parent\030\001 \001(\tB,\340A\002\372A&\022$" + + "dialogflow.googleapis.com/Experiment\022G\n\n" + + "experiment\030\002 \001(\0132..google.cloud.dialogfl" + + "ow.cx.v3beta1.ExperimentB\003\340A\002\"\230\001\n\027Update" + + "ExperimentRequest\022G\n\nexperiment\030\001 \001(\0132.." + + "google.cloud.dialogflow.cx.v3beta1.Exper" + + "imentB\003\340A\002\0224\n\013update_mask\030\002 \001(\0132\032.google" + + ".protobuf.FieldMaskB\003\340A\002\"U\n\027DeleteExperi" + + "mentRequest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n$dialo" + + "gflow.googleapis.com/Experiment\"T\n\026Start" + + "ExperimentRequest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n" + + "$dialogflow.googleapis.com/Experiment\"S\n" + + "\025StopExperimentRequest\022:\n\004name\030\001 \001(\tB,\340A" + + "\002\372A&\n$dialogflow.googleapis.com/Experime" + + "nt2\335\r\n\013Experiments\022\351\001\n\017ListExperiments\022:" + + ".google.cloud.dialogflow.cx.v3beta1.List" + + "ExperimentsRequest\032;.google.cloud.dialog" + + "flow.cx.v3beta1.ListExperimentsResponse\"" + + "]\202\323\344\223\002N\022L/v3beta1/{parent=projects/*/loc" + + "ations/*/agents/*/environments/*}/experi" + + "ments\332A\006parent\022\326\001\n\rGetExperiment\0228.googl" + + "e.cloud.dialogflow.cx.v3beta1.GetExperim" + + "entRequest\032..google.cloud.dialogflow.cx." + + "v3beta1.Experiment\"[\202\323\344\223\002N\022L/v3beta1/{na" + + "me=projects/*/locations/*/agents/*/envir" + + "onments/*/experiments/*}\332A\004name\022\365\001\n\020Crea" + + "teExperiment\022;.google.cloud.dialogflow.c" + + "x.v3beta1.CreateExperimentRequest\032..goog" + + "le.cloud.dialogflow.cx.v3beta1.Experimen" + + "t\"t\202\323\344\223\002Z\"L/v3beta1/{parent=projects/*/l" + + "ocations/*/agents/*/environments/*}/expe" + + "riments:\nexperiment\332A\021parent,experiment\022" + + "\206\002\n\020UpdateExperiment\022;.google.cloud.dial" + + "ogflow.cx.v3beta1.UpdateExperimentReques" + + "t\032..google.cloud.dialogflow.cx.v3beta1.E" + + "xperiment\"\204\001\202\323\344\223\002e2W/v3beta1/{experiment" + + ".name=projects/*/locations/*/agents/*/en" + + "vironments/*/experiments/*}:\nexperiment\332" + + "A\026experiment,update_mask\022\304\001\n\020DeleteExper" + + "iment\022;.google.cloud.dialogflow.cx.v3bet" + + "a1.DeleteExperimentRequest\032\026.google.prot" + + "obuf.Empty\"[\202\323\344\223\002N*L/v3beta1/{name=proje" + + "cts/*/locations/*/agents/*/environments/" + + "*/experiments/*}\332A\004name\022\343\001\n\017StartExperim" + + "ent\022:.google.cloud.dialogflow.cx.v3beta1" + + ".StartExperimentRequest\032..google.cloud.d" + + "ialogflow.cx.v3beta1.Experiment\"d\202\323\344\223\002W\"" + + "R/v3beta1/{name=projects/*/locations/*/a" + + "gents/*/environments/*/experiments/*}:st" + + "art:\001*\332A\004name\022\340\001\n\016StopExperiment\0229.googl" + + "e.cloud.dialogflow.cx.v3beta1.StopExperi" + + "mentRequest\032..google.cloud.dialogflow.cx" + + ".v3beta1.Experiment\"c\202\323\344\223\002V\"Q/v3beta1/{n" + + "ame=projects/*/locations/*/agents/*/envi" + + "ronments/*/experiments/*}:stop:\001*\332A\004name" + + "\032x\312A\031dialogflow.googleapis.com\322AYhttps:/" + + "/www.googleapis.com/auth/cloud-platform," + + "https://www.googleapis.com/auth/dialogfl" + + "owB\256\001\n&com.google.cloud.dialogflow.cx.v3" + + "beta1B\017ExperimentProtoP\001ZDgoogle.golang." + + "org/genproto/googleapis/cloud/dialogflow" + + "/cx/v3beta1;cx\370\001\001\242\002\002DF\252\002\"Google.Cloud.Di" + + "alogflow.Cx.V3Beta1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.protobuf.DurationProto.getDescriptor(), + com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), + com.google.protobuf.TimestampProto.getDescriptor(), + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "Description", + "State", + "Definition", + "Result", + "CreateTime", + "StartTime", + "EndTime", + "LastUpdateTime", + "ExperimentLength", + "VariantsHistory", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Definition_descriptor, + new java.lang.String[] { + "Condition", "VersionVariants", "Variants", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor, + new java.lang.String[] { + "VersionMetrics", "LastUpdateTime", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_ConfidenceInterval_descriptor, + new java.lang.String[] { + "ConfidenceLevel", "Ratio", "LowerBound", "UpperBound", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor + .getNestedTypes() + .get(1); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_Metric_descriptor, + new java.lang.String[] { + "Type", "Ratio", "ConfidenceInterval", "Value", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_descriptor + .getNestedTypes() + .get(2); + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_Experiment_Result_VersionMetrics_descriptor, + new java.lang.String[] { + "Version", "Metrics", "SessionCount", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor, + new java.lang.String[] { + "Variants", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_descriptor, + new java.lang.String[] { + "Version", "TrafficAllocation", "IsControlGroup", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_descriptor, + new java.lang.String[] { + "VersionVariants", "UpdateTime", "Variants", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_descriptor, + new java.lang.String[] { + "Experiments", "NextPageToken", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateExperimentRequest_descriptor, + new java.lang.String[] { + "Parent", "Experiment", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(7); + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_descriptor, + new java.lang.String[] { + "Experiment", "UpdateMask", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(8); + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(9); + internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_descriptor = + getDescriptor().getMessageTypes().get(10); + internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_descriptor, + new java.lang.String[] { + "Name", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + 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.ResourceProto.getDescriptor(); + com.google.protobuf.DurationProto.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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequest.java index 27b117424..df969dcfe 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
+ * The request message for
+ * [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest} @@ -180,10 +181,10 @@ public com.google.protobuf.ByteString getNameBytes() { * * *
-   * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-   * export the agent to. The format of this URI must be
-   * `gs://<bucket-name>/<object-name>`.
-   * If left unspecified, the serialized agent is returned inline.
+   * Optional. The [Google Cloud
+   * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+   * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+   * left unspecified, the serialized agent is returned inline.
    * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -206,10 +207,10 @@ public java.lang.String getAgentUri() { * * *
-   * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-   * export the agent to. The format of this URI must be
-   * `gs://<bucket-name>/<object-name>`.
-   * If left unspecified, the serialized agent is returned inline.
+   * Optional. The [Google Cloud
+   * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+   * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+   * left unspecified, the serialized agent is returned inline.
    * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -402,7 +403,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
+   * The request message for
+   * [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest} @@ -690,10 +692,10 @@ public Builder setNameBytes(com.google.protobuf.ByteString value) { * * *
-     * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-     * export the agent to. The format of this URI must be
-     * `gs://<bucket-name>/<object-name>`.
-     * If left unspecified, the serialized agent is returned inline.
+     * Optional. The [Google Cloud
+     * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+     * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+     * left unspecified, the serialized agent is returned inline.
      * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -715,10 +717,10 @@ public java.lang.String getAgentUri() { * * *
-     * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-     * export the agent to. The format of this URI must be
-     * `gs://<bucket-name>/<object-name>`.
-     * If left unspecified, the serialized agent is returned inline.
+     * Optional. The [Google Cloud
+     * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+     * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+     * left unspecified, the serialized agent is returned inline.
      * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -740,10 +742,10 @@ public com.google.protobuf.ByteString getAgentUriBytes() { * * *
-     * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-     * export the agent to. The format of this URI must be
-     * `gs://<bucket-name>/<object-name>`.
-     * If left unspecified, the serialized agent is returned inline.
+     * Optional. The [Google Cloud
+     * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+     * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+     * left unspecified, the serialized agent is returned inline.
      * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -764,10 +766,10 @@ public Builder setAgentUri(java.lang.String value) { * * *
-     * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-     * export the agent to. The format of this URI must be
-     * `gs://<bucket-name>/<object-name>`.
-     * If left unspecified, the serialized agent is returned inline.
+     * Optional. The [Google Cloud
+     * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+     * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+     * left unspecified, the serialized agent is returned inline.
      * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -784,10 +786,10 @@ public Builder clearAgentUri() { * * *
-     * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-     * export the agent to. The format of this URI must be
-     * `gs://<bucket-name>/<object-name>`.
-     * If left unspecified, the serialized agent is returned inline.
+     * Optional. The [Google Cloud
+     * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+     * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+     * left unspecified, the serialized agent is returned inline.
      * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequestOrBuilder.java index b98996f88..e7cfc610a 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequestOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequestOrBuilder.java @@ -58,10 +58,10 @@ public interface ExportAgentRequestOrBuilder * * *
-   * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-   * export the agent to. The format of this URI must be
-   * `gs://<bucket-name>/<object-name>`.
-   * If left unspecified, the serialized agent is returned inline.
+   * Optional. The [Google Cloud
+   * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+   * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+   * left unspecified, the serialized agent is returned inline.
    * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; @@ -73,10 +73,10 @@ public interface ExportAgentRequestOrBuilder * * *
-   * Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to
-   * export the agent to. The format of this URI must be
-   * `gs://<bucket-name>/<object-name>`.
-   * If left unspecified, the serialized agent is returned inline.
+   * Optional. The [Google Cloud
+   * Storage](https://cloud.google.com/storage/docs/) URI to export the agent
+   * to. The format of this URI must be `gs://<bucket-name>/<object-name>`. If
+   * left unspecified, the serialized agent is returned inline.
    * 
* * string agent_uri = 2 [(.google.api.field_behavior) = OPTIONAL]; diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponse.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponse.java index 2a4779528..7fe730328 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponse.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponse.java @@ -22,7 +22,8 @@ * * *
- * The response message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
+ * The response message for
+ * [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ExportAgentResponse} @@ -168,7 +169,8 @@ public AgentCase getAgentCase() { * *
    * The URI to a file containing the exported agent. This field is populated
-   * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+   * only if `agent_uri` is specified in
+   * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
    * 
* * string agent_uri = 1; @@ -196,7 +198,8 @@ public java.lang.String getAgentUri() { * *
    * The URI to a file containing the exported agent. This field is populated
-   * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+   * only if `agent_uri` is specified in
+   * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
    * 
* * string agent_uri = 1; @@ -432,7 +435,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The response message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
+   * The response message for
+   * [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ExportAgentResponse} @@ -626,7 +630,8 @@ public Builder clearAgent() { * *
      * The URI to a file containing the exported agent. This field is populated
-     * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+     * only if `agent_uri` is specified in
+     * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
      * 
* * string agent_uri = 1; @@ -655,7 +660,8 @@ public java.lang.String getAgentUri() { * *
      * The URI to a file containing the exported agent. This field is populated
-     * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+     * only if `agent_uri` is specified in
+     * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
      * 
* * string agent_uri = 1; @@ -684,7 +690,8 @@ public com.google.protobuf.ByteString getAgentUriBytes() { * *
      * The URI to a file containing the exported agent. This field is populated
-     * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+     * only if `agent_uri` is specified in
+     * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
      * 
* * string agent_uri = 1; @@ -706,7 +713,8 @@ public Builder setAgentUri(java.lang.String value) { * *
      * The URI to a file containing the exported agent. This field is populated
-     * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+     * only if `agent_uri` is specified in
+     * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
      * 
* * string agent_uri = 1; @@ -726,7 +734,8 @@ public Builder clearAgentUri() { * *
      * The URI to a file containing the exported agent. This field is populated
-     * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+     * only if `agent_uri` is specified in
+     * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
      * 
* * string agent_uri = 1; diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponseOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponseOrBuilder.java index c3a8774a5..ea355ae19 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponseOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponseOrBuilder.java @@ -28,7 +28,8 @@ public interface ExportAgentResponseOrBuilder * *
    * The URI to a file containing the exported agent. This field is populated
-   * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+   * only if `agent_uri` is specified in
+   * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
    * 
* * string agent_uri = 1; @@ -41,7 +42,8 @@ public interface ExportAgentResponseOrBuilder * *
    * The URI to a file containing the exported agent. This field is populated
-   * only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
+   * only if `agent_uri` is specified in
+   * [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest].
    * 
* * string agent_uri = 1; diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetAgentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetAgentRequest.java index 222abad8b..e13c8fe2e 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetAgentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetAgentRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.GetAgent][google.cloud.dialogflow.cx.v3beta1.Agents.GetAgent].
+ * The request message for
+ * [Agents.GetAgent][google.cloud.dialogflow.cx.v3beta1.Agents.GetAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.GetAgentRequest} @@ -330,7 +331,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.GetAgent][google.cloud.dialogflow.cx.v3beta1.Agents.GetAgent].
+   * The request message for
+   * [Agents.GetAgent][google.cloud.dialogflow.cx.v3beta1.Agents.GetAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.GetAgentRequest} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequest.java new file mode 100644 index 000000000..4f8e2a29e --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequest.java @@ -0,0 +1,665 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.GetExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.GetExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest} + */ +public final class GetExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) + GetExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetExperimentRequest.newBuilder() to construct. + private GetExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private GetExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.GetExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest 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.dialogflow.cx.v3beta1.GetExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest 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.dialogflow.cx.v3beta1.GetExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest 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.dialogflow.cx.v3beta1.GetExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest 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.dialogflow.cx.v3beta1.GetExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest 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.dialogflow.cx.v3beta1.GetExperimentRequest 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 request message for [Experiments.GetExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.GetExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.GetExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest other) { + if (other == com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3beta1.GetExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new GetExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.GetExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequestOrBuilder.java new file mode 100644 index 000000000..cd551a79b --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface GetExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.GetExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment].
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequest.java new file mode 100644 index 000000000..d22af576e --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequest.java @@ -0,0 +1,674 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [SecuritySettingsService.GetSecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService.GetSecuritySettings].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest} + */ +public final class GetSecuritySettingsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) + GetSecuritySettingsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use GetSecuritySettingsRequest.newBuilder() to construct. + private GetSecuritySettingsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private GetSecuritySettingsRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetSecuritySettingsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private GetSecuritySettingsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<security settings 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. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<security settings 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest 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 request message for [SecuritySettingsService.GetSecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService.GetSecuritySettings].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<security settings 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. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<security settings 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. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<security settings 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<security settings ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<security settings 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; + 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetSecuritySettingsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new GetSecuritySettingsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.GetSecuritySettingsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequestOrBuilder.java new file mode 100644 index 000000000..b63dc8253 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface GetSecuritySettingsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.GetSecuritySettingsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<security settings ID>`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<security settings 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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsRequest.java index 72b151ff7..dd5389bb2 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
+ * The request message for
+ * [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListAgentsRequest} @@ -429,7 +430,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
+   * The request message for
+   * [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListAgentsRequest} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsResponse.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsResponse.java index 84837d503..028c3aeac 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsResponse.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListAgentsResponse.java @@ -22,7 +22,8 @@ * * *
- * The response message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
+ * The response message for
+ * [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListAgentsResponse} @@ -427,7 +428,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The response message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
+   * The response message for
+   * [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListAgentsResponse} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequest.java new file mode 100644 index 000000000..6f9ccd7dd --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequest.java @@ -0,0 +1,942 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3beta1.Experiments.ListExperiments].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest} + */ +public final class ListExperimentsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) + ListExperimentsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListExperimentsRequest.newBuilder() to construct. + private ListExperimentsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListExperimentsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListExperimentsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ListExperimentsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 16: + { + pageSize_ = input.readInt32(); + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + pageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment 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 PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of items to return in a single page. By default 20 and
+   * at most 100.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!getPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!getPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.ListExperimentsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest 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.dialogflow.cx.v3beta1.ListExperimentsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest 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.dialogflow.cx.v3beta1.ListExperimentsRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest 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.dialogflow.cx.v3beta1.ListExperimentsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest 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.dialogflow.cx.v3beta1.ListExperimentsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest 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.dialogflow.cx.v3beta1.ListExperimentsRequest 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 request message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3beta1.Experiments.ListExperiments].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.ListExperimentsRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest.getDefaultInstance()) + return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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 [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment 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; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + 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.dialogflow.cx.v3beta1.ListExperimentsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListExperimentsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListExperimentsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.ListExperimentsRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequestOrBuilder.java new file mode 100644 index 000000000..d898d28f1 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequestOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface ListExperimentsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ListExperimentsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of items to return in a single page. By default 20 and
+   * at most 100.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponse.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponse.java new file mode 100644 index 000000000..7b8008b6e --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponse.java @@ -0,0 +1,1223 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The response message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3beta1.Experiments.ListExperiments].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse} + */ +public final class ListExperimentsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) + ListExperimentsResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListExperimentsResponse.newBuilder() to construct. + private ListExperimentsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListExperimentsResponse() { + experiments_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListExperimentsResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ListExperimentsResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + experiments_ = + new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + experiments_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.parser(), + extensionRegistry)); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + nextPageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + experiments_ = java.util.Collections.unmodifiableList(experiments_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.class, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.Builder.class); + } + + public static final int EXPERIMENTS_FIELD_NUMBER = 1; + private java.util.List experiments_; + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + @java.lang.Override + public java.util.List getExperimentsList() { + return experiments_; + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + @java.lang.Override + public java.util.List + getExperimentsOrBuilderList() { + return experiments_; + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + @java.lang.Override + public int getExperimentsCount() { + return experiments_.size(); + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiments(int index) { + return experiments_.get(index); + } + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentsOrBuilder( + int index) { + return experiments_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < experiments_.size(); i++) { + output.writeMessage(1, experiments_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < experiments_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, experiments_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.ListExperimentsResponse)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse other = + (com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) obj; + + if (!getExperimentsList().equals(other.getExperimentsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getExperimentsCount() > 0) { + hash = (37 * hash) + EXPERIMENTS_FIELD_NUMBER; + hash = (53 * hash) + getExperimentsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse 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.dialogflow.cx.v3beta1.ListExperimentsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse 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.dialogflow.cx.v3beta1.ListExperimentsResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse 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.dialogflow.cx.v3beta1.ListExperimentsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse 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.dialogflow.cx.v3beta1.ListExperimentsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse 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.dialogflow.cx.v3beta1.ListExperimentsResponse 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 response message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3beta1.Experiments.ListExperiments].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.class, + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getExperimentsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (experimentsBuilder_ == null) { + experiments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + experimentsBuilder_.clear(); + } + nextPageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListExperimentsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse build() { + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse result = + new com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse(this); + int from_bitField0_ = bitField0_; + if (experimentsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + experiments_ = java.util.Collections.unmodifiableList(experiments_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.experiments_ = experiments_; + } else { + result.experiments_ = experimentsBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.ListExperimentsResponse) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse.getDefaultInstance()) + return this; + if (experimentsBuilder_ == null) { + if (!other.experiments_.isEmpty()) { + if (experiments_.isEmpty()) { + experiments_ = other.experiments_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureExperimentsIsMutable(); + experiments_.addAll(other.experiments_); + } + onChanged(); + } + } else { + if (!other.experiments_.isEmpty()) { + if (experimentsBuilder_.isEmpty()) { + experimentsBuilder_.dispose(); + experimentsBuilder_ = null; + experiments_ = other.experiments_; + bitField0_ = (bitField0_ & ~0x00000001); + experimentsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getExperimentsFieldBuilder() + : null; + } else { + experimentsBuilder_.addAllMessages(other.experiments_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List experiments_ = + java.util.Collections.emptyList(); + + private void ensureExperimentsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + experiments_ = + new java.util.ArrayList( + experiments_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder> + experimentsBuilder_; + + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public java.util.List getExperimentsList() { + if (experimentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(experiments_); + } else { + return experimentsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public int getExperimentsCount() { + if (experimentsBuilder_ == null) { + return experiments_.size(); + } else { + return experimentsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiments(int index) { + if (experimentsBuilder_ == null) { + return experiments_.get(index); + } else { + return experimentsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder setExperiments( + int index, com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExperimentsIsMutable(); + experiments_.set(index, value); + onChanged(); + } else { + experimentsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder setExperiments( + int index, com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder builderForValue) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.set(index, builderForValue.build()); + onChanged(); + } else { + experimentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder addExperiments(com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExperimentsIsMutable(); + experiments_.add(value); + onChanged(); + } else { + experimentsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder addExperiments( + int index, com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureExperimentsIsMutable(); + experiments_.add(index, value); + onChanged(); + } else { + experimentsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder addExperiments( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder builderForValue) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.add(builderForValue.build()); + onChanged(); + } else { + experimentsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder addExperiments( + int index, com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder builderForValue) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.add(index, builderForValue.build()); + onChanged(); + } else { + experimentsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder addAllExperiments( + java.lang.Iterable values) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, experiments_); + onChanged(); + } else { + experimentsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder clearExperiments() { + if (experimentsBuilder_ == null) { + experiments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + experimentsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public Builder removeExperiments(int index) { + if (experimentsBuilder_ == null) { + ensureExperimentsIsMutable(); + experiments_.remove(index); + onChanged(); + } else { + experimentsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder getExperimentsBuilder( + int index) { + return getExperimentsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentsOrBuilder( + int index) { + if (experimentsBuilder_ == null) { + return experiments_.get(index); + } else { + return experimentsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public java.util.List + getExperimentsOrBuilderList() { + if (experimentsBuilder_ != null) { + return experimentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(experiments_); + } + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder addExperimentsBuilder() { + return getExperimentsFieldBuilder() + .addBuilder(com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance()); + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder addExperimentsBuilder( + int index) { + return getExperimentsFieldBuilder() + .addBuilder( + index, com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance()); + } + /** + * + * + *
+     * The list of experiments. There will be a maximum number of items
+     * returned based on the page_size field in the request. The list may in some
+     * cases be empty or contain fewer entries than page_size even if this isn't
+     * the last page.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + public java.util.List + getExperimentsBuilderList() { + return getExperimentsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder> + getExperimentsFieldBuilder() { + if (experimentsBuilder_ == null) { + experimentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder>( + experiments_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + experiments_ = null; + } + return experimentsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + 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.dialogflow.cx.v3beta1.ListExperimentsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) + private static final com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListExperimentsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListExperimentsResponse(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.ListExperimentsResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponseOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponseOrBuilder.java new file mode 100644 index 000000000..473f7028e --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponseOrBuilder.java @@ -0,0 +1,119 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface ListExperimentsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ListExperimentsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + java.util.List getExperimentsList(); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiments(int index); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + int getExperimentsCount(); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + java.util.List + getExperimentsOrBuilderList(); + /** + * + * + *
+   * The list of experiments. There will be a maximum number of items
+   * returned based on the page_size field in the request. The list may in some
+   * cases be empty or contain fewer entries than page_size even if this isn't
+   * the last page.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.Experiment experiments = 1; + */ + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentsOrBuilder(int index); + + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequest.java new file mode 100644 index 000000000..85d7d1cbb --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequest.java @@ -0,0 +1,942 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [SecuritySettings.ListSecuritySettings][].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest} + */ +public final class ListSecuritySettingsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) + ListSecuritySettingsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListSecuritySettingsRequest.newBuilder() to construct. + private ListSecuritySettingsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListSecuritySettingsRequest() { + parent_ = ""; + pageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListSecuritySettingsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ListSecuritySettingsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + parent_ = s; + break; + } + case 16: + { + pageSize_ = input.readInt32(); + break; + } + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + + pageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest.Builder.class); + } + + public static final int PARENT_FIELD_NUMBER = 1; + private volatile java.lang.Object parent_; + /** + * + * + *
+   * Required. The location to list all security settings for.
+   * Format: `projects/<Project ID>/locations/<Location 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 location to list all security settings for.
+   * Format: `projects/<Project ID>/locations/<Location 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 PAGE_SIZE_FIELD_NUMBER = 2; + private int pageSize_; + /** + * + * + *
+   * The maximum number of items to return in a single page. By default 20 and
+   * at most 100.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + + public static final int PAGE_TOKEN_FIELD_NUMBER = 3; + private volatile java.lang.Object pageToken_; + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getPageTokenBytes() { + java.lang.Object ref = pageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + pageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (!getParentBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); + } + if (pageSize_ != 0) { + output.writeInt32(2, pageSize_); + } + if (!getPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getParentBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); + } + if (pageSize_ != 0) { + size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); + } + if (!getPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) obj; + + if (!getParent().equals(other.getParent())) return false; + if (getPageSize() != other.getPageSize()) return false; + if (!getPageToken().equals(other.getPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + PARENT_FIELD_NUMBER; + hash = (53 * hash) + getParent().hashCode(); + hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; + hash = (53 * hash) + getPageSize(); + hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest 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 request message for [SecuritySettings.ListSecuritySettings][].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + parent_ = ""; + + pageSize_ = 0; + + pageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest(this); + result.parent_ = parent_; + result.pageSize_ = pageSize_; + result.pageToken_ = pageToken_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + .getDefaultInstance()) return this; + if (!other.getParent().isEmpty()) { + parent_ = other.parent_; + onChanged(); + } + if (other.getPageSize() != 0) { + setPageSize(other.getPageSize()); + } + if (!other.getPageToken().isEmpty()) { + pageToken_ = other.pageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object parent_ = ""; + /** + * + * + *
+     * Required. The location to list all security settings for.
+     * Format: `projects/<Project ID>/locations/<Location 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 location to list all security settings for.
+     * Format: `projects/<Project ID>/locations/<Location 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 location to list all security settings for.
+     * Format: `projects/<Project ID>/locations/<Location 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The location to list all security settings for.
+     * Format: `projects/<Project ID>/locations/<Location ID>`.
+     * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearParent() { + + parent_ = getDefaultInstance().getParent(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The location to list all security settings for.
+     * Format: `projects/<Project ID>/locations/<Location 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; + onChanged(); + return this; + } + + private int pageSize_; + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + @java.lang.Override + public int getPageSize() { + return pageSize_; + } + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @param value The pageSize to set. + * @return This builder for chaining. + */ + public Builder setPageSize(int value) { + + pageSize_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * The maximum number of items to return in a single page. By default 20 and
+     * at most 100.
+     * 
+ * + * int32 page_size = 2; + * + * @return This builder for chaining. + */ + public Builder clearPageSize() { + + pageSize_ = 0; + onChanged(); + return this; + } + + private java.lang.Object pageToken_ = ""; + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + } + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + onChanged(); + return this; + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @return This builder for chaining. + */ + public Builder clearPageToken() { + + pageToken_ = getDefaultInstance().getPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * The next_page_token value returned from a previous list request.
+     * 
+ * + * string page_token = 3; + * + * @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; + 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListSecuritySettingsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListSecuritySettingsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.ListSecuritySettingsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequestOrBuilder.java new file mode 100644 index 000000000..b7005cfd1 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequestOrBuilder.java @@ -0,0 +1,95 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface ListSecuritySettingsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The location to list all security settings for.
+   * Format: `projects/<Project ID>/locations/<Location ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The parent. + */ + java.lang.String getParent(); + /** + * + * + *
+   * Required. The location to list all security settings for.
+   * Format: `projects/<Project ID>/locations/<Location ID>`.
+   * 
+ * + * + * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for parent. + */ + com.google.protobuf.ByteString getParentBytes(); + + /** + * + * + *
+   * The maximum number of items to return in a single page. By default 20 and
+   * at most 100.
+   * 
+ * + * int32 page_size = 2; + * + * @return The pageSize. + */ + int getPageSize(); + + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The pageToken. + */ + java.lang.String getPageToken(); + /** + * + * + *
+   * The next_page_token value returned from a previous list request.
+   * 
+ * + * string page_token = 3; + * + * @return The bytes for pageToken. + */ + com.google.protobuf.ByteString getPageTokenBytes(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponse.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponse.java new file mode 100644 index 000000000..d8236deb2 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponse.java @@ -0,0 +1,1194 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The response message for [SecuritySettings.ListSecuritySettings][].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse} + */ +public final class ListSecuritySettingsResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) + ListSecuritySettingsResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use ListSecuritySettingsResponse.newBuilder() to construct. + private ListSecuritySettingsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private ListSecuritySettingsResponse() { + securitySettings_ = java.util.Collections.emptyList(); + nextPageToken_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new ListSecuritySettingsResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private ListSecuritySettingsResponse( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + securitySettings_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings>(); + mutable_bitField0_ |= 0x00000001; + } + securitySettings_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.parser(), + extensionRegistry)); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + nextPageToken_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + securitySettings_ = java.util.Collections.unmodifiableList(securitySettings_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse.class, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse.Builder.class); + } + + public static final int SECURITY_SETTINGS_FIELD_NUMBER = 1; + private java.util.List securitySettings_; + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + @java.lang.Override + public java.util.List + getSecuritySettingsList() { + return securitySettings_; + } + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + @java.lang.Override + public java.util.List + getSecuritySettingsOrBuilderList() { + return securitySettings_; + } + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + @java.lang.Override + public int getSecuritySettingsCount() { + return securitySettings_.size(); + } + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings(int index) { + return securitySettings_.get(index); + } + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder + getSecuritySettingsOrBuilder(int index) { + return securitySettings_.get(index); + } + + public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; + private volatile java.lang.Object nextPageToken_; + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + @java.lang.Override + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } + } + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < securitySettings_.size(); i++) { + output.writeMessage(1, securitySettings_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < securitySettings_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, securitySettings_.get(i)); + } + if (!getNextPageTokenBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse other = + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) obj; + + if (!getSecuritySettingsList().equals(other.getSecuritySettingsList())) return false; + if (!getNextPageToken().equals(other.getNextPageToken())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSecuritySettingsCount() > 0) { + hash = (37 * hash) + SECURITY_SETTINGS_FIELD_NUMBER; + hash = (53 * hash) + getSecuritySettingsList().hashCode(); + } + hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; + hash = (53 * hash) + getNextPageToken().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse 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 response message for [SecuritySettings.ListSecuritySettings][].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponseOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse.class, + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getSecuritySettingsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (securitySettingsBuilder_ == null) { + securitySettings_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + securitySettingsBuilder_.clear(); + } + nextPageToken_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse build() { + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse result = + new com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse(this); + int from_bitField0_ = bitField0_; + if (securitySettingsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + securitySettings_ = java.util.Collections.unmodifiableList(securitySettings_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.securitySettings_ = securitySettings_; + } else { + result.securitySettings_ = securitySettingsBuilder_.build(); + } + result.nextPageToken_ = nextPageToken_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + .getDefaultInstance()) return this; + if (securitySettingsBuilder_ == null) { + if (!other.securitySettings_.isEmpty()) { + if (securitySettings_.isEmpty()) { + securitySettings_ = other.securitySettings_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSecuritySettingsIsMutable(); + securitySettings_.addAll(other.securitySettings_); + } + onChanged(); + } + } else { + if (!other.securitySettings_.isEmpty()) { + if (securitySettingsBuilder_.isEmpty()) { + securitySettingsBuilder_.dispose(); + securitySettingsBuilder_ = null; + securitySettings_ = other.securitySettings_; + bitField0_ = (bitField0_ & ~0x00000001); + securitySettingsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getSecuritySettingsFieldBuilder() + : null; + } else { + securitySettingsBuilder_.addAllMessages(other.securitySettings_); + } + } + } + if (!other.getNextPageToken().isEmpty()) { + nextPageToken_ = other.nextPageToken_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + securitySettings_ = java.util.Collections.emptyList(); + + private void ensureSecuritySettingsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + securitySettings_ = + new java.util.ArrayList( + securitySettings_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + securitySettingsBuilder_; + + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public java.util.List + getSecuritySettingsList() { + if (securitySettingsBuilder_ == null) { + return java.util.Collections.unmodifiableList(securitySettings_); + } else { + return securitySettingsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public int getSecuritySettingsCount() { + if (securitySettingsBuilder_ == null) { + return securitySettings_.size(); + } else { + return securitySettingsBuilder_.getCount(); + } + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings(int index) { + if (securitySettingsBuilder_ == null) { + return securitySettings_.get(index); + } else { + return securitySettingsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder setSecuritySettings( + int index, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSecuritySettingsIsMutable(); + securitySettings_.set(index, value); + onChanged(); + } else { + securitySettingsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder setSecuritySettings( + int index, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder builderForValue) { + if (securitySettingsBuilder_ == null) { + ensureSecuritySettingsIsMutable(); + securitySettings_.set(index, builderForValue.build()); + onChanged(); + } else { + securitySettingsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder addSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSecuritySettingsIsMutable(); + securitySettings_.add(value); + onChanged(); + } else { + securitySettingsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder addSecuritySettings( + int index, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSecuritySettingsIsMutable(); + securitySettings_.add(index, value); + onChanged(); + } else { + securitySettingsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder addSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder builderForValue) { + if (securitySettingsBuilder_ == null) { + ensureSecuritySettingsIsMutable(); + securitySettings_.add(builderForValue.build()); + onChanged(); + } else { + securitySettingsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder addSecuritySettings( + int index, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder builderForValue) { + if (securitySettingsBuilder_ == null) { + ensureSecuritySettingsIsMutable(); + securitySettings_.add(index, builderForValue.build()); + onChanged(); + } else { + securitySettingsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder addAllSecuritySettings( + java.lang.Iterable + values) { + if (securitySettingsBuilder_ == null) { + ensureSecuritySettingsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, securitySettings_); + onChanged(); + } else { + securitySettingsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder clearSecuritySettings() { + if (securitySettingsBuilder_ == null) { + securitySettings_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + securitySettingsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public Builder removeSecuritySettings(int index) { + if (securitySettingsBuilder_ == null) { + ensureSecuritySettingsIsMutable(); + securitySettings_.remove(index); + onChanged(); + } else { + securitySettingsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder + getSecuritySettingsBuilder(int index) { + return getSecuritySettingsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder + getSecuritySettingsOrBuilder(int index) { + if (securitySettingsBuilder_ == null) { + return securitySettings_.get(index); + } else { + return securitySettingsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + getSecuritySettingsOrBuilderList() { + if (securitySettingsBuilder_ != null) { + return securitySettingsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(securitySettings_); + } + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder + addSecuritySettingsBuilder() { + return getSecuritySettingsFieldBuilder() + .addBuilder(com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance()); + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder + addSecuritySettingsBuilder(int index) { + return getSecuritySettingsFieldBuilder() + .addBuilder( + index, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance()); + } + /** + * + * + *
+     * The list of security settings.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + public java.util.List + getSecuritySettingsBuilderList() { + return getSecuritySettingsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + getSecuritySettingsFieldBuilder() { + if (securitySettingsBuilder_ == null) { + securitySettingsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder>( + securitySettings_, + ((bitField0_ & 0x00000001) != 0), + getParentForChildren(), + isClean()); + securitySettings_ = null; + } + return securitySettingsBuilder_; + } + + private java.lang.Object nextPageToken_ = ""; + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + public java.lang.String getNextPageToken() { + java.lang.Object ref = nextPageToken_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + nextPageToken_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + public com.google.protobuf.ByteString getNextPageTokenBytes() { + java.lang.Object ref = nextPageToken_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + nextPageToken_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageToken(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + nextPageToken_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @return This builder for chaining. + */ + public Builder clearNextPageToken() { + + nextPageToken_ = getDefaultInstance().getNextPageToken(); + onChanged(); + return this; + } + /** + * + * + *
+     * Token to retrieve the next page of results, or empty if there are no more
+     * results in the list.
+     * 
+ * + * string next_page_token = 2; + * + * @param value The bytes for nextPageToken to set. + * @return This builder for chaining. + */ + public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + nextPageToken_ = value; + 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) + private static final com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public ListSecuritySettingsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new ListSecuritySettingsResponse(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.ListSecuritySettingsResponse + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponseOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponseOrBuilder.java new file mode 100644 index 000000000..0c5677073 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponseOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface ListSecuritySettingsResponseOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ListSecuritySettingsResponse) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + java.util.List getSecuritySettingsList(); + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings(int index); + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + int getSecuritySettingsCount(); + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + java.util.List + getSecuritySettingsOrBuilderList(); + /** + * + * + *
+   * The list of security settings.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder getSecuritySettingsOrBuilder( + int index); + + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The nextPageToken. + */ + java.lang.String getNextPageToken(); + /** + * + * + *
+   * Token to retrieve the next page of results, or empty if there are no more
+   * results in the list.
+   * 
+ * + * string next_page_token = 2; + * + * @return The bytes for nextPageToken. + */ + com.google.protobuf.ByteString getNextPageTokenBytes(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Match.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Match.java index 130016604..6b0f8f511 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Match.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Match.java @@ -527,7 +527,8 @@ public com.google.protobuf.ByteString getEventBytes() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -554,7 +555,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -581,7 +583,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1465,7 +1468,8 @@ public Builder setEventBytes(com.google.protobuf.ByteString value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1491,7 +1495,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1521,7 +1526,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1555,7 +1561,8 @@ public Builder setParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1586,7 +1593,8 @@ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1622,7 +1630,8 @@ public Builder mergeParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1654,7 +1663,8 @@ public Builder clearParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1680,7 +1690,8 @@ public com.google.protobuf.Struct.Builder getParametersBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -1708,7 +1719,8 @@ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/MatchOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/MatchOrBuilder.java index 0a9eef550..1eca0a51c 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/MatchOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/MatchOrBuilder.java @@ -103,7 +103,8 @@ public interface MatchOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -127,7 +128,8 @@ public interface MatchOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -151,7 +153,8 @@ public interface MatchOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParameters.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParameters.java index 4bacb3ae3..5d05c3b88 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParameters.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParameters.java @@ -460,7 +460,8 @@ public com.google.protobuf.StructOrBuilder getPayloadOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -490,7 +491,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -520,7 +522,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2147,7 +2150,8 @@ public com.google.protobuf.StructOrBuilder getPayloadOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2176,7 +2180,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2209,7 +2214,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2246,7 +2252,8 @@ public Builder setParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2280,7 +2287,8 @@ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2319,7 +2327,8 @@ public Builder mergeParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2354,7 +2363,8 @@ public Builder clearParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2383,7 +2393,8 @@ public com.google.protobuf.Struct.Builder getParametersBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2414,7 +2425,8 @@ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParametersOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParametersOrBuilder.java index 25f0f3901..b5788c2bf 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParametersOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryParametersOrBuilder.java @@ -211,7 +211,8 @@ com.google.cloud.dialogflow.cx.v3beta1.SessionEntityTypeOrBuilder getSessionEnti * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -238,7 +239,8 @@ com.google.cloud.dialogflow.cx.v3beta1.SessionEntityTypeOrBuilder getSessionEnti * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -265,7 +267,8 @@ com.google.cloud.dialogflow.cx.v3beta1.SessionEntityTypeOrBuilder getSessionEnti * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResult.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResult.java index c600283ff..e53512152 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResult.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResult.java @@ -641,7 +641,8 @@ public com.google.protobuf.ByteString getLanguageCodeBytes() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -668,7 +669,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -695,7 +697,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2672,7 +2675,8 @@ public Builder setLanguageCodeBytes(com.google.protobuf.ByteString value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2698,7 +2702,8 @@ public boolean hasParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2728,7 +2733,8 @@ public com.google.protobuf.Struct getParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2762,7 +2768,8 @@ public Builder setParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2793,7 +2800,8 @@ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2829,7 +2837,8 @@ public Builder mergeParameters(com.google.protobuf.Struct value) { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2861,7 +2870,8 @@ public Builder clearParameters() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2887,7 +2897,8 @@ public com.google.protobuf.Struct.Builder getParametersBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -2915,7 +2926,8 @@ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResultOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResultOrBuilder.java index df71a6807..a9da1e52f 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResultOrBuilder.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/QueryResultOrBuilder.java @@ -174,7 +174,8 @@ public interface QueryResultOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -198,7 +199,8 @@ public interface QueryResultOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values @@ -222,7 +224,8 @@ public interface QueryResultOrBuilder * - MapKey value: parameter name * - MapValue type: * - If parameter's entity type is a composite entity: map - * - Else: string or number, depending on parameter value type + * - Else: depending on parameter value type, could be one of string, + * number, boolean, null, list or map * - MapValue value: * - If parameter's entity type is a composite entity: * map from composite entity property names to property values diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessage.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessage.java index c37b6cd79..c48702eea 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessage.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessage.java @@ -3926,81 +3926,111 @@ public com.google.protobuf.Parser getParserForType() { } } - public interface PlayAudioOrBuilder + public interface MixedAudioOrBuilder extends - // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) com.google.protobuf.MessageOrBuilder { /** * * *
-     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-     * value. It is specific to the client that reads it.
+     * Segments this audio response is composed of.
      * 
* - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The audioUri. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - java.lang.String getAudioUri(); + java.util.List + getSegmentsList(); /** * * *
-     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-     * value. It is specific to the client that reads it.
+     * Segments this audio response is composed of.
      * 
* - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment getSegments( + int index); + /** * - * @return The bytes for audioUri. + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - com.google.protobuf.ByteString getAudioUriBytes(); - + int getSegmentsCount(); /** * * *
-     * Output only. Whether the playback of this message can be interrupted by the end
-     * user's speech and the client can then starts the next Dialogflow
-     * request.
+     * Segments this audio response is composed of.
      * 
* - * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; * + */ + java.util.List< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> + getSegmentsOrBuilderList(); + /** * - * @return The allowPlaybackInterruption. + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - boolean getAllowPlaybackInterruption(); + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder + getSegmentsOrBuilder(int index); } /** * * *
-   * Specifies an audio clip to be played by the client as part of the response.
+   * Represents an audio message that is composed of both segments
+   * synthesized from the Dialogflow agent prompts and ones hosted externally
+   * at the specified URIs.
+   * The external URIs are specified via
+   * [play_audio][google.cloud.dialogflow.cx.v3beta1.ResponseMessage.play_audio].
+   * This message is generated by Dialogflow only and not supposed to be
+   * defined by the user.
    * 
* - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio} + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio} */ - public static final class PlayAudio extends com.google.protobuf.GeneratedMessageV3 + public static final class MixedAudio extends com.google.protobuf.GeneratedMessageV3 implements - // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) - PlayAudioOrBuilder { + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) + MixedAudioOrBuilder { private static final long serialVersionUID = 0L; - // Use PlayAudio.newBuilder() to construct. - private PlayAudio(com.google.protobuf.GeneratedMessageV3.Builder builder) { + // Use MixedAudio.newBuilder() to construct. + private MixedAudio(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private PlayAudio() { - audioUri_ = ""; + private MixedAudio() { + segments_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PlayAudio(); + return new MixedAudio(); } @java.lang.Override @@ -4008,7 +4038,7 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PlayAudio( + private MixedAudio( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { @@ -4016,6 +4046,7 @@ private PlayAudio( if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } + int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { @@ -4028,14 +4059,18 @@ private PlayAudio( break; case 10: { - java.lang.String s = input.readStringRequireUtf8(); - - audioUri_ = s; - break; - } - case 16: - { - allowPlaybackInterruption_ = input.readBool(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + segments_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + .Segment>(); + mutable_bitField0_ |= 0x00000001; + } + segments_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + .parser(), + extensionRegistry)); break; } default: @@ -4052,6 +4087,9 @@ private PlayAudio( } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + segments_ = java.util.Collections.unmodifiableList(segments_); + } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } @@ -4059,978 +4097,1391 @@ private PlayAudio( public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.Builder.class); + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Builder.class); } - public static final int AUDIO_URI_FIELD_NUMBER = 1; - private volatile java.lang.Object audioUri_; - /** - * - * - *
-     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-     * value. It is specific to the client that reads it.
-     * 
- * - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The audioUri. - */ - @java.lang.Override - public java.lang.String getAudioUri() { - java.lang.Object ref = audioUri_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - audioUri_ = s; - return s; - } + public interface SegmentOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+       * Raw audio synthesized from the Dialogflow agent's response using
+       * the output config specified in the request.
+       * 
+ * + * bytes audio = 1; + * + * @return The audio. + */ + com.google.protobuf.ByteString getAudio(); + + /** + * + * + *
+       * Client-specific URI that points to an audio clip accessible to the
+       * client. Dialogflow does not impose any validation on it.
+       * 
+ * + * string uri = 2; + * + * @return The uri. + */ + java.lang.String getUri(); + /** + * + * + *
+       * Client-specific URI that points to an audio clip accessible to the
+       * client. Dialogflow does not impose any validation on it.
+       * 
+ * + * string uri = 2; + * + * @return The bytes for uri. + */ + com.google.protobuf.ByteString getUriBytes(); + + /** + * + * + *
+       * Output only. Whether the playback of this segment can be interrupted by the end
+       * user's speech and the client should then start the next Dialogflow
+       * request.
+       * 
+ * + * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The allowPlaybackInterruption. + */ + boolean getAllowPlaybackInterruption(); + + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.ContentCase + getContentCase(); } /** * * *
-     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-     * value. It is specific to the client that reads it.
+     * Represents one segment of audio.
      * 
* - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for audioUri. + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment} */ - @java.lang.Override - public com.google.protobuf.ByteString getAudioUriBytes() { - java.lang.Object ref = audioUri_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - audioUri_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; + public static final class Segment extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + SegmentOrBuilder { + private static final long serialVersionUID = 0L; + // Use Segment.newBuilder() to construct. + private Segment(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); } - } - public static final int ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER = 2; - private boolean allowPlaybackInterruption_; - /** - * - * - *
-     * Output only. Whether the playback of this message can be interrupted by the end
-     * user's speech and the client can then starts the next Dialogflow
-     * request.
-     * 
- * - * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The allowPlaybackInterruption. - */ - @java.lang.Override - public boolean getAllowPlaybackInterruption() { - return allowPlaybackInterruption_; - } - - 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 (!getAudioUriBytes().isEmpty()) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, audioUri_); - } - if (allowPlaybackInterruption_ != false) { - output.writeBool(2, allowPlaybackInterruption_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; + private Segment() {} - size = 0; - if (!getAudioUriBytes().isEmpty()) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, audioUri_); - } - if (allowPlaybackInterruption_ != false) { - size += - com.google.protobuf.CodedOutputStream.computeBoolSize(2, allowPlaybackInterruption_); + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Segment(); } - size += unknownFields.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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio)) { - return super.equals(obj); + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; } - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio other = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) obj; - - if (!getAudioUri().equals(other.getAudioUri())) return false; - if (getAllowPlaybackInterruption() != other.getAllowPlaybackInterruption()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; + private Segment( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + contentCase_ = 1; + content_ = input.readBytes(); + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + contentCase_ = 2; + content_ = s; + break; + } + case 24: + { + allowPlaybackInterruption_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + AUDIO_URI_FIELD_NUMBER; - hash = (53 * hash) + getAudioUri().hashCode(); - hash = (37 * hash) + ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowPlaybackInterruption()); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - 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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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; - } - /** - * - * - *
-     * Specifies an audio clip to be played by the client as part of the response.
-     * 
- * - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudioOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.Builder.class); + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + .class); } - // Construct using - // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } - - @java.lang.Override - public Builder clear() { - super.clear(); - audioUri_ = ""; - - allowPlaybackInterruption_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; - } + private int contentCase_ = 0; + private java.lang.Object content_; - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - getDefaultInstanceForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - .getDefaultInstance(); - } + public enum ContentCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AUDIO(1), + URI(2), + CONTENT_NOT_SET(0); + private final int value; - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio build() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); + private ContentCase(int value) { + this.value = value; } - return result; - } - - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio buildPartial() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio result = - new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio(this); - result.audioUri_ = audioUri_; - result.allowPlaybackInterruption_ = allowPlaybackInterruption_; - onBuilt(); - return result; - } - - @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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) { - return mergeFrom( - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) other); - } else { - super.mergeFrom(other); - return this; + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ContentCase valueOf(int value) { + return forNumber(value); } - } - public Builder mergeFrom( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio other) { - if (other - == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - .getDefaultInstance()) return this; - if (!other.getAudioUri().isEmpty()) { - audioUri_ = other.audioUri_; - onChanged(); + public static ContentCase forNumber(int value) { + switch (value) { + case 1: + return AUDIO; + case 2: + return URI; + case 0: + return CONTENT_NOT_SET; + default: + return null; + } } - if (other.getAllowPlaybackInterruption() != false) { - setAllowPlaybackInterruption(other.getAllowPlaybackInterruption()); + + public int getNumber() { + return this.value; } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } + }; - @java.lang.Override - public final boolean isInitialized() { - return true; + public ContentCase getContentCase() { + return ContentCase.forNumber(contentCase_); } + public static final int AUDIO_FIELD_NUMBER = 1; + /** + * + * + *
+       * Raw audio synthesized from the Dialogflow agent's response using
+       * the output config specified in the request.
+       * 
+ * + * bytes audio = 1; + * + * @return The audio. + */ @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } + public com.google.protobuf.ByteString getAudio() { + if (contentCase_ == 1) { + return (com.google.protobuf.ByteString) content_; } - return this; + return com.google.protobuf.ByteString.EMPTY; } - private java.lang.Object audioUri_ = ""; + public static final int URI_FIELD_NUMBER = 2; /** * * *
-       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-       * value. It is specific to the client that reads it.
+       * Client-specific URI that points to an audio clip accessible to the
+       * client. Dialogflow does not impose any validation on it.
        * 
* - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * string uri = 2; * - * @return The audioUri. + * @return The uri. */ - public java.lang.String getAudioUri() { - java.lang.Object ref = audioUri_; - if (!(ref instanceof java.lang.String)) { + public java.lang.String getUri() { + java.lang.Object ref = ""; + if (contentCase_ == 2) { + ref = content_; + } + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); - audioUri_ = s; + if (contentCase_ == 2) { + content_ = s; + } return s; - } else { - return (java.lang.String) ref; } } /** * * *
-       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-       * value. It is specific to the client that reads it.
+       * Client-specific URI that points to an audio clip accessible to the
+       * client. Dialogflow does not impose any validation on it.
        * 
* - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * string uri = 2; * - * @return The bytes for audioUri. + * @return The bytes for uri. */ - public com.google.protobuf.ByteString getAudioUriBytes() { - java.lang.Object ref = audioUri_; - if (ref instanceof String) { + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = ""; + if (contentCase_ == 2) { + ref = content_; + } + if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - audioUri_ = b; + if (contentCase_ == 2) { + content_ = b; + } return b; } else { return (com.google.protobuf.ByteString) ref; } } + + public static final int ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER = 3; + private boolean allowPlaybackInterruption_; /** * * *
-       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-       * value. It is specific to the client that reads it.
+       * Output only. Whether the playback of this segment can be interrupted by the end
+       * user's speech and the client should then start the next Dialogflow
+       * request.
        * 
* - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * * - * @param value The audioUri to set. - * @return This builder for chaining. + * @return The allowPlaybackInterruption. */ - public Builder setAudioUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } + @java.lang.Override + public boolean getAllowPlaybackInterruption() { + return allowPlaybackInterruption_; + } - audioUri_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-       * value. It is specific to the client that reads it.
-       * 
- * - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearAudioUri() { + private byte memoizedIsInitialized = -1; - audioUri_ = getDefaultInstance().getAudioUri(); - onChanged(); - return this; - } - /** - * - * - *
-       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
-       * value. It is specific to the client that reads it.
-       * 
- * - * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for audioUri to set. - * @return This builder for chaining. - */ - public Builder setAudioUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; - audioUri_ = value; - onChanged(); - return this; + memoizedIsInitialized = 1; + return true; } - private boolean allowPlaybackInterruption_; - /** - * - * - *
-       * Output only. Whether the playback of this message can be interrupted by the end
-       * user's speech and the client can then starts the next Dialogflow
-       * request.
-       * 
- * - * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The allowPlaybackInterruption. - */ @java.lang.Override - public boolean getAllowPlaybackInterruption() { - return allowPlaybackInterruption_; + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (contentCase_ == 1) { + output.writeBytes(1, (com.google.protobuf.ByteString) content_); + } + if (contentCase_ == 2) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, content_); + } + if (allowPlaybackInterruption_ != false) { + output.writeBool(3, allowPlaybackInterruption_); + } + unknownFields.writeTo(output); } - /** - * - * - *
-       * Output only. Whether the playback of this message can be interrupted by the end
-       * user's speech and the client can then starts the next Dialogflow
-       * request.
-       * 
- * - * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The allowPlaybackInterruption to set. - * @return This builder for chaining. - */ - public Builder setAllowPlaybackInterruption(boolean value) { - allowPlaybackInterruption_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Output only. Whether the playback of this message can be interrupted by the end
-       * user's speech and the client can then starts the next Dialogflow
-       * request.
-       * 
- * - * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return This builder for chaining. - */ - public Builder clearAllowPlaybackInterruption() { + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; - allowPlaybackInterruption_ = false; - onChanged(); - return this; + size = 0; + if (contentCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeBytesSize( + 1, (com.google.protobuf.ByteString) content_); + } + if (contentCase_ == 2) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, content_); + } + if (allowPlaybackInterruption_ != false) { + size += + com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowPlaybackInterruption_); + } + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; } @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj + instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment other = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) obj; + + if (getAllowPlaybackInterruption() != other.getAllowPlaybackInterruption()) return false; + if (!getContentCase().equals(other.getContentCase())) return false; + switch (contentCase_) { + case 1: + if (!getAudio().equals(other.getAudio())) return false; + break; + case 2: + if (!getUri().equals(other.getUri())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; } @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER; + hash = + (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowPlaybackInterruption()); + switch (contentCase_) { + case 1: + hash = (37 * hash) + AUDIO_FIELD_NUMBER; + hash = (53 * hash) + getAudio().hashCode(); + break; + case 2: + hash = (37 * hash) + URI_FIELD_NUMBER; + hash = (53 * hash) + getUri().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; } - // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) - } - - // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) - private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - DEFAULT_INSTANCE; + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom(java.nio.ByteBuffer data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } - static { - DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio(); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + 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.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - getDefaultInstance() { - return DEFAULT_INSTANCE; - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom(com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PlayAudio parsePartialFrom( - com.google.protobuf.CodedInputStream input, + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom( + com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PlayAudio(input, extensionRegistry); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } + return PARSER.parseFrom(data, extensionRegistry); + } - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } - public interface EndInteractionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) - com.google.protobuf.MessageOrBuilder {} - /** - * - * - *
-   * Indicates that interaction with the Dialogflow agent has ended.
-   * This message is generated by Dialogflow only and not supposed to be
-   * defined by the user.
-   * 
- * - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction} - */ - public static final class EndInteraction extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) - EndInteractionOrBuilder { - private static final long serialVersionUID = 0L; - // Use EndInteraction.newBuilder() to construct. - private EndInteraction(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private EndInteraction() {} + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new EndInteraction(); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } - private EndInteraction( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + 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 - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.Builder.class); - } + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } - private byte memoizedIsInitialized = -1; + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; + public static Builder newBuilder( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } - memoizedIsInitialized = 1; - return true; - } + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - unknownFields.writeTo(output); - } + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+       * Represents one segment of audio.
+       * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; + } - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + .class); + } - size = 0; - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; - } + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction)) { - return super.equals(obj); - } - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction other = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) obj; + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } - if (!unknownFields.equals(other.unknownFields)) return false; - return true; - } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } + @java.lang.Override + public Builder clear() { + super.clear(); + allowPlaybackInterruption_ = false; - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + contentCase_ = 0; + content_ = null; + return this; + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + .getDefaultInstance(); + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment build() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction - parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment result = + new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment(this); + if (contentCase_ == 1) { + result.content_ = content_; + } + if (contentCase_ == 2) { + result.content_ = content_; + } + result.allowPlaybackInterruption_ = allowPlaybackInterruption_; + result.contentCase_ = contentCase_; + onBuilt(); + return result; + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } + @java.lang.Override + public Builder clone() { + return super.clone(); + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction 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 setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); + } - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); + } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } - public static Builder newBuilder( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } + @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 toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Indicates that interaction with the Dialogflow agent has ended.
-     * This message is generated by Dialogflow only and not supposed to be
-     * defined by the user.
-     * 
- * - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteractionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; - } + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other + instanceof + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) other); + } else { + super.mergeFrom(other); + return this; + } + } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.Builder - .class); - } + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + .getDefaultInstance()) return this; + if (other.getAllowPlaybackInterruption() != false) { + setAllowPlaybackInterruption(other.getAllowPlaybackInterruption()); + } + switch (other.getContentCase()) { + case AUDIO: + { + setAudio(other.getAudio()); + break; + } + case URI: + { + contentCase_ = 2; + content_ = other.content_; + onChanged(); + break; + } + case CONTENT_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); + return this; + } - // Construct using - // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + @java.lang.Override + public final boolean isInitialized() { + return true; + } - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } + @java.lang.Override + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment parsedMessage = + null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } + private int contentCase_ = 0; + private java.lang.Object content_; - @java.lang.Override - public Builder clear() { - super.clear(); - return this; - } + public ContentCase getContentCase() { + return ContentCase.forNumber(contentCase_); + } - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; - } + public Builder clearContent() { + contentCase_ = 0; + content_ = null; + onChanged(); + return this; + } + + /** + * + * + *
+         * Raw audio synthesized from the Dialogflow agent's response using
+         * the output config specified in the request.
+         * 
+ * + * bytes audio = 1; + * + * @return The audio. + */ + public com.google.protobuf.ByteString getAudio() { + if (contentCase_ == 1) { + return (com.google.protobuf.ByteString) content_; + } + return com.google.protobuf.ByteString.EMPTY; + } + /** + * + * + *
+         * Raw audio synthesized from the Dialogflow agent's response using
+         * the output config specified in the request.
+         * 
+ * + * bytes audio = 1; + * + * @param value The audio to set. + * @return This builder for chaining. + */ + public Builder setAudio(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + contentCase_ = 1; + content_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Raw audio synthesized from the Dialogflow agent's response using
+         * the output config specified in the request.
+         * 
+ * + * bytes audio = 1; + * + * @return This builder for chaining. + */ + public Builder clearAudio() { + if (contentCase_ == 1) { + contentCase_ = 0; + content_ = null; + onChanged(); + } + return this; + } + + /** + * + * + *
+         * Client-specific URI that points to an audio clip accessible to the
+         * client. Dialogflow does not impose any validation on it.
+         * 
+ * + * string uri = 2; + * + * @return The uri. + */ + @java.lang.Override + public java.lang.String getUri() { + java.lang.Object ref = ""; + if (contentCase_ == 2) { + ref = content_; + } + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + if (contentCase_ == 2) { + content_ = s; + } + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+         * Client-specific URI that points to an audio clip accessible to the
+         * client. Dialogflow does not impose any validation on it.
+         * 
+ * + * string uri = 2; + * + * @return The bytes for uri. + */ + @java.lang.Override + public com.google.protobuf.ByteString getUriBytes() { + java.lang.Object ref = ""; + if (contentCase_ == 2) { + ref = content_; + } + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + if (contentCase_ == 2) { + content_ = b; + } + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+         * Client-specific URI that points to an audio clip accessible to the
+         * client. Dialogflow does not impose any validation on it.
+         * 
+ * + * string uri = 2; + * + * @param value The uri to set. + * @return This builder for chaining. + */ + public Builder setUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + contentCase_ = 2; + content_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Client-specific URI that points to an audio clip accessible to the
+         * client. Dialogflow does not impose any validation on it.
+         * 
+ * + * string uri = 2; + * + * @return This builder for chaining. + */ + public Builder clearUri() { + if (contentCase_ == 2) { + contentCase_ = 0; + content_ = null; + onChanged(); + } + return this; + } + /** + * + * + *
+         * Client-specific URI that points to an audio clip accessible to the
+         * client. Dialogflow does not impose any validation on it.
+         * 
+ * + * string uri = 2; + * + * @param value The bytes for uri to set. + * @return This builder for chaining. + */ + public Builder setUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + contentCase_ = 2; + content_ = value; + onChanged(); + return this; + } + + private boolean allowPlaybackInterruption_; + /** + * + * + *
+         * Output only. Whether the playback of this segment can be interrupted by the end
+         * user's speech and the client should then start the next Dialogflow
+         * request.
+         * 
+ * + * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return The allowPlaybackInterruption. + */ + @java.lang.Override + public boolean getAllowPlaybackInterruption() { + return allowPlaybackInterruption_; + } + /** + * + * + *
+         * Output only. Whether the playback of this segment can be interrupted by the end
+         * user's speech and the client should then start the next Dialogflow
+         * request.
+         * 
+ * + * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @param value The allowPlaybackInterruption to set. + * @return This builder for chaining. + */ + public Builder setAllowPlaybackInterruption(boolean value) { + + allowPlaybackInterruption_ = value; + onChanged(); + return this; + } + /** + * + * + *
+         * Output only. Whether the playback of this segment can be interrupted by the end
+         * user's speech and the client should then start the next Dialogflow
+         * request.
+         * 
+ * + * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * + * @return This builder for chaining. + */ + public Builder clearAllowPlaybackInterruption() { + + allowPlaybackInterruption_ = 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Segment parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Segment(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int SEGMENTS_FIELD_NUMBER = 1; + private java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> + segments_; + /** + * + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + @java.lang.Override + public java.util.List + getSegmentsList() { + return segments_; + } + /** + * + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + @java.lang.Override + public java.util.List< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> + getSegmentsOrBuilderList() { + return segments_; + } + /** + * + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + @java.lang.Override + public int getSegmentsCount() { + return segments_.size(); + } + /** + * + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment getSegments( + int index) { + return segments_.get(index); + } + /** + * + * + *
+     * Segments this audio response is composed of.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder + getSegmentsOrBuilder(int index) { + return segments_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < segments_.size(); i++) { + output.writeMessage(1, segments_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < segments_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, segments_.get(i)); + } + size += unknownFields.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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio other = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) obj; + + if (!getSegmentsList().equals(other.getSegmentsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getSegmentsCount() > 0) { + hash = (37 * hash) + SEGMENTS_FIELD_NUMBER; + hash = (53 * hash) + getSegmentsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio 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; + } + /** + * + * + *
+     * Represents an audio message that is composed of both segments
+     * synthesized from the Dialogflow agent prompts and ones hosted externally
+     * at the specified URIs.
+     * The external URIs are specified via
+     * [play_audio][google.cloud.dialogflow.cx.v3beta1.ResponseMessage.play_audio].
+     * This message is generated by Dialogflow only and not supposed to be
+     * defined by the user.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudioOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getSegmentsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (segmentsBuilder_ == null) { + segments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + segmentsBuilder_.clear(); + } + return this; + } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio getDefaultInstanceForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio .getDefaultInstance(); } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction build() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction result = - buildPartial(); + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio build() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } @@ -5038,9 +5489,19 @@ public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction bui } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction buildPartial() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction result = - new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction(this); + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio result = + new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio(this); + int from_bitField0_ = bitField0_; + if (segmentsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + segments_ = java.util.Collections.unmodifiableList(segments_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.segments_ = segments_; + } else { + result.segments_ = segmentsBuilder_.build(); + } onBuilt(); return result; } @@ -5061,1439 +5522,1258 @@ 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) { - return mergeFrom( - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction other) { - if (other - == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction - .getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); - 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 { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) - } - - // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) - private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = - new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction(); - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction - getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public EndInteraction parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new EndInteraction(input, extensionRegistry); - } - }; - - 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface MixedAudioOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Segments this audio response is composed of.
-     * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - java.util.List - getSegmentsList(); - /** - * - * - *
-     * Segments this audio response is composed of.
-     * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment getSegments( - int index); - /** - * - * - *
-     * Segments this audio response is composed of.
-     * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - int getSegmentsCount(); - /** - * - * - *
-     * Segments this audio response is composed of.
-     * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - java.util.List< - ? extends - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> - getSegmentsOrBuilderList(); - /** - * - * - *
-     * Segments this audio response is composed of.
-     * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder - getSegmentsOrBuilder(int index); - } - /** - * - * - *
-   * Represents an audio message that is composed of both segments
-   * synthesized from the Dialogflow agent prompts and ones hosted externally
-   * at the specified URIs.
-   * The external URIs are specified via
-   * [play_audio][google.cloud.dialogflow.cx.v3beta1.ResponseMessage.play_audio].
-   * This message is generated by Dialogflow only and not supposed to be
-   * defined by the user.
-   * 
- * - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio} - */ - public static final class MixedAudio extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) - MixedAudioOrBuilder { - private static final long serialVersionUID = 0L; - // Use MixedAudio.newBuilder() to construct. - private MixedAudio(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private MixedAudio() { - segments_ = java.util.Collections.emptyList(); - } + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new MixedAudio(); - } + @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 final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); + } - private MixedAudio( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) other); + } else { + super.mergeFrom(other); + return this; + } } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - segments_ = - new java.util.ArrayList< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio - .Segment>(); - mutable_bitField0_ |= 0x00000001; - } - segments_.add( - input.readMessage( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - .parser(), - extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + .getDefaultInstance()) return this; + if (segmentsBuilder_ == null) { + if (!other.segments_.isEmpty()) { + if (segments_.isEmpty()) { + segments_ = other.segments_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureSegmentsIsMutable(); + segments_.addAll(other.segments_); + } + onChanged(); + } + } else { + if (!other.segments_.isEmpty()) { + if (segmentsBuilder_.isEmpty()) { + segmentsBuilder_.dispose(); + segmentsBuilder_ = null; + segments_ = other.segments_; + bitField0_ = (bitField0_ & ~0x00000001); + segmentsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getSegmentsFieldBuilder() + : null; + } else { + segmentsBuilder_.addAllMessages(other.segments_); + } } } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - segments_ = java.util.Collections.unmodifiableList(segments_); + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); + return this; } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; - } + private int bitField0_; - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Builder.class); - } + private java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> + segments_ = java.util.Collections.emptyList(); - public interface SegmentOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) - com.google.protobuf.MessageOrBuilder { + private void ensureSegmentsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + segments_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment>( + segments_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> + segmentsBuilder_; /** * * *
-       * Raw audio synthesized from the Dialogflow agent's response using
-       * the output config specified in the request.
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> + getSegmentsList() { + if (segmentsBuilder_ == null) { + return java.util.Collections.unmodifiableList(segments_); + } else { + return segmentsBuilder_.getMessageList(); + } + } + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public int getSegmentsCount() { + if (segmentsBuilder_ == null) { + return segments_.size(); + } else { + return segmentsBuilder_.getCount(); + } + } + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment getSegments( + int index) { + if (segmentsBuilder_ == null) { + return segments_.get(index); + } else { + return segmentsBuilder_.getMessage(index); + } + } + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public Builder setSegments( + int index, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment value) { + if (segmentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSegmentsIsMutable(); + segments_.set(index, value); + onChanged(); + } else { + segmentsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+       * Segments this audio response is composed of.
        * 
* - * bytes audio = 1; - * - * @return The audio. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - com.google.protobuf.ByteString getAudio(); - + public Builder setSegments( + int index, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + builderForValue) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.set(index, builderForValue.build()); + onChanged(); + } else { + segmentsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } /** * * *
-       * Client-specific URI that points to an audio clip accessible to the
-       * client. Dialogflow does not impose any validation on it.
+       * Segments this audio response is composed of.
        * 
* - * string uri = 2; - * - * @return The uri. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - java.lang.String getUri(); + public Builder addSegments( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment value) { + if (segmentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSegmentsIsMutable(); + segments_.add(value); + onChanged(); + } else { + segmentsBuilder_.addMessage(value); + } + return this; + } /** * * *
-       * Client-specific URI that points to an audio clip accessible to the
-       * client. Dialogflow does not impose any validation on it.
+       * Segments this audio response is composed of.
        * 
* - * string uri = 2; - * - * @return The bytes for uri. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - com.google.protobuf.ByteString getUriBytes(); - + public Builder addSegments( + int index, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment value) { + if (segmentsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureSegmentsIsMutable(); + segments_.add(index, value); + onChanged(); + } else { + segmentsBuilder_.addMessage(index, value); + } + return this; + } /** * * *
-       * Output only. Whether the playback of this segment can be interrupted by the end
-       * user's speech and the client should then start the next Dialogflow
-       * request.
+       * Segments this audio response is composed of.
        * 
* - * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; * - * - * @return The allowPlaybackInterruption. */ - boolean getAllowPlaybackInterruption(); - - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.ContentCase - getContentCase(); - } - /** - * - * - *
-     * Represents one segment of audio.
-     * 
- * - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment} - */ - public static final class Segment extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) - SegmentOrBuilder { - private static final long serialVersionUID = 0L; - // Use Segment.newBuilder() to construct. - private Segment(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Segment() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Segment(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - private Segment( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - contentCase_ = 1; - content_ = input.readBytes(); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - contentCase_ = 2; - content_ = s; - break; - } - case 24: - { - allowPlaybackInterruption_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); + public Builder addSegments( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + builderForValue) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.add(builderForValue.build()); + onChanged(); + } else { + segmentsBuilder_.addMessage(builderForValue.build()); } + return this; } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - .class); - } - - private int contentCase_ = 0; - private java.lang.Object content_; - - public enum ContentCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - AUDIO(1), - URI(2), - CONTENT_NOT_SET(0); - private final int value; - - private ContentCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static ContentCase valueOf(int value) { - return forNumber(value); - } - - public static ContentCase forNumber(int value) { - switch (value) { - case 1: - return AUDIO; - case 2: - return URI; - case 0: - return CONTENT_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public Builder addSegments( + int index, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + builderForValue) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.add(index, builderForValue.build()); + onChanged(); + } else { + segmentsBuilder_.addMessage(index, builderForValue.build()); } - }; - - public ContentCase getContentCase() { - return ContentCase.forNumber(contentCase_); + return this; } - - public static final int AUDIO_FIELD_NUMBER = 1; /** * * *
-       * Raw audio synthesized from the Dialogflow agent's response using
-       * the output config specified in the request.
+       * Segments this audio response is composed of.
        * 
* - * bytes audio = 1; - * - * @return The audio. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - @java.lang.Override - public com.google.protobuf.ByteString getAudio() { - if (contentCase_ == 1) { - return (com.google.protobuf.ByteString) content_; + public Builder addAllSegments( + java.lang.Iterable< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> + values) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, segments_); + onChanged(); + } else { + segmentsBuilder_.addAllMessages(values); } - return com.google.protobuf.ByteString.EMPTY; + return this; } - - public static final int URI_FIELD_NUMBER = 2; /** * * *
-       * Client-specific URI that points to an audio clip accessible to the
-       * client. Dialogflow does not impose any validation on it.
+       * Segments this audio response is composed of.
        * 
* - * string uri = 2; - * - * @return The uri. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - public java.lang.String getUri() { - java.lang.Object ref = ""; - if (contentCase_ == 2) { - ref = content_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; + public Builder clearSegments() { + if (segmentsBuilder_ == null) { + segments_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (contentCase_ == 2) { - content_ = s; - } - return s; + segmentsBuilder_.clear(); } + return this; } /** * * *
-       * Client-specific URI that points to an audio clip accessible to the
-       * client. Dialogflow does not impose any validation on it.
+       * Segments this audio response is composed of.
        * 
* - * string uri = 2; - * - * @return The bytes for uri. + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * */ - public com.google.protobuf.ByteString getUriBytes() { - java.lang.Object ref = ""; - if (contentCase_ == 2) { - ref = content_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (contentCase_ == 2) { - content_ = b; - } - return b; + public Builder removeSegments(int index) { + if (segmentsBuilder_ == null) { + ensureSegmentsIsMutable(); + segments_.remove(index); + onChanged(); } else { - return (com.google.protobuf.ByteString) ref; + segmentsBuilder_.remove(index); } + return this; } - - public static final int ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER = 3; - private boolean allowPlaybackInterruption_; /** * * *
-       * Output only. Whether the playback of this segment can be interrupted by the end
-       * user's speech and the client should then start the next Dialogflow
-       * request.
+       * Segments this audio response is composed of.
        * 
* - * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; * - * - * @return The allowPlaybackInterruption. */ - @java.lang.Override - public boolean getAllowPlaybackInterruption() { - return allowPlaybackInterruption_; - } - - 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 (contentCase_ == 1) { - output.writeBytes(1, (com.google.protobuf.ByteString) content_); - } - if (contentCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, content_); - } - if (allowPlaybackInterruption_ != false) { - output.writeBool(3, allowPlaybackInterruption_); - } - unknownFields.writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (contentCase_ == 1) { - size += - com.google.protobuf.CodedOutputStream.computeBytesSize( - 1, (com.google.protobuf.ByteString) content_); - } - if (contentCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, content_); - } - if (allowPlaybackInterruption_ != false) { - size += - com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowPlaybackInterruption_); - } - size += unknownFields.getSerializedSize(); - memoizedSize = size; - return size; + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + getSegmentsBuilder(int index) { + return getSegmentsFieldBuilder().getBuilder(index); } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj - instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment)) { - return super.equals(obj); - } - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment other = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) obj; - - if (getAllowPlaybackInterruption() != other.getAllowPlaybackInterruption()) return false; - if (!getContentCase().equals(other.getContentCase())) return false; - switch (contentCase_) { - case 1: - if (!getAudio().equals(other.getAudio())) return false; - break; - case 2: - if (!getUri().equals(other.getUri())) return false; - break; - case 0: - default: + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder + getSegmentsOrBuilder(int index) { + if (segmentsBuilder_ == null) { + return segments_.get(index); + } else { + return segmentsBuilder_.getMessageOrBuilder(index); } - if (!unknownFields.equals(other.unknownFields)) 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) + ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER; - hash = - (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowPlaybackInterruption()); - switch (contentCase_) { - case 1: - hash = (37 * hash) + AUDIO_FIELD_NUMBER; - hash = (53 * hash) + getAudio().hashCode(); - break; - case 2: - hash = (37 * hash) + URI_FIELD_NUMBER; - hash = (53 * hash) + getUri().hashCode(); - break; - case 0: - default: + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public java.util.List< + ? extends + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + .SegmentOrBuilder> + getSegmentsOrBuilderList() { + if (segmentsBuilder_ != null) { + return segmentsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(segments_); } - hash = (29 * hash) + unknownFields.hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + addSegmentsBuilder() { + return getSegmentsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + .getDefaultInstance()); } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder + addSegmentsBuilder(int index) { + return getSegmentsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment + .getDefaultInstance()); } - - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + /** + * + * + *
+       * Segments this audio response is composed of.
+       * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * + */ + public java.util.List< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder> + getSegmentsBuilderList() { + return getSegmentsFieldBuilder().getBuilderList(); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> + getSegmentsFieldBuilder() { + if (segmentsBuilder_ == null) { + segmentsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + .SegmentOrBuilder>( + segments_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + segments_ = null; + } + return segmentsBuilder_; } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + @java.lang.Override + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } + // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) + private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + DEFAULT_INSTANCE; - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio(); + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + getDefaultInstance() { + return DEFAULT_INSTANCE; + } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - parseFrom( + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public MixedAudio parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } + throws com.google.protobuf.InvalidProtocolBufferException { + return new MixedAudio(input, extensionRegistry); + } + }; - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } + public static com.google.protobuf.Parser parser() { + return PARSER; + } - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } + @java.lang.Override + public com.google.protobuf.Parser getParserForType() { + return PARSER; + } - public static Builder newBuilder( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } + public interface EndInteractionOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) + com.google.protobuf.MessageOrBuilder {} + /** + * + * + *
+   * Indicates that interaction with the Dialogflow agent has ended.
+   * This message is generated by Dialogflow only and not supposed to be
+   * defined by the user.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction} + */ + public static final class EndInteraction extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) + EndInteractionOrBuilder { + private static final long serialVersionUID = 0L; + // Use EndInteraction.newBuilder() to construct. + private EndInteraction(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; + private EndInteraction() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new EndInteraction(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private EndInteraction( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); } - /** - * - * - *
-       * Represents one segment of audio.
-       * 
- * - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - .class); - } + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; + } - // Construct using - // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.Builder.class); + } - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } + private byte memoizedIsInitialized = -1; - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} - } + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; - @java.lang.Override - public Builder clear() { - super.clear(); - allowPlaybackInterruption_ = false; + memoizedIsInitialized = 1; + return true; + } - contentCase_ = 0; - content_ = null; - return this; - } + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + unknownFields.writeTo(output); + } - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; - } + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - getDefaultInstanceForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - .getDefaultInstance(); - } + size = 0; + size += unknownFields.getSerializedSize(); + memoizedSize = size; + return size; + } - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment build() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment result = - buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } + @java.lang.Override + public boolean equals(final java.lang.Object obj) { + if (obj == this) { + return true; + } + if (!(obj instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction other = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) obj; - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - buildPartial() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment result = - new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment(this); - if (contentCase_ == 1) { - result.content_ = content_; - } - if (contentCase_ == 2) { - result.content_ = content_; - } - result.allowPlaybackInterruption_ = allowPlaybackInterruption_; - result.contentCase_ = contentCase_; - onBuilt(); - return result; - } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } - @java.lang.Override - public Builder clone() { - return super.clone(); - } + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other - instanceof - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) { - return mergeFrom( - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) other); - } else { - super.mergeFrom(other); - return this; - } - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } - public Builder mergeFrom( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment other) { - if (other - == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - .getDefaultInstance()) return this; - if (other.getAllowPlaybackInterruption() != false) { - setAllowPlaybackInterruption(other.getAllowPlaybackInterruption()); - } - switch (other.getContentCase()) { - case AUDIO: - { - setAudio(other.getAudio()); - break; - } - case URI: - { - contentCase_ = 2; - content_ = other.content_; - onChanged(); - break; - } - case CONTENT_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.unknownFields); - onChanged(); - return this; - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } - @java.lang.Override - public final boolean isInitialized() { - return true; - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment parsedMessage = - null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); + } - private int contentCase_ = 0; - private java.lang.Object content_; + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } - public ContentCase getContentCase() { - return ContentCase.forNumber(contentCase_); - } + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } - public Builder clearContent() { - contentCase_ = 0; - content_ = null; - onChanged(); - return this; - } + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); + } - /** - * - * - *
-         * Raw audio synthesized from the Dialogflow agent's response using
-         * the output config specified in the request.
-         * 
- * - * bytes audio = 1; - * - * @return The audio. - */ - public com.google.protobuf.ByteString getAudio() { - if (contentCase_ == 1) { - return (com.google.protobuf.ByteString) content_; - } - return com.google.protobuf.ByteString.EMPTY; - } - /** - * - * - *
-         * Raw audio synthesized from the Dialogflow agent's response using
-         * the output config specified in the request.
-         * 
- * - * bytes audio = 1; - * - * @param value The audio to set. - * @return This builder for chaining. - */ - public Builder setAudio(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - contentCase_ = 1; - content_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Raw audio synthesized from the Dialogflow agent's response using
-         * the output config specified in the request.
-         * 
- * - * bytes audio = 1; - * - * @return This builder for chaining. - */ - public Builder clearAudio() { - if (contentCase_ == 1) { - contentCase_ = 0; - content_ = null; - onChanged(); - } - return this; - } + public static Builder newBuilder() { + return DEFAULT_INSTANCE.toBuilder(); + } - /** - * - * - *
-         * Client-specific URI that points to an audio clip accessible to the
-         * client. Dialogflow does not impose any validation on it.
-         * 
- * - * string uri = 2; - * - * @return The uri. - */ - @java.lang.Override - public java.lang.String getUri() { - java.lang.Object ref = ""; - if (contentCase_ == 2) { - ref = content_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (contentCase_ == 2) { - content_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-         * Client-specific URI that points to an audio clip accessible to the
-         * client. Dialogflow does not impose any validation on it.
-         * 
- * - * string uri = 2; - * - * @return The bytes for uri. - */ - @java.lang.Override - public com.google.protobuf.ByteString getUriBytes() { - java.lang.Object ref = ""; - if (contentCase_ == 2) { - ref = content_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (contentCase_ == 2) { - content_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-         * Client-specific URI that points to an audio clip accessible to the
-         * client. Dialogflow does not impose any validation on it.
-         * 
- * - * string uri = 2; - * - * @param value The uri to set. - * @return This builder for chaining. - */ - public Builder setUri(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - contentCase_ = 2; - content_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Client-specific URI that points to an audio clip accessible to the
-         * client. Dialogflow does not impose any validation on it.
-         * 
- * - * string uri = 2; - * - * @return This builder for chaining. - */ - public Builder clearUri() { - if (contentCase_ == 2) { - contentCase_ = 0; - content_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-         * Client-specific URI that points to an audio clip accessible to the
-         * client. Dialogflow does not impose any validation on it.
-         * 
- * - * string uri = 2; - * - * @param value The bytes for uri to set. - * @return This builder for chaining. - */ - public Builder setUriBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - contentCase_ = 2; - content_ = value; - onChanged(); - return this; - } + public static Builder newBuilder( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction prototype) { + return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); + } - private boolean allowPlaybackInterruption_; - /** - * - * - *
-         * Output only. Whether the playback of this segment can be interrupted by the end
-         * user's speech and the client should then start the next Dialogflow
-         * request.
-         * 
- * - * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The allowPlaybackInterruption. - */ - @java.lang.Override - public boolean getAllowPlaybackInterruption() { - return allowPlaybackInterruption_; - } - /** - * - * - *
-         * Output only. Whether the playback of this segment can be interrupted by the end
-         * user's speech and the client should then start the next Dialogflow
-         * request.
-         * 
- * - * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The allowPlaybackInterruption to set. - * @return This builder for chaining. - */ - public Builder setAllowPlaybackInterruption(boolean value) { + @java.lang.Override + public Builder toBuilder() { + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); + } - allowPlaybackInterruption_ = value; - onChanged(); - return this; - } - /** - * - * - *
-         * Output only. Whether the playback of this segment can be interrupted by the end
-         * user's speech and the client should then start the next Dialogflow
-         * request.
-         * 
- * - * bool allow_playback_interruption = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return This builder for chaining. - */ - public Builder clearAllowPlaybackInterruption() { + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * + * + *
+     * Indicates that interaction with the Dialogflow agent has ended.
+     * This message is generated by Dialogflow only and not supposed to be
+     * defined by the user.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteractionOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; + } - allowPlaybackInterruption_ = false; - onChanged(); - return this; - } + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.Builder + .class); + } - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction build() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction result = + buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); } + return result; + } - // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction result = + new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction(this); + onBuilt(); + return result; } - // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment) - private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - DEFAULT_INSTANCE; + @java.lang.Override + public Builder clone() { + return super.clone(); + } - static { - DEFAULT_INSTANCE = - new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment(); + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - getDefaultInstance() { - return DEFAULT_INSTANCE; + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); } - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Segment parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Segment(input, extensionRegistry); - } - }; + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); + } - public static com.google.protobuf.Parser parser() { - return PARSER; + @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 com.google.protobuf.Parser getParserForType() { - return PARSER; + 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + .getDefaultInstance()) return this; + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + @java.lang.Override + public final Builder setUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.setUnknownFields(unknownFields); } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - getDefaultInstanceForType() { - return DEFAULT_INSTANCE; + public final Builder mergeUnknownFields( + final com.google.protobuf.UnknownFieldSet unknownFields) { + return super.mergeUnknownFields(unknownFields); } + + // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) } - public static final int SEGMENTS_FIELD_NUMBER = 1; - private java.util.List< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> - segments_; + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction) + private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = + new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public EndInteraction parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new EndInteraction(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.ResponseMessage.EndInteraction + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public interface PlayAudioOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) + com.google.protobuf.MessageOrBuilder { + /** * * *
-     * Segments this audio response is composed of.
+     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+     * value. It is specific to the client that reads it.
      * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The audioUri. */ - @java.lang.Override - public java.util.List - getSegmentsList() { - return segments_; - } + java.lang.String getAudioUri(); /** * * *
-     * Segments this audio response is composed of.
+     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+     * value. It is specific to the client that reads it.
      * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for audioUri. + */ + com.google.protobuf.ByteString getAudioUriBytes(); + + /** + * + * + *
+     * Output only. Whether the playback of this message can be interrupted by the end
+     * user's speech and the client can then starts the next Dialogflow
+     * request.
+     * 
+ * + * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return The allowPlaybackInterruption. */ + boolean getAllowPlaybackInterruption(); + } + /** + * + * + *
+   * Specifies an audio clip to be played by the client as part of the response.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio} + */ + public static final class PlayAudio extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) + PlayAudioOrBuilder { + private static final long serialVersionUID = 0L; + // Use PlayAudio.newBuilder() to construct. + private PlayAudio(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private PlayAudio() { + audioUri_ = ""; + } + @java.lang.Override - public java.util.List< - ? extends - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> - getSegmentsOrBuilderList() { - return segments_; + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new PlayAudio(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private PlayAudio( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + audioUri_ = s; + break; + } + case 16: + { + allowPlaybackInterruption_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.Builder.class); } + + public static final int AUDIO_URI_FIELD_NUMBER = 1; + private volatile java.lang.Object audioUri_; /** * * *
-     * Segments this audio response is composed of.
+     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+     * value. It is specific to the client that reads it.
      * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The audioUri. */ @java.lang.Override - public int getSegmentsCount() { - return segments_.size(); + public java.lang.String getAudioUri() { + java.lang.Object ref = audioUri_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + audioUri_ = s; + return s; + } } /** * * *
-     * Segments this audio response is composed of.
+     * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+     * value. It is specific to the client that reads it.
      * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for audioUri. */ @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment getSegments( - int index) { - return segments_.get(index); + public com.google.protobuf.ByteString getAudioUriBytes() { + java.lang.Object ref = audioUri_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + audioUri_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } } + + public static final int ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER = 2; + private boolean allowPlaybackInterruption_; /** * * *
-     * Segments this audio response is composed of.
+     * Output only. Whether the playback of this message can be interrupted by the end
+     * user's speech and the client can then starts the next Dialogflow
+     * request.
      * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return The allowPlaybackInterruption. */ @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder - getSegmentsOrBuilder(int index) { - return segments_.get(index); + public boolean getAllowPlaybackInterruption() { + return allowPlaybackInterruption_; } private byte memoizedIsInitialized = -1; @@ -6510,8 +6790,11 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < segments_.size(); i++) { - output.writeMessage(1, segments_.get(i)); + if (!getAudioUriBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, audioUri_); + } + if (allowPlaybackInterruption_ != false) { + output.writeBool(2, allowPlaybackInterruption_); } unknownFields.writeTo(output); } @@ -6522,8 +6805,12 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - for (int i = 0; i < segments_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, segments_.get(i)); + if (!getAudioUriBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, audioUri_); + } + if (allowPlaybackInterruption_ != false) { + size += + com.google.protobuf.CodedOutputStream.computeBoolSize(2, allowPlaybackInterruption_); } size += unknownFields.getSerializedSize(); memoizedSize = size; @@ -6535,13 +6822,14 @@ public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } - if (!(obj instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio)) { + if (!(obj instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio)) { return super.equals(obj); } - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio other = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) obj; + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio other = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) obj; - if (!getSegmentsList().equals(other.getSegmentsList())) return false; + if (!getAudioUri().equals(other.getAudioUri())) return false; + if (getAllowPlaybackInterruption() != other.getAllowPlaybackInterruption()) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } @@ -6553,68 +6841,68 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - if (getSegmentsCount() > 0) { - hash = (37 * hash) + SEGMENTS_FIELD_NUMBER; - hash = (53 * hash) + getSegmentsList().hashCode(); - } + hash = (37 * hash) + AUDIO_URI_FIELD_NUMBER; + hash = (53 * hash) + getAudioUri().hashCode(); + hash = (37 * hash) + ALLOW_PLAYBACK_INTERRUPTION_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowPlaybackInterruption()); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio 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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -6622,12 +6910,12 @@ public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio PARSER, input, extensionRegistry); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parseFrom( + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { @@ -6645,7 +6933,7 @@ public static Builder newBuilder() { } public static Builder newBuilder( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio prototype) { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @@ -6664,39 +6952,33 @@ protected Builder newBuilderForType( * * *
-     * Represents an audio message that is composed of both segments
-     * synthesized from the Dialogflow agent prompts and ones hosted externally
-     * at the specified URIs.
-     * The external URIs are specified via
-     * [play_audio][google.cloud.dialogflow.cx.v3beta1.ResponseMessage.play_audio].
-     * This message is generated by Dialogflow only and not supposed to be
-     * defined by the user.
+     * Specifies an audio clip to be played by the client as part of the response.
      * 
* - * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio} + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements - // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudioOrBuilder { + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudioOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_fieldAccessorTable + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable .ensureFieldAccessorsInitialized( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.class, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Builder.class); + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.class, + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.Builder.class); } // Construct using - // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.newBuilder() + // com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio.newBuilder() private Builder() { maybeForceBuilderInitialization(); } @@ -6707,592 +6989,310 @@ private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { } private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getSegmentsFieldBuilder(); - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override public Builder clear() { super.clear(); - if (segmentsBuilder_ == null) { - segments_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - segmentsBuilder_.clear(); - } + audioUri_ = ""; + + allowPlaybackInterruption_ = false; + return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessageProto - .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; + .internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio getDefaultInstanceForType() { - return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + return com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio .getDefaultInstance(); } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio build() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio result = buildPartial(); + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio build() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } - return result; - } - - @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio buildPartial() { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio result = - new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio(this); - int from_bitField0_ = bitField0_; - if (segmentsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - segments_ = java.util.Collections.unmodifiableList(segments_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.segments_ = segments_; - } else { - result.segments_ = segmentsBuilder_.build(); - } - onBuilt(); - return result; - } - - @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.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) { - return mergeFrom( - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio other) { - if (other - == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio - .getDefaultInstance()) return this; - if (segmentsBuilder_ == null) { - if (!other.segments_.isEmpty()) { - if (segments_.isEmpty()) { - segments_ = other.segments_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSegmentsIsMutable(); - segments_.addAll(other.segments_); - } - onChanged(); - } - } else { - if (!other.segments_.isEmpty()) { - if (segmentsBuilder_.isEmpty()) { - segmentsBuilder_.dispose(); - segmentsBuilder_ = null; - segments_ = other.segments_; - bitField0_ = (bitField0_ & ~0x00000001); - segmentsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getSegmentsFieldBuilder() - : null; - } else { - segmentsBuilder_.addAllMessages(other.segments_); - } - } - } - this.mergeUnknownFields(other.unknownFields); - 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 { - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) - e.getUnfinishedMessage(); - throw e.unwrapIOException(); - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - - private int bitField0_; - - private java.util.List< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> - segments_ = java.util.Collections.emptyList(); - - private void ensureSegmentsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - segments_ = - new java.util.ArrayList< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment>( - segments_); - bitField0_ |= 0x00000001; - } + return result; } - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> - segmentsBuilder_; + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio result = + new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio(this); + result.audioUri_ = audioUri_; + result.allowPlaybackInterruption_ = allowPlaybackInterruption_; + onBuilt(); + return result; + } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public java.util.List< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> - getSegmentsList() { - if (segmentsBuilder_ == null) { - return java.util.Collections.unmodifiableList(segments_); - } else { - return segmentsBuilder_.getMessageList(); - } + @java.lang.Override + public Builder clone() { + return super.clone(); } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public int getSegmentsCount() { - if (segmentsBuilder_ == null) { - return segments_.size(); - } else { - return segmentsBuilder_.getCount(); - } + + @java.lang.Override + public Builder setField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.setField(field, value); } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment getSegments( - int index) { - if (segmentsBuilder_ == null) { - return segments_.get(index); - } else { - return segmentsBuilder_.getMessage(index); - } + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { + return super.clearField(field); } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public Builder setSegments( - int index, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment value) { - if (segmentsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSegmentsIsMutable(); - segments_.set(index, value); - onChanged(); - } else { - segmentsBuilder_.setMessage(index, value); - } - return this; + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { + return super.clearOneof(oneof); } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public Builder setSegments( + + @java.lang.Override + public Builder setRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, int index, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - builderForValue) { - if (segmentsBuilder_ == null) { - ensureSegmentsIsMutable(); - segments_.set(index, builderForValue.build()); - onChanged(); - } else { - segmentsBuilder_.setMessage(index, builderForValue.build()); - } - return this; + java.lang.Object value) { + return super.setRepeatedField(field, index, value); } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public Builder addSegments( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment value) { - if (segmentsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSegmentsIsMutable(); - segments_.add(value); - onChanged(); - } else { - segmentsBuilder_.addMessage(value); - } - return this; + + @java.lang.Override + public Builder addRepeatedField( + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { + return super.addRepeatedField(field, value); } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public Builder addSegments( - int index, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment value) { - if (segmentsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSegmentsIsMutable(); - segments_.add(index, value); - onChanged(); + + @java.lang.Override + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) other); } else { - segmentsBuilder_.addMessage(index, value); + super.mergeFrom(other); + return this; } - return this; } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public Builder addSegments( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - builderForValue) { - if (segmentsBuilder_ == null) { - ensureSegmentsIsMutable(); - segments_.add(builderForValue.build()); + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio + .getDefaultInstance()) return this; + if (!other.getAudioUri().isEmpty()) { + audioUri_ = other.audioUri_; onChanged(); - } else { - segmentsBuilder_.addMessage(builderForValue.build()); } + if (other.getAllowPlaybackInterruption() != false) { + setAllowPlaybackInterruption(other.getAllowPlaybackInterruption()); + } + this.mergeUnknownFields(other.unknownFields); + onChanged(); return this; } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
- * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public Builder addSegments( - int index, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - builderForValue) { - if (segmentsBuilder_ == null) { - ensureSegmentsIsMutable(); - segments_.add(index, builderForValue.build()); - onChanged(); - } else { - segmentsBuilder_.addMessage(index, builderForValue.build()); + + @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 { + com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } } return this; } + + private java.lang.Object audioUri_ = ""; /** * * *
-       * Segments this audio response is composed of.
+       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+       * value. It is specific to the client that reads it.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The audioUri. */ - public Builder addAllSegments( - java.lang.Iterable< - ? extends - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment> - values) { - if (segmentsBuilder_ == null) { - ensureSegmentsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, segments_); - onChanged(); + public java.lang.String getAudioUri() { + java.lang.Object ref = audioUri_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + audioUri_ = s; + return s; } else { - segmentsBuilder_.addAllMessages(values); + return (java.lang.String) ref; } - return this; } /** * * *
-       * Segments this audio response is composed of.
+       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+       * value. It is specific to the client that reads it.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for audioUri. */ - public Builder clearSegments() { - if (segmentsBuilder_ == null) { - segments_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); + public com.google.protobuf.ByteString getAudioUriBytes() { + java.lang.Object ref = audioUri_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + audioUri_ = b; + return b; } else { - segmentsBuilder_.clear(); + return (com.google.protobuf.ByteString) ref; } - return this; } /** * * *
-       * Segments this audio response is composed of.
+       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+       * value. It is specific to the client that reads it.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The audioUri to set. + * @return This builder for chaining. */ - public Builder removeSegments(int index) { - if (segmentsBuilder_ == null) { - ensureSegmentsIsMutable(); - segments_.remove(index); - onChanged(); - } else { - segmentsBuilder_.remove(index); + public Builder setAudioUri(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); } + + audioUri_ = value; + onChanged(); return this; } /** * * *
-       * Segments this audio response is composed of.
+       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+       * value. It is specific to the client that reads it.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * - */ - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - getSegmentsBuilder(int index) { - return getSegmentsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-       * Segments this audio response is composed of.
-       * 
+ * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; * - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * @return This builder for chaining. */ - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder - getSegmentsOrBuilder(int index) { - if (segmentsBuilder_ == null) { - return segments_.get(index); - } else { - return segmentsBuilder_.getMessageOrBuilder(index); - } + public Builder clearAudioUri() { + + audioUri_ = getDefaultInstance().getAudioUri(); + onChanged(); + return this; } /** * * *
-       * Segments this audio response is composed of.
+       * Required. URI of the audio clip. Dialogflow does not impose any validation on this
+       * value. It is specific to the client that reads it.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; - * + * string audio_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for audioUri to set. + * @return This builder for chaining. */ - public java.util.List< - ? extends - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio - .SegmentOrBuilder> - getSegmentsOrBuilderList() { - if (segmentsBuilder_ != null) { - return segmentsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(segments_); + public Builder setAudioUriBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); } + checkByteStringIsUtf8(value); + + audioUri_ = value; + onChanged(); + return this; } + + private boolean allowPlaybackInterruption_; /** * * *
-       * Segments this audio response is composed of.
+       * Output only. Whether the playback of this message can be interrupted by the end
+       * user's speech and the client can then starts the next Dialogflow
+       * request.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return The allowPlaybackInterruption. */ - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - addSegmentsBuilder() { - return getSegmentsFieldBuilder() - .addBuilder( - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - .getDefaultInstance()); + @java.lang.Override + public boolean getAllowPlaybackInterruption() { + return allowPlaybackInterruption_; } /** * * *
-       * Segments this audio response is composed of.
+       * Output only. Whether the playback of this message can be interrupted by the end
+       * user's speech and the client can then starts the next Dialogflow
+       * request.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @param value The allowPlaybackInterruption to set. + * @return This builder for chaining. */ - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder - addSegmentsBuilder(int index) { - return getSegmentsFieldBuilder() - .addBuilder( - index, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment - .getDefaultInstance()); + public Builder setAllowPlaybackInterruption(boolean value) { + + allowPlaybackInterruption_ = value; + onChanged(); + return this; } /** * * *
-       * Segments this audio response is composed of.
+       * Output only. Whether the playback of this message can be interrupted by the end
+       * user's speech and the client can then starts the next Dialogflow
+       * request.
        * 
* - * - * repeated .google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment segments = 1; + * bool allow_playback_interruption = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; * + * + * @return This builder for chaining. */ - public java.util.List< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder> - getSegmentsBuilderList() { - return getSegmentsFieldBuilder().getBuilderList(); - } + public Builder clearAllowPlaybackInterruption() { - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.SegmentOrBuilder> - getSegmentsFieldBuilder() { - if (segmentsBuilder_ == null) { - segmentsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio.Segment.Builder, - com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio - .SegmentOrBuilder>( - segments_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - segments_ = null; - } - return segmentsBuilder_; + allowPlaybackInterruption_ = false; + onChanged(); + return this; } @java.lang.Override @@ -7307,44 +7307,44 @@ public final Builder mergeUnknownFields( return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) + // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) } - // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio) - private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio) + private static final com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio DEFAULT_INSTANCE; static { - DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio(); + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio(); } - public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + public static com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { @java.lang.Override - public MixedAudio parsePartialFrom( + public PlayAudio parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new MixedAudio(input, extensionRegistry); + return new PlayAudio(input, extensionRegistry); } }; - public static com.google.protobuf.Parser parser() { + public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override - public com.google.protobuf.Parser getParserForType() { + public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override - public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.MixedAudio + public com.google.cloud.dialogflow.cx.v3beta1.ResponseMessage.PlayAudio getDefaultInstanceForType() { return DEFAULT_INSTANCE; } diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessageProto.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessageProto.java index 81a007d29..c7d6ed8c8 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessageProto.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessageProto.java @@ -47,14 +47,6 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_OutputAudioText_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_OutputAudioText_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable @@ -63,6 +55,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor; static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable; public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; @@ -102,14 +102,14 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { + "\027.google.protobuf.Struct\032e\n\017OutputAudioT" + "ext\022\016\n\004text\030\001 \001(\tH\000\022\016\n\004ssml\030\002 \001(\tH\000\022(\n\033a" + "llow_playback_interruption\030\003 \001(\010B\003\340A\003B\010\n" - + "\006source\032M\n\tPlayAudio\022\026\n\taudio_uri\030\001 \001(\tB" - + "\003\340A\002\022(\n\033allow_playback_interruption\030\002 \001(" - + "\010B\003\340A\003\032\020\n\016EndInteraction\032\306\001\n\nMixedAudio\022" - + "X\n\010segments\030\001 \003(\0132F.google.cloud.dialogf" - + "low.cx.v3beta1.ResponseMessage.MixedAudi" - + "o.Segment\032^\n\007Segment\022\017\n\005audio\030\001 \001(\014H\000\022\r\n" - + "\003uri\030\002 \001(\tH\000\022(\n\033allow_playback_interrupt" - + "ion\030\003 \001(\010B\003\340A\003B\t\n\007contentB\t\n\007messageB\263\001\n" + + "\006source\032\306\001\n\nMixedAudio\022X\n\010segments\030\001 \003(\013" + + "2F.google.cloud.dialogflow.cx.v3beta1.Re" + + "sponseMessage.MixedAudio.Segment\032^\n\007Segm" + + "ent\022\017\n\005audio\030\001 \001(\014H\000\022\r\n\003uri\030\002 \001(\tH\000\022(\n\033a" + + "llow_playback_interruption\030\003 \001(\010B\003\340A\003B\t\n" + + "\007content\032\020\n\016EndInteraction\032M\n\tPlayAudio\022" + + "\026\n\taudio_uri\030\001 \001(\tB\003\340A\002\022(\n\033allow_playbac" + + "k_interruption\030\002 \001(\010B\003\340A\003B\t\n\007messageB\263\001\n" + "&com.google.cloud.dialogflow.cx.v3beta1B" + "\024ResponseMessageProtoP\001ZDgoogle.golang.o" + "rg/genproto/googleapis/cloud/dialogflow/" @@ -180,15 +180,25 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new java.lang.String[] { "Text", "Ssml", "AllowPlaybackInterruption", "Source", }); - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor = internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_descriptor .getNestedTypes() .get(4); - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable = + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor, + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor, new java.lang.String[] { - "AudioUri", "AllowPlaybackInterruption", + "Segments", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor + .getNestedTypes() + .get(0); + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor, + new java.lang.String[] { + "Audio", "Uri", "AllowPlaybackInterruption", "Content", }); internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor = internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_descriptor @@ -198,25 +208,15 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_EndInteraction_descriptor, new java.lang.String[] {}); - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor = + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor = internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_descriptor .getNestedTypes() .get(6); - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor, - new java.lang.String[] { - "Segments", - }); - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor = - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_descriptor - .getNestedTypes() - .get(0); - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_fieldAccessorTable = + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_fieldAccessorTable = new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_MixedAudio_Segment_descriptor, + internal_static_google_cloud_dialogflow_cx_v3beta1_ResponseMessage_PlayAudio_descriptor, new java.lang.String[] { - "Audio", "Uri", "AllowPlaybackInterruption", "Content", + "AudioUri", "AllowPlaybackInterruption", }); com.google.protobuf.ExtensionRegistry registry = com.google.protobuf.ExtensionRegistry.newInstance(); diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/RestoreAgentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/RestoreAgentRequest.java index ea4141050..a588b042f 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/RestoreAgentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/RestoreAgentRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3beta1.Agents.RestoreAgent].
+ * The request message for
+ * [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3beta1.Agents.RestoreAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.RestoreAgentRequest} @@ -507,7 +508,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3beta1.Agents.RestoreAgent].
+   * The request message for
+   * [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3beta1.Agents.RestoreAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.RestoreAgentRequest} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettings.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettings.java new file mode 100644 index 000000000..fcc4f5a5b --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettings.java @@ -0,0 +1,2475 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * Represents the settings related to security issues, such as data redaction
+ * and data retention. It may take hours for updates on the settings to
+ * propagate to all the related components and take effect.
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.SecuritySettings} + */ +public final class SecuritySettings extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.SecuritySettings) + SecuritySettingsOrBuilder { + private static final long serialVersionUID = 0L; + // Use SecuritySettings.newBuilder() to construct. + private SecuritySettings(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private SecuritySettings() { + name_ = ""; + displayName_ = ""; + redactionStrategy_ = 0; + redactionScope_ = 0; + inspectTemplate_ = ""; + purgeDataTypes_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SecuritySettings(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private SecuritySettings( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + + displayName_ = s; + break; + } + case 24: + { + int rawValue = input.readEnum(); + + redactionStrategy_ = rawValue; + break; + } + case 32: + { + int rawValue = input.readEnum(); + + redactionScope_ = rawValue; + break; + } + case 48: + { + dataRetentionCase_ = 6; + dataRetention_ = input.readInt32(); + break; + } + case 64: + { + int rawValue = input.readEnum(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + purgeDataTypes_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + purgeDataTypes_.add(rawValue); + break; + } + case 66: + { + int length = input.readRawVarint32(); + int oldLimit = input.pushLimit(length); + while (input.getBytesUntilLimit() > 0) { + int rawValue = input.readEnum(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + purgeDataTypes_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + purgeDataTypes_.add(rawValue); + } + input.popLimit(oldLimit); + break; + } + case 74: + { + java.lang.String s = input.readStringRequireUtf8(); + + inspectTemplate_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + purgeDataTypes_ = java.util.Collections.unmodifiableList(purgeDataTypes_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.class, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder.class); + } + + /** + * + * + *
+   * Defines how we redact data.
+   * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy} + */ + public enum RedactionStrategy implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Do not redact.
+     * 
+ * + * REDACTION_STRATEGY_UNSPECIFIED = 0; + */ + REDACTION_STRATEGY_UNSPECIFIED(0), + /** + * + * + *
+     * Call redaction service to clean up the data to be persisted.
+     * 
+ * + * REDACT_WITH_SERVICE = 1; + */ + REDACT_WITH_SERVICE(1), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Do not redact.
+     * 
+ * + * REDACTION_STRATEGY_UNSPECIFIED = 0; + */ + public static final int REDACTION_STRATEGY_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * Call redaction service to clean up the data to be persisted.
+     * 
+ * + * REDACT_WITH_SERVICE = 1; + */ + public static final int REDACT_WITH_SERVICE_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static RedactionStrategy 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 RedactionStrategy forNumber(int value) { + switch (value) { + case 0: + return REDACTION_STRATEGY_UNSPECIFIED; + case 1: + return REDACT_WITH_SERVICE; + 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 RedactionStrategy findValueByNumber(int number) { + return RedactionStrategy.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.dialogflow.cx.v3beta1.SecuritySettings.getDescriptor() + .getEnumTypes() + .get(0); + } + + private static final RedactionStrategy[] VALUES = values(); + + public static RedactionStrategy 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 RedactionStrategy(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy) + } + + /** + * + * + *
+   * Defines what types of data to redact.
+   * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope} + */ + public enum RedactionScope implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Don't redact any kind of data.
+     * 
+ * + * REDACTION_SCOPE_UNSPECIFIED = 0; + */ + REDACTION_SCOPE_UNSPECIFIED(0), + /** + * + * + *
+     * On data to be written to disk or similar devices that are capable of
+     * holding data even if power is disconnected. This includes data that are
+     * temporarily saved on disk.
+     * 
+ * + * REDACT_DISK_STORAGE = 2; + */ + REDACT_DISK_STORAGE(2), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Don't redact any kind of data.
+     * 
+ * + * REDACTION_SCOPE_UNSPECIFIED = 0; + */ + public static final int REDACTION_SCOPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * On data to be written to disk or similar devices that are capable of
+     * holding data even if power is disconnected. This includes data that are
+     * temporarily saved on disk.
+     * 
+ * + * REDACT_DISK_STORAGE = 2; + */ + public static final int REDACT_DISK_STORAGE_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 RedactionScope 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 RedactionScope forNumber(int value) { + switch (value) { + case 0: + return REDACTION_SCOPE_UNSPECIFIED; + case 2: + return REDACT_DISK_STORAGE; + 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 RedactionScope findValueByNumber(int number) { + return RedactionScope.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.dialogflow.cx.v3beta1.SecuritySettings.getDescriptor() + .getEnumTypes() + .get(1); + } + + private static final RedactionScope[] VALUES = values(); + + public static RedactionScope 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 RedactionScope(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope) + } + + /** + * + * + *
+   * Type of data we purge after retention settings triggers purge.
+   * 
+ * + * Protobuf enum {@code google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType} + */ + public enum PurgeDataType implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+     * Unspecified. Do not use.
+     * 
+ * + * PURGE_DATA_TYPE_UNSPECIFIED = 0; + */ + PURGE_DATA_TYPE_UNSPECIFIED(0), + /** + * + * + *
+     * Dialogflow history. This does not include Stackdriver log, which is
+     * owned by the user not Dialogflow.
+     * 
+ * + * DIALOGFLOW_HISTORY = 1; + */ + DIALOGFLOW_HISTORY(1), + UNRECOGNIZED(-1), + ; + + /** + * + * + *
+     * Unspecified. Do not use.
+     * 
+ * + * PURGE_DATA_TYPE_UNSPECIFIED = 0; + */ + public static final int PURGE_DATA_TYPE_UNSPECIFIED_VALUE = 0; + /** + * + * + *
+     * Dialogflow history. This does not include Stackdriver log, which is
+     * owned by the user not Dialogflow.
+     * 
+ * + * DIALOGFLOW_HISTORY = 1; + */ + public static final int DIALOGFLOW_HISTORY_VALUE = 1; + + public final int getNumber() { + if (this == UNRECOGNIZED) { + throw new java.lang.IllegalArgumentException( + "Can't get the number of an unknown enum value."); + } + return value; + } + + /** + * @param value The numeric wire value of the corresponding enum entry. + * @return The enum associated with the given numeric wire value. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static PurgeDataType 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 PurgeDataType forNumber(int value) { + switch (value) { + case 0: + return PURGE_DATA_TYPE_UNSPECIFIED; + case 1: + return DIALOGFLOW_HISTORY; + 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 PurgeDataType findValueByNumber(int number) { + return PurgeDataType.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.dialogflow.cx.v3beta1.SecuritySettings.getDescriptor() + .getEnumTypes() + .get(2); + } + + private static final PurgeDataType[] VALUES = values(); + + public static PurgeDataType 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 PurgeDataType(int value) { + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType) + } + + private int dataRetentionCase_ = 0; + private java.lang.Object dataRetention_; + + public enum DataRetentionCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + RETENTION_WINDOW_DAYS(6), + DATARETENTION_NOT_SET(0); + private final int value; + + private DataRetentionCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static DataRetentionCase valueOf(int value) { + return forNumber(value); + } + + public static DataRetentionCase forNumber(int value) { + switch (value) { + case 6: + return RETENTION_WINDOW_DAYS; + case 0: + return DATARETENTION_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public DataRetentionCase getDataRetentionCase() { + return DataRetentionCase.forNumber(dataRetentionCase_); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings ID>`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + @java.lang.Override + public java.lang.String getName() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } + } + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings ID>`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + @java.lang.Override + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int DISPLAY_NAME_FIELD_NUMBER = 2; + private volatile java.lang.Object displayName_; + /** + * + * + *
+   * Required. The human-readable name of the security settings, unique within the
+   * location.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + @java.lang.Override + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } + } + /** + * + * + *
+   * Required. The human-readable name of the security settings, unique within the
+   * location.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + @java.lang.Override + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int REDACTION_STRATEGY_FIELD_NUMBER = 3; + private int redactionStrategy_; + /** + * + * + *
+   * Strategy that defines how we do redaction.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return The enum numeric value on the wire for redactionStrategy. + */ + @java.lang.Override + public int getRedactionStrategyValue() { + return redactionStrategy_; + } + /** + * + * + *
+   * Strategy that defines how we do redaction.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return The redactionStrategy. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy + getRedactionStrategy() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy result = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy.valueOf( + redactionStrategy_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy.UNRECOGNIZED + : result; + } + + public static final int REDACTION_SCOPE_FIELD_NUMBER = 4; + private int redactionScope_; + /** + * + * + *
+   * Defines on what data we apply redaction. Note that we don't
+   * redact data to which we don't have access, e.g., Stackdriver logs.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return The enum numeric value on the wire for redactionScope. + */ + @java.lang.Override + public int getRedactionScopeValue() { + return redactionScope_; + } + /** + * + * + *
+   * Defines on what data we apply redaction. Note that we don't
+   * redact data to which we don't have access, e.g., Stackdriver logs.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return The redactionScope. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope + getRedactionScope() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope result = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope.valueOf( + redactionScope_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope.UNRECOGNIZED + : result; + } + + public static final int INSPECT_TEMPLATE_FIELD_NUMBER = 9; + private volatile java.lang.Object inspectTemplate_; + /** + * + * + *
+   * DLP inspect template name. Use this template to define inspect base
+   * settings.
+   * If empty, we use the default DLP inspect config.
+   * The template name will have one of the following formats:
+   * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+   * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+   * 
+ * + * string inspect_template = 9; + * + * @return The inspectTemplate. + */ + @java.lang.Override + public java.lang.String getInspectTemplate() { + java.lang.Object ref = inspectTemplate_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + inspectTemplate_ = s; + return s; + } + } + /** + * + * + *
+   * DLP inspect template name. Use this template to define inspect base
+   * settings.
+   * If empty, we use the default DLP inspect config.
+   * The template name will have one of the following formats:
+   * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+   * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+   * 
+ * + * string inspect_template = 9; + * + * @return The bytes for inspectTemplate. + */ + @java.lang.Override + public com.google.protobuf.ByteString getInspectTemplateBytes() { + java.lang.Object ref = inspectTemplate_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + inspectTemplate_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int RETENTION_WINDOW_DAYS_FIELD_NUMBER = 6; + /** + * + * + *
+   * Retains the data for the specified number of days.
+   * User must Set a value lower than Dialogflow's default 30d TTL. Setting a
+   * value higher than that has no effect.
+   * A missing value or setting to 0 also means we use Dialogflow's default
+   * TTL.
+   * 
+ * + * int32 retention_window_days = 6; + * + * @return The retentionWindowDays. + */ + @java.lang.Override + public int getRetentionWindowDays() { + if (dataRetentionCase_ == 6) { + return (java.lang.Integer) dataRetention_; + } + return 0; + } + + public static final int PURGE_DATA_TYPES_FIELD_NUMBER = 8; + private java.util.List purgeDataTypes_; + private static final com.google.protobuf.Internal.ListAdapter.Converter< + java.lang.Integer, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType> + purgeDataTypes_converter_ = + new com.google.protobuf.Internal.ListAdapter.Converter< + java.lang.Integer, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType>() { + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType convert( + java.lang.Integer from) { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType result = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType.valueOf( + from); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType + .UNRECOGNIZED + : result; + } + }; + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return A list containing the purgeDataTypes. + */ + @java.lang.Override + public java.util.List + getPurgeDataTypesList() { + return new com.google.protobuf.Internal.ListAdapter< + java.lang.Integer, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType>( + purgeDataTypes_, purgeDataTypes_converter_); + } + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return The count of purgeDataTypes. + */ + @java.lang.Override + public int getPurgeDataTypesCount() { + return purgeDataTypes_.size(); + } + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the element to return. + * @return The purgeDataTypes at the given index. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType getPurgeDataTypes( + int index) { + return purgeDataTypes_converter_.convert(purgeDataTypes_.get(index)); + } + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return A list containing the enum numeric values on the wire for purgeDataTypes. + */ + @java.lang.Override + public java.util.List getPurgeDataTypesValueList() { + return purgeDataTypes_; + } + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of purgeDataTypes at the given index. + */ + @java.lang.Override + public int getPurgeDataTypesValue(int index) { + return purgeDataTypes_.get(index); + } + + private int purgeDataTypesMemoizedSerializedSize; + + 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 { + getSerializedSize(); + if (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + if (!getDisplayNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); + } + if (redactionStrategy_ + != com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy + .REDACTION_STRATEGY_UNSPECIFIED + .getNumber()) { + output.writeEnum(3, redactionStrategy_); + } + if (redactionScope_ + != com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope + .REDACTION_SCOPE_UNSPECIFIED + .getNumber()) { + output.writeEnum(4, redactionScope_); + } + if (dataRetentionCase_ == 6) { + output.writeInt32(6, (int) ((java.lang.Integer) dataRetention_)); + } + if (getPurgeDataTypesList().size() > 0) { + output.writeUInt32NoTag(66); + output.writeUInt32NoTag(purgeDataTypesMemoizedSerializedSize); + } + for (int i = 0; i < purgeDataTypes_.size(); i++) { + output.writeEnumNoTag(purgeDataTypes_.get(i)); + } + if (!getInspectTemplateBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 9, inspectTemplate_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + if (!getDisplayNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); + } + if (redactionStrategy_ + != com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy + .REDACTION_STRATEGY_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, redactionStrategy_); + } + if (redactionScope_ + != com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope + .REDACTION_SCOPE_UNSPECIFIED + .getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, redactionScope_); + } + if (dataRetentionCase_ == 6) { + size += + com.google.protobuf.CodedOutputStream.computeInt32Size( + 6, (int) ((java.lang.Integer) dataRetention_)); + } + { + int dataSize = 0; + for (int i = 0; i < purgeDataTypes_.size(); i++) { + dataSize += + com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag(purgeDataTypes_.get(i)); + } + size += dataSize; + if (!getPurgeDataTypesList().isEmpty()) { + size += 1; + size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); + } + purgeDataTypesMemoizedSerializedSize = dataSize; + } + if (!getInspectTemplateBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, inspectTemplate_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.SecuritySettings)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings other = + (com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings) obj; + + if (!getName().equals(other.getName())) return false; + if (!getDisplayName().equals(other.getDisplayName())) return false; + if (redactionStrategy_ != other.redactionStrategy_) return false; + if (redactionScope_ != other.redactionScope_) return false; + if (!getInspectTemplate().equals(other.getInspectTemplate())) return false; + if (!purgeDataTypes_.equals(other.purgeDataTypes_)) return false; + if (!getDataRetentionCase().equals(other.getDataRetentionCase())) return false; + switch (dataRetentionCase_) { + case 6: + if (getRetentionWindowDays() != other.getRetentionWindowDays()) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + hash = (37 * hash) + NAME_FIELD_NUMBER; + hash = (53 * hash) + getName().hashCode(); + hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; + hash = (53 * hash) + getDisplayName().hashCode(); + hash = (37 * hash) + REDACTION_STRATEGY_FIELD_NUMBER; + hash = (53 * hash) + redactionStrategy_; + hash = (37 * hash) + REDACTION_SCOPE_FIELD_NUMBER; + hash = (53 * hash) + redactionScope_; + hash = (37 * hash) + INSPECT_TEMPLATE_FIELD_NUMBER; + hash = (53 * hash) + getInspectTemplate().hashCode(); + if (getPurgeDataTypesCount() > 0) { + hash = (37 * hash) + PURGE_DATA_TYPES_FIELD_NUMBER; + hash = (53 * hash) + purgeDataTypes_.hashCode(); + } + switch (dataRetentionCase_) { + case 6: + hash = (37 * hash) + RETENTION_WINDOW_DAYS_FIELD_NUMBER; + hash = (53 * hash) + getRetentionWindowDays(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings 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.dialogflow.cx.v3beta1.SecuritySettings parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings 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.dialogflow.cx.v3beta1.SecuritySettings parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings 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.dialogflow.cx.v3beta1.SecuritySettings parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings 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.dialogflow.cx.v3beta1.SecuritySettings parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings 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.dialogflow.cx.v3beta1.SecuritySettings 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; + } + /** + * + * + *
+   * Represents the settings related to security issues, such as data redaction
+   * and data retention. It may take hours for updates on the settings to
+   * propagate to all the related components and take effect.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.SecuritySettings} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.SecuritySettings) + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.class, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + displayName_ = ""; + + redactionStrategy_ = 0; + + redactionScope_ = 0; + + inspectTemplate_ = ""; + + purgeDataTypes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + dataRetentionCase_ = 0; + dataRetention_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings build() { + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings result = + new com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings(this); + int from_bitField0_ = bitField0_; + result.name_ = name_; + result.displayName_ = displayName_; + result.redactionStrategy_ = redactionStrategy_; + result.redactionScope_ = redactionScope_; + result.inspectTemplate_ = inspectTemplate_; + if (dataRetentionCase_ == 6) { + result.dataRetention_ = dataRetention_; + } + if (((bitField0_ & 0x00000001) != 0)) { + purgeDataTypes_ = java.util.Collections.unmodifiableList(purgeDataTypes_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.purgeDataTypes_ = purgeDataTypes_; + result.dataRetentionCase_ = dataRetentionCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.SecuritySettings) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings other) { + if (other == com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + if (!other.getDisplayName().isEmpty()) { + displayName_ = other.displayName_; + onChanged(); + } + if (other.redactionStrategy_ != 0) { + setRedactionStrategyValue(other.getRedactionStrategyValue()); + } + if (other.redactionScope_ != 0) { + setRedactionScopeValue(other.getRedactionScopeValue()); + } + if (!other.getInspectTemplate().isEmpty()) { + inspectTemplate_ = other.inspectTemplate_; + onChanged(); + } + if (!other.purgeDataTypes_.isEmpty()) { + if (purgeDataTypes_.isEmpty()) { + purgeDataTypes_ = other.purgeDataTypes_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensurePurgeDataTypesIsMutable(); + purgeDataTypes_.addAll(other.purgeDataTypes_); + } + onChanged(); + } + switch (other.getDataRetentionCase()) { + case RETENTION_WINDOW_DAYS: + { + setRetentionWindowDays(other.getRetentionWindowDays()); + break; + } + case DATARETENTION_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int dataRetentionCase_ = 0; + private java.lang.Object dataRetention_; + + public DataRetentionCase getDataRetentionCase() { + return DataRetentionCase.forNumber(dataRetentionCase_); + } + + public Builder clearDataRetention() { + dataRetentionCase_ = 0; + dataRetention_ = null; + onChanged(); + return this; + } + + private int bitField0_; + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings ID>`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + public java.lang.String getName() { + java.lang.Object ref = name_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + name_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings ID>`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + public com.google.protobuf.ByteString getNameBytes() { + java.lang.Object ref = name_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + name_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings ID>`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The name to set. + * @return This builder for chaining. + */ + public Builder setName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + name_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings ID>`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the settings.
+     * Format: `projects/<Project ID>/locations/<Location
+     * ID>/securitySettings/<Security Settings ID>`.
+     * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for name to set. + * @return This builder for chaining. + */ + public Builder setNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + name_ = value; + onChanged(); + return this; + } + + private java.lang.Object displayName_ = ""; + /** + * + * + *
+     * Required. The human-readable name of the security settings, unique within the
+     * location.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + public java.lang.String getDisplayName() { + java.lang.Object ref = displayName_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + displayName_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * Required. The human-readable name of the security settings, unique within the
+     * location.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + public com.google.protobuf.ByteString getDisplayNameBytes() { + java.lang.Object ref = displayName_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + displayName_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * Required. The human-readable name of the security settings, unique within the
+     * location.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayName(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + displayName_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The human-readable name of the security settings, unique within the
+     * location.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. + */ + public Builder clearDisplayName() { + + displayName_ = getDefaultInstance().getDisplayName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. The human-readable name of the security settings, unique within the
+     * location.
+     * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes for displayName to set. + * @return This builder for chaining. + */ + public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + displayName_ = value; + onChanged(); + return this; + } + + private int redactionStrategy_ = 0; + /** + * + * + *
+     * Strategy that defines how we do redaction.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return The enum numeric value on the wire for redactionStrategy. + */ + @java.lang.Override + public int getRedactionStrategyValue() { + return redactionStrategy_; + } + /** + * + * + *
+     * Strategy that defines how we do redaction.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @param value The enum numeric value on the wire for redactionStrategy to set. + * @return This builder for chaining. + */ + public Builder setRedactionStrategyValue(int value) { + + redactionStrategy_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Strategy that defines how we do redaction.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return The redactionStrategy. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy + getRedactionStrategy() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy result = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy.valueOf( + redactionStrategy_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * Strategy that defines how we do redaction.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @param value The redactionStrategy to set. + * @return This builder for chaining. + */ + public Builder setRedactionStrategy( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy value) { + if (value == null) { + throw new NullPointerException(); + } + + redactionStrategy_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Strategy that defines how we do redaction.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return This builder for chaining. + */ + public Builder clearRedactionStrategy() { + + redactionStrategy_ = 0; + onChanged(); + return this; + } + + private int redactionScope_ = 0; + /** + * + * + *
+     * Defines on what data we apply redaction. Note that we don't
+     * redact data to which we don't have access, e.g., Stackdriver logs.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return The enum numeric value on the wire for redactionScope. + */ + @java.lang.Override + public int getRedactionScopeValue() { + return redactionScope_; + } + /** + * + * + *
+     * Defines on what data we apply redaction. Note that we don't
+     * redact data to which we don't have access, e.g., Stackdriver logs.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @param value The enum numeric value on the wire for redactionScope to set. + * @return This builder for chaining. + */ + public Builder setRedactionScopeValue(int value) { + + redactionScope_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Defines on what data we apply redaction. Note that we don't
+     * redact data to which we don't have access, e.g., Stackdriver logs.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return The redactionScope. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope + getRedactionScope() { + @SuppressWarnings("deprecation") + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope result = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope.valueOf( + redactionScope_); + return result == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope.UNRECOGNIZED + : result; + } + /** + * + * + *
+     * Defines on what data we apply redaction. Note that we don't
+     * redact data to which we don't have access, e.g., Stackdriver logs.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @param value The redactionScope to set. + * @return This builder for chaining. + */ + public Builder setRedactionScope( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope value) { + if (value == null) { + throw new NullPointerException(); + } + + redactionScope_ = value.getNumber(); + onChanged(); + return this; + } + /** + * + * + *
+     * Defines on what data we apply redaction. Note that we don't
+     * redact data to which we don't have access, e.g., Stackdriver logs.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return This builder for chaining. + */ + public Builder clearRedactionScope() { + + redactionScope_ = 0; + onChanged(); + return this; + } + + private java.lang.Object inspectTemplate_ = ""; + /** + * + * + *
+     * DLP inspect template name. Use this template to define inspect base
+     * settings.
+     * If empty, we use the default DLP inspect config.
+     * The template name will have one of the following formats:
+     * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+     * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+     * 
+ * + * string inspect_template = 9; + * + * @return The inspectTemplate. + */ + public java.lang.String getInspectTemplate() { + java.lang.Object ref = inspectTemplate_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + inspectTemplate_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+     * DLP inspect template name. Use this template to define inspect base
+     * settings.
+     * If empty, we use the default DLP inspect config.
+     * The template name will have one of the following formats:
+     * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+     * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+     * 
+ * + * string inspect_template = 9; + * + * @return The bytes for inspectTemplate. + */ + public com.google.protobuf.ByteString getInspectTemplateBytes() { + java.lang.Object ref = inspectTemplate_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + inspectTemplate_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+     * DLP inspect template name. Use this template to define inspect base
+     * settings.
+     * If empty, we use the default DLP inspect config.
+     * The template name will have one of the following formats:
+     * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+     * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+     * 
+ * + * string inspect_template = 9; + * + * @param value The inspectTemplate to set. + * @return This builder for chaining. + */ + public Builder setInspectTemplate(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + inspectTemplate_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * DLP inspect template name. Use this template to define inspect base
+     * settings.
+     * If empty, we use the default DLP inspect config.
+     * The template name will have one of the following formats:
+     * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+     * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+     * 
+ * + * string inspect_template = 9; + * + * @return This builder for chaining. + */ + public Builder clearInspectTemplate() { + + inspectTemplate_ = getDefaultInstance().getInspectTemplate(); + onChanged(); + return this; + } + /** + * + * + *
+     * DLP inspect template name. Use this template to define inspect base
+     * settings.
+     * If empty, we use the default DLP inspect config.
+     * The template name will have one of the following formats:
+     * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+     * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+     * 
+ * + * string inspect_template = 9; + * + * @param value The bytes for inspectTemplate to set. + * @return This builder for chaining. + */ + public Builder setInspectTemplateBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + inspectTemplate_ = value; + onChanged(); + return this; + } + + /** + * + * + *
+     * Retains the data for the specified number of days.
+     * User must Set a value lower than Dialogflow's default 30d TTL. Setting a
+     * value higher than that has no effect.
+     * A missing value or setting to 0 also means we use Dialogflow's default
+     * TTL.
+     * 
+ * + * int32 retention_window_days = 6; + * + * @return The retentionWindowDays. + */ + public int getRetentionWindowDays() { + if (dataRetentionCase_ == 6) { + return (java.lang.Integer) dataRetention_; + } + return 0; + } + /** + * + * + *
+     * Retains the data for the specified number of days.
+     * User must Set a value lower than Dialogflow's default 30d TTL. Setting a
+     * value higher than that has no effect.
+     * A missing value or setting to 0 also means we use Dialogflow's default
+     * TTL.
+     * 
+ * + * int32 retention_window_days = 6; + * + * @param value The retentionWindowDays to set. + * @return This builder for chaining. + */ + public Builder setRetentionWindowDays(int value) { + dataRetentionCase_ = 6; + dataRetention_ = value; + onChanged(); + return this; + } + /** + * + * + *
+     * Retains the data for the specified number of days.
+     * User must Set a value lower than Dialogflow's default 30d TTL. Setting a
+     * value higher than that has no effect.
+     * A missing value or setting to 0 also means we use Dialogflow's default
+     * TTL.
+     * 
+ * + * int32 retention_window_days = 6; + * + * @return This builder for chaining. + */ + public Builder clearRetentionWindowDays() { + if (dataRetentionCase_ == 6) { + dataRetentionCase_ = 0; + dataRetention_ = null; + onChanged(); + } + return this; + } + + private java.util.List purgeDataTypes_ = java.util.Collections.emptyList(); + + private void ensurePurgeDataTypesIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + purgeDataTypes_ = new java.util.ArrayList(purgeDataTypes_); + bitField0_ |= 0x00000001; + } + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return A list containing the purgeDataTypes. + */ + public java.util.List + getPurgeDataTypesList() { + return new com.google.protobuf.Internal.ListAdapter< + java.lang.Integer, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType>( + purgeDataTypes_, purgeDataTypes_converter_); + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return The count of purgeDataTypes. + */ + public int getPurgeDataTypesCount() { + return purgeDataTypes_.size(); + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the element to return. + * @return The purgeDataTypes at the given index. + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType getPurgeDataTypes( + int index) { + return purgeDataTypes_converter_.convert(purgeDataTypes_.get(index)); + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index to set the value at. + * @param value The purgeDataTypes to set. + * @return This builder for chaining. + */ + public Builder setPurgeDataTypes( + int index, com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType value) { + if (value == null) { + throw new NullPointerException(); + } + ensurePurgeDataTypesIsMutable(); + purgeDataTypes_.set(index, value.getNumber()); + onChanged(); + return this; + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param value The purgeDataTypes to add. + * @return This builder for chaining. + */ + public Builder addPurgeDataTypes( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType value) { + if (value == null) { + throw new NullPointerException(); + } + ensurePurgeDataTypesIsMutable(); + purgeDataTypes_.add(value.getNumber()); + onChanged(); + return this; + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param values The purgeDataTypes to add. + * @return This builder for chaining. + */ + public Builder addAllPurgeDataTypes( + java.lang.Iterable< + ? extends com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType> + values) { + ensurePurgeDataTypesIsMutable(); + for (com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType value : values) { + purgeDataTypes_.add(value.getNumber()); + } + onChanged(); + return this; + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return This builder for chaining. + */ + public Builder clearPurgeDataTypes() { + purgeDataTypes_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + return this; + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return A list containing the enum numeric values on the wire for purgeDataTypes. + */ + public java.util.List getPurgeDataTypesValueList() { + return java.util.Collections.unmodifiableList(purgeDataTypes_); + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of purgeDataTypes at the given index. + */ + public int getPurgeDataTypesValue(int index) { + return purgeDataTypes_.get(index); + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of purgeDataTypes at the given index. + * @return This builder for chaining. + */ + public Builder setPurgeDataTypesValue(int index, int value) { + ensurePurgeDataTypesIsMutable(); + purgeDataTypes_.set(index, value); + onChanged(); + return this; + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param value The enum numeric value on the wire for purgeDataTypes to add. + * @return This builder for chaining. + */ + public Builder addPurgeDataTypesValue(int value) { + ensurePurgeDataTypesIsMutable(); + purgeDataTypes_.add(value); + onChanged(); + return this; + } + /** + * + * + *
+     * List of types of data to remove when retention settings triggers purge.
+     * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param values The enum numeric values on the wire for purgeDataTypes to add. + * @return This builder for chaining. + */ + public Builder addAllPurgeDataTypesValue(java.lang.Iterable values) { + ensurePurgeDataTypesIsMutable(); + for (int value : values) { + purgeDataTypes_.add(value); + } + 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.dialogflow.cx.v3beta1.SecuritySettings) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.SecuritySettings) + private static final com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SecuritySettings parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SecuritySettings(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.SecuritySettings getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsName.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsName.java new file mode 100644 index 000000000..f7234f20c --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsName.java @@ -0,0 +1,227 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package com.google.cloud.dialogflow.cx.v3beta1; + +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 SecuritySettingsName implements ResourceName { + private static final PathTemplate PROJECT_LOCATION_SECURITY_SETTINGS = + PathTemplate.createWithoutUrlEncoding( + "projects/{project}/locations/{location}/securitySettings/{security_settings}"); + private volatile Map fieldValuesMap; + private final String project; + private final String location; + private final String securitySettings; + + @Deprecated + protected SecuritySettingsName() { + project = null; + location = null; + securitySettings = null; + } + + private SecuritySettingsName(Builder builder) { + project = Preconditions.checkNotNull(builder.getProject()); + location = Preconditions.checkNotNull(builder.getLocation()); + securitySettings = Preconditions.checkNotNull(builder.getSecuritySettings()); + } + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSecuritySettings() { + return securitySettings; + } + + public static Builder newBuilder() { + return new Builder(); + } + + public Builder toBuilder() { + return new Builder(this); + } + + public static SecuritySettingsName of(String project, String location, String securitySettings) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSecuritySettings(securitySettings) + .build(); + } + + public static String format(String project, String location, String securitySettings) { + return newBuilder() + .setProject(project) + .setLocation(location) + .setSecuritySettings(securitySettings) + .build() + .toString(); + } + + public static SecuritySettingsName parse(String formattedString) { + if (formattedString.isEmpty()) { + return null; + } + Map matchMap = + PROJECT_LOCATION_SECURITY_SETTINGS.validatedMatch( + formattedString, "SecuritySettingsName.parse: formattedString not in valid format"); + return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("security_settings")); + } + + 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 (SecuritySettingsName value : values) { + if (value == null) { + list.add(""); + } else { + list.add(value.toString()); + } + } + return list; + } + + public static boolean isParsableFrom(String formattedString) { + return PROJECT_LOCATION_SECURITY_SETTINGS.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 (securitySettings != null) { + fieldMapBuilder.put("security_settings", securitySettings); + } + fieldValuesMap = fieldMapBuilder.build(); + } + } + } + return fieldValuesMap; + } + + public String getFieldValue(String fieldName) { + return getFieldValuesMap().get(fieldName); + } + + @Override + public String toString() { + return PROJECT_LOCATION_SECURITY_SETTINGS.instantiate( + "project", project, "location", location, "security_settings", securitySettings); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (o != null || getClass() == o.getClass()) { + SecuritySettingsName that = ((SecuritySettingsName) o); + return Objects.equals(this.project, that.project) + && Objects.equals(this.location, that.location) + && Objects.equals(this.securitySettings, that.securitySettings); + } + 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(securitySettings); + return h; + } + + /** Builder for projects/{project}/locations/{location}/securitySettings/{security_settings}. */ + public static class Builder { + private String project; + private String location; + private String securitySettings; + + protected Builder() {} + + public String getProject() { + return project; + } + + public String getLocation() { + return location; + } + + public String getSecuritySettings() { + return securitySettings; + } + + public Builder setProject(String project) { + this.project = project; + return this; + } + + public Builder setLocation(String location) { + this.location = location; + return this; + } + + public Builder setSecuritySettings(String securitySettings) { + this.securitySettings = securitySettings; + return this; + } + + private Builder(SecuritySettingsName securitySettingsName) { + project = securitySettingsName.project; + location = securitySettingsName.location; + securitySettings = securitySettingsName.securitySettings; + } + + public SecuritySettingsName build() { + return new SecuritySettingsName(this); + } + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsOrBuilder.java new file mode 100644 index 000000000..af48d7da7 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsOrBuilder.java @@ -0,0 +1,269 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface SecuritySettingsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.SecuritySettings) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings ID>`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. Resource name of the settings.
+   * Format: `projects/<Project ID>/locations/<Location
+   * ID>/securitySettings/<Security Settings ID>`.
+   * 
+ * + * string name = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for name. + */ + com.google.protobuf.ByteString getNameBytes(); + + /** + * + * + *
+   * Required. The human-readable name of the security settings, unique within the
+   * location.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The displayName. + */ + java.lang.String getDisplayName(); + /** + * + * + *
+   * Required. The human-readable name of the security settings, unique within the
+   * location.
+   * 
+ * + * string display_name = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The bytes for displayName. + */ + com.google.protobuf.ByteString getDisplayNameBytes(); + + /** + * + * + *
+   * Strategy that defines how we do redaction.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return The enum numeric value on the wire for redactionStrategy. + */ + int getRedactionStrategyValue(); + /** + * + * + *
+   * Strategy that defines how we do redaction.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy redaction_strategy = 3; + * + * + * @return The redactionStrategy. + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionStrategy getRedactionStrategy(); + + /** + * + * + *
+   * Defines on what data we apply redaction. Note that we don't
+   * redact data to which we don't have access, e.g., Stackdriver logs.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return The enum numeric value on the wire for redactionScope. + */ + int getRedactionScopeValue(); + /** + * + * + *
+   * Defines on what data we apply redaction. Note that we don't
+   * redact data to which we don't have access, e.g., Stackdriver logs.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope redaction_scope = 4; + * + * + * @return The redactionScope. + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.RedactionScope getRedactionScope(); + + /** + * + * + *
+   * DLP inspect template name. Use this template to define inspect base
+   * settings.
+   * If empty, we use the default DLP inspect config.
+   * The template name will have one of the following formats:
+   * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+   * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+   * 
+ * + * string inspect_template = 9; + * + * @return The inspectTemplate. + */ + java.lang.String getInspectTemplate(); + /** + * + * + *
+   * DLP inspect template name. Use this template to define inspect base
+   * settings.
+   * If empty, we use the default DLP inspect config.
+   * The template name will have one of the following formats:
+   * `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR
+   * `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`
+   * 
+ * + * string inspect_template = 9; + * + * @return The bytes for inspectTemplate. + */ + com.google.protobuf.ByteString getInspectTemplateBytes(); + + /** + * + * + *
+   * Retains the data for the specified number of days.
+   * User must Set a value lower than Dialogflow's default 30d TTL. Setting a
+   * value higher than that has no effect.
+   * A missing value or setting to 0 also means we use Dialogflow's default
+   * TTL.
+   * 
+ * + * int32 retention_window_days = 6; + * + * @return The retentionWindowDays. + */ + int getRetentionWindowDays(); + + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return A list containing the purgeDataTypes. + */ + java.util.List + getPurgeDataTypesList(); + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return The count of purgeDataTypes. + */ + int getPurgeDataTypesCount(); + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the element to return. + * @return The purgeDataTypes at the given index. + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType getPurgeDataTypes( + int index); + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @return A list containing the enum numeric values on the wire for purgeDataTypes. + */ + java.util.List getPurgeDataTypesValueList(); + /** + * + * + *
+   * List of types of data to remove when retention settings triggers purge.
+   * 
+ * + * + * repeated .google.cloud.dialogflow.cx.v3beta1.SecuritySettings.PurgeDataType purge_data_types = 8; + * + * + * @param index The index of the value to return. + * @return The enum numeric value on the wire of purgeDataTypes at the given index. + */ + int getPurgeDataTypesValue(int index); + + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.DataRetentionCase + getDataRetentionCase(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsProto.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsProto.java new file mode 100644 index 000000000..df4e2a754 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsProto.java @@ -0,0 +1,251 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public final class SecuritySettingsProto { + private SecuritySettingsProto() {} + + 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_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_fieldAccessorTable; + static final com.google.protobuf.Descriptors.Descriptor + internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_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/dialogflow/cx/v3beta1/sec" + + "urity_settings.proto\022\"google.cloud.dialo" + + "gflow.cx.v3beta1\032\034google/api/annotations" + + ".proto\032\027google/api/client.proto\032\037google/" + + "api/field_behavior.proto\032\031google/api/res" + + "ource.proto\032#google/longrunning/operatio" + + "ns.proto\032\033google/protobuf/empty.proto\032 g" + + "oogle/protobuf/field_mask.proto\"^\n\032GetSe" + + "curitySettingsRequest\022@\n\004name\030\001 \001(\tB2\340A\002" + + "\372A,\n*dialogflow.googleapis.com/SecurityS" + + "ettings\"\253\001\n\035UpdateSecuritySettingsReques" + + "t\022T\n\021security_settings\030\001 \001(\01324.google.cl" + + "oud.dialogflow.cx.v3beta1.SecuritySettin" + + "gsB\003\340A\002\0224\n\013update_mask\030\002 \001(\0132\032.google.pr" + + "otobuf.FieldMaskB\003\340A\002\"\210\001\n\033ListSecuritySe" + + "ttingsRequest\022B\n\006parent\030\001 \001(\tB2\340A\002\372A,\022*d" + + "ialogflow.googleapis.com/SecuritySetting" + + "s\022\021\n\tpage_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t" + + "\"\210\001\n\034ListSecuritySettingsResponse\022O\n\021sec" + + "urity_settings\030\001 \003(\01324.google.cloud.dial" + + "ogflow.cx.v3beta1.SecuritySettings\022\027\n\017ne" + + "xt_page_token\030\002 \001(\t\"\271\001\n\035CreateSecuritySe" + + "ttingsRequest\022B\n\006parent\030\001 \001(\tB2\340A\002\372A,\022*d" + + "ialogflow.googleapis.com/SecuritySetting" + + "s\022T\n\021security_settings\030\002 \001(\01324.google.cl" + + "oud.dialogflow.cx.v3beta1.SecuritySettin" + + "gsB\003\340A\002\"a\n\035DeleteSecuritySettingsRequest" + + "\022@\n\004name\030\001 \001(\tB2\340A\002\372A,\n*dialogflow.googl" + + "eapis.com/SecuritySettings\"\224\006\n\020SecurityS" + + "ettings\022\021\n\004name\030\001 \001(\tB\003\340A\002\022\031\n\014display_na" + + "me\030\002 \001(\tB\003\340A\002\022b\n\022redaction_strategy\030\003 \001(" + + "\0162F.google.cloud.dialogflow.cx.v3beta1.S" + + "ecuritySettings.RedactionStrategy\022\\\n\017red" + + "action_scope\030\004 \001(\0162C.google.cloud.dialog" + + "flow.cx.v3beta1.SecuritySettings.Redacti" + + "onScope\022\030\n\020inspect_template\030\t \001(\t\022\037\n\025ret" + + "ention_window_days\030\006 \001(\005H\000\022\\\n\020purge_data" + + "_types\030\010 \003(\0162B.google.cloud.dialogflow.c" + + "x.v3beta1.SecuritySettings.PurgeDataType" + + "\"P\n\021RedactionStrategy\022\"\n\036REDACTION_STRAT" + + "EGY_UNSPECIFIED\020\000\022\027\n\023REDACT_WITH_SERVICE" + + "\020\001\"J\n\016RedactionScope\022\037\n\033REDACTION_SCOPE_" + + "UNSPECIFIED\020\000\022\027\n\023REDACT_DISK_STORAGE\020\002\"H" + + "\n\rPurgeDataType\022\037\n\033PURGE_DATA_TYPE_UNSPE" + + "CIFIED\020\000\022\026\n\022DIALOGFLOW_HISTORY\020\001:}\352Az\n*d" + + "ialogflow.googleapis.com/SecuritySetting" + + "s\022Lprojects/{project}/locations/{locatio" + + "n}/securitySettings/{security_settings}B" + + "\020\n\016data_retention2\265\n\n\027SecuritySettingsSe" + + "rvice\022\202\002\n\026CreateSecuritySettings\022A.googl" + + "e.cloud.dialogflow.cx.v3beta1.CreateSecu" + + "ritySettingsRequest\0324.google.cloud.dialo" + + "gflow.cx.v3beta1.SecuritySettings\"o\202\323\344\223\002" + + "N\"9/v3beta1/{parent=projects/*/locations" + + "/*}/securitySettings:\021security_settings\332" + + "A\030parent,security_settings\022\325\001\n\023GetSecuri" + + "tySettings\022>.google.cloud.dialogflow.cx." + + "v3beta1.GetSecuritySettingsRequest\0324.goo" + + "gle.cloud.dialogflow.cx.v3beta1.Security" + + "Settings\"H\202\323\344\223\002;\0229/v3beta1/{name=project" + + "s/*/locations/*/securitySettings/*}\332A\004na" + + "me\022\232\002\n\026UpdateSecuritySettings\022A.google.c" + + "loud.dialogflow.cx.v3beta1.UpdateSecurit" + + "ySettingsRequest\0324.google.cloud.dialogfl" + + "ow.cx.v3beta1.SecuritySettings\"\206\001\202\323\344\223\002`2" + + "K/v3beta1/{security_settings.name=projec" + + "ts/*/locations/*/securitySettings/*}:\021se" + + "curity_settings\332A\035security_settings,upda" + + "te_mask\022\345\001\n\024ListSecuritySettings\022?.googl" + + "e.cloud.dialogflow.cx.v3beta1.ListSecuri" + + "tySettingsRequest\032@.google.cloud.dialogf" + + "low.cx.v3beta1.ListSecuritySettingsRespo" + + "nse\"J\202\323\344\223\002;\0229/v3beta1/{parent=projects/*" + + "/locations/*}/securitySettings\332A\006parent\022" + + "\275\001\n\026DeleteSecuritySettings\022A.google.clou" + + "d.dialogflow.cx.v3beta1.DeleteSecuritySe" + + "ttingsRequest\032\026.google.protobuf.Empty\"H\202" + + "\323\344\223\002;*9/v3beta1/{name=projects/*/locatio" + + "ns/*/securitySettings/*}\332A\004name\032x\312A\031dial" + + "ogflow.googleapis.com\322AYhttps://www.goog" + + "leapis.com/auth/cloud-platform,https://w" + + "ww.googleapis.com/auth/dialogflowB\264\001\n&co" + + "m.google.cloud.dialogflow.cx.v3beta1B\025Se" + + "curitySettingsProtoP\001ZDgoogle.golang.org" + + "/genproto/googleapis/cloud/dialogflow/cx" + + "/v3beta1;cx\370\001\001\242\002\002DF\252\002\"Google.Cloud.Dialo" + + "gflow.Cx.V3Beta1b\006proto3" + }; + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + com.google.longrunning.OperationsProto.getDescriptor(), + com.google.protobuf.EmptyProto.getDescriptor(), + com.google.protobuf.FieldMaskProto.getDescriptor(), + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_descriptor = + getDescriptor().getMessageTypes().get(0); + internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_GetSecuritySettingsRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_descriptor = + getDescriptor().getMessageTypes().get(1); + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_descriptor, + new java.lang.String[] { + "SecuritySettings", "UpdateMask", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_descriptor = + getDescriptor().getMessageTypes().get(2); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsRequest_descriptor, + new java.lang.String[] { + "Parent", "PageSize", "PageToken", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_descriptor = + getDescriptor().getMessageTypes().get(3); + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_ListSecuritySettingsResponse_descriptor, + new java.lang.String[] { + "SecuritySettings", "NextPageToken", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_descriptor = + getDescriptor().getMessageTypes().get(4); + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_CreateSecuritySettingsRequest_descriptor, + new java.lang.String[] { + "Parent", "SecuritySettings", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_descriptor = + getDescriptor().getMessageTypes().get(5); + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_DeleteSecuritySettingsRequest_descriptor, + new java.lang.String[] { + "Name", + }); + internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_descriptor = + getDescriptor().getMessageTypes().get(6); + internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_cloud_dialogflow_cx_v3beta1_SecuritySettings_descriptor, + new java.lang.String[] { + "Name", + "DisplayName", + "RedactionStrategy", + "RedactionScope", + "InspectTemplate", + "RetentionWindowDays", + "PurgeDataTypes", + "DataRetention", + }); + com.google.protobuf.ExtensionRegistry registry = + com.google.protobuf.ExtensionRegistry.newInstance(); + registry.add(com.google.api.ClientProto.defaultHost); + registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); + registry.add(com.google.api.AnnotationsProto.http); + registry.add(com.google.api.ClientProto.methodSignature); + registry.add(com.google.api.ClientProto.oauthScopes); + registry.add(com.google.api.ResourceProto.resource); + registry.add(com.google.api.ResourceProto.resourceReference); + 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.ResourceProto.getDescriptor(); + com.google.longrunning.OperationsProto.getDescriptor(); + com.google.protobuf.EmptyProto.getDescriptor(); + com.google.protobuf.FieldMaskProto.getDescriptor(); + } + + // @@protoc_insertion_point(outer_class_scope) +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequest.java new file mode 100644 index 000000000..0f926fe27 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequest.java @@ -0,0 +1,669 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.StartExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.StartExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest} + */ +public final class StartExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) + StartExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use StartExperimentRequest.newBuilder() to construct. + private StartExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private StartExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StartExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private StartExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.StartExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest 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.dialogflow.cx.v3beta1.StartExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest 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.dialogflow.cx.v3beta1.StartExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest 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.dialogflow.cx.v3beta1.StartExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest 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.dialogflow.cx.v3beta1.StartExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest 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.dialogflow.cx.v3beta1.StartExperimentRequest 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 request message for [Experiments.StartExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.StartExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StartExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.StartExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to start.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3beta1.StartExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StartExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new StartExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.StartExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequestOrBuilder.java new file mode 100644 index 000000000..ca5732d15 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface StartExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.StartExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. Resource name of the experiment to start.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequest.java new file mode 100644 index 000000000..8036a1c27 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequest.java @@ -0,0 +1,668 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.StopExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.StopExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest} + */ +public final class StopExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) + StopExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use StopExperimentRequest.newBuilder() to construct. + private StopExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private StopExperimentRequest() { + name_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StopExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private StopExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + name_ = s; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.Builder.class); + } + + public static final int NAME_FIELD_NUMBER = 1; + private volatile java.lang.Object name_; + /** + * + * + *
+   * Required. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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 (!getNameBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getNameBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.StopExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) obj; + + if (!getName().equals(other.getName())) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest 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.dialogflow.cx.v3beta1.StopExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest 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.dialogflow.cx.v3beta1.StopExperimentRequest parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest 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.dialogflow.cx.v3beta1.StopExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest 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.dialogflow.cx.v3beta1.StopExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest 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.dialogflow.cx.v3beta1.StopExperimentRequest 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 request message for [Experiments.StopExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.StopExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + name_ = ""; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_StopExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest(this); + result.name_ = name_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.StopExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest.getDefaultInstance()) + return this; + if (!other.getName().isEmpty()) { + name_ = other.name_; + onChanged(); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object name_ = ""; + /** + * + * + *
+     * Required. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+     * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. + */ + public Builder clearName() { + + name_ = getDefaultInstance().getName(); + onChanged(); + return this; + } + /** + * + * + *
+     * Required. Resource name of the experiment to stop.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/environments/<Environment ID>/experiments/<Experiment 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; + 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.dialogflow.cx.v3beta1.StopExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public StopExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new StopExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.StopExperimentRequest getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequestOrBuilder.java new file mode 100644 index 000000000..8aed1c386 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequestOrBuilder.java @@ -0,0 +1,58 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface StopExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.StopExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment ID>`.
+   * 
+ * + * + * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The name. + */ + java.lang.String getName(); + /** + * + * + *
+   * Required. Resource name of the experiment to stop.
+   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+   * ID>/environments/<Environment ID>/experiments/<Experiment 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/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateAgentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateAgentRequest.java index fae08853f..438235950 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateAgentRequest.java +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateAgentRequest.java @@ -22,7 +22,8 @@ * * *
- * The request message for [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent].
+ * The request message for
+ * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent].
  * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.UpdateAgentRequest} @@ -419,7 +420,8 @@ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.Build * * *
-   * The request message for [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent].
+   * The request message for
+   * [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent].
    * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.UpdateAgentRequest} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequest.java new file mode 100644 index 000000000..e056312ae --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequest.java @@ -0,0 +1,1050 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [Experiments.UpdateExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.UpdateExperiment].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest} + */ +public final class UpdateExperimentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) + UpdateExperimentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateExperimentRequest.newBuilder() to construct. + private UpdateExperimentRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateExperimentRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateExperimentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UpdateExperimentRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder subBuilder = null; + if (experiment_ != null) { + subBuilder = experiment_.toBuilder(); + } + experiment_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(experiment_); + experiment_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.protobuf.FieldMask.Builder subBuilder = null; + if (updateMask_ != null) { + subBuilder = updateMask_.toBuilder(); + } + updateMask_ = + input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateMask_); + updateMask_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.Builder.class); + } + + public static final int EXPERIMENT_FIELD_NUMBER = 1; + private com.google.cloud.dialogflow.cx.v3beta1.Experiment experiment_; + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + @java.lang.Override + public boolean hasExperiment() { + return experiment_ != null; + } + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment() { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance() + : experiment_; + } + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentOrBuilder() { + return getExperiment(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .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 updateMask_ != null; + } + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .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 mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + 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 (experiment_ != null) { + output.writeMessage(1, getExperiment()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (experiment_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getExperiment()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.UpdateExperimentRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) obj; + + if (hasExperiment() != other.hasExperiment()) return false; + if (hasExperiment()) { + if (!getExperiment().equals(other.getExperiment())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasExperiment()) { + hash = (37 * hash) + EXPERIMENT_FIELD_NUMBER; + hash = (53 * hash) + getExperiment().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest 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.dialogflow.cx.v3beta1.UpdateExperimentRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest 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.dialogflow.cx.v3beta1.UpdateExperimentRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest 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.dialogflow.cx.v3beta1.UpdateExperimentRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest 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.dialogflow.cx.v3beta1.UpdateExperimentRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest 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.dialogflow.cx.v3beta1.UpdateExperimentRequest 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 request message for [Experiments.UpdateExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.UpdateExperiment].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (experimentBuilder_ == null) { + experiment_ = null; + } else { + experiment_ = null; + experimentBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateExperimentRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest(this); + if (experimentBuilder_ == null) { + result.experiment_ = experiment_; + } else { + result.experiment_ = experimentBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.UpdateExperimentRequest) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest.getDefaultInstance()) + return this; + if (other.hasExperiment()) { + mergeExperiment(other.getExperiment()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.dialogflow.cx.v3beta1.Experiment experiment_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder> + experimentBuilder_; + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + public boolean hasExperiment() { + return experimentBuilder_ != null || experiment_ != null; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment() { + if (experimentBuilder_ == null) { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance() + : experiment_; + } else { + return experimentBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment(com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + experiment_ = value; + onChanged(); + } else { + experimentBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setExperiment( + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder builderForValue) { + if (experimentBuilder_ == null) { + experiment_ = builderForValue.build(); + onChanged(); + } else { + experimentBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeExperiment(com.google.cloud.dialogflow.cx.v3beta1.Experiment value) { + if (experimentBuilder_ == null) { + if (experiment_ != null) { + experiment_ = + com.google.cloud.dialogflow.cx.v3beta1.Experiment.newBuilder(experiment_) + .mergeFrom(value) + .buildPartial(); + } else { + experiment_ = value; + } + onChanged(); + } else { + experimentBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearExperiment() { + if (experimentBuilder_ == null) { + experiment_ = null; + onChanged(); + } else { + experiment_ = null; + experimentBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder getExperimentBuilder() { + + onChanged(); + return getExperimentFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentOrBuilder() { + if (experimentBuilder_ != null) { + return experimentBuilder_.getMessageOrBuilder(); + } else { + return experiment_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.Experiment.getDefaultInstance() + : experiment_; + } + } + /** + * + * + *
+     * Required. The experiment to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder> + getExperimentFieldBuilder() { + if (experimentBuilder_ == null) { + experimentBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.Experiment, + com.google.cloud.dialogflow.cx.v3beta1.Experiment.Builder, + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder>( + getExperiment(), getParentForChildren(), isClean()); + experiment_ = null; + } + return experimentBuilder_; + } + + 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 mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .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 mask to control which fields get updated.
+     * 
+ * + * .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; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .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(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The mask to control which fields get updated.
+     * 
+ * + * .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 mask to control which fields get updated.
+     * 
+ * + * .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.dialogflow.cx.v3beta1.UpdateExperimentRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateExperimentRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UpdateExperimentRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.UpdateExperimentRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequestOrBuilder.java new file mode 100644 index 000000000..15440bde7 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequestOrBuilder.java @@ -0,0 +1,104 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface UpdateExperimentRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.UpdateExperimentRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the experiment field is set. + */ + boolean hasExperiment(); + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The experiment. + */ + com.google.cloud.dialogflow.cx.v3beta1.Experiment getExperiment(); + /** + * + * + *
+   * Required. The experiment to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.Experiment experiment = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.ExperimentOrBuilder getExperimentOrBuilder(); + + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * Required. The mask to control which fields get updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequest.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequest.java new file mode 100644 index 000000000..9df220545 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequest.java @@ -0,0 +1,1084 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The request message for [SecuritySettingsService.UpdateSecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService.UpdateSecuritySettings].
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest} + */ +public final class UpdateSecuritySettingsRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) + UpdateSecuritySettingsRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use UpdateSecuritySettingsRequest.newBuilder() to construct. + private UpdateSecuritySettingsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private UpdateSecuritySettingsRequest() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new UpdateSecuritySettingsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private UpdateSecuritySettingsRequest( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder subBuilder = null; + if (securitySettings_ != null) { + subBuilder = securitySettings_.toBuilder(); + } + securitySettings_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(securitySettings_); + securitySettings_ = subBuilder.buildPartial(); + } + + break; + } + case 18: + { + com.google.protobuf.FieldMask.Builder subBuilder = null; + if (updateMask_ != null) { + subBuilder = updateMask_.toBuilder(); + } + updateMask_ = + input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateMask_); + updateMask_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest.Builder.class); + } + + public static final int SECURITY_SETTINGS_FIELD_NUMBER = 1; + private com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings securitySettings_; + /** + * + * + *
+   * Required. [SecuritySettings] object that contains values for each of the
+   * fields to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the securitySettings field is set. + */ + @java.lang.Override + public boolean hasSecuritySettings() { + return securitySettings_ != null; + } + /** + * + * + *
+   * Required. [SecuritySettings] object that contains values for each of the
+   * fields to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The securitySettings. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings() { + return securitySettings_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance() + : securitySettings_; + } + /** + * + * + *
+   * Required. [SecuritySettings] object that contains values for each of the
+   * fields to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder + getSecuritySettingsOrBuilder() { + return getSecuritySettings(); + } + + public static final int UPDATE_MASK_FIELD_NUMBER = 2; + private com.google.protobuf.FieldMask updateMask_; + /** + * + * + *
+   * Required. The mask to control which fields get updated. If the mask is not present,
+   * all fields will be updated.
+   * 
+ * + * .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 updateMask_ != null; + } + /** + * + * + *
+   * Required. The mask to control which fields get updated. If the mask is not present,
+   * all fields will be updated.
+   * 
+ * + * .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 mask to control which fields get updated. If the mask is not present,
+   * all fields will be updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + @java.lang.Override + public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { + return getUpdateMask(); + } + + 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 (securitySettings_ != null) { + output.writeMessage(1, getSecuritySettings()); + } + if (updateMask_ != null) { + output.writeMessage(2, getUpdateMask()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (securitySettings_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getSecuritySettings()); + } + if (updateMask_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest other = + (com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) obj; + + if (hasSecuritySettings() != other.hasSecuritySettings()) return false; + if (hasSecuritySettings()) { + if (!getSecuritySettings().equals(other.getSecuritySettings())) return false; + } + if (hasUpdateMask() != other.hasUpdateMask()) return false; + if (hasUpdateMask()) { + if (!getUpdateMask().equals(other.getUpdateMask())) return false; + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasSecuritySettings()) { + hash = (37 * hash) + SECURITY_SETTINGS_FIELD_NUMBER; + hash = (53 * hash) + getSecuritySettings().hashCode(); + } + if (hasUpdateMask()) { + hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; + hash = (53 * hash) + getUpdateMask().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + 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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest 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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest 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 request message for [SecuritySettingsService.UpdateSecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService.UpdateSecuritySettings].
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequestOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest.class, + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest.Builder.class); + } + + // Construct using + // com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (securitySettingsBuilder_ == null) { + securitySettings_ = null; + } else { + securitySettings_ = null; + securitySettingsBuilder_ = null; + } + if (updateMaskBuilder_ == null) { + updateMask_ = null; + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_UpdateSecuritySettingsRequest_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + .getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest build() { + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest result = + new com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest(this); + if (securitySettingsBuilder_ == null) { + result.securitySettings_ = securitySettings_; + } else { + result.securitySettings_ = securitySettingsBuilder_.build(); + } + if (updateMaskBuilder_ == null) { + result.updateMask_ = updateMask_; + } else { + result.updateMask_ = updateMaskBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) { + return mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + .getDefaultInstance()) return this; + if (other.hasSecuritySettings()) { + mergeSecuritySettings(other.getSecuritySettings()); + } + if (other.hasUpdateMask()) { + mergeUpdateMask(other.getUpdateMask()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings securitySettings_; + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + securitySettingsBuilder_; + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the securitySettings field is set. + */ + public boolean hasSecuritySettings() { + return securitySettingsBuilder_ != null || securitySettings_ != null; + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The securitySettings. + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings() { + if (securitySettingsBuilder_ == null) { + return securitySettings_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance() + : securitySettings_; + } else { + return securitySettingsBuilder_.getMessage(); + } + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + securitySettings_ = value; + onChanged(); + } else { + securitySettingsBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder setSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder builderForValue) { + if (securitySettingsBuilder_ == null) { + securitySettings_ = builderForValue.build(); + onChanged(); + } else { + securitySettingsBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeSecuritySettings( + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings value) { + if (securitySettingsBuilder_ == null) { + if (securitySettings_ != null) { + securitySettings_ = + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.newBuilder(securitySettings_) + .mergeFrom(value) + .buildPartial(); + } else { + securitySettings_ = value; + } + onChanged(); + } else { + securitySettingsBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearSecuritySettings() { + if (securitySettingsBuilder_ == null) { + securitySettings_ = null; + onChanged(); + } else { + securitySettings_ = null; + securitySettingsBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder + getSecuritySettingsBuilder() { + + onChanged(); + return getSecuritySettingsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder + getSecuritySettingsOrBuilder() { + if (securitySettingsBuilder_ != null) { + return securitySettingsBuilder_.getMessageOrBuilder(); + } else { + return securitySettings_ == null + ? com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.getDefaultInstance() + : securitySettings_; + } + } + /** + * + * + *
+     * Required. [SecuritySettings] object that contains values for each of the
+     * fields to update.
+     * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder> + getSecuritySettingsFieldBuilder() { + if (securitySettingsBuilder_ == null) { + securitySettingsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings.Builder, + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder>( + getSecuritySettings(), getParentForChildren(), isClean()); + securitySettings_ = null; + } + return securitySettingsBuilder_; + } + + 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 mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + public boolean hasUpdateMask() { + return updateMaskBuilder_ != null || updateMask_ != null; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .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 mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .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; + onChanged(); + } else { + updateMaskBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .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(); + onChanged(); + } else { + updateMaskBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { + if (updateMaskBuilder_ == null) { + if (updateMask_ != null) { + updateMask_ = + com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); + } else { + updateMask_ = value; + } + onChanged(); + } else { + updateMaskBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public Builder clearUpdateMask() { + if (updateMaskBuilder_ == null) { + updateMask_ = null; + onChanged(); + } else { + updateMask_ = null; + updateMaskBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Required. The mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { + + onChanged(); + return getUpdateMaskFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Required. The mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .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 mask to control which fields get updated. If the mask is not present,
+     * all fields will be updated.
+     * 
+ * + * .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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) + private static final com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public UpdateSecuritySettingsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new UpdateSecuritySettingsRequest(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequestOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequestOrBuilder.java new file mode 100644 index 000000000..44986e560 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequestOrBuilder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/security_settings.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface UpdateSecuritySettingsRequestOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.UpdateSecuritySettingsRequest) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * Required. [SecuritySettings] object that contains values for each of the
+   * fields to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the securitySettings field is set. + */ + boolean hasSecuritySettings(); + /** + * + * + *
+   * Required. [SecuritySettings] object that contains values for each of the
+   * fields to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The securitySettings. + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettings getSecuritySettings(); + /** + * + * + *
+   * Required. [SecuritySettings] object that contains values for each of the
+   * fields to update.
+   * 
+ * + * + * .google.cloud.dialogflow.cx.v3beta1.SecuritySettings security_settings = 1 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.cloud.dialogflow.cx.v3beta1.SecuritySettingsOrBuilder getSecuritySettingsOrBuilder(); + + /** + * + * + *
+   * Required. The mask to control which fields get updated. If the mask is not present,
+   * all fields will be updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return Whether the updateMask field is set. + */ + boolean hasUpdateMask(); + /** + * + * + *
+   * Required. The mask to control which fields get updated. If the mask is not present,
+   * all fields will be updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * + * @return The updateMask. + */ + com.google.protobuf.FieldMask getUpdateMask(); + /** + * + * + *
+   * Required. The mask to control which fields get updated. If the mask is not present,
+   * all fields will be updated.
+   * 
+ * + * .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + * + */ + com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistory.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistory.java new file mode 100644 index 000000000..77706d146 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistory.java @@ -0,0 +1,1118 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * The history of variants update.
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.VariantsHistory} + */ +public final class VariantsHistory extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.VariantsHistory) + VariantsHistoryOrBuilder { + private static final long serialVersionUID = 0L; + // Use VariantsHistory.newBuilder() to construct. + private VariantsHistory(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private VariantsHistory() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new VariantsHistory(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private VariantsHistory( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder subBuilder = null; + if (variantsCase_ == 1) { + subBuilder = + ((com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_) + .toBuilder(); + } + variants_ = + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.parser(), + extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom( + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_); + variants_ = subBuilder.buildPartial(); + } + variantsCase_ = 1; + break; + } + case 18: + { + com.google.protobuf.Timestamp.Builder subBuilder = null; + if (updateTime_ != null) { + subBuilder = updateTime_.toBuilder(); + } + updateTime_ = + input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(updateTime_); + updateTime_ = subBuilder.buildPartial(); + } + + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.class, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder.class); + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public enum VariantsCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + VERSION_VARIANTS(1), + VARIANTS_NOT_SET(0); + private final int value; + + private VariantsCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static VariantsCase valueOf(int value) { + return forNumber(value); + } + + public static VariantsCase forNumber(int value) { + switch (value) { + case 1: + return VERSION_VARIANTS; + case 0: + return VARIANTS_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public static final int VERSION_VARIANTS_FIELD_NUMBER = 1; + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 1; + } + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getVersionVariants() { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + + public static final int UPDATE_TIME_FIELD_NUMBER = 2; + private com.google.protobuf.Timestamp updateTime_; + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return Whether the updateTime field is set. + */ + @java.lang.Override + public boolean hasUpdateTime() { + return updateTime_ != null; + } + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return The updateTime. + */ + @java.lang.Override + public com.google.protobuf.Timestamp getUpdateTime() { + return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; + } + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + @java.lang.Override + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + return getUpdateTime(); + } + + 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 (variantsCase_ == 1) { + output.writeMessage(1, (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_); + } + if (updateTime_ != null) { + output.writeMessage(2, getUpdateTime()); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (variantsCase_ == 1) { + size += + com.google.protobuf.CodedOutputStream.computeMessageSize( + 1, (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_); + } + if (updateTime_ != null) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateTime()); + } + size += unknownFields.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.dialogflow.cx.v3beta1.VariantsHistory)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory other = + (com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory) obj; + + if (hasUpdateTime() != other.hasUpdateTime()) return false; + if (hasUpdateTime()) { + if (!getUpdateTime().equals(other.getUpdateTime())) return false; + } + if (!getVariantsCase().equals(other.getVariantsCase())) return false; + switch (variantsCase_) { + case 1: + if (!getVersionVariants().equals(other.getVersionVariants())) return false; + break; + case 0: + default: + } + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (hasUpdateTime()) { + hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; + hash = (53 * hash) + getUpdateTime().hashCode(); + } + switch (variantsCase_) { + case 1: + hash = (37 * hash) + VERSION_VARIANTS_FIELD_NUMBER; + hash = (53 * hash) + getVersionVariants().hashCode(); + break; + case 0: + default: + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory 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.dialogflow.cx.v3beta1.VariantsHistory parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory 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.dialogflow.cx.v3beta1.VariantsHistory parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory 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.dialogflow.cx.v3beta1.VariantsHistory parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory 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.dialogflow.cx.v3beta1.VariantsHistory parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory 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.dialogflow.cx.v3beta1.VariantsHistory 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 history of variants update.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.VariantsHistory} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.VariantsHistory) + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistoryOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.class, + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (updateTimeBuilder_ == null) { + updateTime_ = null; + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + variantsCase_ = 0; + variants_ = null; + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VariantsHistory_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory build() { + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory result = + new com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory(this); + if (variantsCase_ == 1) { + if (versionVariantsBuilder_ == null) { + result.variants_ = variants_; + } else { + result.variants_ = versionVariantsBuilder_.build(); + } + } + if (updateTimeBuilder_ == null) { + result.updateTime_ = updateTime_; + } else { + result.updateTime_ = updateTimeBuilder_.build(); + } + result.variantsCase_ = variantsCase_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.VariantsHistory) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory other) { + if (other == com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.getDefaultInstance()) + return this; + if (other.hasUpdateTime()) { + mergeUpdateTime(other.getUpdateTime()); + } + switch (other.getVariantsCase()) { + case VERSION_VARIANTS: + { + mergeVersionVariants(other.getVersionVariants()); + break; + } + case VARIANTS_NOT_SET: + { + break; + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int variantsCase_ = 0; + private java.lang.Object variants_; + + public VariantsCase getVariantsCase() { + return VariantsCase.forNumber(variantsCase_); + } + + public Builder clearVariants() { + variantsCase_ = 0; + variants_ = null; + onChanged(); + return this; + } + + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder> + versionVariantsBuilder_; + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + * + * @return Whether the versionVariants field is set. + */ + @java.lang.Override + public boolean hasVersionVariants() { + return variantsCase_ == 1; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + * + * @return The versionVariants. + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } else { + if (variantsCase_ == 1) { + return versionVariantsBuilder_.getMessage(); + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + public Builder setVersionVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + variants_ = value; + onChanged(); + } else { + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 1; + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + public Builder setVersionVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder builderForValue) { + if (versionVariantsBuilder_ == null) { + variants_ = builderForValue.build(); + onChanged(); + } else { + versionVariantsBuilder_.setMessage(builderForValue.build()); + } + variantsCase_ = 1; + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + public Builder mergeVersionVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants value) { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 1 + && variants_ + != com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance()) { + variants_ = + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.newBuilder( + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_) + .mergeFrom(value) + .buildPartial(); + } else { + variants_ = value; + } + onChanged(); + } else { + if (variantsCase_ == 1) { + versionVariantsBuilder_.mergeFrom(value); + } + versionVariantsBuilder_.setMessage(value); + } + variantsCase_ = 1; + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + public Builder clearVersionVariants() { + if (versionVariantsBuilder_ == null) { + if (variantsCase_ == 1) { + variantsCase_ = 0; + variants_ = null; + onChanged(); + } + } else { + if (variantsCase_ == 1) { + variantsCase_ = 0; + variants_ = null; + } + versionVariantsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder + getVersionVariantsBuilder() { + return getVersionVariantsFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder + getVersionVariantsOrBuilder() { + if ((variantsCase_ == 1) && (versionVariantsBuilder_ != null)) { + return versionVariantsBuilder_.getMessageOrBuilder(); + } else { + if (variantsCase_ == 1) { + return (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_; + } + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + } + /** + * + * + *
+     * The flow versions as the variants.
+     * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + private com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder> + getVersionVariantsFieldBuilder() { + if (versionVariantsBuilder_ == null) { + if (!(variantsCase_ == 1)) { + variants_ = com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + versionVariantsBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder>( + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) variants_, + getParentForChildren(), + isClean()); + variants_ = null; + } + variantsCase_ = 1; + onChanged(); + ; + return versionVariantsBuilder_; + } + + 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_; + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return Whether the updateTime field is set. + */ + public boolean hasUpdateTime() { + return updateTimeBuilder_ != null || updateTime_ != null; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @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(); + } + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + updateTime_ = value; + onChanged(); + } else { + updateTimeBuilder_.setMessage(value); + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { + if (updateTimeBuilder_ == null) { + updateTime_ = builderForValue.build(); + onChanged(); + } else { + updateTimeBuilder_.setMessage(builderForValue.build()); + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { + if (updateTimeBuilder_ == null) { + if (updateTime_ != null) { + updateTime_ = + com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); + } else { + updateTime_ = value; + } + onChanged(); + } else { + updateTimeBuilder_.mergeFrom(value); + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public Builder clearUpdateTime() { + if (updateTimeBuilder_ == null) { + updateTime_ = null; + onChanged(); + } else { + updateTime_ = null; + updateTimeBuilder_ = null; + } + + return this; + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { + + onChanged(); + return getUpdateTimeFieldBuilder().getBuilder(); + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { + if (updateTimeBuilder_ != null) { + return updateTimeBuilder_.getMessageOrBuilder(); + } else { + return updateTime_ == null + ? com.google.protobuf.Timestamp.getDefaultInstance() + : updateTime_; + } + } + /** + * + * + *
+     * Update time of the variants.
+     * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + 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_; + } + + @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.dialogflow.cx.v3beta1.VariantsHistory) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.VariantsHistory) + private static final com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VariantsHistory parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new VariantsHistory(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.VariantsHistory getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistoryOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistoryOrBuilder.java new file mode 100644 index 000000000..053593084 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistoryOrBuilder.java @@ -0,0 +1,97 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface VariantsHistoryOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.VariantsHistory) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + * + * @return Whether the versionVariants field is set. + */ + boolean hasVersionVariants(); + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + * + * @return The versionVariants. + */ + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getVersionVariants(); + /** + * + * + *
+   * The flow versions as the variants.
+   * 
+ * + * .google.cloud.dialogflow.cx.v3beta1.VersionVariants version_variants = 1; + */ + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder getVersionVariantsOrBuilder(); + + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return Whether the updateTime field is set. + */ + boolean hasUpdateTime(); + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + * + * @return The updateTime. + */ + com.google.protobuf.Timestamp getUpdateTime(); + /** + * + * + *
+   * Update time of the variants.
+   * 
+ * + * .google.protobuf.Timestamp update_time = 2; + */ + com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); + + public com.google.cloud.dialogflow.cx.v3beta1.VariantsHistory.VariantsCase getVariantsCase(); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariants.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariants.java new file mode 100644 index 000000000..2cf87f7bd --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariants.java @@ -0,0 +1,1882 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +/** + * + * + *
+ * A list of flow version variants.
+ * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.VersionVariants} + */ +public final class VersionVariants extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.VersionVariants) + VersionVariantsOrBuilder { + private static final long serialVersionUID = 0L; + // Use VersionVariants.newBuilder() to construct. + private VersionVariants(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private VersionVariants() { + variants_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new VersionVariants(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private VersionVariants( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + variants_ = + new java.util.ArrayList< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant>(); + mutable_bitField0_ |= 0x00000001; + } + variants_.add( + input.readMessage( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.parser(), + extensionRegistry)); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + if (((mutable_bitField0_ & 0x00000001) != 0)) { + variants_ = java.util.Collections.unmodifiableList(variants_); + } + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.class, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder.class); + } + + public interface VariantOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The version. + */ + java.lang.String getVersion(); + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + com.google.protobuf.ByteString getVersionBytes(); + + /** + * + * + *
+     * Percentage of the traffic which should be routed to this
+     * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+     * 
+ * + * float traffic_allocation = 2; + * + * @return The trafficAllocation. + */ + float getTrafficAllocation(); + + /** + * + * + *
+     * Whether the variant is for the control group.
+     * 
+ * + * bool is_control_group = 3; + * + * @return The isControlGroup. + */ + boolean getIsControlGroup(); + } + /** + * + * + *
+   * A single flow version with specified traffic allocation.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant} + */ + public static final class Variant extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) + VariantOrBuilder { + private static final long serialVersionUID = 0L; + // Use Variant.newBuilder() to construct. + private Variant(com.google.protobuf.GeneratedMessageV3.Builder builder) { + super(builder); + } + + private Variant() { + version_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Variant(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + private Variant( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + this(); + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + + version_ = s; + break; + } + case 21: + { + trafficAllocation_ = input.readFloat(); + break; + } + case 24: + { + isControlGroup_ = input.readBool(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.class, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder.class); + } + + public static final int VERSION_FIELD_NUMBER = 1; + private volatile java.lang.Object version_; + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The version. + */ + @java.lang.Override + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; + } else { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } + } + /** + * + * + *
+     * The name of the flow version.
+     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+     * ID>/flows/<Flow ID>/versions/<Version ID>`.
+     * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + @java.lang.Override + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + + public static final int TRAFFIC_ALLOCATION_FIELD_NUMBER = 2; + private float trafficAllocation_; + /** + * + * + *
+     * Percentage of the traffic which should be routed to this
+     * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+     * 
+ * + * float traffic_allocation = 2; + * + * @return The trafficAllocation. + */ + @java.lang.Override + public float getTrafficAllocation() { + return trafficAllocation_; + } + + public static final int IS_CONTROL_GROUP_FIELD_NUMBER = 3; + private boolean isControlGroup_; + /** + * + * + *
+     * Whether the variant is for the control group.
+     * 
+ * + * bool is_control_group = 3; + * + * @return The isControlGroup. + */ + @java.lang.Override + public boolean getIsControlGroup() { + return isControlGroup_; + } + + 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 (!getVersionBytes().isEmpty()) { + com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_); + } + if (trafficAllocation_ != 0F) { + output.writeFloat(2, trafficAllocation_); + } + if (isControlGroup_ != false) { + output.writeBool(3, isControlGroup_); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + if (!getVersionBytes().isEmpty()) { + size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_); + } + if (trafficAllocation_ != 0F) { + size += com.google.protobuf.CodedOutputStream.computeFloatSize(2, trafficAllocation_); + } + if (isControlGroup_ != false) { + size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, isControlGroup_); + } + size += unknownFields.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.dialogflow.cx.v3beta1.VersionVariants.Variant)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant other = + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) obj; + + if (!getVersion().equals(other.getVersion())) return false; + if (java.lang.Float.floatToIntBits(getTrafficAllocation()) + != java.lang.Float.floatToIntBits(other.getTrafficAllocation())) return false; + if (getIsControlGroup() != other.getIsControlGroup()) return false; + if (!unknownFields.equals(other.unknownFields)) 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) + VERSION_FIELD_NUMBER; + hash = (53 * hash) + getVersion().hashCode(); + hash = (37 * hash) + TRAFFIC_ALLOCATION_FIELD_NUMBER; + hash = (53 * hash) + java.lang.Float.floatToIntBits(getTrafficAllocation()); + hash = (37 * hash) + IS_CONTROL_GROUP_FIELD_NUMBER; + hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getIsControlGroup()); + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant 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.dialogflow.cx.v3beta1.VersionVariants.Variant parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant 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.dialogflow.cx.v3beta1.VersionVariants.Variant parseFrom( + byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant 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.dialogflow.cx.v3beta1.VersionVariants.Variant parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant 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.dialogflow.cx.v3beta1.VersionVariants.Variant parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant 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.dialogflow.cx.v3beta1.VersionVariants.Variant 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 single flow version with specified traffic allocation.
+     * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant} + */ + public static final class Builder + extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.class, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} + } + + @java.lang.Override + public Builder clear() { + super.clear(); + version_ = ""; + + trafficAllocation_ = 0F; + + isControlGroup_ = false; + + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_Variant_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant + getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant build() { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant result = + new com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant(this); + result.version_ = version_; + result.trafficAllocation_ = trafficAllocation_; + result.isControlGroup_ = isControlGroup_; + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.VersionVariants.Variant) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant other) { + if (other + == com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.getDefaultInstance()) + return this; + if (!other.getVersion().isEmpty()) { + version_ = other.version_; + onChanged(); + } + if (other.getTrafficAllocation() != 0F) { + setTrafficAllocation(other.getTrafficAllocation()); + } + if (other.getIsControlGroup() != false) { + setIsControlGroup(other.getIsControlGroup()); + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) + e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private java.lang.Object version_ = ""; + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @return The version. + */ + public java.lang.String getVersion() { + java.lang.Object ref = version_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); + version_ = s; + return s; + } else { + return (java.lang.String) ref; + } + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @return The bytes for version. + */ + public com.google.protobuf.ByteString getVersionBytes() { + java.lang.Object ref = version_; + if (ref instanceof String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); + version_ = b; + return b; + } else { + return (com.google.protobuf.ByteString) ref; + } + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @param value The version to set. + * @return This builder for chaining. + */ + public Builder setVersion(java.lang.String value) { + if (value == null) { + throw new NullPointerException(); + } + + version_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @return This builder for chaining. + */ + public Builder clearVersion() { + + version_ = getDefaultInstance().getVersion(); + onChanged(); + return this; + } + /** + * + * + *
+       * The name of the flow version.
+       * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
+       * ID>/flows/<Flow ID>/versions/<Version ID>`.
+       * 
+ * + * string version = 1; + * + * @param value The bytes for version to set. + * @return This builder for chaining. + */ + public Builder setVersionBytes(com.google.protobuf.ByteString value) { + if (value == null) { + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + + version_ = value; + onChanged(); + return this; + } + + private float trafficAllocation_; + /** + * + * + *
+       * Percentage of the traffic which should be routed to this
+       * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+       * 
+ * + * float traffic_allocation = 2; + * + * @return The trafficAllocation. + */ + @java.lang.Override + public float getTrafficAllocation() { + return trafficAllocation_; + } + /** + * + * + *
+       * Percentage of the traffic which should be routed to this
+       * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+       * 
+ * + * float traffic_allocation = 2; + * + * @param value The trafficAllocation to set. + * @return This builder for chaining. + */ + public Builder setTrafficAllocation(float value) { + + trafficAllocation_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Percentage of the traffic which should be routed to this
+       * version of flow. Traffic allocation for a single flow must sum up to 1.0.
+       * 
+ * + * float traffic_allocation = 2; + * + * @return This builder for chaining. + */ + public Builder clearTrafficAllocation() { + + trafficAllocation_ = 0F; + onChanged(); + return this; + } + + private boolean isControlGroup_; + /** + * + * + *
+       * Whether the variant is for the control group.
+       * 
+ * + * bool is_control_group = 3; + * + * @return The isControlGroup. + */ + @java.lang.Override + public boolean getIsControlGroup() { + return isControlGroup_; + } + /** + * + * + *
+       * Whether the variant is for the control group.
+       * 
+ * + * bool is_control_group = 3; + * + * @param value The isControlGroup to set. + * @return This builder for chaining. + */ + public Builder setIsControlGroup(boolean value) { + + isControlGroup_ = value; + onChanged(); + return this; + } + /** + * + * + *
+       * Whether the variant is for the control group.
+       * 
+ * + * bool is_control_group = 3; + * + * @return This builder for chaining. + */ + public Builder clearIsControlGroup() { + + isControlGroup_ = 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.dialogflow.cx.v3beta1.VersionVariants.Variant) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant) + private static final com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant + DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant + getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Variant parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Variant(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.VersionVariants.Variant + getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } + } + + public static final int VARIANTS_FIELD_NUMBER = 1; + private java.util.List variants_; + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public java.util.List + getVariantsList() { + return variants_; + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder> + getVariantsOrBuilderList() { + return variants_; + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public int getVariantsCount() { + return variants_.size(); + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant getVariants(int index) { + return variants_.get(index); + } + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder + getVariantsOrBuilder(int index) { + return variants_.get(index); + } + + private byte memoizedIsInitialized = -1; + + @java.lang.Override + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized == 1) return true; + if (isInitialized == 0) return false; + + memoizedIsInitialized = 1; + return true; + } + + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + for (int i = 0; i < variants_.size(); i++) { + output.writeMessage(1, variants_.get(i)); + } + unknownFields.writeTo(output); + } + + @java.lang.Override + public int getSerializedSize() { + int size = memoizedSize; + if (size != -1) return size; + + size = 0; + for (int i = 0; i < variants_.size(); i++) { + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, variants_.get(i)); + } + size += unknownFields.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.dialogflow.cx.v3beta1.VersionVariants)) { + return super.equals(obj); + } + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants other = + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) obj; + + if (!getVariantsList().equals(other.getVariantsList())) return false; + if (!unknownFields.equals(other.unknownFields)) return false; + return true; + } + + @java.lang.Override + public int hashCode() { + if (memoizedHashCode != 0) { + return memoizedHashCode; + } + int hash = 41; + hash = (19 * hash) + getDescriptor().hashCode(); + if (getVariantsCount() > 0) { + hash = (37 * hash) + VARIANTS_FIELD_NUMBER; + hash = (53 * hash) + getVariantsList().hashCode(); + } + hash = (29 * hash) + unknownFields.hashCode(); + memoizedHashCode = hash; + return hash; + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants parseFrom( + java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants 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.dialogflow.cx.v3beta1.VersionVariants parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants 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.dialogflow.cx.v3beta1.VersionVariants parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants parseFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants 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.dialogflow.cx.v3beta1.VersionVariants parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants 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.dialogflow.cx.v3beta1.VersionVariants parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants 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.dialogflow.cx.v3beta1.VersionVariants 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 list of flow version variants.
+   * 
+ * + * Protobuf type {@code google.cloud.dialogflow.cx.v3beta1.VersionVariants} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements + // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3beta1.VersionVariants) + com.google.cloud.dialogflow.cx.v3beta1.VersionVariantsOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.class, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Builder.class); + } + + // Construct using com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { + getVariantsFieldBuilder(); + } + } + + @java.lang.Override + public Builder clear() { + super.clear(); + if (variantsBuilder_ == null) { + variants_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + } else { + variantsBuilder_.clear(); + } + return this; + } + + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.cloud.dialogflow.cx.v3beta1.ExperimentProto + .internal_static_google_cloud_dialogflow_cx_v3beta1_VersionVariants_descriptor; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getDefaultInstanceForType() { + return com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance(); + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants build() { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + @java.lang.Override + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants buildPartial() { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants result = + new com.google.cloud.dialogflow.cx.v3beta1.VersionVariants(this); + int from_bitField0_ = bitField0_; + if (variantsBuilder_ == null) { + if (((bitField0_ & 0x00000001) != 0)) { + variants_ = java.util.Collections.unmodifiableList(variants_); + bitField0_ = (bitField0_ & ~0x00000001); + } + result.variants_ = variants_; + } else { + result.variants_ = variantsBuilder_.build(); + } + onBuilt(); + return result; + } + + @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.dialogflow.cx.v3beta1.VersionVariants) { + return mergeFrom((com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3beta1.VersionVariants other) { + if (other == com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.getDefaultInstance()) + return this; + if (variantsBuilder_ == null) { + if (!other.variants_.isEmpty()) { + if (variants_.isEmpty()) { + variants_ = other.variants_; + bitField0_ = (bitField0_ & ~0x00000001); + } else { + ensureVariantsIsMutable(); + variants_.addAll(other.variants_); + } + onChanged(); + } + } else { + if (!other.variants_.isEmpty()) { + if (variantsBuilder_.isEmpty()) { + variantsBuilder_.dispose(); + variantsBuilder_ = null; + variants_ = other.variants_; + bitField0_ = (bitField0_ & ~0x00000001); + variantsBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getVariantsFieldBuilder() + : null; + } else { + variantsBuilder_.addAllMessages(other.variants_); + } + } + } + this.mergeUnknownFields(other.unknownFields); + 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 { + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = + (com.google.cloud.dialogflow.cx.v3beta1.VersionVariants) e.getUnfinishedMessage(); + throw e.unwrapIOException(); + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + + private int bitField0_; + + private java.util.List + variants_ = java.util.Collections.emptyList(); + + private void ensureVariantsIsMutable() { + if (!((bitField0_ & 0x00000001) != 0)) { + variants_ = + new java.util.ArrayList( + variants_); + bitField0_ |= 0x00000001; + } + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder> + variantsBuilder_; + + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public java.util.List + getVariantsList() { + if (variantsBuilder_ == null) { + return java.util.Collections.unmodifiableList(variants_); + } else { + return variantsBuilder_.getMessageList(); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public int getVariantsCount() { + if (variantsBuilder_ == null) { + return variants_.size(); + } else { + return variantsBuilder_.getCount(); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant getVariants(int index) { + if (variantsBuilder_ == null) { + return variants_.get(index); + } else { + return variantsBuilder_.getMessage(index); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder setVariants( + int index, com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant value) { + if (variantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsIsMutable(); + variants_.set(index, value); + onChanged(); + } else { + variantsBuilder_.setMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder setVariants( + int index, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder builderForValue) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.set(index, builderForValue.build()); + onChanged(); + } else { + variantsBuilder_.setMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder addVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant value) { + if (variantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsIsMutable(); + variants_.add(value); + onChanged(); + } else { + variantsBuilder_.addMessage(value); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder addVariants( + int index, com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant value) { + if (variantsBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + ensureVariantsIsMutable(); + variants_.add(index, value); + onChanged(); + } else { + variantsBuilder_.addMessage(index, value); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder addVariants( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder builderForValue) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.add(builderForValue.build()); + onChanged(); + } else { + variantsBuilder_.addMessage(builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder addVariants( + int index, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder builderForValue) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.add(index, builderForValue.build()); + onChanged(); + } else { + variantsBuilder_.addMessage(index, builderForValue.build()); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder addAllVariants( + java.lang.Iterable + values) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, variants_); + onChanged(); + } else { + variantsBuilder_.addAllMessages(values); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder clearVariants() { + if (variantsBuilder_ == null) { + variants_ = java.util.Collections.emptyList(); + bitField0_ = (bitField0_ & ~0x00000001); + onChanged(); + } else { + variantsBuilder_.clear(); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public Builder removeVariants(int index) { + if (variantsBuilder_ == null) { + ensureVariantsIsMutable(); + variants_.remove(index); + onChanged(); + } else { + variantsBuilder_.remove(index); + } + return this; + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder + getVariantsBuilder(int index) { + return getVariantsFieldBuilder().getBuilder(index); + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder + getVariantsOrBuilder(int index) { + if (variantsBuilder_ == null) { + return variants_.get(index); + } else { + return variantsBuilder_.getMessageOrBuilder(index); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public java.util.List< + ? extends com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder> + getVariantsOrBuilderList() { + if (variantsBuilder_ != null) { + return variantsBuilder_.getMessageOrBuilderList(); + } else { + return java.util.Collections.unmodifiableList(variants_); + } + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder + addVariantsBuilder() { + return getVariantsFieldBuilder() + .addBuilder( + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.getDefaultInstance()); + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder + addVariantsBuilder(int index) { + return getVariantsFieldBuilder() + .addBuilder( + index, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.getDefaultInstance()); + } + /** + * + * + *
+     * A list of flow version variants.
+     * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + * + */ + public java.util.List + getVariantsBuilderList() { + return getVariantsFieldBuilder().getBuilderList(); + } + + private com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder> + getVariantsFieldBuilder() { + if (variantsBuilder_ == null) { + variantsBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant.Builder, + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder>( + variants_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); + variants_ = null; + } + return variantsBuilder_; + } + + @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.dialogflow.cx.v3beta1.VersionVariants) + } + + // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3beta1.VersionVariants) + private static final com.google.cloud.dialogflow.cx.v3beta1.VersionVariants DEFAULT_INSTANCE; + + static { + DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3beta1.VersionVariants(); + } + + public static com.google.cloud.dialogflow.cx.v3beta1.VersionVariants getDefaultInstance() { + return DEFAULT_INSTANCE; + } + + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public VersionVariants parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new VersionVariants(input, extensionRegistry); + } + }; + + 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.dialogflow.cx.v3beta1.VersionVariants getDefaultInstanceForType() { + return DEFAULT_INSTANCE; + } +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariantsOrBuilder.java b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariantsOrBuilder.java new file mode 100644 index 000000000..a76704633 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariantsOrBuilder.java @@ -0,0 +1,78 @@ +/* + * Copyright 2020 Google LLC + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 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/dialogflow/cx/v3beta1/experiment.proto + +package com.google.cloud.dialogflow.cx.v3beta1; + +public interface VersionVariantsOrBuilder + extends + // @@protoc_insertion_point(interface_extends:google.cloud.dialogflow.cx.v3beta1.VersionVariants) + com.google.protobuf.MessageOrBuilder { + + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + java.util.List getVariantsList(); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant getVariants(int index); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + int getVariantsCount(); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + java.util.List + getVariantsOrBuilderList(); + /** + * + * + *
+   * A list of flow version variants.
+   * 
+ * + * repeated .google.cloud.dialogflow.cx.v3beta1.VersionVariants.Variant variants = 1; + */ + com.google.cloud.dialogflow.cx.v3beta1.VersionVariants.VariantOrBuilder getVariantsOrBuilder( + int index); +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/agent.proto b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/agent.proto index 473475d6b..ba80999fd 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/agent.proto +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/agent.proto @@ -21,6 +21,7 @@ import "google/api/client.proto"; import "google/api/field_behavior.proto"; import "google/api/resource.proto"; import "google/cloud/dialogflow/cx/v3beta1/flow.proto"; +import "google/cloud/dialogflow/cx/v3beta1/security_settings.proto"; import "google/longrunning/operations.proto"; import "google/protobuf/empty.proto"; import "google/protobuf/field_mask.proto"; @@ -121,9 +122,13 @@ message SpeechToTextSettings { // in your app, product, or service to determine user intent and respond to the // user in a natural way. // -// After you create an agent, you can add [Intents][google.cloud.dialogflow.cx.v3beta1.Intent], -// [Entity Types][google.cloud.dialogflow.cx.v3beta1.EntityType], [Flows][google.cloud.dialogflow.cx.v3beta1.Flow], [Fulfillments][google.cloud.dialogflow.cx.v3beta1.Fulfillment], -// [Webhooks][google.cloud.dialogflow.cx.v3beta1.Webhook], and so on to manage the conversation flows.. +// After you create an agent, you can add +// [Intents][google.cloud.dialogflow.cx.v3beta1.Intent], [Entity +// Types][google.cloud.dialogflow.cx.v3beta1.EntityType], +// [Flows][google.cloud.dialogflow.cx.v3beta1.Flow], +// [Fulfillments][google.cloud.dialogflow.cx.v3beta1.Fulfillment], +// [Webhooks][google.cloud.dialogflow.cx.v3beta1.Webhook], and so on to manage +// the conversation flows.. message Agent { option (google.api.resource) = { type: "dialogflow.googleapis.com/Agent" @@ -131,7 +136,10 @@ message Agent { }; // The unique identifier of the agent. - // Required for the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent] + // Required for the + // [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + // method. + // [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent] // populates the name automatically. // Format: `projects//locations//agents/`. string name = 1; @@ -143,7 +151,9 @@ message Agent { // See [Language // Support](https://cloud.google.com/dialogflow/docs/reference/language) // for a list of the currently supported language codes. - // This field cannot be set by the [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] method. + // This field cannot be set by the + // [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent] + // method. string default_language_code = 3 [(google.api.field_behavior) = IMMUTABLE]; // Required. The time zone of the agent from the [time zone @@ -164,16 +174,13 @@ message Agent { // Speech recognition related settings. SpeechToTextSettings speech_to_text_settings = 13; - // Immutable. Name of the start flow in this agent. A start flow will be automatically - // created when the agent is created, and can only be deleted by deleting the - // agent. - // Format: `projects//locations//agents//flows/`. + // Immutable. Name of the start flow in this agent. A start flow will be + // automatically created when the agent is created, and can only be deleted by + // deleting the agent. Format: `projects//locations//agents//flows/`. string start_flow = 16 [ (google.api.field_behavior) = IMMUTABLE, - (google.api.resource_reference) = { - type: "dialogflow.googleapis.com/Flow" - } + (google.api.resource_reference) = { type: "dialogflow.googleapis.com/Flow" } ]; // Indicates if stackdriver logging is enabled for the agent. @@ -184,7 +191,8 @@ message Agent { bool enable_spell_correction = 20; } -// The request message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents]. +// The request message for +// [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents]. message ListAgentsRequest { // Required. The location to list all agents for. // Format: `projects//locations/`. @@ -203,7 +211,8 @@ message ListAgentsRequest { string page_token = 3; } -// The response message for [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents]. +// The response message for +// [Agents.ListAgents][google.cloud.dialogflow.cx.v3beta1.Agents.ListAgents]. message ListAgentsResponse { // The list of agents. There will be a maximum number of items returned based // on the page_size field in the request. @@ -214,7 +223,8 @@ message ListAgentsResponse { string next_page_token = 2; } -// The request message for [Agents.GetAgent][google.cloud.dialogflow.cx.v3beta1.Agents.GetAgent]. +// The request message for +// [Agents.GetAgent][google.cloud.dialogflow.cx.v3beta1.Agents.GetAgent]. message GetAgentRequest { // Required. The name of the agent. // Format: `projects//locations//agents/`. @@ -226,7 +236,8 @@ message GetAgentRequest { ]; } -// The request message for [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]. +// The request message for +// [Agents.CreateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.CreateAgent]. message CreateAgentRequest { // Required. The location to create a agent for. // Format: `projects//locations/`. @@ -241,7 +252,8 @@ message CreateAgentRequest { Agent agent = 2 [(google.api.field_behavior) = REQUIRED]; } -// The request message for [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]. +// The request message for +// [Agents.UpdateAgent][google.cloud.dialogflow.cx.v3beta1.Agents.UpdateAgent]. message UpdateAgentRequest { // Required. The agent to update. Agent agent = 1 [(google.api.field_behavior) = REQUIRED]; @@ -251,7 +263,8 @@ message UpdateAgentRequest { google.protobuf.FieldMask update_mask = 2; } -// The request message for [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3beta1.Agents.DeleteAgent]. +// The request message for +// [Agents.DeleteAgent][google.cloud.dialogflow.cx.v3beta1.Agents.DeleteAgent]. message DeleteAgentRequest { // Required. The name of the agent to delete. // Format: `projects//locations//agents/`. @@ -263,7 +276,8 @@ message DeleteAgentRequest { ]; } -// The request message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent]. +// The request message for +// [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent]. message ExportAgentRequest { // Required. The name of the agent to export. // Format: `projects//locations//agents/`. @@ -274,19 +288,21 @@ message ExportAgentRequest { } ]; - // Optional. The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to - // export the agent to. The format of this URI must be - // `gs:///`. - // If left unspecified, the serialized agent is returned inline. + // Optional. The [Google Cloud + // Storage](https://cloud.google.com/storage/docs/) URI to export the agent + // to. The format of this URI must be `gs:///`. If + // left unspecified, the serialized agent is returned inline. string agent_uri = 2 [(google.api.field_behavior) = OPTIONAL]; } -// The response message for [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent]. +// The response message for +// [Agents.ExportAgent][google.cloud.dialogflow.cx.v3beta1.Agents.ExportAgent]. message ExportAgentResponse { // The exported agent. oneof agent { // The URI to a file containing the exported agent. This field is populated - // only if `agent_uri` is specified in [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest]. + // only if `agent_uri` is specified in + // [ExportAgentRequest][google.cloud.dialogflow.cx.v3beta1.ExportAgentRequest]. string agent_uri = 1; // Uncompressed raw byte content for agent. @@ -294,7 +310,8 @@ message ExportAgentResponse { } } -// The request message for [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3beta1.Agents.RestoreAgent]. +// The request message for +// [Agents.RestoreAgent][google.cloud.dialogflow.cx.v3beta1.Agents.RestoreAgent]. message RestoreAgentRequest { // Required. The name of the agent to restore into. // Format: `projects//locations//agents/`. diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/audio_config.proto b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/audio_config.proto index e28a50da9..c0043a529 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/audio_config.proto +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/audio_config.proto @@ -29,31 +29,6 @@ option java_outer_classname = "AudioConfigProto"; option java_package = "com.google.cloud.dialogflow.cx.v3beta1"; option objc_class_prefix = "DF"; -// Information for a word recognized by the speech recognizer. -message SpeechWordInfo { - // The word this info is for. - string word = 3; - - // Time offset relative to the beginning of the audio that corresponds to the - // start of the spoken word. This is an experimental feature and the accuracy - // of the time offset can vary. - google.protobuf.Duration start_offset = 1; - - // Time offset relative to the beginning of the audio that corresponds to the - // end of the spoken word. This is an experimental feature and the accuracy of - // the time offset can vary. - google.protobuf.Duration end_offset = 2; - - // The Speech confidence between 0.0 and 1.0 for this word. A higher number - // indicates an estimated greater likelihood that the recognized word is - // correct. The default of 0.0 is a sentinel value indicating that confidence - // was not set. - // - // This field is not guaranteed to be fully stable over time for the same - // audio input. Users should also not rely on it to always be provided. - float confidence = 4; -} - // Audio encoding of the audio content sent in the conversational query request. // Refer to the // [Cloud Speech API @@ -103,6 +78,31 @@ enum AudioEncoding { AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE = 7; } +// Information for a word recognized by the speech recognizer. +message SpeechWordInfo { + // The word this info is for. + string word = 3; + + // Time offset relative to the beginning of the audio that corresponds to the + // start of the spoken word. This is an experimental feature and the accuracy + // of the time offset can vary. + google.protobuf.Duration start_offset = 1; + + // Time offset relative to the beginning of the audio that corresponds to the + // end of the spoken word. This is an experimental feature and the accuracy of + // the time offset can vary. + google.protobuf.Duration end_offset = 2; + + // The Speech confidence between 0.0 and 1.0 for this word. A higher number + // indicates an estimated greater likelihood that the recognized word is + // correct. The default of 0.0 is a sentinel value indicating that confidence + // was not set. + // + // This field is not guaranteed to be fully stable over time for the same + // audio input. Users should also not rely on it to always be provided. + float confidence = 4; +} + // Instructs the speech recognizer on how to process the audio content. message InputAudioConfig { // Required. Audio encoding of the audio content to process. diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/experiment.proto b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/experiment.proto new file mode 100644 index 000000000..491ce2177 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/experiment.proto @@ -0,0 +1,415 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.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.dialogflow.cx.v3beta1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/protobuf/duration.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; +import "google/protobuf/timestamp.proto"; + +option cc_enable_arenas = true; +option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3Beta1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3beta1;cx"; +option java_multiple_files = true; +option java_outer_classname = "ExperimentProto"; +option java_package = "com.google.cloud.dialogflow.cx.v3beta1"; +option objc_class_prefix = "DF"; + +// Service for managing [Experiments][google.cloud.dialogflow.cx.v3beta1.Experiment]. +service Experiments { + option (google.api.default_host) = "dialogflow.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform," + "https://www.googleapis.com/auth/dialogflow"; + + // Returns the list of all experiments in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + rpc ListExperiments(ListExperimentsRequest) returns (ListExperimentsResponse) { + option (google.api.http) = { + get: "/v3beta1/{parent=projects/*/locations/*/agents/*/environments/*}/experiments" + }; + option (google.api.method_signature) = "parent"; + } + + // Retrieves the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + rpc GetExperiment(GetExperimentRequest) returns (Experiment) { + option (google.api.http) = { + get: "/v3beta1/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Creates an [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment] in the specified [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + rpc CreateExperiment(CreateExperimentRequest) returns (Experiment) { + option (google.api.http) = { + post: "/v3beta1/{parent=projects/*/locations/*/agents/*/environments/*}/experiments" + body: "experiment" + }; + option (google.api.method_signature) = "parent,experiment"; + } + + // Updates the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + rpc UpdateExperiment(UpdateExperimentRequest) returns (Experiment) { + option (google.api.http) = { + patch: "/v3beta1/{experiment.name=projects/*/locations/*/agents/*/environments/*/experiments/*}" + body: "experiment" + }; + option (google.api.method_signature) = "experiment,update_mask"; + } + + // Deletes the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. + rpc DeleteExperiment(DeleteExperimentRequest) returns (google.protobuf.Empty) { + option (google.api.http) = { + delete: "/v3beta1/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Starts the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of + // experiment from PENDING to RUNNING. + rpc StartExperiment(StartExperimentRequest) returns (Experiment) { + option (google.api.http) = { + post: "/v3beta1/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}:start" + body: "*" + }; + option (google.api.method_signature) = "name"; + } + + // Stops the specified [Experiment][google.cloud.dialogflow.cx.v3beta1.Experiment]. This rpc only changes the state of + // experiment from RUNNING to DONE. + rpc StopExperiment(StopExperimentRequest) returns (Experiment) { + option (google.api.http) = { + post: "/v3beta1/{name=projects/*/locations/*/agents/*/environments/*/experiments/*}:stop" + body: "*" + }; + option (google.api.method_signature) = "name"; + } +} + +// Represents an experiment in an environment. +// Next ID: 13 +message Experiment { + option (google.api.resource) = { + type: "dialogflow.googleapis.com/Experiment" + pattern: "projects/{project}/locations/{location}/agents/{agent}/environments/{environment}/experiments/{experiment}" + }; + + // Definition of the experiment. + // Next ID: 3 + message Definition { + // The condition defines which subset of sessions are selected for + // this experiment. If not specified, all sessions are eligible. E.g. + // "query_input.language_code=en" See the [conditions + // reference](https://cloud.google.com/dialogflow/cx/docs/reference/condition). + string condition = 1; + + // The variants of the experiment. We currently only support single variant + // experiment. + oneof variants { + // The flow versions as the variants of this experiment. + VersionVariants version_variants = 2; + } + } + + // The inference result which includes an objective metric to optimize and the + // confidence interval. + message Result { + // A confidence interval is a range of possible values for the experiment + // objective you are trying to measure. + message ConfidenceInterval { + // The confidence level used to construct the interval, i.e. there is X% + // chance that the true value is within this interval. + double confidence_level = 1; + + // The percent change between an experiment metric's value and the value + // for its control. + double ratio = 2; + + // Lower bound of the interval. + double lower_bound = 3; + + // Upper bound of the interval. + double upper_bound = 4; + } + + // Metric and corresponding confidence intervals. + message Metric { + // The type of the metric. + MetricType type = 1; + + // The actual value of the metric. + oneof value { + // Ratio value of a metric. + double ratio = 2; + } + + // The probability that the treatment is better than all other treatments + // in the experiment + ConfidenceInterval confidence_interval = 3; + } + + // Version variant and associated metrics. + message VersionMetrics { + // The name of the flow [Version][google.cloud.dialogflow.cx.v3beta1.Version]. + // Format: `projects//locations//agents//flows//versions/`. + string version = 1 [(google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Version" + }]; + + // The metrics and corresponding confidence intervals in the inference + // result. + repeated Metric metrics = 2; + + // Number of sessions that were allocated to this version. + int32 session_count = 3; + } + + // Types of metric for Dialogflow experiment. + enum MetricType { + // Metric unspecified. + METRIC_UNSPECIFIED = 0; + + // Percentage of contained sessions without user calling back in 24 hours. + CONTAINED_SESSION_NO_CALLBACK_RATE = 1; + + // Percentage of sessions that were handed to a human agent. + LIVE_AGENT_HANDOFF_RATE = 2; + + // Percentage of sessions with the same user calling back. + CALLBACK_SESSION_RATE = 3; + + // Percentage of sessions where user hung up. + ABANDONED_SESSION_RATE = 4; + + // Percentage of sessions reached Dialogflow 'END_PAGE' or + // 'END_SESSION'. + SESSION_END_RATE = 5; + } + + // Version variants and metrics. + repeated VersionMetrics version_metrics = 1; + + // The last time the experiment's stats data was updated. Will have default + // value if stats have never been computed for this experiment. + google.protobuf.Timestamp last_update_time = 2; + } + + // The state of the experiment. + enum State { + // State unspecified. + STATE_UNSPECIFIED = 0; + + // The experiment is created but not started yet. + DRAFT = 1; + + // The experiment is running. + RUNNING = 2; + + // The experiment is done. + DONE = 3; + } + + // The name of the experiment. + // Format: projects//locations//agents//environments//experiments/.. + string name = 1; + + // Required. The human-readable name of the experiment (unique in an environment). Limit + // of 64 characters. + string display_name = 2 [(google.api.field_behavior) = REQUIRED]; + + // The human-readable description of the experiment. + string description = 3; + + // The current state of the experiment. + // Transition triggered by Expriments.StartExperiment: PENDING->RUNNING. + // Transition triggered by Expriments.CancelExperiment: PENDING->CANCELLED or + // RUNNING->CANCELLED. + State state = 4; + + // The definition of the experiment. + Definition definition = 5; + + // Inference result of the experiment. + Result result = 6; + + // Creation time of this experiment. + google.protobuf.Timestamp create_time = 7; + + // Start time of this experiment. + google.protobuf.Timestamp start_time = 8; + + // End time of this experiment. + google.protobuf.Timestamp end_time = 9; + + // Last update time of this experiment. + google.protobuf.Timestamp last_update_time = 10; + + // Maximum number of days to run the experiment. + google.protobuf.Duration experiment_length = 11; + + // The history of updates to the experiment variants. + repeated VariantsHistory variants_history = 12; +} + +// A list of flow version variants. +message VersionVariants { + // A single flow version with specified traffic allocation. + message Variant { + // The name of the flow version. + // Format: `projects//locations//agents//flows//versions/`. + string version = 1; + + // Percentage of the traffic which should be routed to this + // version of flow. Traffic allocation for a single flow must sum up to 1.0. + float traffic_allocation = 2; + + // Whether the variant is for the control group. + bool is_control_group = 3; + } + + // A list of flow version variants. + repeated Variant variants = 1; +} + +// The history of variants update. +message VariantsHistory { + // The variants updated. We currently only support single variant + // experiment. + oneof variants { + // The flow versions as the variants. + VersionVariants version_variants = 1; + } + + // Update time of the variants. + google.protobuf.Timestamp update_time = 2; +} + +// The request message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3beta1.Experiments.ListExperiments]. +message ListExperimentsRequest { + // Required. The [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to list all environments for. + // Format: `projects//locations//agents//environments/`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "dialogflow.googleapis.com/Experiment" + } + ]; + + // The maximum number of items to return in a single page. By default 20 and + // at most 100. + int32 page_size = 2; + + // The next_page_token value returned from a previous list request. + string page_token = 3; +} + +// The response message for [Experiments.ListExperiments][google.cloud.dialogflow.cx.v3beta1.Experiments.ListExperiments]. +message ListExperimentsResponse { + // The list of experiments. There will be a maximum number of items + // returned based on the page_size field in the request. The list may in some + // cases be empty or contain fewer entries than page_size even if this isn't + // the last page. + repeated Experiment experiments = 1; + + // Token to retrieve the next page of results, or empty if there are no more + // results in the list. + string next_page_token = 2; +} + +// The request message for [Experiments.GetExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.GetExperiment]. +message GetExperimentRequest { + // Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment]. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} + +// The request message for [Experiments.CreateExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.CreateExperiment]. +message CreateExperimentRequest { + // Required. The [Agent][google.cloud.dialogflow.cx.v3beta1.Agent] to create an [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] for. + // Format: `projects//locations//agents//environments/`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "dialogflow.googleapis.com/Experiment" + } + ]; + + // Required. The experiment to create. + Experiment experiment = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for [Experiments.UpdateExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.UpdateExperiment]. +message UpdateExperimentRequest { + // Required. The experiment to update. + Experiment experiment = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The mask to control which fields get updated. + google.protobuf.FieldMask update_mask = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for [Experiments.DeleteExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.DeleteExperiment]. +message DeleteExperimentRequest { + // Required. The name of the [Environment][google.cloud.dialogflow.cx.v3beta1.Environment] to delete. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} + +// The request message for [Experiments.StartExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.StartExperiment]. +message StartExperimentRequest { + // Required. Resource name of the experiment to start. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} + +// The request message for [Experiments.StopExperiment][google.cloud.dialogflow.cx.v3beta1.Experiments.StopExperiment]. +message StopExperimentRequest { + // Required. Resource name of the experiment to stop. + // Format: `projects//locations//agents//environments//experiments/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/Experiment" + } + ]; +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/response_message.proto b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/response_message.proto index ac3b61cd0..7a9f96500 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/response_message.proto +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/response_message.proto @@ -113,25 +113,6 @@ message ResponseMessage { bool allow_playback_interruption = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; } - // Specifies an audio clip to be played by the client as part of the response. - message PlayAudio { - // Required. URI of the audio clip. Dialogflow does not impose any validation on this - // value. It is specific to the client that reads it. - string audio_uri = 1 [(google.api.field_behavior) = REQUIRED]; - - // Output only. Whether the playback of this message can be interrupted by the end - // user's speech and the client can then starts the next Dialogflow - // request. - bool allow_playback_interruption = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - } - - // Indicates that interaction with the Dialogflow agent has ended. - // This message is generated by Dialogflow only and not supposed to be - // defined by the user. - message EndInteraction { - - } - // Represents an audio message that is composed of both segments // synthesized from the Dialogflow agent prompts and ones hosted externally // at the specified URIs. @@ -163,6 +144,25 @@ message ResponseMessage { repeated Segment segments = 1; } + // Indicates that interaction with the Dialogflow agent has ended. + // This message is generated by Dialogflow only and not supposed to be + // defined by the user. + message EndInteraction { + + } + + // Specifies an audio clip to be played by the client as part of the response. + message PlayAudio { + // Required. URI of the audio clip. Dialogflow does not impose any validation on this + // value. It is specific to the client that reads it. + string audio_uri = 1 [(google.api.field_behavior) = REQUIRED]; + + // Output only. Whether the playback of this message can be interrupted by the end + // user's speech and the client can then starts the next Dialogflow + // request. + bool allow_playback_interruption = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; + } + // Required. The rich response message. oneof message { // Returns a text response. diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/security_settings.proto b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/security_settings.proto new file mode 100644 index 000000000..e86c99424 --- /dev/null +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/security_settings.proto @@ -0,0 +1,246 @@ +// Copyright 2020 Google LLC +// +// Licensed under the Apache License, Version 2.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.dialogflow.cx.v3beta1; + +import "google/api/annotations.proto"; +import "google/api/client.proto"; +import "google/api/field_behavior.proto"; +import "google/api/resource.proto"; +import "google/longrunning/operations.proto"; +import "google/protobuf/empty.proto"; +import "google/protobuf/field_mask.proto"; + +option cc_enable_arenas = true; +option csharp_namespace = "Google.Cloud.Dialogflow.Cx.V3Beta1"; +option go_package = "google.golang.org/genproto/googleapis/cloud/dialogflow/cx/v3beta1;cx"; +option java_multiple_files = true; +option java_outer_classname = "SecuritySettingsProto"; +option java_package = "com.google.cloud.dialogflow.cx.v3beta1"; +option objc_class_prefix = "DF"; + +// Service for managing security settings for Dialogflow. +service SecuritySettingsService { + option (google.api.default_host) = "dialogflow.googleapis.com"; + option (google.api.oauth_scopes) = + "https://www.googleapis.com/auth/cloud-platform," + "https://www.googleapis.com/auth/dialogflow"; + + // Create security settings in the specified location. + rpc CreateSecuritySettings(CreateSecuritySettingsRequest) returns (SecuritySettings) { + option (google.api.http) = { + post: "/v3beta1/{parent=projects/*/locations/*}/securitySettings" + body: "security_settings" + }; + option (google.api.method_signature) = "parent,security_settings"; + } + + // Retrieves the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + // The returned settings may be stale by up to 1 minute. + rpc GetSecuritySettings(GetSecuritySettingsRequest) returns (SecuritySettings) { + option (google.api.http) = { + get: "/v3beta1/{name=projects/*/locations/*/securitySettings/*}" + }; + option (google.api.method_signature) = "name"; + } + + // Updates the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + rpc UpdateSecuritySettings(UpdateSecuritySettingsRequest) returns (SecuritySettings) { + option (google.api.http) = { + patch: "/v3beta1/{security_settings.name=projects/*/locations/*/securitySettings/*}" + body: "security_settings" + }; + option (google.api.method_signature) = "security_settings,update_mask"; + } + + // Returns the list of all security settings in the specified location. + rpc ListSecuritySettings(ListSecuritySettingsRequest) returns (ListSecuritySettingsResponse) { + option (google.api.http) = { + get: "/v3beta1/{parent=projects/*/locations/*}/securitySettings" + }; + option (google.api.method_signature) = "parent"; + } + + // Deletes the specified [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings]. + rpc DeleteSecuritySettings(DeleteSecuritySettingsRequest) returns (google.protobuf.Empty) { + option (google.api.http) = { + delete: "/v3beta1/{name=projects/*/locations/*/securitySettings/*}" + }; + option (google.api.method_signature) = "name"; + } +} + +// The request message for [SecuritySettingsService.GetSecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService.GetSecuritySettings]. +message GetSecuritySettingsRequest { + // Required. Resource name of the settings. + // Format: `projects//locations//securitySettings/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/SecuritySettings" + } + ]; +} + +// The request message for [SecuritySettingsService.UpdateSecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettingsService.UpdateSecuritySettings]. +message UpdateSecuritySettingsRequest { + // Required. [SecuritySettings] object that contains values for each of the + // fields to update. + SecuritySettings security_settings = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The mask to control which fields get updated. If the mask is not present, + // all fields will be updated. + google.protobuf.FieldMask update_mask = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for [SecuritySettings.ListSecuritySettings][]. +message ListSecuritySettingsRequest { + // Required. The location to list all security settings for. + // Format: `projects//locations/`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "dialogflow.googleapis.com/SecuritySettings" + } + ]; + + // The maximum number of items to return in a single page. By default 20 and + // at most 100. + int32 page_size = 2; + + // The next_page_token value returned from a previous list request. + string page_token = 3; +} + +// The response message for [SecuritySettings.ListSecuritySettings][]. +message ListSecuritySettingsResponse { + // The list of security settings. + repeated SecuritySettings security_settings = 1; + + // Token to retrieve the next page of results, or empty if there are no more + // results in the list. + string next_page_token = 2; +} + +// The request message for [SecuritySettings.CreateSecuritySettings][]. +message CreateSecuritySettingsRequest { + // Required. The location to create an [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] for. + // Format: `projects//locations/`. + string parent = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + child_type: "dialogflow.googleapis.com/SecuritySettings" + } + ]; + + // Required. The security settings to create. + SecuritySettings security_settings = 2 [(google.api.field_behavior) = REQUIRED]; +} + +// The request message for [SecuritySettings.DeleteSecuritySettings][]. +message DeleteSecuritySettingsRequest { + // Required. The name of the [SecuritySettings][google.cloud.dialogflow.cx.v3beta1.SecuritySettings] to delete. + // Format: `projects//locations//securitySettings/`. + string name = 1 [ + (google.api.field_behavior) = REQUIRED, + (google.api.resource_reference) = { + type: "dialogflow.googleapis.com/SecuritySettings" + } + ]; +} + +// Represents the settings related to security issues, such as data redaction +// and data retention. It may take hours for updates on the settings to +// propagate to all the related components and take effect. +message SecuritySettings { + option (google.api.resource) = { + type: "dialogflow.googleapis.com/SecuritySettings" + pattern: "projects/{project}/locations/{location}/securitySettings/{security_settings}" + }; + + // Defines how we redact data. + enum RedactionStrategy { + // Do not redact. + REDACTION_STRATEGY_UNSPECIFIED = 0; + + // Call redaction service to clean up the data to be persisted. + REDACT_WITH_SERVICE = 1; + } + + // Defines what types of data to redact. + enum RedactionScope { + // Don't redact any kind of data. + REDACTION_SCOPE_UNSPECIFIED = 0; + + // On data to be written to disk or similar devices that are capable of + // holding data even if power is disconnected. This includes data that are + // temporarily saved on disk. + REDACT_DISK_STORAGE = 2; + } + + // Type of data we purge after retention settings triggers purge. + enum PurgeDataType { + // Unspecified. Do not use. + PURGE_DATA_TYPE_UNSPECIFIED = 0; + + // Dialogflow history. This does not include Stackdriver log, which is + // owned by the user not Dialogflow. + DIALOGFLOW_HISTORY = 1; + } + + // Required. Resource name of the settings. + // Format: `projects//locations//securitySettings/`. + string name = 1 [(google.api.field_behavior) = REQUIRED]; + + // Required. The human-readable name of the security settings, unique within the + // location. + string display_name = 2 [(google.api.field_behavior) = REQUIRED]; + + // Strategy that defines how we do redaction. + RedactionStrategy redaction_strategy = 3; + + // Defines on what data we apply redaction. Note that we don't + // redact data to which we don't have access, e.g., Stackdriver logs. + RedactionScope redaction_scope = 4; + + // DLP inspect template name. Use this template to define inspect base + // settings. + // + // If empty, we use the default DLP inspect config. + // + // The template name will have one of the following formats: + // `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR + // `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID` + string inspect_template = 9; + + // Specifies how data is retained. Note that even if the data is + // purged due to retention policy, we may still hold it in backup storage for + // a few days without allowing direct readings. + oneof data_retention { + // Retains the data for the specified number of days. + // User must Set a value lower than Dialogflow's default 30d TTL. Setting a + // value higher than that has no effect. + // A missing value or setting to 0 also means we use Dialogflow's default + // TTL. + int32 retention_window_days = 6; + } + + // List of types of data to remove when retention settings triggers purge. + repeated PurgeDataType purge_data_types = 8; +} diff --git a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/session.proto b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/session.proto index 8b4040815..5e8f07aa4 100644 --- a/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/session.proto +++ b/proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/session.proto @@ -380,7 +380,8 @@ message QueryParameters { // - MapKey value: parameter name // - MapValue type: // - If parameter's entity type is a composite entity: map - // - Else: string or number, depending on parameter value type + // - Else: depending on parameter value type, could be one of string, + // number, boolean, null, list or map // - MapValue value: // - If parameter's entity type is a composite entity: // map from composite entity property names to property values @@ -475,7 +476,8 @@ message QueryResult { // - MapKey value: parameter name // - MapValue type: // - If parameter's entity type is a composite entity: map - // - Else: string or number, depending on parameter value type + // - Else: depending on parameter value type, could be one of string, + // number, boolean, null, list or map // - MapValue value: // - If parameter's entity type is a composite entity: // map from composite entity property names to property values @@ -626,7 +628,8 @@ message Match { // - MapKey value: parameter name // - MapValue type: // - If parameter's entity type is a composite entity: map - // - Else: string or number, depending on parameter value type + // - Else: depending on parameter value type, could be one of string, + // number, boolean, null, list or map // - MapValue value: // - If parameter's entity type is a composite entity: // map from composite entity property names to property values diff --git a/synth.metadata b/synth.metadata index 043311316..8c84b2409 100644 --- a/synth.metadata +++ b/synth.metadata @@ -4,30 +4,30 @@ "git": { "name": ".", "remote": "https://github.com/googleapis/java-dialogflow-cx.git", - "sha": "ed967fea79714f9697bf3862719fb6be7a42946b" + "sha": "939932849fbb87897faf6b11c5c6b2df496ef72d" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "e4d01555afeb93d2f3b467056ea884b092567d1b", - "internalRef": "346434847" + "sha": "91e206bcfeaf8948ea03fe3cb1b7616108496cd3", + "internalRef": "350949863" } }, { "git": { "name": "googleapis", "remote": "https://github.com/googleapis/googleapis.git", - "sha": "e4d01555afeb93d2f3b467056ea884b092567d1b", - "internalRef": "346434847" + "sha": "91e206bcfeaf8948ea03fe3cb1b7616108496cd3", + "internalRef": "350949863" } }, { "git": { "name": "synthtool", "remote": "https://github.com/googleapis/synthtool.git", - "sha": "6133907dbb3ddab204a17a15d5c53ec0aae9b033" + "sha": "fb53b6fb373b7c3edf4e55f3e8036bc6d73fa483" } } ], @@ -123,6 +123,8 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EntityTypesSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsSettings.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClient.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/IntentsClient.java", @@ -148,6 +150,8 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EntityTypesStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/EnvironmentsStubSettings.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStub.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/ExperimentsStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/FlowsStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcAgentsCallableFactory.java", @@ -156,6 +160,8 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEntityTypesStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEnvironmentsCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcEnvironmentsStub.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsCallableFactory.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcExperimentsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcFlowsCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcFlowsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3/stub/GrpcIntentsCallableFactory.java", @@ -196,12 +202,16 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsSettings.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClient.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesSettings.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClient.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesClient.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsClient.java", @@ -219,6 +229,8 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EntityTypesStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EnvironmentsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/EnvironmentsStubSettings.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStub.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/ExperimentsStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/FlowsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/FlowsStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcAgentsCallableFactory.java", @@ -227,12 +239,16 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEntityTypesStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcEnvironmentsStub.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsCallableFactory.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcExperimentsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcFlowsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcIntentsStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcPagesStub.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceCallableFactory.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSecuritySettingsServiceStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesCallableFactory.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionEntityTypesStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/GrpcSessionsCallableFactory.java", @@ -247,6 +263,8 @@ "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/IntentsStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/PagesStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/PagesStubSettings.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStub.java", + "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SecuritySettingsServiceStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionEntityTypesStub.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionEntityTypesStubSettings.java", "google-cloud-dialogflow-cx/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/stub/SessionsStub.java", @@ -260,6 +278,7 @@ "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/AgentsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/EntityTypesClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsClientTest.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/ExperimentsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/FlowsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/IntentsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockAgents.java", @@ -268,6 +287,8 @@ "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockEntityTypesImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockEnvironments.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockEnvironmentsImpl.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperiments.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockExperimentsImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockFlows.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockFlowsImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3/MockIntents.java", @@ -296,6 +317,7 @@ "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsClientTest.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockAgents.java", @@ -304,12 +326,16 @@ "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockEntityTypesImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockEnvironments.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockEnvironmentsImpl.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperiments.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockExperimentsImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockFlows.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockFlowsImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockIntents.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockIntentsImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockPages.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockPagesImpl.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsService.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSecuritySettingsServiceImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSessionEntityTypes.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSessionEntityTypesImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockSessions.java", @@ -321,6 +347,7 @@ "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockWebhooks.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/MockWebhooksImpl.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/PagesClientTest.java", + "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsClientTest.java", "google-cloud-dialogflow-cx/src/test/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsClientTest.java", @@ -329,6 +356,7 @@ "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/AgentsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/EntityTypesGrpc.java", "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/EnvironmentsGrpc.java", + "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/FlowsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/IntentsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/PagesGrpc.java", @@ -341,9 +369,11 @@ "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/AgentsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EntityTypesGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EnvironmentsGrpc.java", + "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/FlowsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/IntentsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/PagesGrpc.java", + "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsServiceGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityTypesGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionsGrpc.java", "grpc-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/TransitionRouteGroupsGrpc.java", @@ -365,6 +395,8 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/CreateIntentRequest.java", @@ -389,6 +421,8 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/DeleteIntentRequest.java", @@ -423,6 +457,10 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/EventHandlerOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/EventInput.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/EventInputOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Experiment.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentName.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExperimentProto.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExportAgentRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExportAgentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ExportAgentResponse.java", @@ -446,6 +484,8 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/GetIntentRequest.java", @@ -483,6 +523,10 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListEnvironmentsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListEnvironmentsResponse.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListEnvironmentsResponseOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponse.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListExperimentsResponseOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListFlowsRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListFlowsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/ListFlowsResponse.java", @@ -570,6 +614,10 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SpeechWordInfo.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SpeechWordInfoOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/SsmlVoiceGender.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StartExperimentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StopExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/StreamingDetectIntentResponse.java", @@ -594,6 +642,8 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateIntentRequest.java", @@ -610,10 +660,14 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateVersionRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateWebhookRequest.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/UpdateWebhookRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistory.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VariantsHistoryOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Version.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionName.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionProto.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariants.java", + "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VersionVariantsOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VoiceSelectionParams.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/VoiceSelectionParamsOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3/src/main/java/com/google/cloud/dialogflow/cx/v3/Webhook.java", @@ -628,6 +682,7 @@ "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/audio_config.proto", "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/entity_type.proto", "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/environment.proto", + "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/experiment.proto", "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/flow.proto", "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/fulfillment.proto", "proto-google-cloud-dialogflow-cx-v3/src/main/proto/google/cloud/dialogflow/cx/v3/intent.proto", @@ -653,12 +708,16 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateIntentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateIntentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreatePageRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreatePageRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSecuritySettingsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSessionEntityTypeRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateSessionEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/CreateTransitionRouteGroupRequest.java", @@ -675,12 +734,16 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteIntentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteIntentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeletePageRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeletePageRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSecuritySettingsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSessionEntityTypeRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteSessionEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/DeleteTransitionRouteGroupRequest.java", @@ -707,6 +770,10 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EventHandlerOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EventInput.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/EventInputOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Experiment.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentName.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExperimentProto.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ExportAgentResponse.java", @@ -730,12 +797,16 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetIntentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetIntentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetPageRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetPageRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSecuritySettingsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSessionEntityTypeRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetSessionEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/GetTransitionRouteGroupRequest.java", @@ -765,6 +836,10 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListEnvironmentsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListEnvironmentsResponse.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListEnvironmentsResponseOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponse.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListExperimentsResponseOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListFlowsRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListFlowsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListFlowsResponse.java", @@ -777,6 +852,10 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListPagesRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListPagesResponse.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListPagesResponseOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponse.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSecuritySettingsResponseOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSessionEntityTypesRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSessionEntityTypesRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ListSessionEntityTypesResponse.java", @@ -828,6 +907,10 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/ResponseMessageProto.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/RestoreAgentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/RestoreAgentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettings.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsName.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SecuritySettingsProto.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SentimentAnalysisResult.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SentimentAnalysisResultOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SessionEntityType.java", @@ -844,6 +927,10 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SpeechWordInfo.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SpeechWordInfoOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/SsmlVoiceGender.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StartExperimentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StopExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StreamingDetectIntentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StreamingDetectIntentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/StreamingDetectIntentResponse.java", @@ -868,12 +955,16 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateEnvironmentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateEnvironmentRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateExperimentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateFlowRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateFlowRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateIntentRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateIntentRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdatePageRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdatePageRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequest.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSecuritySettingsRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSessionEntityTypeRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateSessionEntityTypeRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateTransitionRouteGroupRequest.java", @@ -882,10 +973,14 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateVersionRequestOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateWebhookRequest.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/UpdateWebhookRequestOrBuilder.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistory.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VariantsHistoryOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Version.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionName.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionProto.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariants.java", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VersionVariantsOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VoiceSelectionParams.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/VoiceSelectionParamsOrBuilder.java", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/java/com/google/cloud/dialogflow/cx/v3beta1/Webhook.java", @@ -900,11 +995,13 @@ "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/audio_config.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/entity_type.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/environment.proto", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/experiment.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/flow.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/fulfillment.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/intent.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/page.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/response_message.proto", + "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/security_settings.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/session.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/session_entity_type.proto", "proto-google-cloud-dialogflow-cx-v3beta1/src/main/proto/google/cloud/dialogflow/cx/v3beta1/transition_route_group.proto",