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:
+ *
+ *
+ * - 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.
+ *
- 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.
+ *
- 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 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();
+ * }
+ */
+@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:
+ *
+ *
+ * - 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.
+ *
- 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.
+ *
- 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.
+ *
+ *