diff --git a/java-dialogflow/.gitignore b/java-dialogflow/.gitignore
new file mode 100644
index 000000000000..069d08fc73e8
--- /dev/null
+++ b/java-dialogflow/.gitignore
@@ -0,0 +1,17 @@
+# Maven
+target/
+
+# Eclipse
+.classpath
+.project
+.settings
+
+# Intellij
+*.iml
+.idea/
+
+# python utilities
+*.pyc
+__pycache__
+
+.flattened-pom.xml
diff --git a/java-dialogflow/README.md b/java-dialogflow/README.md
index 268f1381ae0d..9d5786ffb77a 100644
--- a/java-dialogflow/README.md
+++ b/java-dialogflow/README.md
@@ -19,20 +19,20 @@ If you are using Maven, add this to your pom.xml file:
The top-level message sent to the client by the server is `StreamingAnalyzeContentResponse`. + * Multiple response messages can be returned in order. The first one or more messages contain the + * `recognition_result` field. Each result represents a more complete transcript of what the user + * said. The next message contains the `reply_text` field and potentially the `reply_audio` field. + * The message can also contain the `automated_agent_reply` field. + * + *
Note: Always use agent versions for production traffic sent to virtual agents. See [Versions + * and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions). + * + *
Sample code: + * + *
{@code + * // This snippet has been automatically generated and should be regarded as a code template only. + * // It will require modifications to work: + * // - It may require correct/in-range values for request initialization. + * // - It may require specifying regional endpoints when creating the service client as shown in + * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library + * try (ParticipantsClient participantsClient = ParticipantsClient.create()) { + * BidiStream+ */ + public final BidiStreamingCallable< + StreamingAnalyzeContentRequest, StreamingAnalyzeContentResponse> + streamingAnalyzeContentCallable() { + return stub.streamingAnalyzeContentCallable(); + } + // AUTO-GENERATED DOCUMENTATION AND METHOD. /** * Gets suggested articles for a participant based on specific historical messages. diff --git a/java-dialogflow/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/ParticipantsSettings.java b/java-dialogflow/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/ParticipantsSettings.java index 9d72fd69b35d..d208c8c65b2d 100644 --- a/java-dialogflow/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/ParticipantsSettings.java +++ b/java-dialogflow/google-cloud-dialogflow/src/main/java/com/google/cloud/dialogflow/v2/ParticipantsSettings.java @@ -29,6 +29,7 @@ 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.StreamingCallSettings; import com.google.api.gax.rpc.TransportChannelProvider; import com.google.api.gax.rpc.UnaryCallSettings; import com.google.cloud.dialogflow.v2.stub.ParticipantsStubSettings; @@ -103,6 +104,12 @@ public UnaryCallSettingsbidiStream = + * participantsClient.streamingAnalyzeContentCallable().call(); + * StreamingAnalyzeContentRequest request = + * StreamingAnalyzeContentRequest.newBuilder() + * .setParticipant( + * ParticipantName.ofProjectConversationParticipantName( + * "[PROJECT]", "[CONVERSATION]", "[PARTICIPANT]") + * .toString()) + * .setReplyAudioConfig(OutputAudioConfig.newBuilder().build()) + * .setQueryParams(QueryParameters.newBuilder().build()) + * .setAssistQueryParams(AssistQueryParameters.newBuilder().build()) + * .setCxParameters(Struct.newBuilder().build()) + * .setEnablePartialAutomatedAgentReply(true) + * .build(); + * bidiStream.send(request); + * for (StreamingAnalyzeContentResponse response : bidiStream) { + * // Do something when a response is received. + * } + * } + * }
+ * Adds a text (chat, for example), or audio (phone recording, for example) + * message from a participant into the conversation. + * Note: This method is only available through the gRPC API (not REST). + * The top-level message sent to the client by the server is + * `StreamingAnalyzeContentResponse`. Multiple response messages can be + * returned in order. The first one or more messages contain the + * `recognition_result` field. Each result represents a more complete + * transcript of what the user said. The next message contains the + * `reply_text` field and potentially the `reply_audio` field. The message can + * also contain the `automated_agent_reply` field. + * Note: Always use agent versions for production traffic + * sent to virtual agents. See [Versions and + * environments](https://cloud.google.com/dialogflow/es/docs/agents-versions). + *+ */ + public io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest> + streamingAnalyzeContent( + io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse> + responseObserver) { + return io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall( + getStreamingAnalyzeContentMethod(), responseObserver); + } + /** * * @@ -621,6 +700,13 @@ public final io.grpc.ServerServiceDefinition bindService() { com.google.cloud.dialogflow.v2.AnalyzeContentRequest, com.google.cloud.dialogflow.v2.AnalyzeContentResponse>( this, METHODID_ANALYZE_CONTENT))) + .addMethod( + getStreamingAnalyzeContentMethod(), + io.grpc.stub.ServerCalls.asyncBidiStreamingCall( + new MethodHandlers< + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest, + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse>( + this, METHODID_STREAMING_ANALYZE_CONTENT))) .addMethod( getSuggestArticlesMethod(), io.grpc.stub.ServerCalls.asyncUnaryCall( @@ -750,6 +836,36 @@ public void analyzeContent( responseObserver); } + /** + * + * + *
+ * Adds a text (chat, for example), or audio (phone recording, for example) + * message from a participant into the conversation. + * Note: This method is only available through the gRPC API (not REST). + * The top-level message sent to the client by the server is + * `StreamingAnalyzeContentResponse`. Multiple response messages can be + * returned in order. The first one or more messages contain the + * `recognition_result` field. Each result represents a more complete + * transcript of what the user said. The next message contains the + * `reply_text` field and potentially the `reply_audio` field. The message can + * also contain the `automated_agent_reply` field. + * Note: Always use agent versions for production traffic + * sent to virtual agents. See [Versions and + * environments](https://cloud.google.com/dialogflow/es/docs/agents-versions). + *+ */ + public io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest> + streamingAnalyzeContent( + io.grpc.stub.StreamObserver< + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse> + responseObserver) { + return io.grpc.stub.ClientCalls.asyncBidiStreamingCall( + getChannel().newCall(getStreamingAnalyzeContentMethod(), getCallOptions()), + responseObserver); + } + /** * * @@ -1083,6 +1199,7 @@ protected ParticipantsFutureStub build( private static final int METHODID_SUGGEST_ARTICLES = 5; private static final int METHODID_SUGGEST_FAQ_ANSWERS = 6; private static final int METHODID_SUGGEST_SMART_REPLIES = 7; + private static final int METHODID_STREAMING_ANALYZE_CONTENT = 8; private static final class MethodHandlers
+ * Defines the language used in the input text. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.InputTextConfig} + */ +public final class InputTextConfig extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.v2.InputTextConfig) + InputTextConfigOrBuilder { + private static final long serialVersionUID = 0L; + // Use InputTextConfig.newBuilder() to construct. + private InputTextConfig(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private InputTextConfig() { + languageCode_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new InputTextConfig(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.v2.ParticipantProto + .internal_static_google_cloud_dialogflow_v2_InputTextConfig_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.v2.ParticipantProto + .internal_static_google_cloud_dialogflow_v2_InputTextConfig_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.v2.InputTextConfig.class, + com.google.cloud.dialogflow.v2.InputTextConfig.Builder.class); + } + + public static final int LANGUAGE_CODE_FIELD_NUMBER = 1; + private volatile java.lang.Object languageCode_; + /** + * + * + *
+ * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return The languageCode.
+ */
+ @java.lang.Override
+ public java.lang.String getLanguageCode() {
+ java.lang.Object ref = languageCode_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ languageCode_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return The bytes for languageCode.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getLanguageCodeBytes() {
+ java.lang.Object ref = languageCode_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ languageCode_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(languageCode_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, languageCode_);
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(languageCode_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, languageCode_);
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.cloud.dialogflow.v2.InputTextConfig)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.dialogflow.v2.InputTextConfig other =
+ (com.google.cloud.dialogflow.v2.InputTextConfig) obj;
+
+ if (!getLanguageCode().equals(other.getLanguageCode())) return false;
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + LANGUAGE_CODE_FIELD_NUMBER;
+ hash = (53 * hash) + getLanguageCode().hashCode();
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(java.nio.ByteBuffer data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(com.google.cloud.dialogflow.v2.InputTextConfig prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * Defines the language used in the input text. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.InputTextConfig} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return The languageCode.
+ */
+ public java.lang.String getLanguageCode() {
+ java.lang.Object ref = languageCode_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ languageCode_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return The bytes for languageCode.
+ */
+ public com.google.protobuf.ByteString getLanguageCodeBytes() {
+ java.lang.Object ref = languageCode_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ languageCode_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @param value The languageCode to set.
+ * @return This builder for chaining.
+ */
+ public Builder setLanguageCode(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ languageCode_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearLanguageCode() {
+
+ languageCode_ = getDefaultInstance().getLanguageCode();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @param value The bytes for languageCode to set.
+ * @return This builder for chaining.
+ */
+ public Builder setLanguageCodeBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ languageCode_ = value;
+ onChanged();
+ return this;
+ }
+
+ @java.lang.Override
+ public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFields(unknownFields);
+ }
+
+ @java.lang.Override
+ public final Builder mergeUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.mergeUnknownFields(unknownFields);
+ }
+
+ // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.v2.InputTextConfig)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.v2.InputTextConfig)
+ private static final com.google.cloud.dialogflow.v2.InputTextConfig DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.dialogflow.v2.InputTextConfig();
+ }
+
+ public static com.google.cloud.dialogflow.v2.InputTextConfig getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return The languageCode.
+ */
+ java.lang.String getLanguageCode();
+ /**
+ *
+ *
+ * + * Required. The language of this conversational query. See [Language + * Support](https://cloud.google.com/dialogflow/docs/reference/language) + * for a list of the currently supported language codes. + *+ * + *
string language_code = 1 [(.google.api.field_behavior) = REQUIRED];
+ *
+ * @return The bytes for languageCode.
+ */
+ com.google.protobuf.ByteString getLanguageCodeBytes();
+}
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/Participant.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/Participant.java
index dc6c0ac436f1..a22fff3aa358 100644
--- a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/Participant.java
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/Participant.java
@@ -41,6 +41,7 @@ private Participant() {
name_ = "";
role_ = 0;
sipRecordingMediaLabel_ = "";
+ obfuscatedExternalUserId_ = "";
}
@java.lang.Override
@@ -409,6 +410,95 @@ public com.google.protobuf.ByteString getSipRecordingMediaLabelBytes() {
}
}
+ public static final int OBFUSCATED_EXTERNAL_USER_ID_FIELD_NUMBER = 7;
+ private volatile java.lang.Object obfuscatedExternalUserId_;
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The obfuscatedExternalUserId.
+ */
+ @java.lang.Override
+ public java.lang.String getObfuscatedExternalUserId() {
+ java.lang.Object ref = obfuscatedExternalUserId_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ obfuscatedExternalUserId_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for obfuscatedExternalUserId.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getObfuscatedExternalUserIdBytes() {
+ java.lang.Object ref = obfuscatedExternalUserId_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ obfuscatedExternalUserId_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
public static final int DOCUMENTS_METADATA_FILTERS_FIELD_NUMBER = 8;
private static final class DocumentsMetadataFiltersDefaultEntryHolder {
@@ -604,6 +694,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sipRecordingMediaLabel_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 6, sipRecordingMediaLabel_);
}
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(obfuscatedExternalUserId_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 7, obfuscatedExternalUserId_);
+ }
com.google.protobuf.GeneratedMessageV3.serializeStringMapTo(
output,
internalGetDocumentsMetadataFilters(),
@@ -627,6 +720,10 @@ public int getSerializedSize() {
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(sipRecordingMediaLabel_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, sipRecordingMediaLabel_);
}
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(obfuscatedExternalUserId_)) {
+ size +=
+ com.google.protobuf.GeneratedMessageV3.computeStringSize(7, obfuscatedExternalUserId_);
+ }
for (java.util.Map.Entry+ * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return The obfuscatedExternalUserId.
+ */
+ public java.lang.String getObfuscatedExternalUserId() {
+ java.lang.Object ref = obfuscatedExternalUserId_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ obfuscatedExternalUserId_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return The bytes for obfuscatedExternalUserId.
+ */
+ public com.google.protobuf.ByteString getObfuscatedExternalUserIdBytes() {
+ java.lang.Object ref = obfuscatedExternalUserId_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ obfuscatedExternalUserId_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @param value The obfuscatedExternalUserId to set.
+ * @return This builder for chaining.
+ */
+ public Builder setObfuscatedExternalUserId(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ obfuscatedExternalUserId_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearObfuscatedExternalUserId() {
+
+ obfuscatedExternalUserId_ = getDefaultInstance().getObfuscatedExternalUserId();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ *
+ * @param value The bytes for obfuscatedExternalUserId to set.
+ * @return This builder for chaining.
+ */
+ public Builder setObfuscatedExternalUserIdBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ obfuscatedExternalUserId_ = value;
+ onChanged();
+ return this;
+ }
+
private com.google.protobuf.MapField+ * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The obfuscatedExternalUserId.
+ */
+ java.lang.String getObfuscatedExternalUserId();
+ /**
+ *
+ *
+ * + * Optional. Obfuscated user id that should be associated with the created participant. + * You can specify a user id as follows: + * 1. If you set this field in + * [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or + * [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant], + * Dialogflow adds the obfuscated user id with the participant. + * 2. If you set this field in + * [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or + * [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id], + * Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id]. + * Dialogflow returns an error if you try to add a user id for a + * non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant. + * Dialogflow uses this user id for billing and measurement purposes. For + * example, Dialogflow determines whether a user in one conversation returned + * in a later conversation. + * Note: + * * Please never pass raw user ids to Dialogflow. Always obfuscate your user + * id first. + * * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a + * hash function like SHA-512. + * * The length of the user id must be <= 256 characters. + *+ * + *
string obfuscated_external_user_id = 7 [(.google.api.field_behavior) = OPTIONAL];
+ *
+ * @return The bytes for obfuscatedExternalUserId.
+ */
+ com.google.protobuf.ByteString getObfuscatedExternalUserIdBytes();
+
/**
*
*
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/ParticipantProto.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/ParticipantProto.java
index 1159b14d84a5..df461ad107b8 100644
--- a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/ParticipantProto.java
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/ParticipantProto.java
@@ -71,6 +71,14 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r
internal_static_google_cloud_dialogflow_v2_AnalyzeContentResponse_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_dialogflow_v2_AnalyzeContentResponse_fieldAccessorTable;
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_descriptor;
+ static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_fieldAccessorTable;
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_descriptor;
+ static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_dialogflow_v2_SuggestArticlesRequest_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
@@ -127,6 +135,10 @@ public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry r
internal_static_google_cloud_dialogflow_v2_SuggestionResult_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_google_cloud_dialogflow_v2_SuggestionResult_fieldAccessorTable;
+ static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_google_cloud_dialogflow_v2_InputTextConfig_descriptor;
+ static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
+ internal_static_google_cloud_dialogflow_v2_InputTextConfig_fieldAccessorTable;
static final com.google.protobuf.Descriptors.Descriptor
internal_static_google_cloud_dialogflow_v2_AnnotatedMessagePart_descriptor;
static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
@@ -162,228 +174,266 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
+ "google/protobuf/field_mask.proto\032\034google"
+ "/protobuf/struct.proto\032\037google/protobuf/"
+ "timestamp.proto\032\027google/rpc/status.proto"
- + "\"\347\004\n\013Participant\022\021\n\004name\030\001 \001(\tB\003\340A\001\022?\n\004r"
+ + "\"\221\005\n\013Participant\022\021\n\004name\030\001 \001(\tB\003\340A\001\022?\n\004r"
+ "ole\030\002 \001(\0162,.google.cloud.dialogflow.v2.P"
+ "articipant.RoleB\003\340A\005\022&\n\031sip_recording_me"
- + "dia_label\030\006 \001(\tB\003\340A\001\022n\n\032documents_metada"
- + "ta_filters\030\010 \003(\0132E.google.cloud.dialogfl"
- + "ow.v2.Participant.DocumentsMetadataFilte"
- + "rsEntryB\003\340A\001\032?\n\035DocumentsMetadataFilters"
- + "Entry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"P\n"
- + "\004Role\022\024\n\020ROLE_UNSPECIFIED\020\000\022\017\n\013HUMAN_AGE"
- + "NT\020\001\022\023\n\017AUTOMATED_AGENT\020\002\022\014\n\010END_USER\020\003:"
- + "\330\001\352A\324\001\n%dialogflow.googleapis.com/Partic"
- + "ipant\022Jprojects/{project}/conversations/"
- + "{conversation}/participants/{participant"
- + "}\022_projects/{project}/locations/{locatio"
- + "n}/conversations/{conversation}/particip"
- + "ants/{participant}\"\214\005\n\007Message\022\021\n\004name\030\001"
- + " \001(\tB\003\340A\001\022\024\n\007content\030\002 \001(\tB\003\340A\002\022\032\n\rlangu"
- + "age_code\030\003 \001(\tB\003\340A\001\022\030\n\013participant\030\004 \001(\t"
- + "B\003\340A\003\022K\n\020participant_role\030\005 \001(\0162,.google"
- + ".cloud.dialogflow.v2.Participant.RoleB\003\340"
- + "A\003\0224\n\013create_time\030\006 \001(\0132\032.google.protobu"
- + "f.TimestampB\003\340A\003\0222\n\tsend_time\030\t \001(\0132\032.go"
- + "ogle.protobuf.TimestampB\003\340A\001\022N\n\022message_"
- + "annotation\030\007 \001(\0132-.google.cloud.dialogfl"
- + "ow.v2.MessageAnnotationB\003\340A\003\022T\n\022sentimen"
- + "t_analysis\030\010 \001(\01323.google.cloud.dialogfl"
- + "ow.v2.SentimentAnalysisResultB\003\340A\003:\304\001\352A\300"
- + "\001\n!dialogflow.googleapis.com/Message\022Bpr"
- + "ojects/{project}/conversations/{conversa"
- + "tion}/messages/{message}\022Wprojects/{proj"
- + "ect}/locations/{location}/conversations/"
- + "{conversation}/messages/{message}\"\234\001\n\030Cr"
- + "eateParticipantRequest\022=\n\006parent\030\001 \001(\tB-"
- + "\340A\002\372A\'\022%dialogflow.googleapis.com/Partic"
- + "ipant\022A\n\013participant\030\002 \001(\0132\'.google.clou"
- + "d.dialogflow.v2.ParticipantB\003\340A\002\"T\n\025GetP"
- + "articipantRequest\022;\n\004name\030\001 \001(\tB-\340A\002\372A\'\n"
- + "%dialogflow.googleapis.com/Participant\"\211"
- + "\001\n\027ListParticipantsRequest\022=\n\006parent\030\001 \001"
- + "(\tB-\340A\002\372A\'\022%dialogflow.googleapis.com/Pa"
- + "rticipant\022\026\n\tpage_size\030\002 \001(\005B\003\340A\001\022\027\n\npag"
- + "e_token\030\003 \001(\tB\003\340A\001\"r\n\030ListParticipantsRe"
- + "sponse\022=\n\014participants\030\001 \003(\0132\'.google.cl"
- + "oud.dialogflow.v2.Participant\022\027\n\017next_pa"
- + "ge_token\030\002 \001(\t\"\223\001\n\030UpdateParticipantRequ"
- + "est\022A\n\013participant\030\001 \001(\0132\'.google.cloud."
- + "dialogflow.v2.ParticipantB\003\340A\002\0224\n\013update"
- + "_mask\030\002 \001(\0132\032.google.protobuf.FieldMaskB"
- + "\003\340A\002\"\202\004\n\025AnalyzeContentRequest\022B\n\013partic"
- + "ipant\030\001 \001(\tB-\340A\002\372A\'\n%dialogflow.googleap"
- + "is.com/Participant\022;\n\ntext_input\030\006 \001(\0132%"
- + ".google.cloud.dialogflow.v2.TextInputH\000\022"
- + "=\n\013event_input\030\010 \001(\0132&.google.cloud.dial"
- + "ogflow.v2.EventInputH\000\022I\n\022reply_audio_co"
- + "nfig\030\005 \001(\0132-.google.cloud.dialogflow.v2."
- + "OutputAudioConfig\022A\n\014query_params\030\t \001(\0132"
- + "+.google.cloud.dialogflow.v2.QueryParame"
- + "ters\022N\n\023assist_query_params\030\016 \001(\01321.goog"
- + "le.cloud.dialogflow.v2.AssistQueryParame"
- + "ters\022.\n\rcx_parameters\030\022 \001(\0132\027.google.pro"
- + "tobuf.Struct\022\022\n\nrequest_id\030\013 \001(\tB\007\n\005inpu"
- + "t\",\n\016DtmfParameters\022\032\n\022accepts_dtmf_inpu"
- + "t\030\001 \001(\010\"\336\003\n\026AnalyzeContentResponse\022\022\n\nre"
- + "ply_text\030\001 \001(\t\022<\n\013reply_audio\030\002 \001(\0132\'.go"
- + "ogle.cloud.dialogflow.v2.OutputAudio\022N\n\025"
- + "automated_agent_reply\030\003 \001(\0132/.google.clo"
- + "ud.dialogflow.v2.AutomatedAgentReply\0224\n\007"
- + "message\030\005 \001(\0132#.google.cloud.dialogflow."
- + "v2.Message\022T\n\036human_agent_suggestion_res"
- + "ults\030\006 \003(\0132,.google.cloud.dialogflow.v2."
- + "SuggestionResult\022Q\n\033end_user_suggestion_"
- + "results\030\007 \003(\0132,.google.cloud.dialogflow."
- + "v2.SuggestionResult\022C\n\017dtmf_parameters\030\t"
- + " \001(\0132*.google.cloud.dialogflow.v2.DtmfPa"
- + "rameters\"\205\002\n\026SuggestArticlesRequest\022=\n\006p"
+ + "dia_label\030\006 \001(\tB\003\340A\001\022(\n\033obfuscated_exter"
+ + "nal_user_id\030\007 \001(\tB\003\340A\001\022n\n\032documents_meta"
+ + "data_filters\030\010 \003(\0132E.google.cloud.dialog"
+ + "flow.v2.Participant.DocumentsMetadataFil"
+ + "tersEntryB\003\340A\001\032?\n\035DocumentsMetadataFilte"
+ + "rsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\""
+ + "P\n\004Role\022\024\n\020ROLE_UNSPECIFIED\020\000\022\017\n\013HUMAN_A"
+ + "GENT\020\001\022\023\n\017AUTOMATED_AGENT\020\002\022\014\n\010END_USER\020"
+ + "\003:\330\001\352A\324\001\n%dialogflow.googleapis.com/Part"
+ + "icipant\022Jprojects/{project}/conversation"
+ + "s/{conversation}/participants/{participa"
+ + "nt}\022_projects/{project}/locations/{locat"
+ + "ion}/conversations/{conversation}/partic"
+ + "ipants/{participant}\"\214\005\n\007Message\022\021\n\004name"
+ + "\030\001 \001(\tB\003\340A\001\022\024\n\007content\030\002 \001(\tB\003\340A\002\022\032\n\rlan"
+ + "guage_code\030\003 \001(\tB\003\340A\001\022\030\n\013participant\030\004 \001"
+ + "(\tB\003\340A\003\022K\n\020participant_role\030\005 \001(\0162,.goog"
+ + "le.cloud.dialogflow.v2.Participant.RoleB"
+ + "\003\340A\003\0224\n\013create_time\030\006 \001(\0132\032.google.proto"
+ + "buf.TimestampB\003\340A\003\0222\n\tsend_time\030\t \001(\0132\032."
+ + "google.protobuf.TimestampB\003\340A\001\022N\n\022messag"
+ + "e_annotation\030\007 \001(\0132-.google.cloud.dialog"
+ + "flow.v2.MessageAnnotationB\003\340A\003\022T\n\022sentim"
+ + "ent_analysis\030\010 \001(\01323.google.cloud.dialog"
+ + "flow.v2.SentimentAnalysisResultB\003\340A\003:\304\001\352"
+ + "A\300\001\n!dialogflow.googleapis.com/Message\022B"
+ + "projects/{project}/conversations/{conver"
+ + "sation}/messages/{message}\022Wprojects/{pr"
+ + "oject}/locations/{location}/conversation"
+ + "s/{conversation}/messages/{message}\"\234\001\n\030"
+ + "CreateParticipantRequest\022=\n\006parent\030\001 \001(\t"
+ + "B-\340A\002\372A\'\022%dialogflow.googleapis.com/Part"
+ + "icipant\022A\n\013participant\030\002 \001(\0132\'.google.cl"
+ + "oud.dialogflow.v2.ParticipantB\003\340A\002\"T\n\025Ge"
+ + "tParticipantRequest\022;\n\004name\030\001 \001(\tB-\340A\002\372A"
+ + "\'\n%dialogflow.googleapis.com/Participant"
+ + "\"\211\001\n\027ListParticipantsRequest\022=\n\006parent\030\001"
+ + " \001(\tB-\340A\002\372A\'\022%dialogflow.googleapis.com/"
+ + "Participant\022\026\n\tpage_size\030\002 \001(\005B\003\340A\001\022\027\n\np"
+ + "age_token\030\003 \001(\tB\003\340A\001\"r\n\030ListParticipants"
+ + "Response\022=\n\014participants\030\001 \003(\0132\'.google."
+ + "cloud.dialogflow.v2.Participant\022\027\n\017next_"
+ + "page_token\030\002 \001(\t\"\223\001\n\030UpdateParticipantRe"
+ + "quest\022A\n\013participant\030\001 \001(\0132\'.google.clou"
+ + "d.dialogflow.v2.ParticipantB\003\340A\002\0224\n\013upda"
+ + "te_mask\030\002 \001(\0132\032.google.protobuf.FieldMas"
+ + "kB\003\340A\002\"\202\004\n\025AnalyzeContentRequest\022B\n\013part"
+ + "icipant\030\001 \001(\tB-\340A\002\372A\'\n%dialogflow.google"
+ + "apis.com/Participant\022;\n\ntext_input\030\006 \001(\013"
+ + "2%.google.cloud.dialogflow.v2.TextInputH"
+ + "\000\022=\n\013event_input\030\010 \001(\0132&.google.cloud.di"
+ + "alogflow.v2.EventInputH\000\022I\n\022reply_audio_"
+ + "config\030\005 \001(\0132-.google.cloud.dialogflow.v"
+ + "2.OutputAudioConfig\022A\n\014query_params\030\t \001("
+ + "\0132+.google.cloud.dialogflow.v2.QueryPara"
+ + "meters\022N\n\023assist_query_params\030\016 \001(\01321.go"
+ + "ogle.cloud.dialogflow.v2.AssistQueryPara"
+ + "meters\022.\n\rcx_parameters\030\022 \001(\0132\027.google.p"
+ + "rotobuf.Struct\022\022\n\nrequest_id\030\013 \001(\tB\007\n\005in"
+ + "put\",\n\016DtmfParameters\022\032\n\022accepts_dtmf_in"
+ + "put\030\001 \001(\010\"\336\003\n\026AnalyzeContentResponse\022\022\n\n"
+ + "reply_text\030\001 \001(\t\022<\n\013reply_audio\030\002 \001(\0132\'."
+ + "google.cloud.dialogflow.v2.OutputAudio\022N"
+ + "\n\025automated_agent_reply\030\003 \001(\0132/.google.c"
+ + "loud.dialogflow.v2.AutomatedAgentReply\0224"
+ + "\n\007message\030\005 \001(\0132#.google.cloud.dialogflo"
+ + "w.v2.Message\022T\n\036human_agent_suggestion_r"
+ + "esults\030\006 \003(\0132,.google.cloud.dialogflow.v"
+ + "2.SuggestionResult\022Q\n\033end_user_suggestio"
+ + "n_results\030\007 \003(\0132,.google.cloud.dialogflo"
+ + "w.v2.SuggestionResult\022C\n\017dtmf_parameters"
+ + "\030\t \001(\0132*.google.cloud.dialogflow.v2.Dtmf"
+ + "Parameters\"\261\005\n\036StreamingAnalyzeContentRe"
+ + "quest\022B\n\013participant\030\001 \001(\tB-\340A\002\372A\'\n%dial"
+ + "ogflow.googleapis.com/Participant\022D\n\014aud"
+ + "io_config\030\002 \001(\0132,.google.cloud.dialogflo"
+ + "w.v2.InputAudioConfigH\000\022B\n\013text_config\030\003"
+ + " \001(\0132+.google.cloud.dialogflow.v2.InputT"
+ + "extConfigH\000\022I\n\022reply_audio_config\030\004 \001(\0132"
+ + "-.google.cloud.dialogflow.v2.OutputAudio"
+ + "Config\022\025\n\013input_audio\030\005 \001(\014H\001\022\024\n\ninput_t"
+ + "ext\030\006 \001(\tH\001\022E\n\ninput_dtmf\030\t \001(\0132/.google"
+ + ".cloud.dialogflow.v2.TelephonyDtmfEvents"
+ + "H\001\022A\n\014query_params\030\007 \001(\0132+.google.cloud."
+ + "dialogflow.v2.QueryParameters\022N\n\023assist_"
+ + "query_params\030\010 \001(\01321.google.cloud.dialog"
+ + "flow.v2.AssistQueryParameters\022.\n\rcx_para"
+ + "meters\030\r \001(\0132\027.google.protobuf.Struct\022,\n"
+ + "$enable_partial_automated_agent_reply\030\014 "
+ + "\001(\010B\010\n\006configB\007\n\005input\"\273\004\n\037StreamingAnal"
+ + "yzeContentResponse\022R\n\022recognition_result"
+ + "\030\001 \001(\01326.google.cloud.dialogflow.v2.Stre"
+ + "amingRecognitionResult\022\022\n\nreply_text\030\002 \001"
+ + "(\t\022<\n\013reply_audio\030\003 \001(\0132\'.google.cloud.d"
+ + "ialogflow.v2.OutputAudio\022N\n\025automated_ag"
+ + "ent_reply\030\004 \001(\0132/.google.cloud.dialogflo"
+ + "w.v2.AutomatedAgentReply\0224\n\007message\030\006 \001("
+ + "\0132#.google.cloud.dialogflow.v2.Message\022T"
+ + "\n\036human_agent_suggestion_results\030\007 \003(\0132,"
+ + ".google.cloud.dialogflow.v2.SuggestionRe"
+ + "sult\022Q\n\033end_user_suggestion_results\030\010 \003("
+ + "\0132,.google.cloud.dialogflow.v2.Suggestio"
+ + "nResult\022C\n\017dtmf_parameters\030\n \001(\0132*.googl"
+ + "e.cloud.dialogflow.v2.DtmfParameters\"\205\002\n"
+ + "\026SuggestArticlesRequest\022=\n\006parent\030\001 \001(\tB"
+ + "-\340A\002\372A\'\n%dialogflow.googleapis.com/Parti"
+ + "cipant\022A\n\016latest_message\030\002 \001(\tB)\340A\001\372A#\n!"
+ + "dialogflow.googleapis.com/Message\022\031\n\014con"
+ + "text_size\030\003 \001(\005B\003\340A\001\022N\n\023assist_query_par"
+ + "ams\030\004 \001(\01321.google.cloud.dialogflow.v2.A"
+ + "ssistQueryParameters\"\213\001\n\027SuggestArticles"
+ + "Response\022B\n\017article_answers\030\001 \003(\0132).goog"
+ + "le.cloud.dialogflow.v2.ArticleAnswer\022\026\n\016"
+ + "latest_message\030\002 \001(\t\022\024\n\014context_size\030\003 \001"
+ + "(\005\"\207\002\n\030SuggestFaqAnswersRequest\022=\n\006paren"
+ + "t\030\001 \001(\tB-\340A\002\372A\'\n%dialogflow.googleapis.c"
+ + "om/Participant\022A\n\016latest_message\030\002 \001(\tB)"
+ + "\340A\001\372A#\n!dialogflow.googleapis.com/Messag"
+ + "e\022\031\n\014context_size\030\003 \001(\005B\003\340A\001\022N\n\023assist_q"
+ + "uery_params\030\004 \001(\01321.google.cloud.dialogf"
+ + "low.v2.AssistQueryParameters\"\205\001\n\031Suggest"
+ + "FaqAnswersResponse\022:\n\013faq_answers\030\001 \003(\0132"
+ + "%.google.cloud.dialogflow.v2.FaqAnswer\022\026"
+ + "\n\016latest_message\030\002 \001(\t\022\024\n\014context_size\030\003"
+ + " \001(\005\"\364\001\n\032SuggestSmartRepliesRequest\022=\n\006p"
+ "arent\030\001 \001(\tB-\340A\002\372A\'\n%dialogflow.googleap"
- + "is.com/Participant\022A\n\016latest_message\030\002 \001"
- + "(\tB)\340A\001\372A#\n!dialogflow.googleapis.com/Me"
- + "ssage\022\031\n\014context_size\030\003 \001(\005B\003\340A\001\022N\n\023assi"
- + "st_query_params\030\004 \001(\01321.google.cloud.dia"
- + "logflow.v2.AssistQueryParameters\"\213\001\n\027Sug"
- + "gestArticlesResponse\022B\n\017article_answers\030"
- + "\001 \003(\0132).google.cloud.dialogflow.v2.Artic"
- + "leAnswer\022\026\n\016latest_message\030\002 \001(\t\022\024\n\014cont"
- + "ext_size\030\003 \001(\005\"\207\002\n\030SuggestFaqAnswersRequ"
- + "est\022=\n\006parent\030\001 \001(\tB-\340A\002\372A\'\n%dialogflow."
- + "googleapis.com/Participant\022A\n\016latest_mes"
- + "sage\030\002 \001(\tB)\340A\001\372A#\n!dialogflow.googleapi"
- + "s.com/Message\022\031\n\014context_size\030\003 \001(\005B\003\340A\001"
- + "\022N\n\023assist_query_params\030\004 \001(\01321.google.c"
- + "loud.dialogflow.v2.AssistQueryParameters"
- + "\"\205\001\n\031SuggestFaqAnswersResponse\022:\n\013faq_an"
- + "swers\030\001 \003(\0132%.google.cloud.dialogflow.v2"
- + ".FaqAnswer\022\026\n\016latest_message\030\002 \001(\t\022\024\n\014co"
- + "ntext_size\030\003 \001(\005\"\364\001\n\032SuggestSmartReplies"
- + "Request\022=\n\006parent\030\001 \001(\tB-\340A\002\372A\'\n%dialogf"
- + "low.googleapis.com/Participant\022A\n\022curren"
- + "t_text_input\030\004 \001(\0132%.google.cloud.dialog"
- + "flow.v2.TextInput\022>\n\016latest_message\030\002 \001("
- + "\tB&\372A#\n!dialogflow.googleapis.com/Messag"
- + "e\022\024\n\014context_size\030\003 \001(\005\"\303\001\n\033SuggestSmart"
- + "RepliesResponse\022N\n\023smart_reply_answers\030\001"
- + " \003(\0132,.google.cloud.dialogflow.v2.SmartR"
- + "eplyAnswerB\003\340A\003\022>\n\016latest_message\030\002 \001(\tB"
- + "&\372A#\n!dialogflow.googleapis.com/Message\022"
- + "\024\n\014context_size\030\003 \001(\005\"[\n\013OutputAudio\022=\n\006"
- + "config\030\001 \001(\0132-.google.cloud.dialogflow.v"
- + "2.OutputAudioConfig\022\r\n\005audio\030\002 \001(\014\"\317\002\n\023A"
- + "utomatedAgentReply\022P\n\026detect_intent_resp"
- + "onse\030\001 \001(\01320.google.cloud.dialogflow.v2."
- + "DetectIntentResponse\022k\n\032automated_agent_"
- + "reply_type\030\007 \001(\0162G.google.cloud.dialogfl"
- + "ow.v2.AutomatedAgentReply.AutomatedAgent"
- + "ReplyType\022\032\n\022allow_cancellation\030\010 \001(\010\"]\n"
- + "\027AutomatedAgentReplyType\022*\n&AUTOMATED_AG"
- + "ENT_REPLY_TYPE_UNSPECIFIED\020\000\022\013\n\007PARTIAL\020"
- + "\001\022\t\n\005FINAL\020\002\"\344\001\n\rArticleAnswer\022\r\n\005title\030"
- + "\001 \001(\t\022\013\n\003uri\030\002 \001(\t\022\020\n\010snippets\030\003 \003(\t\022\022\n\n"
- + "confidence\030\004 \001(\002\022I\n\010metadata\030\005 \003(\01327.goo"
- + "gle.cloud.dialogflow.v2.ArticleAnswer.Me"
- + "tadataEntry\022\025\n\ranswer_record\030\006 \001(\t\032/\n\rMe"
- + "tadataEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:"
- + "\0028\001\"\340\001\n\tFaqAnswer\022\016\n\006answer\030\001 \001(\t\022\022\n\ncon"
- + "fidence\030\002 \001(\002\022\020\n\010question\030\003 \001(\t\022\016\n\006sourc"
- + "e\030\004 \001(\t\022E\n\010metadata\030\005 \003(\01323.google.cloud"
- + ".dialogflow.v2.FaqAnswer.MetadataEntry\022\025"
- + "\n\ranswer_record\030\006 \001(\t\032/\n\rMetadataEntry\022\013"
- + "\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"y\n\020SmartR"
- + "eplyAnswer\022\r\n\005reply\030\001 \001(\t\022\022\n\nconfidence\030"
- + "\002 \001(\002\022B\n\ranswer_record\030\003 \001(\tB+\372A(\n&dialo"
- + "gflow.googleapis.com/AnswerRecord\"\352\002\n\020Su"
- + "ggestionResult\022#\n\005error\030\001 \001(\0132\022.google.r"
- + "pc.StatusH\000\022X\n\031suggest_articles_response"
- + "\030\002 \001(\01323.google.cloud.dialogflow.v2.Sugg"
- + "estArticlesResponseH\000\022]\n\034suggest_faq_ans"
- + "wers_response\030\003 \001(\01325.google.cloud.dialo"
- + "gflow.v2.SuggestFaqAnswersResponseH\000\022a\n\036"
- + "suggest_smart_replies_response\030\004 \001(\01327.g"
- + "oogle.cloud.dialogflow.v2.SuggestSmartRe"
- + "pliesResponseH\000B\025\n\023suggestion_response\"j"
- + "\n\024AnnotatedMessagePart\022\014\n\004text\030\001 \001(\t\022\023\n\013"
- + "entity_type\030\002 \001(\t\022/\n\017formatted_value\030\003 \001"
- + "(\0132\026.google.protobuf.Value\"n\n\021MessageAnn"
- + "otation\022?\n\005parts\030\001 \003(\01320.google.cloud.di"
- + "alogflow.v2.AnnotatedMessagePart\022\030\n\020cont"
- + "ain_entities\030\002 \001(\010\"\315\001\n\025AssistQueryParame"
- + "ters\022s\n\032documents_metadata_filters\030\001 \003(\013"
- + "2O.google.cloud.dialogflow.v2.AssistQuer"
- + "yParameters.DocumentsMetadataFiltersEntr"
- + "y\032?\n\035DocumentsMetadataFiltersEntry\022\013\n\003ke"
- + "y\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\0012\337\024\n\014Participa"
- + "nts\022\245\002\n\021CreateParticipant\0224.google.cloud"
- + ".dialogflow.v2.CreateParticipantRequest\032"
- + "\'.google.cloud.dialogflow.v2.Participant"
- + "\"\260\001\202\323\344\223\002\224\001\"4/v2/{parent=projects/*/conve"
- + "rsations/*}/participants:\013participantZO\""
- + "@/v2/{parent=projects/*/locations/*/conv"
- + "ersations/*}/participants:\013participant\332A"
- + "\022parent,participant\022\366\001\n\016GetParticipant\0221"
- + ".google.cloud.dialogflow.v2.GetParticipa"
- + "ntRequest\032\'.google.cloud.dialogflow.v2.P"
- + "articipant\"\207\001\202\323\344\223\002z\0224/v2/{name=projects/"
- + "*/conversations/*/participants/*}ZB\022@/v2"
- + "/{name=projects/*/locations/*/conversati"
- + "ons/*/participants/*}\332A\004name\022\211\002\n\020ListPar"
- + "ticipants\0223.google.cloud.dialogflow.v2.L"
- + "istParticipantsRequest\0324.google.cloud.di"
- + "alogflow.v2.ListParticipantsResponse\"\211\001\202"
- + "\323\344\223\002z\0224/v2/{parent=projects/*/conversati"
- + "ons/*}/participantsZB\022@/v2/{parent=proje"
- + "cts/*/locations/*/conversations/*}/parti"
- + "cipants\332A\006parent\022\302\002\n\021UpdateParticipant\0224"
- + ".google.cloud.dialogflow.v2.UpdatePartic"
- + "ipantRequest\032\'.google.cloud.dialogflow.v"
- + "2.Participant\"\315\001\202\323\344\223\002\254\0012@/v2/{participan"
- + "t.name=projects/*/conversations/*/partic"
- + "ipants/*}:\013participantZ[2L/v2/{participa"
- + "nt.name=projects/*/locations/*/conversat"
- + "ions/*/participants/*}:\013participant\332A\027pa"
- + "rticipant,update_mask\022\340\002\n\016AnalyzeContent"
- + "\0221.google.cloud.dialogflow.v2.AnalyzeCon"
- + "tentRequest\0322.google.cloud.dialogflow.v2"
- + ".AnalyzeContentResponse\"\346\001\202\323\344\223\002\254\001\"J/v2/{"
- + "participant=projects/*/conversations/*/p"
- + "articipants/*}:analyzeContent:\001*Z[\"V/v2/"
- + "{participant=projects/*/locations/*/conv"
- + "ersations/*/participants/*}:analyzeConte"
- + "nt:\001*\332A\026participant,text_input\332A\027partici"
- + "pant,event_input\022\311\002\n\017SuggestArticles\0222.g"
- + "oogle.cloud.dialogflow.v2.SuggestArticle"
- + "sRequest\0323.google.cloud.dialogflow.v2.Su"
- + "ggestArticlesResponse\"\314\001\202\323\344\223\002\274\001\"R/v2/{pa"
- + "rent=projects/*/conversations/*/particip"
- + "ants/*}/suggestions:suggestArticles:\001*Zc"
- + "\"^/v2/{parent=projects/*/locations/*/con"
- + "versations/*/participants/*}/suggestions"
- + ":suggestArticles:\001*\332A\006parent\022\323\002\n\021Suggest"
- + "FaqAnswers\0224.google.cloud.dialogflow.v2."
- + "SuggestFaqAnswersRequest\0325.google.cloud."
- + "dialogflow.v2.SuggestFaqAnswersResponse\""
- + "\320\001\202\323\344\223\002\300\001\"T/v2/{parent=projects/*/conver"
- + "sations/*/participants/*}/suggestions:su"
- + "ggestFaqAnswers:\001*Ze\"`/v2/{parent=projec"
- + "ts/*/locations/*/conversations/*/partici"
- + "pants/*}/suggestions:suggestFaqAnswers:\001"
- + "*\332A\006parent\022\335\002\n\023SuggestSmartReplies\0226.goo"
- + "gle.cloud.dialogflow.v2.SuggestSmartRepl"
- + "iesRequest\0327.google.cloud.dialogflow.v2."
- + "SuggestSmartRepliesResponse\"\324\001\202\323\344\223\002\304\001\"V/"
- + "v2/{parent=projects/*/conversations/*/pa"
- + "rticipants/*}/suggestions:suggestSmartRe"
- + "plies:\001*Zg\"b/v2/{parent=projects/*/locat"
+ + "is.com/Participant\022A\n\022current_text_input"
+ + "\030\004 \001(\0132%.google.cloud.dialogflow.v2.Text"
+ + "Input\022>\n\016latest_message\030\002 \001(\tB&\372A#\n!dial"
+ + "ogflow.googleapis.com/Message\022\024\n\014context"
+ + "_size\030\003 \001(\005\"\303\001\n\033SuggestSmartRepliesRespo"
+ + "nse\022N\n\023smart_reply_answers\030\001 \003(\0132,.googl"
+ + "e.cloud.dialogflow.v2.SmartReplyAnswerB\003"
+ + "\340A\003\022>\n\016latest_message\030\002 \001(\tB&\372A#\n!dialog"
+ + "flow.googleapis.com/Message\022\024\n\014context_s"
+ + "ize\030\003 \001(\005\"[\n\013OutputAudio\022=\n\006config\030\001 \001(\013"
+ + "2-.google.cloud.dialogflow.v2.OutputAudi"
+ + "oConfig\022\r\n\005audio\030\002 \001(\014\"\317\002\n\023AutomatedAgen"
+ + "tReply\022P\n\026detect_intent_response\030\001 \001(\01320"
+ + ".google.cloud.dialogflow.v2.DetectIntent"
+ + "Response\022k\n\032automated_agent_reply_type\030\007"
+ + " \001(\0162G.google.cloud.dialogflow.v2.Automa"
+ + "tedAgentReply.AutomatedAgentReplyType\022\032\n"
+ + "\022allow_cancellation\030\010 \001(\010\"]\n\027AutomatedAg"
+ + "entReplyType\022*\n&AUTOMATED_AGENT_REPLY_TY"
+ + "PE_UNSPECIFIED\020\000\022\013\n\007PARTIAL\020\001\022\t\n\005FINAL\020\002"
+ + "\"\344\001\n\rArticleAnswer\022\r\n\005title\030\001 \001(\t\022\013\n\003uri"
+ + "\030\002 \001(\t\022\020\n\010snippets\030\003 \003(\t\022\022\n\nconfidence\030\004"
+ + " \001(\002\022I\n\010metadata\030\005 \003(\01327.google.cloud.di"
+ + "alogflow.v2.ArticleAnswer.MetadataEntry\022"
+ + "\025\n\ranswer_record\030\006 \001(\t\032/\n\rMetadataEntry\022"
+ + "\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"\340\001\n\tFaqA"
+ + "nswer\022\016\n\006answer\030\001 \001(\t\022\022\n\nconfidence\030\002 \001("
+ + "\002\022\020\n\010question\030\003 \001(\t\022\016\n\006source\030\004 \001(\t\022E\n\010m"
+ + "etadata\030\005 \003(\01323.google.cloud.dialogflow."
+ + "v2.FaqAnswer.MetadataEntry\022\025\n\ranswer_rec"
+ + "ord\030\006 \001(\t\032/\n\rMetadataEntry\022\013\n\003key\030\001 \001(\t\022"
+ + "\r\n\005value\030\002 \001(\t:\0028\001\"y\n\020SmartReplyAnswer\022\r"
+ + "\n\005reply\030\001 \001(\t\022\022\n\nconfidence\030\002 \001(\002\022B\n\rans"
+ + "wer_record\030\003 \001(\tB+\372A(\n&dialogflow.google"
+ + "apis.com/AnswerRecord\"\352\002\n\020SuggestionResu"
+ + "lt\022#\n\005error\030\001 \001(\0132\022.google.rpc.StatusH\000\022"
+ + "X\n\031suggest_articles_response\030\002 \001(\01323.goo"
+ + "gle.cloud.dialogflow.v2.SuggestArticlesR"
+ + "esponseH\000\022]\n\034suggest_faq_answers_respons"
+ + "e\030\003 \001(\01325.google.cloud.dialogflow.v2.Sug"
+ + "gestFaqAnswersResponseH\000\022a\n\036suggest_smar"
+ + "t_replies_response\030\004 \001(\01327.google.cloud."
+ + "dialogflow.v2.SuggestSmartRepliesRespons"
+ + "eH\000B\025\n\023suggestion_response\"-\n\017InputTextC"
+ + "onfig\022\032\n\rlanguage_code\030\001 \001(\tB\003\340A\002\"j\n\024Ann"
+ + "otatedMessagePart\022\014\n\004text\030\001 \001(\t\022\023\n\013entit"
+ + "y_type\030\002 \001(\t\022/\n\017formatted_value\030\003 \001(\0132\026."
+ + "google.protobuf.Value\"n\n\021MessageAnnotati"
+ + "on\022?\n\005parts\030\001 \003(\01320.google.cloud.dialogf"
+ + "low.v2.AnnotatedMessagePart\022\030\n\020contain_e"
+ + "ntities\030\002 \001(\010\"\315\001\n\025AssistQueryParameters\022"
+ + "s\n\032documents_metadata_filters\030\001 \003(\0132O.go"
+ + "ogle.cloud.dialogflow.v2.AssistQueryPara"
+ + "meters.DocumentsMetadataFiltersEntry\032?\n\035"
+ + "DocumentsMetadataFiltersEntry\022\013\n\003key\030\001 \001"
+ + "(\t\022\r\n\005value\030\002 \001(\t:\0028\0012\372\025\n\014Participants\022\245"
+ + "\002\n\021CreateParticipant\0224.google.cloud.dial"
+ + "ogflow.v2.CreateParticipantRequest\032\'.goo"
+ + "gle.cloud.dialogflow.v2.Participant\"\260\001\202\323"
+ + "\344\223\002\224\001\"4/v2/{parent=projects/*/conversati"
+ + "ons/*}/participants:\013participantZO\"@/v2/"
+ + "{parent=projects/*/locations/*/conversat"
+ + "ions/*}/participants:\013participant\332A\022pare"
+ + "nt,participant\022\366\001\n\016GetParticipant\0221.goog"
+ + "le.cloud.dialogflow.v2.GetParticipantReq"
+ + "uest\032\'.google.cloud.dialogflow.v2.Partic"
+ + "ipant\"\207\001\202\323\344\223\002z\0224/v2/{name=projects/*/con"
+ + "versations/*/participants/*}ZB\022@/v2/{nam"
+ + "e=projects/*/locations/*/conversations/*"
+ + "/participants/*}\332A\004name\022\211\002\n\020ListParticip"
+ + "ants\0223.google.cloud.dialogflow.v2.ListPa"
+ + "rticipantsRequest\0324.google.cloud.dialogf"
+ + "low.v2.ListParticipantsResponse\"\211\001\202\323\344\223\002z"
+ + "\0224/v2/{parent=projects/*/conversations/*"
+ + "}/participantsZB\022@/v2/{parent=projects/*"
+ + "/locations/*/conversations/*}/participan"
+ + "ts\332A\006parent\022\302\002\n\021UpdateParticipant\0224.goog"
+ + "le.cloud.dialogflow.v2.UpdateParticipant"
+ + "Request\032\'.google.cloud.dialogflow.v2.Par"
+ + "ticipant\"\315\001\202\323\344\223\002\254\0012@/v2/{participant.nam"
+ + "e=projects/*/conversations/*/participant"
+ + "s/*}:\013participantZ[2L/v2/{participant.na"
+ + "me=projects/*/locations/*/conversations/"
+ + "*/participants/*}:\013participant\332A\027partici"
+ + "pant,update_mask\022\340\002\n\016AnalyzeContent\0221.go"
+ + "ogle.cloud.dialogflow.v2.AnalyzeContentR"
+ + "equest\0322.google.cloud.dialogflow.v2.Anal"
+ + "yzeContentResponse\"\346\001\202\323\344\223\002\254\001\"J/v2/{parti"
+ + "cipant=projects/*/conversations/*/partic"
+ + "ipants/*}:analyzeContent:\001*Z[\"V/v2/{part"
+ + "icipant=projects/*/locations/*/conversat"
+ + "ions/*/participants/*}:analyzeContent:\001*"
+ + "\332A\026participant,text_input\332A\027participant,"
+ + "event_input\022\230\001\n\027StreamingAnalyzeContent\022"
+ + ":.google.cloud.dialogflow.v2.StreamingAn"
+ + "alyzeContentRequest\032;.google.cloud.dialo"
+ + "gflow.v2.StreamingAnalyzeContentResponse"
+ + "\"\000(\0010\001\022\311\002\n\017SuggestArticles\0222.google.clou"
+ + "d.dialogflow.v2.SuggestArticlesRequest\0323"
+ + ".google.cloud.dialogflow.v2.SuggestArtic"
+ + "lesResponse\"\314\001\202\323\344\223\002\274\001\"R/v2/{parent=proje"
+ + "cts/*/conversations/*/participants/*}/su"
+ + "ggestions:suggestArticles:\001*Zc\"^/v2/{par"
+ + "ent=projects/*/locations/*/conversations"
+ + "/*/participants/*}/suggestions:suggestAr"
+ + "ticles:\001*\332A\006parent\022\323\002\n\021SuggestFaqAnswers"
+ + "\0224.google.cloud.dialogflow.v2.SuggestFaq"
+ + "AnswersRequest\0325.google.cloud.dialogflow"
+ + ".v2.SuggestFaqAnswersResponse\"\320\001\202\323\344\223\002\300\001\""
+ + "T/v2/{parent=projects/*/conversations/*/"
+ + "participants/*}/suggestions:suggestFaqAn"
+ + "swers:\001*Ze\"`/v2/{parent=projects/*/locat"
+ "ions/*/conversations/*/participants/*}/s"
- + "uggestions:suggestSmartReplies:\001*\332A\006pare"
- + "nt\032x\312A\031dialogflow.googleapis.com\322AYhttps"
- + "://www.googleapis.com/auth/cloud-platfor"
- + "m,https://www.googleapis.com/auth/dialog"
- + "flowB\237\001\n\036com.google.cloud.dialogflow.v2B"
- + "\020ParticipantProtoP\001ZDgoogle.golang.org/g"
- + "enproto/googleapis/cloud/dialogflow/v2;d"
- + "ialogflow\370\001\001\242\002\002DF\252\002\032Google.Cloud.Dialogf"
- + "low.V2b\006proto3"
+ + "uggestions:suggestFaqAnswers:\001*\332A\006parent"
+ + "\022\335\002\n\023SuggestSmartReplies\0226.google.cloud."
+ + "dialogflow.v2.SuggestSmartRepliesRequest"
+ + "\0327.google.cloud.dialogflow.v2.SuggestSma"
+ + "rtRepliesResponse\"\324\001\202\323\344\223\002\304\001\"V/v2/{parent"
+ + "=projects/*/conversations/*/participants"
+ + "/*}/suggestions:suggestSmartReplies:\001*Zg"
+ + "\"b/v2/{parent=projects/*/locations/*/con"
+ + "versations/*/participants/*}/suggestions"
+ + ":suggestSmartReplies:\001*\332A\006parent\032x\312A\031dia"
+ + "logflow.googleapis.com\322AYhttps://www.goo"
+ + "gleapis.com/auth/cloud-platform,https://"
+ + "www.googleapis.com/auth/dialogflowB\237\001\n\036c"
+ + "om.google.cloud.dialogflow.v2B\020Participa"
+ + "ntProtoP\001ZDgoogle.golang.org/genproto/go"
+ + "ogleapis/cloud/dialogflow/v2;dialogflow\370"
+ + "\001\001\242\002\002DF\252\002\032Google.Cloud.Dialogflow.V2b\006pr"
+ + "oto3"
};
descriptor =
com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom(
@@ -406,7 +456,11 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_Participant_descriptor,
new java.lang.String[] {
- "Name", "Role", "SipRecordingMediaLabel", "DocumentsMetadataFilters",
+ "Name",
+ "Role",
+ "SipRecordingMediaLabel",
+ "ObfuscatedExternalUserId",
+ "DocumentsMetadataFilters",
});
internal_static_google_cloud_dialogflow_v2_Participant_DocumentsMetadataFiltersEntry_descriptor =
internal_static_google_cloud_dialogflow_v2_Participant_descriptor.getNestedTypes().get(0);
@@ -510,8 +564,43 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"EndUserSuggestionResults",
"DtmfParameters",
});
- internal_static_google_cloud_dialogflow_v2_SuggestArticlesRequest_descriptor =
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_descriptor =
getDescriptor().getMessageTypes().get(10);
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_fieldAccessorTable =
+ new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_descriptor,
+ new java.lang.String[] {
+ "Participant",
+ "AudioConfig",
+ "TextConfig",
+ "ReplyAudioConfig",
+ "InputAudio",
+ "InputText",
+ "InputDtmf",
+ "QueryParams",
+ "AssistQueryParams",
+ "CxParameters",
+ "EnablePartialAutomatedAgentReply",
+ "Config",
+ "Input",
+ });
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_descriptor =
+ getDescriptor().getMessageTypes().get(11);
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_fieldAccessorTable =
+ new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_descriptor,
+ new java.lang.String[] {
+ "RecognitionResult",
+ "ReplyText",
+ "ReplyAudio",
+ "AutomatedAgentReply",
+ "Message",
+ "HumanAgentSuggestionResults",
+ "EndUserSuggestionResults",
+ "DtmfParameters",
+ });
+ internal_static_google_cloud_dialogflow_v2_SuggestArticlesRequest_descriptor =
+ getDescriptor().getMessageTypes().get(12);
internal_static_google_cloud_dialogflow_v2_SuggestArticlesRequest_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestArticlesRequest_descriptor,
@@ -519,7 +608,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Parent", "LatestMessage", "ContextSize", "AssistQueryParams",
});
internal_static_google_cloud_dialogflow_v2_SuggestArticlesResponse_descriptor =
- getDescriptor().getMessageTypes().get(11);
+ getDescriptor().getMessageTypes().get(13);
internal_static_google_cloud_dialogflow_v2_SuggestArticlesResponse_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestArticlesResponse_descriptor,
@@ -527,7 +616,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"ArticleAnswers", "LatestMessage", "ContextSize",
});
internal_static_google_cloud_dialogflow_v2_SuggestFaqAnswersRequest_descriptor =
- getDescriptor().getMessageTypes().get(12);
+ getDescriptor().getMessageTypes().get(14);
internal_static_google_cloud_dialogflow_v2_SuggestFaqAnswersRequest_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestFaqAnswersRequest_descriptor,
@@ -535,7 +624,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Parent", "LatestMessage", "ContextSize", "AssistQueryParams",
});
internal_static_google_cloud_dialogflow_v2_SuggestFaqAnswersResponse_descriptor =
- getDescriptor().getMessageTypes().get(13);
+ getDescriptor().getMessageTypes().get(15);
internal_static_google_cloud_dialogflow_v2_SuggestFaqAnswersResponse_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestFaqAnswersResponse_descriptor,
@@ -543,7 +632,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"FaqAnswers", "LatestMessage", "ContextSize",
});
internal_static_google_cloud_dialogflow_v2_SuggestSmartRepliesRequest_descriptor =
- getDescriptor().getMessageTypes().get(14);
+ getDescriptor().getMessageTypes().get(16);
internal_static_google_cloud_dialogflow_v2_SuggestSmartRepliesRequest_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestSmartRepliesRequest_descriptor,
@@ -551,7 +640,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Parent", "CurrentTextInput", "LatestMessage", "ContextSize",
});
internal_static_google_cloud_dialogflow_v2_SuggestSmartRepliesResponse_descriptor =
- getDescriptor().getMessageTypes().get(15);
+ getDescriptor().getMessageTypes().get(17);
internal_static_google_cloud_dialogflow_v2_SuggestSmartRepliesResponse_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestSmartRepliesResponse_descriptor,
@@ -559,7 +648,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"SmartReplyAnswers", "LatestMessage", "ContextSize",
});
internal_static_google_cloud_dialogflow_v2_OutputAudio_descriptor =
- getDescriptor().getMessageTypes().get(16);
+ getDescriptor().getMessageTypes().get(18);
internal_static_google_cloud_dialogflow_v2_OutputAudio_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_OutputAudio_descriptor,
@@ -567,7 +656,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Config", "Audio",
});
internal_static_google_cloud_dialogflow_v2_AutomatedAgentReply_descriptor =
- getDescriptor().getMessageTypes().get(17);
+ getDescriptor().getMessageTypes().get(19);
internal_static_google_cloud_dialogflow_v2_AutomatedAgentReply_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_AutomatedAgentReply_descriptor,
@@ -575,7 +664,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"DetectIntentResponse", "AutomatedAgentReplyType", "AllowCancellation",
});
internal_static_google_cloud_dialogflow_v2_ArticleAnswer_descriptor =
- getDescriptor().getMessageTypes().get(18);
+ getDescriptor().getMessageTypes().get(20);
internal_static_google_cloud_dialogflow_v2_ArticleAnswer_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_ArticleAnswer_descriptor,
@@ -591,7 +680,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Key", "Value",
});
internal_static_google_cloud_dialogflow_v2_FaqAnswer_descriptor =
- getDescriptor().getMessageTypes().get(19);
+ getDescriptor().getMessageTypes().get(21);
internal_static_google_cloud_dialogflow_v2_FaqAnswer_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_FaqAnswer_descriptor,
@@ -607,7 +696,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Key", "Value",
});
internal_static_google_cloud_dialogflow_v2_SmartReplyAnswer_descriptor =
- getDescriptor().getMessageTypes().get(20);
+ getDescriptor().getMessageTypes().get(22);
internal_static_google_cloud_dialogflow_v2_SmartReplyAnswer_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SmartReplyAnswer_descriptor,
@@ -615,7 +704,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Reply", "Confidence", "AnswerRecord",
});
internal_static_google_cloud_dialogflow_v2_SuggestionResult_descriptor =
- getDescriptor().getMessageTypes().get(21);
+ getDescriptor().getMessageTypes().get(23);
internal_static_google_cloud_dialogflow_v2_SuggestionResult_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_SuggestionResult_descriptor,
@@ -626,8 +715,16 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"SuggestSmartRepliesResponse",
"SuggestionResponse",
});
+ internal_static_google_cloud_dialogflow_v2_InputTextConfig_descriptor =
+ getDescriptor().getMessageTypes().get(24);
+ internal_static_google_cloud_dialogflow_v2_InputTextConfig_fieldAccessorTable =
+ new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
+ internal_static_google_cloud_dialogflow_v2_InputTextConfig_descriptor,
+ new java.lang.String[] {
+ "LanguageCode",
+ });
internal_static_google_cloud_dialogflow_v2_AnnotatedMessagePart_descriptor =
- getDescriptor().getMessageTypes().get(22);
+ getDescriptor().getMessageTypes().get(25);
internal_static_google_cloud_dialogflow_v2_AnnotatedMessagePart_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_AnnotatedMessagePart_descriptor,
@@ -635,7 +732,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Text", "EntityType", "FormattedValue",
});
internal_static_google_cloud_dialogflow_v2_MessageAnnotation_descriptor =
- getDescriptor().getMessageTypes().get(23);
+ getDescriptor().getMessageTypes().get(26);
internal_static_google_cloud_dialogflow_v2_MessageAnnotation_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_MessageAnnotation_descriptor,
@@ -643,7 +740,7 @@ public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() {
"Parts", "ContainEntities",
});
internal_static_google_cloud_dialogflow_v2_AssistQueryParameters_descriptor =
- getDescriptor().getMessageTypes().get(24);
+ getDescriptor().getMessageTypes().get(27);
internal_static_google_cloud_dialogflow_v2_AssistQueryParameters_fieldAccessorTable =
new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_google_cloud_dialogflow_v2_AssistQueryParameters_descriptor,
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfig.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfig.java
index 62617c082edb..fff262c82a86 100644
--- a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfig.java
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfig.java
@@ -39,6 +39,7 @@ private SpeechToTextConfig(com.google.protobuf.GeneratedMessageV3.Builder> bui
private SpeechToTextConfig() {
speechModelVariant_ = 0;
+ model_ = "";
}
@java.lang.Override
@@ -115,6 +116,67 @@ public com.google.cloud.dialogflow.v2.SpeechModelVariant getSpeechModelVariant()
return result == null ? com.google.cloud.dialogflow.v2.SpeechModelVariant.UNRECOGNIZED : result;
}
+ public static final int MODEL_FIELD_NUMBER = 2;
+ private volatile java.lang.Object model_;
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return The model.
+ */
+ @java.lang.Override
+ public java.lang.String getModel() {
+ java.lang.Object ref = model_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ model_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return The bytes for model.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getModelBytes() {
+ java.lang.Object ref = model_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ model_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
private byte memoizedIsInitialized = -1;
@java.lang.Override
@@ -134,6 +196,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io
.getNumber()) {
output.writeEnum(1, speechModelVariant_);
}
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(model_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 2, model_);
+ }
getUnknownFields().writeTo(output);
}
@@ -148,6 +213,9 @@ public int getSerializedSize() {
.getNumber()) {
size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, speechModelVariant_);
}
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(model_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, model_);
+ }
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
@@ -165,6 +233,7 @@ public boolean equals(final java.lang.Object obj) {
(com.google.cloud.dialogflow.v2.SpeechToTextConfig) obj;
if (speechModelVariant_ != other.speechModelVariant_) return false;
+ if (!getModel().equals(other.getModel())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@@ -178,6 +247,8 @@ public int hashCode() {
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + SPEECH_MODEL_VARIANT_FIELD_NUMBER;
hash = (53 * hash) + speechModelVariant_;
+ hash = (37 * hash) + MODEL_FIELD_NUMBER;
+ hash = (53 * hash) + getModel().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
@@ -318,6 +389,8 @@ public Builder clear() {
super.clear();
speechModelVariant_ = 0;
+ model_ = "";
+
return this;
}
@@ -346,6 +419,7 @@ public com.google.cloud.dialogflow.v2.SpeechToTextConfig buildPartial() {
com.google.cloud.dialogflow.v2.SpeechToTextConfig result =
new com.google.cloud.dialogflow.v2.SpeechToTextConfig(this);
result.speechModelVariant_ = speechModelVariant_;
+ result.model_ = model_;
onBuilt();
return result;
}
@@ -399,6 +473,10 @@ public Builder mergeFrom(com.google.cloud.dialogflow.v2.SpeechToTextConfig other
if (other.speechModelVariant_ != 0) {
setSpeechModelVariantValue(other.getSpeechModelVariantValue());
}
+ if (!other.getModel().isEmpty()) {
+ model_ = other.model_;
+ onChanged();
+ }
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
@@ -431,6 +509,12 @@ public Builder mergeFrom(
break;
} // case 8
+ case 18:
+ {
+ model_ = input.readStringRequireUtf8();
+
+ break;
+ } // case 18
default:
{
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
@@ -571,6 +655,142 @@ public Builder clearSpeechModelVariant() {
return this;
}
+ private java.lang.Object model_ = "";
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return The model.
+ */
+ public java.lang.String getModel() {
+ java.lang.Object ref = model_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ model_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return The bytes for model.
+ */
+ public com.google.protobuf.ByteString getModelBytes() {
+ java.lang.Object ref = model_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ model_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @param value The model to set.
+ * @return This builder for chaining.
+ */
+ public Builder setModel(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ model_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearModel() {
+
+ model_ = getDefaultInstance().getModel();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @param value The bytes for model to set.
+ * @return This builder for chaining.
+ */
+ public Builder setModelBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ model_ = value;
+ onChanged();
+ return this;
+ }
+
@java.lang.Override
public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfigOrBuilder.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfigOrBuilder.java
index 12c64f937699..41989829784c 100644
--- a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfigOrBuilder.java
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/SpeechToTextConfigOrBuilder.java
@@ -59,4 +59,41 @@ public interface SpeechToTextConfigOrBuilder
* @return The speechModelVariant.
*/
com.google.cloud.dialogflow.v2.SpeechModelVariant getSpeechModelVariant();
+
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return The model.
+ */
+ java.lang.String getModel();
+ /**
+ *
+ *
+ * + * Which Speech model to select. Select the model best suited to your domain + * to get best results. If a model is not explicitly specified, then a default + * model is used. + * Refer to + * [Cloud Speech API + * documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model) + * for more details. + *+ * + *
string model = 2;
+ *
+ * @return The bytes for model.
+ */
+ com.google.protobuf.ByteString getModelBytes();
}
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/StreamingAnalyzeContentRequest.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/StreamingAnalyzeContentRequest.java
new file mode 100644
index 000000000000..961444d7efaf
--- /dev/null
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/StreamingAnalyzeContentRequest.java
@@ -0,0 +1,3460 @@
+/*
+ * Copyright 2020 Google LLC
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/cloud/dialogflow/v2/participant.proto
+
+package com.google.cloud.dialogflow.v2;
+
+/**
+ *
+ *
+ * + * The top-level message sent by the client to the + * [Participants.StreamingAnalyzeContent][google.cloud.dialogflow.v2.Participants.StreamingAnalyzeContent] method. + * Multiple request messages should be sent in order: + * 1. The first message must contain + * [participant][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.participant], + * [config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] and optionally + * [query_params][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.query_params]. If you want + * to receive an audio response, it should also contain + * [reply_audio_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.reply_audio_config]. + * The message must not contain + * [input][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input]. + * 2. If [config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] in the first message + * was set to [audio_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.audio_config], + * all subsequent messages must contain + * [input_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input_audio] to continue + * with Speech recognition. + * However, note that: + * * Dialogflow will bill you for the audio so far. + * * Dialogflow discards all Speech recognition results in favor of the + * text input. + * 3. If [StreamingAnalyzeContentRequest.config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] in the first message was set + * to [StreamingAnalyzeContentRequest.text_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.text_config], then the second message + * must contain only [input_text][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input_text]. + * Moreover, you must not send more than two messages. + * After you sent all input, you must half-close or abort the request stream. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest} + */ +public final class StreamingAnalyzeContentRequest extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest) + StreamingAnalyzeContentRequestOrBuilder { + private static final long serialVersionUID = 0L; + // Use StreamingAnalyzeContentRequest.newBuilder() to construct. + private StreamingAnalyzeContentRequest( + com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private StreamingAnalyzeContentRequest() { + participant_ = ""; + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StreamingAnalyzeContentRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.v2.ParticipantProto + .internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.v2.ParticipantProto + .internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentRequest_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.class, + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.Builder.class); + } + + private int configCase_ = 0; + private java.lang.Object config_; + + public enum ConfigCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + AUDIO_CONFIG(2), + TEXT_CONFIG(3), + CONFIG_NOT_SET(0); + private final int value; + + private ConfigCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static ConfigCase valueOf(int value) { + return forNumber(value); + } + + public static ConfigCase forNumber(int value) { + switch (value) { + case 2: + return AUDIO_CONFIG; + case 3: + return TEXT_CONFIG; + case 0: + return CONFIG_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public ConfigCase getConfigCase() { + return ConfigCase.forNumber(configCase_); + } + + private int inputCase_ = 0; + private java.lang.Object input_; + + public enum InputCase + implements + com.google.protobuf.Internal.EnumLite, + com.google.protobuf.AbstractMessage.InternalOneOfEnum { + INPUT_AUDIO(5), + INPUT_TEXT(6), + INPUT_DTMF(9), + INPUT_NOT_SET(0); + private final int value; + + private InputCase(int value) { + this.value = value; + } + /** + * @param value The number of the enum to look for. + * @return The enum associated with the given number. + * @deprecated Use {@link #forNumber(int)} instead. + */ + @java.lang.Deprecated + public static InputCase valueOf(int value) { + return forNumber(value); + } + + public static InputCase forNumber(int value) { + switch (value) { + case 5: + return INPUT_AUDIO; + case 6: + return INPUT_TEXT; + case 9: + return INPUT_DTMF; + case 0: + return INPUT_NOT_SET; + default: + return null; + } + } + + public int getNumber() { + return this.value; + } + }; + + public InputCase getInputCase() { + return InputCase.forNumber(inputCase_); + } + + public static final int PARTICIPANT_FIELD_NUMBER = 1; + private volatile java.lang.Object participant_; + /** + * + * + *
+ * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The participant.
+ */
+ @java.lang.Override
+ public java.lang.String getParticipant() {
+ java.lang.Object ref = participant_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ participant_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The bytes for participant.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getParticipantBytes() {
+ java.lang.Object ref = participant_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ participant_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int AUDIO_CONFIG_FIELD_NUMBER = 2;
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ *
+ * @return Whether the audioConfig field is set.
+ */
+ @java.lang.Override
+ public boolean hasAudioConfig() {
+ return configCase_ == 2;
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ *
+ * @return The audioConfig.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputAudioConfig getAudioConfig() {
+ if (configCase_ == 2) {
+ return (com.google.cloud.dialogflow.v2.InputAudioConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance();
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputAudioConfigOrBuilder getAudioConfigOrBuilder() {
+ if (configCase_ == 2) {
+ return (com.google.cloud.dialogflow.v2.InputAudioConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance();
+ }
+
+ public static final int TEXT_CONFIG_FIELD_NUMBER = 3;
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ *
+ * @return Whether the textConfig field is set.
+ */
+ @java.lang.Override
+ public boolean hasTextConfig() {
+ return configCase_ == 3;
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ *
+ * @return The textConfig.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputTextConfig getTextConfig() {
+ if (configCase_ == 3) {
+ return (com.google.cloud.dialogflow.v2.InputTextConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance();
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputTextConfigOrBuilder getTextConfigOrBuilder() {
+ if (configCase_ == 3) {
+ return (com.google.cloud.dialogflow.v2.InputTextConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance();
+ }
+
+ public static final int REPLY_AUDIO_CONFIG_FIELD_NUMBER = 4;
+ private com.google.cloud.dialogflow.v2.OutputAudioConfig replyAudioConfig_;
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ *
+ * @return Whether the replyAudioConfig field is set.
+ */
+ @java.lang.Override
+ public boolean hasReplyAudioConfig() {
+ return replyAudioConfig_ != null;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ *
+ * @return The replyAudioConfig.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.OutputAudioConfig getReplyAudioConfig() {
+ return replyAudioConfig_ == null
+ ? com.google.cloud.dialogflow.v2.OutputAudioConfig.getDefaultInstance()
+ : replyAudioConfig_;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.OutputAudioConfigOrBuilder getReplyAudioConfigOrBuilder() {
+ return getReplyAudioConfig();
+ }
+
+ public static final int INPUT_AUDIO_FIELD_NUMBER = 5;
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return Whether the inputAudio field is set.
+ */
+ @java.lang.Override
+ public boolean hasInputAudio() {
+ return inputCase_ == 5;
+ }
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return The inputAudio.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getInputAudio() {
+ if (inputCase_ == 5) {
+ return (com.google.protobuf.ByteString) input_;
+ }
+ return com.google.protobuf.ByteString.EMPTY;
+ }
+
+ public static final int INPUT_TEXT_FIELD_NUMBER = 6;
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return Whether the inputText field is set.
+ */
+ public boolean hasInputText() {
+ return inputCase_ == 6;
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return The inputText.
+ */
+ public java.lang.String getInputText() {
+ java.lang.Object ref = "";
+ if (inputCase_ == 6) {
+ ref = input_;
+ }
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ if (inputCase_ == 6) {
+ input_ = s;
+ }
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return The bytes for inputText.
+ */
+ public com.google.protobuf.ByteString getInputTextBytes() {
+ java.lang.Object ref = "";
+ if (inputCase_ == 6) {
+ ref = input_;
+ }
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ if (inputCase_ == 6) {
+ input_ = b;
+ }
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int INPUT_DTMF_FIELD_NUMBER = 9;
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ *
+ * @return Whether the inputDtmf field is set.
+ */
+ @java.lang.Override
+ public boolean hasInputDtmf() {
+ return inputCase_ == 9;
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ *
+ * @return The inputDtmf.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.TelephonyDtmfEvents getInputDtmf() {
+ if (inputCase_ == 9) {
+ return (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_;
+ }
+ return com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance();
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.TelephonyDtmfEventsOrBuilder getInputDtmfOrBuilder() {
+ if (inputCase_ == 9) {
+ return (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_;
+ }
+ return com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance();
+ }
+
+ public static final int QUERY_PARAMS_FIELD_NUMBER = 7;
+ private com.google.cloud.dialogflow.v2.QueryParameters queryParams_;
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ *
+ * @return Whether the queryParams field is set.
+ */
+ @java.lang.Override
+ public boolean hasQueryParams() {
+ return queryParams_ != null;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ *
+ * @return The queryParams.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.QueryParameters getQueryParams() {
+ return queryParams_ == null
+ ? com.google.cloud.dialogflow.v2.QueryParameters.getDefaultInstance()
+ : queryParams_;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.QueryParametersOrBuilder getQueryParamsOrBuilder() {
+ return getQueryParams();
+ }
+
+ public static final int ASSIST_QUERY_PARAMS_FIELD_NUMBER = 8;
+ private com.google.cloud.dialogflow.v2.AssistQueryParameters assistQueryParams_;
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ *
+ * @return Whether the assistQueryParams field is set.
+ */
+ @java.lang.Override
+ public boolean hasAssistQueryParams() {
+ return assistQueryParams_ != null;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ *
+ * @return The assistQueryParams.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.AssistQueryParameters getAssistQueryParams() {
+ return assistQueryParams_ == null
+ ? com.google.cloud.dialogflow.v2.AssistQueryParameters.getDefaultInstance()
+ : assistQueryParams_;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.AssistQueryParametersOrBuilder
+ getAssistQueryParamsOrBuilder() {
+ return getAssistQueryParams();
+ }
+
+ public static final int CX_PARAMETERS_FIELD_NUMBER = 13;
+ private com.google.protobuf.Struct cxParameters_;
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ *
+ * @return Whether the cxParameters field is set.
+ */
+ @java.lang.Override
+ public boolean hasCxParameters() {
+ return cxParameters_ != null;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ *
+ * @return The cxParameters.
+ */
+ @java.lang.Override
+ public com.google.protobuf.Struct getCxParameters() {
+ return cxParameters_ == null ? com.google.protobuf.Struct.getDefaultInstance() : cxParameters_;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ @java.lang.Override
+ public com.google.protobuf.StructOrBuilder getCxParametersOrBuilder() {
+ return getCxParameters();
+ }
+
+ public static final int ENABLE_PARTIAL_AUTOMATED_AGENT_REPLY_FIELD_NUMBER = 12;
+ private boolean enablePartialAutomatedAgentReply_;
+ /**
+ *
+ *
+ * + * Enable partial virtual agent responses. If this flag is not enabled, + * response stream still contains only one final response even if some + * `Fulfillment`s in Dialogflow virtual agent have been configured to return + * partial responses. + *+ * + *
bool enable_partial_automated_agent_reply = 12;
+ *
+ * @return The enablePartialAutomatedAgentReply.
+ */
+ @java.lang.Override
+ public boolean getEnablePartialAutomatedAgentReply() {
+ return enablePartialAutomatedAgentReply_;
+ }
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(participant_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 1, participant_);
+ }
+ if (configCase_ == 2) {
+ output.writeMessage(2, (com.google.cloud.dialogflow.v2.InputAudioConfig) config_);
+ }
+ if (configCase_ == 3) {
+ output.writeMessage(3, (com.google.cloud.dialogflow.v2.InputTextConfig) config_);
+ }
+ if (replyAudioConfig_ != null) {
+ output.writeMessage(4, getReplyAudioConfig());
+ }
+ if (inputCase_ == 5) {
+ output.writeBytes(5, (com.google.protobuf.ByteString) input_);
+ }
+ if (inputCase_ == 6) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 6, input_);
+ }
+ if (queryParams_ != null) {
+ output.writeMessage(7, getQueryParams());
+ }
+ if (assistQueryParams_ != null) {
+ output.writeMessage(8, getAssistQueryParams());
+ }
+ if (inputCase_ == 9) {
+ output.writeMessage(9, (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_);
+ }
+ if (enablePartialAutomatedAgentReply_ != false) {
+ output.writeBool(12, enablePartialAutomatedAgentReply_);
+ }
+ if (cxParameters_ != null) {
+ output.writeMessage(13, getCxParameters());
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(participant_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, participant_);
+ }
+ if (configCase_ == 2) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeMessageSize(
+ 2, (com.google.cloud.dialogflow.v2.InputAudioConfig) config_);
+ }
+ if (configCase_ == 3) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeMessageSize(
+ 3, (com.google.cloud.dialogflow.v2.InputTextConfig) config_);
+ }
+ if (replyAudioConfig_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getReplyAudioConfig());
+ }
+ if (inputCase_ == 5) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeBytesSize(
+ 5, (com.google.protobuf.ByteString) input_);
+ }
+ if (inputCase_ == 6) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, input_);
+ }
+ if (queryParams_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getQueryParams());
+ }
+ if (assistQueryParams_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getAssistQueryParams());
+ }
+ if (inputCase_ == 9) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeMessageSize(
+ 9, (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_);
+ }
+ if (enablePartialAutomatedAgentReply_ != false) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeBoolSize(
+ 12, enablePartialAutomatedAgentReply_);
+ }
+ if (cxParameters_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(13, getCxParameters());
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest other =
+ (com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest) obj;
+
+ if (!getParticipant().equals(other.getParticipant())) return false;
+ if (hasReplyAudioConfig() != other.hasReplyAudioConfig()) return false;
+ if (hasReplyAudioConfig()) {
+ if (!getReplyAudioConfig().equals(other.getReplyAudioConfig())) return false;
+ }
+ if (hasQueryParams() != other.hasQueryParams()) return false;
+ if (hasQueryParams()) {
+ if (!getQueryParams().equals(other.getQueryParams())) return false;
+ }
+ if (hasAssistQueryParams() != other.hasAssistQueryParams()) return false;
+ if (hasAssistQueryParams()) {
+ if (!getAssistQueryParams().equals(other.getAssistQueryParams())) return false;
+ }
+ if (hasCxParameters() != other.hasCxParameters()) return false;
+ if (hasCxParameters()) {
+ if (!getCxParameters().equals(other.getCxParameters())) return false;
+ }
+ if (getEnablePartialAutomatedAgentReply() != other.getEnablePartialAutomatedAgentReply())
+ return false;
+ if (!getConfigCase().equals(other.getConfigCase())) return false;
+ switch (configCase_) {
+ case 2:
+ if (!getAudioConfig().equals(other.getAudioConfig())) return false;
+ break;
+ case 3:
+ if (!getTextConfig().equals(other.getTextConfig())) return false;
+ break;
+ case 0:
+ default:
+ }
+ if (!getInputCase().equals(other.getInputCase())) return false;
+ switch (inputCase_) {
+ case 5:
+ if (!getInputAudio().equals(other.getInputAudio())) return false;
+ break;
+ case 6:
+ if (!getInputText().equals(other.getInputText())) return false;
+ break;
+ case 9:
+ if (!getInputDtmf().equals(other.getInputDtmf())) return false;
+ break;
+ case 0:
+ default:
+ }
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ hash = (37 * hash) + PARTICIPANT_FIELD_NUMBER;
+ hash = (53 * hash) + getParticipant().hashCode();
+ if (hasReplyAudioConfig()) {
+ hash = (37 * hash) + REPLY_AUDIO_CONFIG_FIELD_NUMBER;
+ hash = (53 * hash) + getReplyAudioConfig().hashCode();
+ }
+ if (hasQueryParams()) {
+ hash = (37 * hash) + QUERY_PARAMS_FIELD_NUMBER;
+ hash = (53 * hash) + getQueryParams().hashCode();
+ }
+ if (hasAssistQueryParams()) {
+ hash = (37 * hash) + ASSIST_QUERY_PARAMS_FIELD_NUMBER;
+ hash = (53 * hash) + getAssistQueryParams().hashCode();
+ }
+ if (hasCxParameters()) {
+ hash = (37 * hash) + CX_PARAMETERS_FIELD_NUMBER;
+ hash = (53 * hash) + getCxParameters().hashCode();
+ }
+ hash = (37 * hash) + ENABLE_PARTIAL_AUTOMATED_AGENT_REPLY_FIELD_NUMBER;
+ hash =
+ (53 * hash)
+ + com.google.protobuf.Internal.hashBoolean(getEnablePartialAutomatedAgentReply());
+ switch (configCase_) {
+ case 2:
+ hash = (37 * hash) + AUDIO_CONFIG_FIELD_NUMBER;
+ hash = (53 * hash) + getAudioConfig().hashCode();
+ break;
+ case 3:
+ hash = (37 * hash) + TEXT_CONFIG_FIELD_NUMBER;
+ hash = (53 * hash) + getTextConfig().hashCode();
+ break;
+ case 0:
+ default:
+ }
+ switch (inputCase_) {
+ case 5:
+ hash = (37 * hash) + INPUT_AUDIO_FIELD_NUMBER;
+ hash = (53 * hash) + getInputAudio().hashCode();
+ break;
+ case 6:
+ hash = (37 * hash) + INPUT_TEXT_FIELD_NUMBER;
+ hash = (53 * hash) + getInputText().hashCode();
+ break;
+ case 9:
+ hash = (37 * hash) + INPUT_DTMF_FIELD_NUMBER;
+ hash = (53 * hash) + getInputDtmf().hashCode();
+ break;
+ case 0:
+ default:
+ }
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(
+ com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * The top-level message sent by the client to the + * [Participants.StreamingAnalyzeContent][google.cloud.dialogflow.v2.Participants.StreamingAnalyzeContent] method. + * Multiple request messages should be sent in order: + * 1. The first message must contain + * [participant][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.participant], + * [config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] and optionally + * [query_params][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.query_params]. If you want + * to receive an audio response, it should also contain + * [reply_audio_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.reply_audio_config]. + * The message must not contain + * [input][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input]. + * 2. If [config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] in the first message + * was set to [audio_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.audio_config], + * all subsequent messages must contain + * [input_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input_audio] to continue + * with Speech recognition. + * However, note that: + * * Dialogflow will bill you for the audio so far. + * * Dialogflow discards all Speech recognition results in favor of the + * text input. + * 3. If [StreamingAnalyzeContentRequest.config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] in the first message was set + * to [StreamingAnalyzeContentRequest.text_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.text_config], then the second message + * must contain only [input_text][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input_text]. + * Moreover, you must not send more than two messages. + * After you sent all input, you must half-close or abort the request stream. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The participant.
+ */
+ public java.lang.String getParticipant() {
+ java.lang.Object ref = participant_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ participant_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The bytes for participant.
+ */
+ public com.google.protobuf.ByteString getParticipantBytes() {
+ java.lang.Object ref = participant_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ participant_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @param value The participant to set.
+ * @return This builder for chaining.
+ */
+ public Builder setParticipant(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ participant_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearParticipant() {
+
+ participant_ = getDefaultInstance().getParticipant();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @param value The bytes for participant to set.
+ * @return This builder for chaining.
+ */
+ public Builder setParticipantBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ participant_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.InputAudioConfig,
+ com.google.cloud.dialogflow.v2.InputAudioConfig.Builder,
+ com.google.cloud.dialogflow.v2.InputAudioConfigOrBuilder>
+ audioConfigBuilder_;
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ *
+ * @return Whether the audioConfig field is set.
+ */
+ @java.lang.Override
+ public boolean hasAudioConfig() {
+ return configCase_ == 2;
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ *
+ * @return The audioConfig.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputAudioConfig getAudioConfig() {
+ if (audioConfigBuilder_ == null) {
+ if (configCase_ == 2) {
+ return (com.google.cloud.dialogflow.v2.InputAudioConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance();
+ } else {
+ if (configCase_ == 2) {
+ return audioConfigBuilder_.getMessage();
+ }
+ return com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance();
+ }
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ public Builder setAudioConfig(com.google.cloud.dialogflow.v2.InputAudioConfig value) {
+ if (audioConfigBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ config_ = value;
+ onChanged();
+ } else {
+ audioConfigBuilder_.setMessage(value);
+ }
+ configCase_ = 2;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ public Builder setAudioConfig(
+ com.google.cloud.dialogflow.v2.InputAudioConfig.Builder builderForValue) {
+ if (audioConfigBuilder_ == null) {
+ config_ = builderForValue.build();
+ onChanged();
+ } else {
+ audioConfigBuilder_.setMessage(builderForValue.build());
+ }
+ configCase_ = 2;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ public Builder mergeAudioConfig(com.google.cloud.dialogflow.v2.InputAudioConfig value) {
+ if (audioConfigBuilder_ == null) {
+ if (configCase_ == 2
+ && config_ != com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance()) {
+ config_ =
+ com.google.cloud.dialogflow.v2.InputAudioConfig.newBuilder(
+ (com.google.cloud.dialogflow.v2.InputAudioConfig) config_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ config_ = value;
+ }
+ onChanged();
+ } else {
+ if (configCase_ == 2) {
+ audioConfigBuilder_.mergeFrom(value);
+ } else {
+ audioConfigBuilder_.setMessage(value);
+ }
+ }
+ configCase_ = 2;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ public Builder clearAudioConfig() {
+ if (audioConfigBuilder_ == null) {
+ if (configCase_ == 2) {
+ configCase_ = 0;
+ config_ = null;
+ onChanged();
+ }
+ } else {
+ if (configCase_ == 2) {
+ configCase_ = 0;
+ config_ = null;
+ }
+ audioConfigBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ public com.google.cloud.dialogflow.v2.InputAudioConfig.Builder getAudioConfigBuilder() {
+ return getAudioConfigFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputAudioConfigOrBuilder getAudioConfigOrBuilder() {
+ if ((configCase_ == 2) && (audioConfigBuilder_ != null)) {
+ return audioConfigBuilder_.getMessageOrBuilder();
+ } else {
+ if (configCase_ == 2) {
+ return (com.google.cloud.dialogflow.v2.InputAudioConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance();
+ }
+ }
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.InputAudioConfig,
+ com.google.cloud.dialogflow.v2.InputAudioConfig.Builder,
+ com.google.cloud.dialogflow.v2.InputAudioConfigOrBuilder>
+ getAudioConfigFieldBuilder() {
+ if (audioConfigBuilder_ == null) {
+ if (!(configCase_ == 2)) {
+ config_ = com.google.cloud.dialogflow.v2.InputAudioConfig.getDefaultInstance();
+ }
+ audioConfigBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.InputAudioConfig,
+ com.google.cloud.dialogflow.v2.InputAudioConfig.Builder,
+ com.google.cloud.dialogflow.v2.InputAudioConfigOrBuilder>(
+ (com.google.cloud.dialogflow.v2.InputAudioConfig) config_,
+ getParentForChildren(),
+ isClean());
+ config_ = null;
+ }
+ configCase_ = 2;
+ onChanged();
+ ;
+ return audioConfigBuilder_;
+ }
+
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.InputTextConfig,
+ com.google.cloud.dialogflow.v2.InputTextConfig.Builder,
+ com.google.cloud.dialogflow.v2.InputTextConfigOrBuilder>
+ textConfigBuilder_;
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ *
+ * @return Whether the textConfig field is set.
+ */
+ @java.lang.Override
+ public boolean hasTextConfig() {
+ return configCase_ == 3;
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ *
+ * @return The textConfig.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputTextConfig getTextConfig() {
+ if (textConfigBuilder_ == null) {
+ if (configCase_ == 3) {
+ return (com.google.cloud.dialogflow.v2.InputTextConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance();
+ } else {
+ if (configCase_ == 3) {
+ return textConfigBuilder_.getMessage();
+ }
+ return com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance();
+ }
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ public Builder setTextConfig(com.google.cloud.dialogflow.v2.InputTextConfig value) {
+ if (textConfigBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ config_ = value;
+ onChanged();
+ } else {
+ textConfigBuilder_.setMessage(value);
+ }
+ configCase_ = 3;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ public Builder setTextConfig(
+ com.google.cloud.dialogflow.v2.InputTextConfig.Builder builderForValue) {
+ if (textConfigBuilder_ == null) {
+ config_ = builderForValue.build();
+ onChanged();
+ } else {
+ textConfigBuilder_.setMessage(builderForValue.build());
+ }
+ configCase_ = 3;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ public Builder mergeTextConfig(com.google.cloud.dialogflow.v2.InputTextConfig value) {
+ if (textConfigBuilder_ == null) {
+ if (configCase_ == 3
+ && config_ != com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance()) {
+ config_ =
+ com.google.cloud.dialogflow.v2.InputTextConfig.newBuilder(
+ (com.google.cloud.dialogflow.v2.InputTextConfig) config_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ config_ = value;
+ }
+ onChanged();
+ } else {
+ if (configCase_ == 3) {
+ textConfigBuilder_.mergeFrom(value);
+ } else {
+ textConfigBuilder_.setMessage(value);
+ }
+ }
+ configCase_ = 3;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ public Builder clearTextConfig() {
+ if (textConfigBuilder_ == null) {
+ if (configCase_ == 3) {
+ configCase_ = 0;
+ config_ = null;
+ onChanged();
+ }
+ } else {
+ if (configCase_ == 3) {
+ configCase_ = 0;
+ config_ = null;
+ }
+ textConfigBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ public com.google.cloud.dialogflow.v2.InputTextConfig.Builder getTextConfigBuilder() {
+ return getTextConfigFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.InputTextConfigOrBuilder getTextConfigOrBuilder() {
+ if ((configCase_ == 3) && (textConfigBuilder_ != null)) {
+ return textConfigBuilder_.getMessageOrBuilder();
+ } else {
+ if (configCase_ == 3) {
+ return (com.google.cloud.dialogflow.v2.InputTextConfig) config_;
+ }
+ return com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance();
+ }
+ }
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.InputTextConfig,
+ com.google.cloud.dialogflow.v2.InputTextConfig.Builder,
+ com.google.cloud.dialogflow.v2.InputTextConfigOrBuilder>
+ getTextConfigFieldBuilder() {
+ if (textConfigBuilder_ == null) {
+ if (!(configCase_ == 3)) {
+ config_ = com.google.cloud.dialogflow.v2.InputTextConfig.getDefaultInstance();
+ }
+ textConfigBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.InputTextConfig,
+ com.google.cloud.dialogflow.v2.InputTextConfig.Builder,
+ com.google.cloud.dialogflow.v2.InputTextConfigOrBuilder>(
+ (com.google.cloud.dialogflow.v2.InputTextConfig) config_,
+ getParentForChildren(),
+ isClean());
+ config_ = null;
+ }
+ configCase_ = 3;
+ onChanged();
+ ;
+ return textConfigBuilder_;
+ }
+
+ private com.google.cloud.dialogflow.v2.OutputAudioConfig replyAudioConfig_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.OutputAudioConfig,
+ com.google.cloud.dialogflow.v2.OutputAudioConfig.Builder,
+ com.google.cloud.dialogflow.v2.OutputAudioConfigOrBuilder>
+ replyAudioConfigBuilder_;
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ *
+ * @return Whether the replyAudioConfig field is set.
+ */
+ public boolean hasReplyAudioConfig() {
+ return replyAudioConfigBuilder_ != null || replyAudioConfig_ != null;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ *
+ * @return The replyAudioConfig.
+ */
+ public com.google.cloud.dialogflow.v2.OutputAudioConfig getReplyAudioConfig() {
+ if (replyAudioConfigBuilder_ == null) {
+ return replyAudioConfig_ == null
+ ? com.google.cloud.dialogflow.v2.OutputAudioConfig.getDefaultInstance()
+ : replyAudioConfig_;
+ } else {
+ return replyAudioConfigBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ public Builder setReplyAudioConfig(com.google.cloud.dialogflow.v2.OutputAudioConfig value) {
+ if (replyAudioConfigBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ replyAudioConfig_ = value;
+ onChanged();
+ } else {
+ replyAudioConfigBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ public Builder setReplyAudioConfig(
+ com.google.cloud.dialogflow.v2.OutputAudioConfig.Builder builderForValue) {
+ if (replyAudioConfigBuilder_ == null) {
+ replyAudioConfig_ = builderForValue.build();
+ onChanged();
+ } else {
+ replyAudioConfigBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ public Builder mergeReplyAudioConfig(com.google.cloud.dialogflow.v2.OutputAudioConfig value) {
+ if (replyAudioConfigBuilder_ == null) {
+ if (replyAudioConfig_ != null) {
+ replyAudioConfig_ =
+ com.google.cloud.dialogflow.v2.OutputAudioConfig.newBuilder(replyAudioConfig_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ replyAudioConfig_ = value;
+ }
+ onChanged();
+ } else {
+ replyAudioConfigBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ public Builder clearReplyAudioConfig() {
+ if (replyAudioConfigBuilder_ == null) {
+ replyAudioConfig_ = null;
+ onChanged();
+ } else {
+ replyAudioConfig_ = null;
+ replyAudioConfigBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ public com.google.cloud.dialogflow.v2.OutputAudioConfig.Builder getReplyAudioConfigBuilder() {
+
+ onChanged();
+ return getReplyAudioConfigFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ public com.google.cloud.dialogflow.v2.OutputAudioConfigOrBuilder
+ getReplyAudioConfigOrBuilder() {
+ if (replyAudioConfigBuilder_ != null) {
+ return replyAudioConfigBuilder_.getMessageOrBuilder();
+ } else {
+ return replyAudioConfig_ == null
+ ? com.google.cloud.dialogflow.v2.OutputAudioConfig.getDefaultInstance()
+ : replyAudioConfig_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.OutputAudioConfig,
+ com.google.cloud.dialogflow.v2.OutputAudioConfig.Builder,
+ com.google.cloud.dialogflow.v2.OutputAudioConfigOrBuilder>
+ getReplyAudioConfigFieldBuilder() {
+ if (replyAudioConfigBuilder_ == null) {
+ replyAudioConfigBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.OutputAudioConfig,
+ com.google.cloud.dialogflow.v2.OutputAudioConfig.Builder,
+ com.google.cloud.dialogflow.v2.OutputAudioConfigOrBuilder>(
+ getReplyAudioConfig(), getParentForChildren(), isClean());
+ replyAudioConfig_ = null;
+ }
+ return replyAudioConfigBuilder_;
+ }
+
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return Whether the inputAudio field is set.
+ */
+ public boolean hasInputAudio() {
+ return inputCase_ == 5;
+ }
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return The inputAudio.
+ */
+ public com.google.protobuf.ByteString getInputAudio() {
+ if (inputCase_ == 5) {
+ return (com.google.protobuf.ByteString) input_;
+ }
+ return com.google.protobuf.ByteString.EMPTY;
+ }
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @param value The inputAudio to set.
+ * @return This builder for chaining.
+ */
+ public Builder setInputAudio(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ inputCase_ = 5;
+ input_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearInputAudio() {
+ if (inputCase_ == 5) {
+ inputCase_ = 0;
+ input_ = null;
+ onChanged();
+ }
+ return this;
+ }
+
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return Whether the inputText field is set.
+ */
+ @java.lang.Override
+ public boolean hasInputText() {
+ return inputCase_ == 6;
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return The inputText.
+ */
+ @java.lang.Override
+ public java.lang.String getInputText() {
+ java.lang.Object ref = "";
+ if (inputCase_ == 6) {
+ ref = input_;
+ }
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ if (inputCase_ == 6) {
+ input_ = s;
+ }
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return The bytes for inputText.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getInputTextBytes() {
+ java.lang.Object ref = "";
+ if (inputCase_ == 6) {
+ ref = input_;
+ }
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ if (inputCase_ == 6) {
+ input_ = b;
+ }
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @param value The inputText to set.
+ * @return This builder for chaining.
+ */
+ public Builder setInputText(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ inputCase_ = 6;
+ input_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearInputText() {
+ if (inputCase_ == 6) {
+ inputCase_ = 0;
+ input_ = null;
+ onChanged();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @param value The bytes for inputText to set.
+ * @return This builder for chaining.
+ */
+ public Builder setInputTextBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+ inputCase_ = 6;
+ input_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents,
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.Builder,
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEventsOrBuilder>
+ inputDtmfBuilder_;
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ *
+ * @return Whether the inputDtmf field is set.
+ */
+ @java.lang.Override
+ public boolean hasInputDtmf() {
+ return inputCase_ == 9;
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ *
+ * @return The inputDtmf.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.TelephonyDtmfEvents getInputDtmf() {
+ if (inputDtmfBuilder_ == null) {
+ if (inputCase_ == 9) {
+ return (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_;
+ }
+ return com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance();
+ } else {
+ if (inputCase_ == 9) {
+ return inputDtmfBuilder_.getMessage();
+ }
+ return com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance();
+ }
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ public Builder setInputDtmf(com.google.cloud.dialogflow.v2.TelephonyDtmfEvents value) {
+ if (inputDtmfBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ input_ = value;
+ onChanged();
+ } else {
+ inputDtmfBuilder_.setMessage(value);
+ }
+ inputCase_ = 9;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ public Builder setInputDtmf(
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.Builder builderForValue) {
+ if (inputDtmfBuilder_ == null) {
+ input_ = builderForValue.build();
+ onChanged();
+ } else {
+ inputDtmfBuilder_.setMessage(builderForValue.build());
+ }
+ inputCase_ = 9;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ public Builder mergeInputDtmf(com.google.cloud.dialogflow.v2.TelephonyDtmfEvents value) {
+ if (inputDtmfBuilder_ == null) {
+ if (inputCase_ == 9
+ && input_ != com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance()) {
+ input_ =
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.newBuilder(
+ (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ input_ = value;
+ }
+ onChanged();
+ } else {
+ if (inputCase_ == 9) {
+ inputDtmfBuilder_.mergeFrom(value);
+ } else {
+ inputDtmfBuilder_.setMessage(value);
+ }
+ }
+ inputCase_ = 9;
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ public Builder clearInputDtmf() {
+ if (inputDtmfBuilder_ == null) {
+ if (inputCase_ == 9) {
+ inputCase_ = 0;
+ input_ = null;
+ onChanged();
+ }
+ } else {
+ if (inputCase_ == 9) {
+ inputCase_ = 0;
+ input_ = null;
+ }
+ inputDtmfBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ public com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.Builder getInputDtmfBuilder() {
+ return getInputDtmfFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.TelephonyDtmfEventsOrBuilder getInputDtmfOrBuilder() {
+ if ((inputCase_ == 9) && (inputDtmfBuilder_ != null)) {
+ return inputDtmfBuilder_.getMessageOrBuilder();
+ } else {
+ if (inputCase_ == 9) {
+ return (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_;
+ }
+ return com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance();
+ }
+ }
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents,
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.Builder,
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEventsOrBuilder>
+ getInputDtmfFieldBuilder() {
+ if (inputDtmfBuilder_ == null) {
+ if (!(inputCase_ == 9)) {
+ input_ = com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.getDefaultInstance();
+ }
+ inputDtmfBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents,
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.Builder,
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEventsOrBuilder>(
+ (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) input_,
+ getParentForChildren(),
+ isClean());
+ input_ = null;
+ }
+ inputCase_ = 9;
+ onChanged();
+ ;
+ return inputDtmfBuilder_;
+ }
+
+ private com.google.cloud.dialogflow.v2.QueryParameters queryParams_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.QueryParameters,
+ com.google.cloud.dialogflow.v2.QueryParameters.Builder,
+ com.google.cloud.dialogflow.v2.QueryParametersOrBuilder>
+ queryParamsBuilder_;
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ *
+ * @return Whether the queryParams field is set.
+ */
+ public boolean hasQueryParams() {
+ return queryParamsBuilder_ != null || queryParams_ != null;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ *
+ * @return The queryParams.
+ */
+ public com.google.cloud.dialogflow.v2.QueryParameters getQueryParams() {
+ if (queryParamsBuilder_ == null) {
+ return queryParams_ == null
+ ? com.google.cloud.dialogflow.v2.QueryParameters.getDefaultInstance()
+ : queryParams_;
+ } else {
+ return queryParamsBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ public Builder setQueryParams(com.google.cloud.dialogflow.v2.QueryParameters value) {
+ if (queryParamsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ queryParams_ = value;
+ onChanged();
+ } else {
+ queryParamsBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ public Builder setQueryParams(
+ com.google.cloud.dialogflow.v2.QueryParameters.Builder builderForValue) {
+ if (queryParamsBuilder_ == null) {
+ queryParams_ = builderForValue.build();
+ onChanged();
+ } else {
+ queryParamsBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ public Builder mergeQueryParams(com.google.cloud.dialogflow.v2.QueryParameters value) {
+ if (queryParamsBuilder_ == null) {
+ if (queryParams_ != null) {
+ queryParams_ =
+ com.google.cloud.dialogflow.v2.QueryParameters.newBuilder(queryParams_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ queryParams_ = value;
+ }
+ onChanged();
+ } else {
+ queryParamsBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ public Builder clearQueryParams() {
+ if (queryParamsBuilder_ == null) {
+ queryParams_ = null;
+ onChanged();
+ } else {
+ queryParams_ = null;
+ queryParamsBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ public com.google.cloud.dialogflow.v2.QueryParameters.Builder getQueryParamsBuilder() {
+
+ onChanged();
+ return getQueryParamsFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ public com.google.cloud.dialogflow.v2.QueryParametersOrBuilder getQueryParamsOrBuilder() {
+ if (queryParamsBuilder_ != null) {
+ return queryParamsBuilder_.getMessageOrBuilder();
+ } else {
+ return queryParams_ == null
+ ? com.google.cloud.dialogflow.v2.QueryParameters.getDefaultInstance()
+ : queryParams_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.QueryParameters,
+ com.google.cloud.dialogflow.v2.QueryParameters.Builder,
+ com.google.cloud.dialogflow.v2.QueryParametersOrBuilder>
+ getQueryParamsFieldBuilder() {
+ if (queryParamsBuilder_ == null) {
+ queryParamsBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.QueryParameters,
+ com.google.cloud.dialogflow.v2.QueryParameters.Builder,
+ com.google.cloud.dialogflow.v2.QueryParametersOrBuilder>(
+ getQueryParams(), getParentForChildren(), isClean());
+ queryParams_ = null;
+ }
+ return queryParamsBuilder_;
+ }
+
+ private com.google.cloud.dialogflow.v2.AssistQueryParameters assistQueryParams_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.AssistQueryParameters,
+ com.google.cloud.dialogflow.v2.AssistQueryParameters.Builder,
+ com.google.cloud.dialogflow.v2.AssistQueryParametersOrBuilder>
+ assistQueryParamsBuilder_;
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ *
+ * @return Whether the assistQueryParams field is set.
+ */
+ public boolean hasAssistQueryParams() {
+ return assistQueryParamsBuilder_ != null || assistQueryParams_ != null;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ *
+ * @return The assistQueryParams.
+ */
+ public com.google.cloud.dialogflow.v2.AssistQueryParameters getAssistQueryParams() {
+ if (assistQueryParamsBuilder_ == null) {
+ return assistQueryParams_ == null
+ ? com.google.cloud.dialogflow.v2.AssistQueryParameters.getDefaultInstance()
+ : assistQueryParams_;
+ } else {
+ return assistQueryParamsBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ public Builder setAssistQueryParams(
+ com.google.cloud.dialogflow.v2.AssistQueryParameters value) {
+ if (assistQueryParamsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ assistQueryParams_ = value;
+ onChanged();
+ } else {
+ assistQueryParamsBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ public Builder setAssistQueryParams(
+ com.google.cloud.dialogflow.v2.AssistQueryParameters.Builder builderForValue) {
+ if (assistQueryParamsBuilder_ == null) {
+ assistQueryParams_ = builderForValue.build();
+ onChanged();
+ } else {
+ assistQueryParamsBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ public Builder mergeAssistQueryParams(
+ com.google.cloud.dialogflow.v2.AssistQueryParameters value) {
+ if (assistQueryParamsBuilder_ == null) {
+ if (assistQueryParams_ != null) {
+ assistQueryParams_ =
+ com.google.cloud.dialogflow.v2.AssistQueryParameters.newBuilder(assistQueryParams_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ assistQueryParams_ = value;
+ }
+ onChanged();
+ } else {
+ assistQueryParamsBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ public Builder clearAssistQueryParams() {
+ if (assistQueryParamsBuilder_ == null) {
+ assistQueryParams_ = null;
+ onChanged();
+ } else {
+ assistQueryParams_ = null;
+ assistQueryParamsBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ public com.google.cloud.dialogflow.v2.AssistQueryParameters.Builder
+ getAssistQueryParamsBuilder() {
+
+ onChanged();
+ return getAssistQueryParamsFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ public com.google.cloud.dialogflow.v2.AssistQueryParametersOrBuilder
+ getAssistQueryParamsOrBuilder() {
+ if (assistQueryParamsBuilder_ != null) {
+ return assistQueryParamsBuilder_.getMessageOrBuilder();
+ } else {
+ return assistQueryParams_ == null
+ ? com.google.cloud.dialogflow.v2.AssistQueryParameters.getDefaultInstance()
+ : assistQueryParams_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.AssistQueryParameters,
+ com.google.cloud.dialogflow.v2.AssistQueryParameters.Builder,
+ com.google.cloud.dialogflow.v2.AssistQueryParametersOrBuilder>
+ getAssistQueryParamsFieldBuilder() {
+ if (assistQueryParamsBuilder_ == null) {
+ assistQueryParamsBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.AssistQueryParameters,
+ com.google.cloud.dialogflow.v2.AssistQueryParameters.Builder,
+ com.google.cloud.dialogflow.v2.AssistQueryParametersOrBuilder>(
+ getAssistQueryParams(), getParentForChildren(), isClean());
+ assistQueryParams_ = null;
+ }
+ return assistQueryParamsBuilder_;
+ }
+
+ private com.google.protobuf.Struct cxParameters_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Struct,
+ com.google.protobuf.Struct.Builder,
+ com.google.protobuf.StructOrBuilder>
+ cxParametersBuilder_;
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ *
+ * @return Whether the cxParameters field is set.
+ */
+ public boolean hasCxParameters() {
+ return cxParametersBuilder_ != null || cxParameters_ != null;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ *
+ * @return The cxParameters.
+ */
+ public com.google.protobuf.Struct getCxParameters() {
+ if (cxParametersBuilder_ == null) {
+ return cxParameters_ == null
+ ? com.google.protobuf.Struct.getDefaultInstance()
+ : cxParameters_;
+ } else {
+ return cxParametersBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ public Builder setCxParameters(com.google.protobuf.Struct value) {
+ if (cxParametersBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ cxParameters_ = value;
+ onChanged();
+ } else {
+ cxParametersBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ public Builder setCxParameters(com.google.protobuf.Struct.Builder builderForValue) {
+ if (cxParametersBuilder_ == null) {
+ cxParameters_ = builderForValue.build();
+ onChanged();
+ } else {
+ cxParametersBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ public Builder mergeCxParameters(com.google.protobuf.Struct value) {
+ if (cxParametersBuilder_ == null) {
+ if (cxParameters_ != null) {
+ cxParameters_ =
+ com.google.protobuf.Struct.newBuilder(cxParameters_).mergeFrom(value).buildPartial();
+ } else {
+ cxParameters_ = value;
+ }
+ onChanged();
+ } else {
+ cxParametersBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ public Builder clearCxParameters() {
+ if (cxParametersBuilder_ == null) {
+ cxParameters_ = null;
+ onChanged();
+ } else {
+ cxParameters_ = null;
+ cxParametersBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ public com.google.protobuf.Struct.Builder getCxParametersBuilder() {
+
+ onChanged();
+ return getCxParametersFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ public com.google.protobuf.StructOrBuilder getCxParametersOrBuilder() {
+ if (cxParametersBuilder_ != null) {
+ return cxParametersBuilder_.getMessageOrBuilder();
+ } else {
+ return cxParameters_ == null
+ ? com.google.protobuf.Struct.getDefaultInstance()
+ : cxParameters_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Struct,
+ com.google.protobuf.Struct.Builder,
+ com.google.protobuf.StructOrBuilder>
+ getCxParametersFieldBuilder() {
+ if (cxParametersBuilder_ == null) {
+ cxParametersBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.protobuf.Struct,
+ com.google.protobuf.Struct.Builder,
+ com.google.protobuf.StructOrBuilder>(
+ getCxParameters(), getParentForChildren(), isClean());
+ cxParameters_ = null;
+ }
+ return cxParametersBuilder_;
+ }
+
+ private boolean enablePartialAutomatedAgentReply_;
+ /**
+ *
+ *
+ * + * Enable partial virtual agent responses. If this flag is not enabled, + * response stream still contains only one final response even if some + * `Fulfillment`s in Dialogflow virtual agent have been configured to return + * partial responses. + *+ * + *
bool enable_partial_automated_agent_reply = 12;
+ *
+ * @return The enablePartialAutomatedAgentReply.
+ */
+ @java.lang.Override
+ public boolean getEnablePartialAutomatedAgentReply() {
+ return enablePartialAutomatedAgentReply_;
+ }
+ /**
+ *
+ *
+ * + * Enable partial virtual agent responses. If this flag is not enabled, + * response stream still contains only one final response even if some + * `Fulfillment`s in Dialogflow virtual agent have been configured to return + * partial responses. + *+ * + *
bool enable_partial_automated_agent_reply = 12;
+ *
+ * @param value The enablePartialAutomatedAgentReply to set.
+ * @return This builder for chaining.
+ */
+ public Builder setEnablePartialAutomatedAgentReply(boolean value) {
+
+ enablePartialAutomatedAgentReply_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Enable partial virtual agent responses. If this flag is not enabled, + * response stream still contains only one final response even if some + * `Fulfillment`s in Dialogflow virtual agent have been configured to return + * partial responses. + *+ * + *
bool enable_partial_automated_agent_reply = 12;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearEnablePartialAutomatedAgentReply() {
+
+ enablePartialAutomatedAgentReply_ = false;
+ onChanged();
+ return this;
+ }
+
+ @java.lang.Override
+ public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFields(unknownFields);
+ }
+
+ @java.lang.Override
+ public final Builder mergeUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.mergeUnknownFields(unknownFields);
+ }
+
+ // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest)
+ private static final com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest
+ DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest();
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The participant.
+ */
+ java.lang.String getParticipant();
+ /**
+ *
+ *
+ * + * Required. The name of the participant this text comes from. + * Format: `projects/<Project ID>/locations/<Location + * ID>/conversations/<Conversation ID>/participants/<Participant ID>`. + *+ * + *
+ * string participant = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }
+ *
+ *
+ * @return The bytes for participant.
+ */
+ com.google.protobuf.ByteString getParticipantBytes();
+
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ *
+ * @return Whether the audioConfig field is set.
+ */
+ boolean hasAudioConfig();
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ *
+ * @return The audioConfig.
+ */
+ com.google.cloud.dialogflow.v2.InputAudioConfig getAudioConfig();
+ /**
+ *
+ *
+ * + * Instructs the speech recognizer how to process the speech audio. + *+ * + *
.google.cloud.dialogflow.v2.InputAudioConfig audio_config = 2;
+ */
+ com.google.cloud.dialogflow.v2.InputAudioConfigOrBuilder getAudioConfigOrBuilder();
+
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ *
+ * @return Whether the textConfig field is set.
+ */
+ boolean hasTextConfig();
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ *
+ * @return The textConfig.
+ */
+ com.google.cloud.dialogflow.v2.InputTextConfig getTextConfig();
+ /**
+ *
+ *
+ * + * The natural language text to be processed. + *+ * + *
.google.cloud.dialogflow.v2.InputTextConfig text_config = 3;
+ */
+ com.google.cloud.dialogflow.v2.InputTextConfigOrBuilder getTextConfigOrBuilder();
+
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ *
+ * @return Whether the replyAudioConfig field is set.
+ */
+ boolean hasReplyAudioConfig();
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ *
+ * @return The replyAudioConfig.
+ */
+ com.google.cloud.dialogflow.v2.OutputAudioConfig getReplyAudioConfig();
+ /**
+ *
+ *
+ * + * Speech synthesis configuration. + * The speech synthesis settings for a virtual agent that may be configured + * for the associated conversation profile are not used when calling + * StreamingAnalyzeContent. If this configuration is not supplied, speech + * synthesis is disabled. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudioConfig reply_audio_config = 4;
+ */
+ com.google.cloud.dialogflow.v2.OutputAudioConfigOrBuilder getReplyAudioConfigOrBuilder();
+
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return Whether the inputAudio field is set.
+ */
+ boolean hasInputAudio();
+ /**
+ *
+ *
+ * + * The input audio content to be recognized. Must be sent if `audio_config` + * is set in the first message. The complete audio over all streaming + * messages must not exceed 1 minute. + *+ * + *
bytes input_audio = 5;
+ *
+ * @return The inputAudio.
+ */
+ com.google.protobuf.ByteString getInputAudio();
+
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return Whether the inputText field is set.
+ */
+ boolean hasInputText();
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return The inputText.
+ */
+ java.lang.String getInputText();
+ /**
+ *
+ *
+ * + * The UTF-8 encoded natural language text to be processed. Must be sent if + * `text_config` is set in the first message. Text length must not exceed + * 256 bytes for virtual agent interactions. The `input_text` field can be + * only sent once. + *+ * + *
string input_text = 6;
+ *
+ * @return The bytes for inputText.
+ */
+ com.google.protobuf.ByteString getInputTextBytes();
+
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ *
+ * @return Whether the inputDtmf field is set.
+ */
+ boolean hasInputDtmf();
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ *
+ * @return The inputDtmf.
+ */
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents getInputDtmf();
+ /**
+ *
+ *
+ * + * The DTMF digits used to invoke intent and fill in parameter value. + * This input is ignored if the previous response indicated that DTMF input + * is not accepted. + *+ * + *
.google.cloud.dialogflow.v2.TelephonyDtmfEvents input_dtmf = 9;
+ */
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEventsOrBuilder getInputDtmfOrBuilder();
+
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ *
+ * @return Whether the queryParams field is set.
+ */
+ boolean hasQueryParams();
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ *
+ * @return The queryParams.
+ */
+ com.google.cloud.dialogflow.v2.QueryParameters getQueryParams();
+ /**
+ *
+ *
+ * + * Parameters for a Dialogflow virtual-agent query. + *+ * + *
.google.cloud.dialogflow.v2.QueryParameters query_params = 7;
+ */
+ com.google.cloud.dialogflow.v2.QueryParametersOrBuilder getQueryParamsOrBuilder();
+
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ *
+ * @return Whether the assistQueryParams field is set.
+ */
+ boolean hasAssistQueryParams();
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ *
+ * @return The assistQueryParams.
+ */
+ com.google.cloud.dialogflow.v2.AssistQueryParameters getAssistQueryParams();
+ /**
+ *
+ *
+ * + * Parameters for a human assist query. + *+ * + *
.google.cloud.dialogflow.v2.AssistQueryParameters assist_query_params = 8;
+ */
+ com.google.cloud.dialogflow.v2.AssistQueryParametersOrBuilder getAssistQueryParamsOrBuilder();
+
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ *
+ * @return Whether the cxParameters field is set.
+ */
+ boolean hasCxParameters();
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ *
+ * @return The cxParameters.
+ */
+ com.google.protobuf.Struct getCxParameters();
+ /**
+ *
+ *
+ * + * Additional parameters to be put into Dialogflow CX session parameters. To + * remove a parameter from the session, clients should explicitly set the + * parameter value to null. + * Note: this field should only be used if you are connecting to a Dialogflow + * CX agent. + *+ * + *
.google.protobuf.Struct cx_parameters = 13;
+ */
+ com.google.protobuf.StructOrBuilder getCxParametersOrBuilder();
+
+ /**
+ *
+ *
+ * + * Enable partial virtual agent responses. If this flag is not enabled, + * response stream still contains only one final response even if some + * `Fulfillment`s in Dialogflow virtual agent have been configured to return + * partial responses. + *+ * + *
bool enable_partial_automated_agent_reply = 12;
+ *
+ * @return The enablePartialAutomatedAgentReply.
+ */
+ boolean getEnablePartialAutomatedAgentReply();
+
+ public com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.ConfigCase getConfigCase();
+
+ public com.google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.InputCase getInputCase();
+}
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/StreamingAnalyzeContentResponse.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/StreamingAnalyzeContentResponse.java
new file mode 100644
index 000000000000..ae03fa48090a
--- /dev/null
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/StreamingAnalyzeContentResponse.java
@@ -0,0 +1,3323 @@
+/*
+ * Copyright 2020 Google LLC
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/cloud/dialogflow/v2/participant.proto
+
+package com.google.cloud.dialogflow.v2;
+
+/**
+ *
+ *
+ * + * The top-level message returned from the `StreamingAnalyzeContent` method. + * Multiple response messages can be returned in order: + * 1. If the input was set to streaming audio, the first one or more messages + * contain `recognition_result`. Each `recognition_result` represents a more + * complete transcript of what the user said. The last `recognition_result` + * has `is_final` set to `true`. + * 2. In virtual agent stage: if `enable_partial_automated_agent_reply` is + * true, the following N (currently 1 <= N <= 4) messages + * contain `automated_agent_reply` and optionally `reply_audio` + * returned by the virtual agent. The first (N-1) + * `automated_agent_reply`s will have `automated_agent_reply_type` set to + * `PARTIAL`. The last `automated_agent_reply` has + * `automated_agent_reply_type` set to `FINAL`. + * If `enable_partial_automated_agent_reply` is not enabled, response stream + * only contains the final reply. + * In human assist stage: the following N (N >= 1) messages contain + * `human_agent_suggestion_results`, `end_user_suggestion_results` or + * `message`. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse} + */ +public final class StreamingAnalyzeContentResponse extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse) + StreamingAnalyzeContentResponseOrBuilder { + private static final long serialVersionUID = 0L; + // Use StreamingAnalyzeContentResponse.newBuilder() to construct. + private StreamingAnalyzeContentResponse( + com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private StreamingAnalyzeContentResponse() { + replyText_ = ""; + humanAgentSuggestionResults_ = java.util.Collections.emptyList(); + endUserSuggestionResults_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new StreamingAnalyzeContentResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.v2.ParticipantProto + .internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.v2.ParticipantProto + .internal_static_google_cloud_dialogflow_v2_StreamingAnalyzeContentResponse_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.class, + com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.Builder.class); + } + + public static final int RECOGNITION_RESULT_FIELD_NUMBER = 1; + private com.google.cloud.dialogflow.v2.StreamingRecognitionResult recognitionResult_; + /** + * + * + *
+ * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ *
+ * @return Whether the recognitionResult field is set.
+ */
+ @java.lang.Override
+ public boolean hasRecognitionResult() {
+ return recognitionResult_ != null;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ *
+ * @return The recognitionResult.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.StreamingRecognitionResult getRecognitionResult() {
+ return recognitionResult_ == null
+ ? com.google.cloud.dialogflow.v2.StreamingRecognitionResult.getDefaultInstance()
+ : recognitionResult_;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.StreamingRecognitionResultOrBuilder
+ getRecognitionResultOrBuilder() {
+ return getRecognitionResult();
+ }
+
+ public static final int REPLY_TEXT_FIELD_NUMBER = 2;
+ private volatile java.lang.Object replyText_;
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return The replyText.
+ */
+ @java.lang.Override
+ public java.lang.String getReplyText() {
+ java.lang.Object ref = replyText_;
+ if (ref instanceof java.lang.String) {
+ return (java.lang.String) ref;
+ } else {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ replyText_ = s;
+ return s;
+ }
+ }
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return The bytes for replyText.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getReplyTextBytes() {
+ java.lang.Object ref = replyText_;
+ if (ref instanceof java.lang.String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ replyText_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+
+ public static final int REPLY_AUDIO_FIELD_NUMBER = 3;
+ private com.google.cloud.dialogflow.v2.OutputAudio replyAudio_;
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ *
+ * @return Whether the replyAudio field is set.
+ */
+ @java.lang.Override
+ public boolean hasReplyAudio() {
+ return replyAudio_ != null;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ *
+ * @return The replyAudio.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.OutputAudio getReplyAudio() {
+ return replyAudio_ == null
+ ? com.google.cloud.dialogflow.v2.OutputAudio.getDefaultInstance()
+ : replyAudio_;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.OutputAudioOrBuilder getReplyAudioOrBuilder() {
+ return getReplyAudio();
+ }
+
+ public static final int AUTOMATED_AGENT_REPLY_FIELD_NUMBER = 4;
+ private com.google.cloud.dialogflow.v2.AutomatedAgentReply automatedAgentReply_;
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ *
+ * @return Whether the automatedAgentReply field is set.
+ */
+ @java.lang.Override
+ public boolean hasAutomatedAgentReply() {
+ return automatedAgentReply_ != null;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ *
+ * @return The automatedAgentReply.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.AutomatedAgentReply getAutomatedAgentReply() {
+ return automatedAgentReply_ == null
+ ? com.google.cloud.dialogflow.v2.AutomatedAgentReply.getDefaultInstance()
+ : automatedAgentReply_;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.AutomatedAgentReplyOrBuilder
+ getAutomatedAgentReplyOrBuilder() {
+ return getAutomatedAgentReply();
+ }
+
+ public static final int MESSAGE_FIELD_NUMBER = 6;
+ private com.google.cloud.dialogflow.v2.Message message_;
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ *
+ * @return Whether the message field is set.
+ */
+ @java.lang.Override
+ public boolean hasMessage() {
+ return message_ != null;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ *
+ * @return The message.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.Message getMessage() {
+ return message_ == null
+ ? com.google.cloud.dialogflow.v2.Message.getDefaultInstance()
+ : message_;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.MessageOrBuilder getMessageOrBuilder() {
+ return getMessage();
+ }
+
+ public static final int HUMAN_AGENT_SUGGESTION_RESULTS_FIELD_NUMBER = 7;
+ private java.util.List+ * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ @java.lang.Override
+ public java.util.List+ * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ @java.lang.Override
+ public java.util.List extends com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder>
+ getHumanAgentSuggestionResultsOrBuilderList() {
+ return humanAgentSuggestionResults_;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ @java.lang.Override
+ public int getHumanAgentSuggestionResultsCount() {
+ return humanAgentSuggestionResults_.size();
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.SuggestionResult getHumanAgentSuggestionResults(int index) {
+ return humanAgentSuggestionResults_.get(index);
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder
+ getHumanAgentSuggestionResultsOrBuilder(int index) {
+ return humanAgentSuggestionResults_.get(index);
+ }
+
+ public static final int END_USER_SUGGESTION_RESULTS_FIELD_NUMBER = 8;
+ private java.util.List+ * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ @java.lang.Override
+ public java.util.List+ * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ @java.lang.Override
+ public java.util.List extends com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder>
+ getEndUserSuggestionResultsOrBuilderList() {
+ return endUserSuggestionResults_;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ @java.lang.Override
+ public int getEndUserSuggestionResultsCount() {
+ return endUserSuggestionResults_.size();
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.SuggestionResult getEndUserSuggestionResults(int index) {
+ return endUserSuggestionResults_.get(index);
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder
+ getEndUserSuggestionResultsOrBuilder(int index) {
+ return endUserSuggestionResults_.get(index);
+ }
+
+ public static final int DTMF_PARAMETERS_FIELD_NUMBER = 10;
+ private com.google.cloud.dialogflow.v2.DtmfParameters dtmfParameters_;
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ *
+ * @return Whether the dtmfParameters field is set.
+ */
+ @java.lang.Override
+ public boolean hasDtmfParameters() {
+ return dtmfParameters_ != null;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ *
+ * @return The dtmfParameters.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.DtmfParameters getDtmfParameters() {
+ return dtmfParameters_ == null
+ ? com.google.cloud.dialogflow.v2.DtmfParameters.getDefaultInstance()
+ : dtmfParameters_;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.DtmfParametersOrBuilder getDtmfParametersOrBuilder() {
+ return getDtmfParameters();
+ }
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ if (recognitionResult_ != null) {
+ output.writeMessage(1, getRecognitionResult());
+ }
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(replyText_)) {
+ com.google.protobuf.GeneratedMessageV3.writeString(output, 2, replyText_);
+ }
+ if (replyAudio_ != null) {
+ output.writeMessage(3, getReplyAudio());
+ }
+ if (automatedAgentReply_ != null) {
+ output.writeMessage(4, getAutomatedAgentReply());
+ }
+ if (message_ != null) {
+ output.writeMessage(6, getMessage());
+ }
+ for (int i = 0; i < humanAgentSuggestionResults_.size(); i++) {
+ output.writeMessage(7, humanAgentSuggestionResults_.get(i));
+ }
+ for (int i = 0; i < endUserSuggestionResults_.size(); i++) {
+ output.writeMessage(8, endUserSuggestionResults_.get(i));
+ }
+ if (dtmfParameters_ != null) {
+ output.writeMessage(10, getDtmfParameters());
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (recognitionResult_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getRecognitionResult());
+ }
+ if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(replyText_)) {
+ size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, replyText_);
+ }
+ if (replyAudio_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getReplyAudio());
+ }
+ if (automatedAgentReply_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getAutomatedAgentReply());
+ }
+ if (message_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getMessage());
+ }
+ for (int i = 0; i < humanAgentSuggestionResults_.size(); i++) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeMessageSize(
+ 7, humanAgentSuggestionResults_.get(i));
+ }
+ for (int i = 0; i < endUserSuggestionResults_.size(); i++) {
+ size +=
+ com.google.protobuf.CodedOutputStream.computeMessageSize(
+ 8, endUserSuggestionResults_.get(i));
+ }
+ if (dtmfParameters_ != null) {
+ size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getDtmfParameters());
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse other =
+ (com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse) obj;
+
+ if (hasRecognitionResult() != other.hasRecognitionResult()) return false;
+ if (hasRecognitionResult()) {
+ if (!getRecognitionResult().equals(other.getRecognitionResult())) return false;
+ }
+ if (!getReplyText().equals(other.getReplyText())) return false;
+ if (hasReplyAudio() != other.hasReplyAudio()) return false;
+ if (hasReplyAudio()) {
+ if (!getReplyAudio().equals(other.getReplyAudio())) return false;
+ }
+ if (hasAutomatedAgentReply() != other.hasAutomatedAgentReply()) return false;
+ if (hasAutomatedAgentReply()) {
+ if (!getAutomatedAgentReply().equals(other.getAutomatedAgentReply())) return false;
+ }
+ if (hasMessage() != other.hasMessage()) return false;
+ if (hasMessage()) {
+ if (!getMessage().equals(other.getMessage())) return false;
+ }
+ if (!getHumanAgentSuggestionResultsList().equals(other.getHumanAgentSuggestionResultsList()))
+ return false;
+ if (!getEndUserSuggestionResultsList().equals(other.getEndUserSuggestionResultsList()))
+ return false;
+ if (hasDtmfParameters() != other.hasDtmfParameters()) return false;
+ if (hasDtmfParameters()) {
+ if (!getDtmfParameters().equals(other.getDtmfParameters())) return false;
+ }
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ if (hasRecognitionResult()) {
+ hash = (37 * hash) + RECOGNITION_RESULT_FIELD_NUMBER;
+ hash = (53 * hash) + getRecognitionResult().hashCode();
+ }
+ hash = (37 * hash) + REPLY_TEXT_FIELD_NUMBER;
+ hash = (53 * hash) + getReplyText().hashCode();
+ if (hasReplyAudio()) {
+ hash = (37 * hash) + REPLY_AUDIO_FIELD_NUMBER;
+ hash = (53 * hash) + getReplyAudio().hashCode();
+ }
+ if (hasAutomatedAgentReply()) {
+ hash = (37 * hash) + AUTOMATED_AGENT_REPLY_FIELD_NUMBER;
+ hash = (53 * hash) + getAutomatedAgentReply().hashCode();
+ }
+ if (hasMessage()) {
+ hash = (37 * hash) + MESSAGE_FIELD_NUMBER;
+ hash = (53 * hash) + getMessage().hashCode();
+ }
+ if (getHumanAgentSuggestionResultsCount() > 0) {
+ hash = (37 * hash) + HUMAN_AGENT_SUGGESTION_RESULTS_FIELD_NUMBER;
+ hash = (53 * hash) + getHumanAgentSuggestionResultsList().hashCode();
+ }
+ if (getEndUserSuggestionResultsCount() > 0) {
+ hash = (37 * hash) + END_USER_SUGGESTION_RESULTS_FIELD_NUMBER;
+ hash = (53 * hash) + getEndUserSuggestionResultsList().hashCode();
+ }
+ if (hasDtmfParameters()) {
+ hash = (37 * hash) + DTMF_PARAMETERS_FIELD_NUMBER;
+ hash = (53 * hash) + getDtmfParameters().hashCode();
+ }
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ byte[] data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(
+ com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * The top-level message returned from the `StreamingAnalyzeContent` method. + * Multiple response messages can be returned in order: + * 1. If the input was set to streaming audio, the first one or more messages + * contain `recognition_result`. Each `recognition_result` represents a more + * complete transcript of what the user said. The last `recognition_result` + * has `is_final` set to `true`. + * 2. In virtual agent stage: if `enable_partial_automated_agent_reply` is + * true, the following N (currently 1 <= N <= 4) messages + * contain `automated_agent_reply` and optionally `reply_audio` + * returned by the virtual agent. The first (N-1) + * `automated_agent_reply`s will have `automated_agent_reply_type` set to + * `PARTIAL`. The last `automated_agent_reply` has + * `automated_agent_reply_type` set to `FINAL`. + * If `enable_partial_automated_agent_reply` is not enabled, response stream + * only contains the final reply. + * In human assist stage: the following N (N >= 1) messages contain + * `human_agent_suggestion_results`, `end_user_suggestion_results` or + * `message`. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ *
+ * @return Whether the recognitionResult field is set.
+ */
+ public boolean hasRecognitionResult() {
+ return recognitionResultBuilder_ != null || recognitionResult_ != null;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ *
+ * @return The recognitionResult.
+ */
+ public com.google.cloud.dialogflow.v2.StreamingRecognitionResult getRecognitionResult() {
+ if (recognitionResultBuilder_ == null) {
+ return recognitionResult_ == null
+ ? com.google.cloud.dialogflow.v2.StreamingRecognitionResult.getDefaultInstance()
+ : recognitionResult_;
+ } else {
+ return recognitionResultBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ public Builder setRecognitionResult(
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult value) {
+ if (recognitionResultBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ recognitionResult_ = value;
+ onChanged();
+ } else {
+ recognitionResultBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ public Builder setRecognitionResult(
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult.Builder builderForValue) {
+ if (recognitionResultBuilder_ == null) {
+ recognitionResult_ = builderForValue.build();
+ onChanged();
+ } else {
+ recognitionResultBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ public Builder mergeRecognitionResult(
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult value) {
+ if (recognitionResultBuilder_ == null) {
+ if (recognitionResult_ != null) {
+ recognitionResult_ =
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult.newBuilder(
+ recognitionResult_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ recognitionResult_ = value;
+ }
+ onChanged();
+ } else {
+ recognitionResultBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ public Builder clearRecognitionResult() {
+ if (recognitionResultBuilder_ == null) {
+ recognitionResult_ = null;
+ onChanged();
+ } else {
+ recognitionResult_ = null;
+ recognitionResultBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ public com.google.cloud.dialogflow.v2.StreamingRecognitionResult.Builder
+ getRecognitionResultBuilder() {
+
+ onChanged();
+ return getRecognitionResultFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ public com.google.cloud.dialogflow.v2.StreamingRecognitionResultOrBuilder
+ getRecognitionResultOrBuilder() {
+ if (recognitionResultBuilder_ != null) {
+ return recognitionResultBuilder_.getMessageOrBuilder();
+ } else {
+ return recognitionResult_ == null
+ ? com.google.cloud.dialogflow.v2.StreamingRecognitionResult.getDefaultInstance()
+ : recognitionResult_;
+ }
+ }
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult,
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult.Builder,
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResultOrBuilder>
+ getRecognitionResultFieldBuilder() {
+ if (recognitionResultBuilder_ == null) {
+ recognitionResultBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult,
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult.Builder,
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResultOrBuilder>(
+ getRecognitionResult(), getParentForChildren(), isClean());
+ recognitionResult_ = null;
+ }
+ return recognitionResultBuilder_;
+ }
+
+ private java.lang.Object replyText_ = "";
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return The replyText.
+ */
+ public java.lang.String getReplyText() {
+ java.lang.Object ref = replyText_;
+ if (!(ref instanceof java.lang.String)) {
+ com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
+ java.lang.String s = bs.toStringUtf8();
+ replyText_ = s;
+ return s;
+ } else {
+ return (java.lang.String) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return The bytes for replyText.
+ */
+ public com.google.protobuf.ByteString getReplyTextBytes() {
+ java.lang.Object ref = replyText_;
+ if (ref instanceof String) {
+ com.google.protobuf.ByteString b =
+ com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
+ replyText_ = b;
+ return b;
+ } else {
+ return (com.google.protobuf.ByteString) ref;
+ }
+ }
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @param value The replyText to set.
+ * @return This builder for chaining.
+ */
+ public Builder setReplyText(java.lang.String value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+
+ replyText_ = value;
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearReplyText() {
+
+ replyText_ = getDefaultInstance().getReplyText();
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @param value The bytes for replyText to set.
+ * @return This builder for chaining.
+ */
+ public Builder setReplyTextBytes(com.google.protobuf.ByteString value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ checkByteStringIsUtf8(value);
+
+ replyText_ = value;
+ onChanged();
+ return this;
+ }
+
+ private com.google.cloud.dialogflow.v2.OutputAudio replyAudio_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.OutputAudio,
+ com.google.cloud.dialogflow.v2.OutputAudio.Builder,
+ com.google.cloud.dialogflow.v2.OutputAudioOrBuilder>
+ replyAudioBuilder_;
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ *
+ * @return Whether the replyAudio field is set.
+ */
+ public boolean hasReplyAudio() {
+ return replyAudioBuilder_ != null || replyAudio_ != null;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ *
+ * @return The replyAudio.
+ */
+ public com.google.cloud.dialogflow.v2.OutputAudio getReplyAudio() {
+ if (replyAudioBuilder_ == null) {
+ return replyAudio_ == null
+ ? com.google.cloud.dialogflow.v2.OutputAudio.getDefaultInstance()
+ : replyAudio_;
+ } else {
+ return replyAudioBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ public Builder setReplyAudio(com.google.cloud.dialogflow.v2.OutputAudio value) {
+ if (replyAudioBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ replyAudio_ = value;
+ onChanged();
+ } else {
+ replyAudioBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ public Builder setReplyAudio(
+ com.google.cloud.dialogflow.v2.OutputAudio.Builder builderForValue) {
+ if (replyAudioBuilder_ == null) {
+ replyAudio_ = builderForValue.build();
+ onChanged();
+ } else {
+ replyAudioBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ public Builder mergeReplyAudio(com.google.cloud.dialogflow.v2.OutputAudio value) {
+ if (replyAudioBuilder_ == null) {
+ if (replyAudio_ != null) {
+ replyAudio_ =
+ com.google.cloud.dialogflow.v2.OutputAudio.newBuilder(replyAudio_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ replyAudio_ = value;
+ }
+ onChanged();
+ } else {
+ replyAudioBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ public Builder clearReplyAudio() {
+ if (replyAudioBuilder_ == null) {
+ replyAudio_ = null;
+ onChanged();
+ } else {
+ replyAudio_ = null;
+ replyAudioBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ public com.google.cloud.dialogflow.v2.OutputAudio.Builder getReplyAudioBuilder() {
+
+ onChanged();
+ return getReplyAudioFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ public com.google.cloud.dialogflow.v2.OutputAudioOrBuilder getReplyAudioOrBuilder() {
+ if (replyAudioBuilder_ != null) {
+ return replyAudioBuilder_.getMessageOrBuilder();
+ } else {
+ return replyAudio_ == null
+ ? com.google.cloud.dialogflow.v2.OutputAudio.getDefaultInstance()
+ : replyAudio_;
+ }
+ }
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.OutputAudio,
+ com.google.cloud.dialogflow.v2.OutputAudio.Builder,
+ com.google.cloud.dialogflow.v2.OutputAudioOrBuilder>
+ getReplyAudioFieldBuilder() {
+ if (replyAudioBuilder_ == null) {
+ replyAudioBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.OutputAudio,
+ com.google.cloud.dialogflow.v2.OutputAudio.Builder,
+ com.google.cloud.dialogflow.v2.OutputAudioOrBuilder>(
+ getReplyAudio(), getParentForChildren(), isClean());
+ replyAudio_ = null;
+ }
+ return replyAudioBuilder_;
+ }
+
+ private com.google.cloud.dialogflow.v2.AutomatedAgentReply automatedAgentReply_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply,
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply.Builder,
+ com.google.cloud.dialogflow.v2.AutomatedAgentReplyOrBuilder>
+ automatedAgentReplyBuilder_;
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ *
+ * @return Whether the automatedAgentReply field is set.
+ */
+ public boolean hasAutomatedAgentReply() {
+ return automatedAgentReplyBuilder_ != null || automatedAgentReply_ != null;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ *
+ * @return The automatedAgentReply.
+ */
+ public com.google.cloud.dialogflow.v2.AutomatedAgentReply getAutomatedAgentReply() {
+ if (automatedAgentReplyBuilder_ == null) {
+ return automatedAgentReply_ == null
+ ? com.google.cloud.dialogflow.v2.AutomatedAgentReply.getDefaultInstance()
+ : automatedAgentReply_;
+ } else {
+ return automatedAgentReplyBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ public Builder setAutomatedAgentReply(
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply value) {
+ if (automatedAgentReplyBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ automatedAgentReply_ = value;
+ onChanged();
+ } else {
+ automatedAgentReplyBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ public Builder setAutomatedAgentReply(
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply.Builder builderForValue) {
+ if (automatedAgentReplyBuilder_ == null) {
+ automatedAgentReply_ = builderForValue.build();
+ onChanged();
+ } else {
+ automatedAgentReplyBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ public Builder mergeAutomatedAgentReply(
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply value) {
+ if (automatedAgentReplyBuilder_ == null) {
+ if (automatedAgentReply_ != null) {
+ automatedAgentReply_ =
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply.newBuilder(automatedAgentReply_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ automatedAgentReply_ = value;
+ }
+ onChanged();
+ } else {
+ automatedAgentReplyBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ public Builder clearAutomatedAgentReply() {
+ if (automatedAgentReplyBuilder_ == null) {
+ automatedAgentReply_ = null;
+ onChanged();
+ } else {
+ automatedAgentReply_ = null;
+ automatedAgentReplyBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ public com.google.cloud.dialogflow.v2.AutomatedAgentReply.Builder
+ getAutomatedAgentReplyBuilder() {
+
+ onChanged();
+ return getAutomatedAgentReplyFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ public com.google.cloud.dialogflow.v2.AutomatedAgentReplyOrBuilder
+ getAutomatedAgentReplyOrBuilder() {
+ if (automatedAgentReplyBuilder_ != null) {
+ return automatedAgentReplyBuilder_.getMessageOrBuilder();
+ } else {
+ return automatedAgentReply_ == null
+ ? com.google.cloud.dialogflow.v2.AutomatedAgentReply.getDefaultInstance()
+ : automatedAgentReply_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply,
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply.Builder,
+ com.google.cloud.dialogflow.v2.AutomatedAgentReplyOrBuilder>
+ getAutomatedAgentReplyFieldBuilder() {
+ if (automatedAgentReplyBuilder_ == null) {
+ automatedAgentReplyBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply,
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply.Builder,
+ com.google.cloud.dialogflow.v2.AutomatedAgentReplyOrBuilder>(
+ getAutomatedAgentReply(), getParentForChildren(), isClean());
+ automatedAgentReply_ = null;
+ }
+ return automatedAgentReplyBuilder_;
+ }
+
+ private com.google.cloud.dialogflow.v2.Message message_;
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.Message,
+ com.google.cloud.dialogflow.v2.Message.Builder,
+ com.google.cloud.dialogflow.v2.MessageOrBuilder>
+ messageBuilder_;
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ *
+ * @return Whether the message field is set.
+ */
+ public boolean hasMessage() {
+ return messageBuilder_ != null || message_ != null;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ *
+ * @return The message.
+ */
+ public com.google.cloud.dialogflow.v2.Message getMessage() {
+ if (messageBuilder_ == null) {
+ return message_ == null
+ ? com.google.cloud.dialogflow.v2.Message.getDefaultInstance()
+ : message_;
+ } else {
+ return messageBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ public Builder setMessage(com.google.cloud.dialogflow.v2.Message value) {
+ if (messageBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ message_ = value;
+ onChanged();
+ } else {
+ messageBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ public Builder setMessage(com.google.cloud.dialogflow.v2.Message.Builder builderForValue) {
+ if (messageBuilder_ == null) {
+ message_ = builderForValue.build();
+ onChanged();
+ } else {
+ messageBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ public Builder mergeMessage(com.google.cloud.dialogflow.v2.Message value) {
+ if (messageBuilder_ == null) {
+ if (message_ != null) {
+ message_ =
+ com.google.cloud.dialogflow.v2.Message.newBuilder(message_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ message_ = value;
+ }
+ onChanged();
+ } else {
+ messageBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ public Builder clearMessage() {
+ if (messageBuilder_ == null) {
+ message_ = null;
+ onChanged();
+ } else {
+ message_ = null;
+ messageBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ public com.google.cloud.dialogflow.v2.Message.Builder getMessageBuilder() {
+
+ onChanged();
+ return getMessageFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ public com.google.cloud.dialogflow.v2.MessageOrBuilder getMessageOrBuilder() {
+ if (messageBuilder_ != null) {
+ return messageBuilder_.getMessageOrBuilder();
+ } else {
+ return message_ == null
+ ? com.google.cloud.dialogflow.v2.Message.getDefaultInstance()
+ : message_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.Message,
+ com.google.cloud.dialogflow.v2.Message.Builder,
+ com.google.cloud.dialogflow.v2.MessageOrBuilder>
+ getMessageFieldBuilder() {
+ if (messageBuilder_ == null) {
+ messageBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.Message,
+ com.google.cloud.dialogflow.v2.Message.Builder,
+ com.google.cloud.dialogflow.v2.MessageOrBuilder>(
+ getMessage(), getParentForChildren(), isClean());
+ message_ = null;
+ }
+ return messageBuilder_;
+ }
+
+ private java.util.List+ * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public java.util.List+ * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public int getHumanAgentSuggestionResultsCount() {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ return humanAgentSuggestionResults_.size();
+ } else {
+ return humanAgentSuggestionResultsBuilder_.getCount();
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult getHumanAgentSuggestionResults(
+ int index) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ return humanAgentSuggestionResults_.get(index);
+ } else {
+ return humanAgentSuggestionResultsBuilder_.getMessage(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder setHumanAgentSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult value) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.set(index, value);
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.setMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder setHumanAgentSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult.Builder builderForValue) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.set(index, builderForValue.build());
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.setMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder addHumanAgentSuggestionResults(
+ com.google.cloud.dialogflow.v2.SuggestionResult value) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.add(value);
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.addMessage(value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder addHumanAgentSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult value) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.add(index, value);
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.addMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder addHumanAgentSuggestionResults(
+ com.google.cloud.dialogflow.v2.SuggestionResult.Builder builderForValue) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.add(builderForValue.build());
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.addMessage(builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder addHumanAgentSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult.Builder builderForValue) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.add(index, builderForValue.build());
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.addMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder addAllHumanAgentSuggestionResults(
+ java.lang.Iterable extends com.google.cloud.dialogflow.v2.SuggestionResult> values) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ ensureHumanAgentSuggestionResultsIsMutable();
+ com.google.protobuf.AbstractMessageLite.Builder.addAll(
+ values, humanAgentSuggestionResults_);
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.addAllMessages(values);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder clearHumanAgentSuggestionResults() {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ humanAgentSuggestionResults_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000001);
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public Builder removeHumanAgentSuggestionResults(int index) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ ensureHumanAgentSuggestionResultsIsMutable();
+ humanAgentSuggestionResults_.remove(index);
+ onChanged();
+ } else {
+ humanAgentSuggestionResultsBuilder_.remove(index);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult.Builder
+ getHumanAgentSuggestionResultsBuilder(int index) {
+ return getHumanAgentSuggestionResultsFieldBuilder().getBuilder(index);
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder
+ getHumanAgentSuggestionResultsOrBuilder(int index) {
+ if (humanAgentSuggestionResultsBuilder_ == null) {
+ return humanAgentSuggestionResults_.get(index);
+ } else {
+ return humanAgentSuggestionResultsBuilder_.getMessageOrBuilder(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public java.util.List extends com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder>
+ getHumanAgentSuggestionResultsOrBuilderList() {
+ if (humanAgentSuggestionResultsBuilder_ != null) {
+ return humanAgentSuggestionResultsBuilder_.getMessageOrBuilderList();
+ } else {
+ return java.util.Collections.unmodifiableList(humanAgentSuggestionResults_);
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult.Builder
+ addHumanAgentSuggestionResultsBuilder() {
+ return getHumanAgentSuggestionResultsFieldBuilder()
+ .addBuilder(com.google.cloud.dialogflow.v2.SuggestionResult.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult.Builder
+ addHumanAgentSuggestionResultsBuilder(int index) {
+ return getHumanAgentSuggestionResultsFieldBuilder()
+ .addBuilder(index, com.google.cloud.dialogflow.v2.SuggestionResult.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
+ * repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ public java.util.List+ * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public java.util.List+ * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public int getEndUserSuggestionResultsCount() {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ return endUserSuggestionResults_.size();
+ } else {
+ return endUserSuggestionResultsBuilder_.getCount();
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult getEndUserSuggestionResults(int index) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ return endUserSuggestionResults_.get(index);
+ } else {
+ return endUserSuggestionResultsBuilder_.getMessage(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder setEndUserSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult value) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.set(index, value);
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.setMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder setEndUserSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult.Builder builderForValue) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.set(index, builderForValue.build());
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.setMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder addEndUserSuggestionResults(
+ com.google.cloud.dialogflow.v2.SuggestionResult value) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.add(value);
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.addMessage(value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder addEndUserSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult value) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.add(index, value);
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.addMessage(index, value);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder addEndUserSuggestionResults(
+ com.google.cloud.dialogflow.v2.SuggestionResult.Builder builderForValue) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.add(builderForValue.build());
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.addMessage(builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder addEndUserSuggestionResults(
+ int index, com.google.cloud.dialogflow.v2.SuggestionResult.Builder builderForValue) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.add(index, builderForValue.build());
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.addMessage(index, builderForValue.build());
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder addAllEndUserSuggestionResults(
+ java.lang.Iterable extends com.google.cloud.dialogflow.v2.SuggestionResult> values) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ ensureEndUserSuggestionResultsIsMutable();
+ com.google.protobuf.AbstractMessageLite.Builder.addAll(values, endUserSuggestionResults_);
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.addAllMessages(values);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder clearEndUserSuggestionResults() {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ endUserSuggestionResults_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000002);
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.clear();
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public Builder removeEndUserSuggestionResults(int index) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ ensureEndUserSuggestionResultsIsMutable();
+ endUserSuggestionResults_.remove(index);
+ onChanged();
+ } else {
+ endUserSuggestionResultsBuilder_.remove(index);
+ }
+ return this;
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult.Builder
+ getEndUserSuggestionResultsBuilder(int index) {
+ return getEndUserSuggestionResultsFieldBuilder().getBuilder(index);
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder
+ getEndUserSuggestionResultsOrBuilder(int index) {
+ if (endUserSuggestionResultsBuilder_ == null) {
+ return endUserSuggestionResults_.get(index);
+ } else {
+ return endUserSuggestionResultsBuilder_.getMessageOrBuilder(index);
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public java.util.List extends com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder>
+ getEndUserSuggestionResultsOrBuilderList() {
+ if (endUserSuggestionResultsBuilder_ != null) {
+ return endUserSuggestionResultsBuilder_.getMessageOrBuilderList();
+ } else {
+ return java.util.Collections.unmodifiableList(endUserSuggestionResults_);
+ }
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult.Builder
+ addEndUserSuggestionResultsBuilder() {
+ return getEndUserSuggestionResultsFieldBuilder()
+ .addBuilder(com.google.cloud.dialogflow.v2.SuggestionResult.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public com.google.cloud.dialogflow.v2.SuggestionResult.Builder
+ addEndUserSuggestionResultsBuilder(int index) {
+ return getEndUserSuggestionResultsFieldBuilder()
+ .addBuilder(index, com.google.cloud.dialogflow.v2.SuggestionResult.getDefaultInstance());
+ }
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ public java.util.List+ * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ *
+ * @return Whether the dtmfParameters field is set.
+ */
+ public boolean hasDtmfParameters() {
+ return dtmfParametersBuilder_ != null || dtmfParameters_ != null;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ *
+ * @return The dtmfParameters.
+ */
+ public com.google.cloud.dialogflow.v2.DtmfParameters getDtmfParameters() {
+ if (dtmfParametersBuilder_ == null) {
+ return dtmfParameters_ == null
+ ? com.google.cloud.dialogflow.v2.DtmfParameters.getDefaultInstance()
+ : dtmfParameters_;
+ } else {
+ return dtmfParametersBuilder_.getMessage();
+ }
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ public Builder setDtmfParameters(com.google.cloud.dialogflow.v2.DtmfParameters value) {
+ if (dtmfParametersBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ dtmfParameters_ = value;
+ onChanged();
+ } else {
+ dtmfParametersBuilder_.setMessage(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ public Builder setDtmfParameters(
+ com.google.cloud.dialogflow.v2.DtmfParameters.Builder builderForValue) {
+ if (dtmfParametersBuilder_ == null) {
+ dtmfParameters_ = builderForValue.build();
+ onChanged();
+ } else {
+ dtmfParametersBuilder_.setMessage(builderForValue.build());
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ public Builder mergeDtmfParameters(com.google.cloud.dialogflow.v2.DtmfParameters value) {
+ if (dtmfParametersBuilder_ == null) {
+ if (dtmfParameters_ != null) {
+ dtmfParameters_ =
+ com.google.cloud.dialogflow.v2.DtmfParameters.newBuilder(dtmfParameters_)
+ .mergeFrom(value)
+ .buildPartial();
+ } else {
+ dtmfParameters_ = value;
+ }
+ onChanged();
+ } else {
+ dtmfParametersBuilder_.mergeFrom(value);
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ public Builder clearDtmfParameters() {
+ if (dtmfParametersBuilder_ == null) {
+ dtmfParameters_ = null;
+ onChanged();
+ } else {
+ dtmfParameters_ = null;
+ dtmfParametersBuilder_ = null;
+ }
+
+ return this;
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ public com.google.cloud.dialogflow.v2.DtmfParameters.Builder getDtmfParametersBuilder() {
+
+ onChanged();
+ return getDtmfParametersFieldBuilder().getBuilder();
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ public com.google.cloud.dialogflow.v2.DtmfParametersOrBuilder getDtmfParametersOrBuilder() {
+ if (dtmfParametersBuilder_ != null) {
+ return dtmfParametersBuilder_.getMessageOrBuilder();
+ } else {
+ return dtmfParameters_ == null
+ ? com.google.cloud.dialogflow.v2.DtmfParameters.getDefaultInstance()
+ : dtmfParameters_;
+ }
+ }
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ private com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.DtmfParameters,
+ com.google.cloud.dialogflow.v2.DtmfParameters.Builder,
+ com.google.cloud.dialogflow.v2.DtmfParametersOrBuilder>
+ getDtmfParametersFieldBuilder() {
+ if (dtmfParametersBuilder_ == null) {
+ dtmfParametersBuilder_ =
+ new com.google.protobuf.SingleFieldBuilderV3<
+ com.google.cloud.dialogflow.v2.DtmfParameters,
+ com.google.cloud.dialogflow.v2.DtmfParameters.Builder,
+ com.google.cloud.dialogflow.v2.DtmfParametersOrBuilder>(
+ getDtmfParameters(), getParentForChildren(), isClean());
+ dtmfParameters_ = null;
+ }
+ return dtmfParametersBuilder_;
+ }
+
+ @java.lang.Override
+ public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.setUnknownFields(unknownFields);
+ }
+
+ @java.lang.Override
+ public final Builder mergeUnknownFields(
+ final com.google.protobuf.UnknownFieldSet unknownFields) {
+ return super.mergeUnknownFields(unknownFields);
+ }
+
+ // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse)
+ }
+
+ // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse)
+ private static final com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse
+ DEFAULT_INSTANCE;
+
+ static {
+ DEFAULT_INSTANCE = new com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse();
+ }
+
+ public static com.google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse
+ getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser+ * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ *
+ * @return Whether the recognitionResult field is set.
+ */
+ boolean hasRecognitionResult();
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ *
+ * @return The recognitionResult.
+ */
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResult getRecognitionResult();
+ /**
+ *
+ *
+ * + * The result of speech recognition. + *+ * + *
.google.cloud.dialogflow.v2.StreamingRecognitionResult recognition_result = 1;
+ */
+ com.google.cloud.dialogflow.v2.StreamingRecognitionResultOrBuilder
+ getRecognitionResultOrBuilder();
+
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return The replyText.
+ */
+ java.lang.String getReplyText();
+ /**
+ *
+ *
+ * + * The output text content. + * This field is set if an automated agent responded with a text for the user. + *+ * + *
string reply_text = 2;
+ *
+ * @return The bytes for replyText.
+ */
+ com.google.protobuf.ByteString getReplyTextBytes();
+
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ *
+ * @return Whether the replyAudio field is set.
+ */
+ boolean hasReplyAudio();
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ *
+ * @return The replyAudio.
+ */
+ com.google.cloud.dialogflow.v2.OutputAudio getReplyAudio();
+ /**
+ *
+ *
+ * + * The audio data bytes encoded as specified in the request. + * This field is set if: + * - The `reply_audio_config` field is specified in the request. + * - The automated agent, which this output comes from, responded with audio. + * In such case, the `reply_audio.config` field contains settings used to + * synthesize the speech. + * In some scenarios, multiple output audio fields may be present in the + * response structure. In these cases, only the top-most-level audio output + * has content. + *+ * + *
.google.cloud.dialogflow.v2.OutputAudio reply_audio = 3;
+ */
+ com.google.cloud.dialogflow.v2.OutputAudioOrBuilder getReplyAudioOrBuilder();
+
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ *
+ * @return Whether the automatedAgentReply field is set.
+ */
+ boolean hasAutomatedAgentReply();
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ *
+ * @return The automatedAgentReply.
+ */
+ com.google.cloud.dialogflow.v2.AutomatedAgentReply getAutomatedAgentReply();
+ /**
+ *
+ *
+ * + * Only set if a Dialogflow automated agent has responded. + * Note that: [AutomatedAgentReply.detect_intent_response.output_audio][] + * and [AutomatedAgentReply.detect_intent_response.output_audio_config][] + * are always empty, use [reply_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentResponse.reply_audio] instead. + *+ * + *
.google.cloud.dialogflow.v2.AutomatedAgentReply automated_agent_reply = 4;
+ */
+ com.google.cloud.dialogflow.v2.AutomatedAgentReplyOrBuilder getAutomatedAgentReplyOrBuilder();
+
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ *
+ * @return Whether the message field is set.
+ */
+ boolean hasMessage();
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ *
+ * @return The message.
+ */
+ com.google.cloud.dialogflow.v2.Message getMessage();
+ /**
+ *
+ *
+ * + * Message analyzed by CCAI. + *+ * + *
.google.cloud.dialogflow.v2.Message message = 6;
+ */
+ com.google.cloud.dialogflow.v2.MessageOrBuilder getMessageOrBuilder();
+
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ java.util.List+ * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ com.google.cloud.dialogflow.v2.SuggestionResult getHumanAgentSuggestionResults(int index);
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ int getHumanAgentSuggestionResultsCount();
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ java.util.List extends com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder>
+ getHumanAgentSuggestionResultsOrBuilderList();
+ /**
+ *
+ *
+ * + * The suggestions for most recent human agent. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.human_agent_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.human_agent_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult human_agent_suggestion_results = 7;
+ *
+ */
+ com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder getHumanAgentSuggestionResultsOrBuilder(
+ int index);
+
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ java.util.List+ * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ com.google.cloud.dialogflow.v2.SuggestionResult getEndUserSuggestionResults(int index);
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ int getEndUserSuggestionResultsCount();
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ java.util.List extends com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder>
+ getEndUserSuggestionResultsOrBuilderList();
+ /**
+ *
+ *
+ * + * The suggestions for end user. The order is the same as + * [HumanAgentAssistantConfig.SuggestionConfig.feature_configs][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.SuggestionConfig.feature_configs] of + * [HumanAgentAssistantConfig.end_user_suggestion_config][google.cloud.dialogflow.v2.HumanAgentAssistantConfig.end_user_suggestion_config]. + *+ * + *
repeated .google.cloud.dialogflow.v2.SuggestionResult end_user_suggestion_results = 8;
+ *
+ */
+ com.google.cloud.dialogflow.v2.SuggestionResultOrBuilder getEndUserSuggestionResultsOrBuilder(
+ int index);
+
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ *
+ * @return Whether the dtmfParameters field is set.
+ */
+ boolean hasDtmfParameters();
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ *
+ * @return The dtmfParameters.
+ */
+ com.google.cloud.dialogflow.v2.DtmfParameters getDtmfParameters();
+ /**
+ *
+ *
+ * + * Indicates the parameters of DTMF. + *+ * + *
.google.cloud.dialogflow.v2.DtmfParameters dtmf_parameters = 10;
+ */
+ com.google.cloud.dialogflow.v2.DtmfParametersOrBuilder getDtmfParametersOrBuilder();
+}
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/TelephonyDtmf.java b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/TelephonyDtmf.java
new file mode 100644
index 000000000000..48f3867a993d
--- /dev/null
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/java/com/google/cloud/dialogflow/v2/TelephonyDtmf.java
@@ -0,0 +1,485 @@
+/*
+ * Copyright 2020 Google LLC
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * https://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: google/cloud/dialogflow/v2/audio_config.proto
+
+package com.google.cloud.dialogflow.v2;
+
+/**
+ *
+ *
+ * + * [DTMF](https://en.wikipedia.org/wiki/Dual-tone_multi-frequency_signaling) + * digit in Telephony Gateway. + *+ * + * Protobuf enum {@code google.cloud.dialogflow.v2.TelephonyDtmf} + */ +public enum TelephonyDtmf implements com.google.protobuf.ProtocolMessageEnum { + /** + * + * + *
+ * Not specified. This value may be used to indicate an absent digit. + *+ * + *
TELEPHONY_DTMF_UNSPECIFIED = 0;
+ */
+ TELEPHONY_DTMF_UNSPECIFIED(0),
+ /**
+ *
+ *
+ * + * Number: '1'. + *+ * + *
DTMF_ONE = 1;
+ */
+ DTMF_ONE(1),
+ /**
+ *
+ *
+ * + * Number: '2'. + *+ * + *
DTMF_TWO = 2;
+ */
+ DTMF_TWO(2),
+ /**
+ *
+ *
+ * + * Number: '3'. + *+ * + *
DTMF_THREE = 3;
+ */
+ DTMF_THREE(3),
+ /**
+ *
+ *
+ * + * Number: '4'. + *+ * + *
DTMF_FOUR = 4;
+ */
+ DTMF_FOUR(4),
+ /**
+ *
+ *
+ * + * Number: '5'. + *+ * + *
DTMF_FIVE = 5;
+ */
+ DTMF_FIVE(5),
+ /**
+ *
+ *
+ * + * Number: '6'. + *+ * + *
DTMF_SIX = 6;
+ */
+ DTMF_SIX(6),
+ /**
+ *
+ *
+ * + * Number: '7'. + *+ * + *
DTMF_SEVEN = 7;
+ */
+ DTMF_SEVEN(7),
+ /**
+ *
+ *
+ * + * Number: '8'. + *+ * + *
DTMF_EIGHT = 8;
+ */
+ DTMF_EIGHT(8),
+ /**
+ *
+ *
+ * + * Number: '9'. + *+ * + *
DTMF_NINE = 9;
+ */
+ DTMF_NINE(9),
+ /**
+ *
+ *
+ * + * Number: '0'. + *+ * + *
DTMF_ZERO = 10;
+ */
+ DTMF_ZERO(10),
+ /**
+ *
+ *
+ * + * Letter: 'A'. + *+ * + *
DTMF_A = 11;
+ */
+ DTMF_A(11),
+ /**
+ *
+ *
+ * + * Letter: 'B'. + *+ * + *
DTMF_B = 12;
+ */
+ DTMF_B(12),
+ /**
+ *
+ *
+ * + * Letter: 'C'. + *+ * + *
DTMF_C = 13;
+ */
+ DTMF_C(13),
+ /**
+ *
+ *
+ * + * Letter: 'D'. + *+ * + *
DTMF_D = 14;
+ */
+ DTMF_D(14),
+ /**
+ *
+ *
+ * + * Asterisk/star: '*'. + *+ * + *
DTMF_STAR = 15;
+ */
+ DTMF_STAR(15),
+ /**
+ *
+ *
+ * + * Pound/diamond/hash/square/gate/octothorpe: '#'. + *+ * + *
DTMF_POUND = 16;
+ */
+ DTMF_POUND(16),
+ UNRECOGNIZED(-1),
+ ;
+
+ /**
+ *
+ *
+ * + * Not specified. This value may be used to indicate an absent digit. + *+ * + *
TELEPHONY_DTMF_UNSPECIFIED = 0;
+ */
+ public static final int TELEPHONY_DTMF_UNSPECIFIED_VALUE = 0;
+ /**
+ *
+ *
+ * + * Number: '1'. + *+ * + *
DTMF_ONE = 1;
+ */
+ public static final int DTMF_ONE_VALUE = 1;
+ /**
+ *
+ *
+ * + * Number: '2'. + *+ * + *
DTMF_TWO = 2;
+ */
+ public static final int DTMF_TWO_VALUE = 2;
+ /**
+ *
+ *
+ * + * Number: '3'. + *+ * + *
DTMF_THREE = 3;
+ */
+ public static final int DTMF_THREE_VALUE = 3;
+ /**
+ *
+ *
+ * + * Number: '4'. + *+ * + *
DTMF_FOUR = 4;
+ */
+ public static final int DTMF_FOUR_VALUE = 4;
+ /**
+ *
+ *
+ * + * Number: '5'. + *+ * + *
DTMF_FIVE = 5;
+ */
+ public static final int DTMF_FIVE_VALUE = 5;
+ /**
+ *
+ *
+ * + * Number: '6'. + *+ * + *
DTMF_SIX = 6;
+ */
+ public static final int DTMF_SIX_VALUE = 6;
+ /**
+ *
+ *
+ * + * Number: '7'. + *+ * + *
DTMF_SEVEN = 7;
+ */
+ public static final int DTMF_SEVEN_VALUE = 7;
+ /**
+ *
+ *
+ * + * Number: '8'. + *+ * + *
DTMF_EIGHT = 8;
+ */
+ public static final int DTMF_EIGHT_VALUE = 8;
+ /**
+ *
+ *
+ * + * Number: '9'. + *+ * + *
DTMF_NINE = 9;
+ */
+ public static final int DTMF_NINE_VALUE = 9;
+ /**
+ *
+ *
+ * + * Number: '0'. + *+ * + *
DTMF_ZERO = 10;
+ */
+ public static final int DTMF_ZERO_VALUE = 10;
+ /**
+ *
+ *
+ * + * Letter: 'A'. + *+ * + *
DTMF_A = 11;
+ */
+ public static final int DTMF_A_VALUE = 11;
+ /**
+ *
+ *
+ * + * Letter: 'B'. + *+ * + *
DTMF_B = 12;
+ */
+ public static final int DTMF_B_VALUE = 12;
+ /**
+ *
+ *
+ * + * Letter: 'C'. + *+ * + *
DTMF_C = 13;
+ */
+ public static final int DTMF_C_VALUE = 13;
+ /**
+ *
+ *
+ * + * Letter: 'D'. + *+ * + *
DTMF_D = 14;
+ */
+ public static final int DTMF_D_VALUE = 14;
+ /**
+ *
+ *
+ * + * Asterisk/star: '*'. + *+ * + *
DTMF_STAR = 15;
+ */
+ public static final int DTMF_STAR_VALUE = 15;
+ /**
+ *
+ *
+ * + * Pound/diamond/hash/square/gate/octothorpe: '#'. + *+ * + *
DTMF_POUND = 16;
+ */
+ public static final int DTMF_POUND_VALUE = 16;
+
+ public final int getNumber() {
+ if (this == UNRECOGNIZED) {
+ throw new java.lang.IllegalArgumentException(
+ "Can't get the number of an unknown enum value.");
+ }
+ return value;
+ }
+
+ /**
+ * @param value The numeric wire value of the corresponding enum entry.
+ * @return The enum associated with the given numeric wire value.
+ * @deprecated Use {@link #forNumber(int)} instead.
+ */
+ @java.lang.Deprecated
+ public static TelephonyDtmf valueOf(int value) {
+ return forNumber(value);
+ }
+
+ /**
+ * @param value The numeric wire value of the corresponding enum entry.
+ * @return The enum associated with the given numeric wire value.
+ */
+ public static TelephonyDtmf forNumber(int value) {
+ switch (value) {
+ case 0:
+ return TELEPHONY_DTMF_UNSPECIFIED;
+ case 1:
+ return DTMF_ONE;
+ case 2:
+ return DTMF_TWO;
+ case 3:
+ return DTMF_THREE;
+ case 4:
+ return DTMF_FOUR;
+ case 5:
+ return DTMF_FIVE;
+ case 6:
+ return DTMF_SIX;
+ case 7:
+ return DTMF_SEVEN;
+ case 8:
+ return DTMF_EIGHT;
+ case 9:
+ return DTMF_NINE;
+ case 10:
+ return DTMF_ZERO;
+ case 11:
+ return DTMF_A;
+ case 12:
+ return DTMF_B;
+ case 13:
+ return DTMF_C;
+ case 14:
+ return DTMF_D;
+ case 15:
+ return DTMF_STAR;
+ case 16:
+ return DTMF_POUND;
+ default:
+ return null;
+ }
+ }
+
+ public static com.google.protobuf.Internal.EnumLiteMap+ * A wrapper of repeated TelephonyDtmf digits. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.TelephonyDtmfEvents} + */ +public final class TelephonyDtmfEvents extends com.google.protobuf.GeneratedMessageV3 + implements + // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.v2.TelephonyDtmfEvents) + TelephonyDtmfEventsOrBuilder { + private static final long serialVersionUID = 0L; + // Use TelephonyDtmfEvents.newBuilder() to construct. + private TelephonyDtmfEvents(com.google.protobuf.GeneratedMessageV3.Builder> builder) { + super(builder); + } + + private TelephonyDtmfEvents() { + dtmfEvents_ = java.util.Collections.emptyList(); + } + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TelephonyDtmfEvents(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { + return this.unknownFields; + } + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.cloud.dialogflow.v2.AudioConfigProto + .internal_static_google_cloud_dialogflow_v2_TelephonyDtmfEvents_descriptor; + } + + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internalGetFieldAccessorTable() { + return com.google.cloud.dialogflow.v2.AudioConfigProto + .internal_static_google_cloud_dialogflow_v2_TelephonyDtmfEvents_fieldAccessorTable + .ensureFieldAccessorsInitialized( + com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.class, + com.google.cloud.dialogflow.v2.TelephonyDtmfEvents.Builder.class); + } + + public static final int DTMF_EVENTS_FIELD_NUMBER = 1; + private java.util.List
+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return A list containing the dtmfEvents.
+ */
+ @java.lang.Override
+ public java.util.List+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return The count of dtmfEvents.
+ */
+ @java.lang.Override
+ public int getDtmfEventsCount() {
+ return dtmfEvents_.size();
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index of the element to return.
+ * @return The dtmfEvents at the given index.
+ */
+ @java.lang.Override
+ public com.google.cloud.dialogflow.v2.TelephonyDtmf getDtmfEvents(int index) {
+ return dtmfEvents_converter_.convert(dtmfEvents_.get(index));
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return A list containing the enum numeric values on the wire for dtmfEvents.
+ */
+ @java.lang.Override
+ public java.util.List+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index of the value to return.
+ * @return The enum numeric value on the wire of dtmfEvents at the given index.
+ */
+ @java.lang.Override
+ public int getDtmfEventsValue(int index) {
+ return dtmfEvents_.get(index);
+ }
+
+ private int dtmfEventsMemoizedSerializedSize;
+
+ private byte memoizedIsInitialized = -1;
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
+ getSerializedSize();
+ if (getDtmfEventsList().size() > 0) {
+ output.writeUInt32NoTag(10);
+ output.writeUInt32NoTag(dtmfEventsMemoizedSerializedSize);
+ }
+ for (int i = 0; i < dtmfEvents_.size(); i++) {
+ output.writeEnumNoTag(dtmfEvents_.get(i));
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ {
+ int dataSize = 0;
+ for (int i = 0; i < dtmfEvents_.size(); i++) {
+ dataSize += com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag(dtmfEvents_.get(i));
+ }
+ size += dataSize;
+ if (!getDtmfEventsList().isEmpty()) {
+ size += 1;
+ size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize);
+ }
+ dtmfEventsMemoizedSerializedSize = dataSize;
+ }
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof com.google.cloud.dialogflow.v2.TelephonyDtmfEvents)) {
+ return super.equals(obj);
+ }
+ com.google.cloud.dialogflow.v2.TelephonyDtmfEvents other =
+ (com.google.cloud.dialogflow.v2.TelephonyDtmfEvents) obj;
+
+ if (!dtmfEvents_.equals(other.dtmfEvents_)) return false;
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ if (getDtmfEventsCount() > 0) {
+ hash = (37 * hash) + DTMF_EVENTS_FIELD_NUMBER;
+ hash = (53 * hash) + dtmfEvents_.hashCode();
+ }
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseDelimitedFrom(
+ java.io.InputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseDelimitedFrom(
+ java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
+ }
+
+ public static com.google.cloud.dialogflow.v2.TelephonyDtmfEvents parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+ PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() {
+ return newBuilder();
+ }
+
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+
+ public static Builder newBuilder(com.google.cloud.dialogflow.v2.TelephonyDtmfEvents prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ *
+ *
+ * + * A wrapper of repeated TelephonyDtmf digits. + *+ * + * Protobuf type {@code google.cloud.dialogflow.v2.TelephonyDtmfEvents} + */ + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return A list containing the dtmfEvents.
+ */
+ public java.util.List+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return The count of dtmfEvents.
+ */
+ public int getDtmfEventsCount() {
+ return dtmfEvents_.size();
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index of the element to return.
+ * @return The dtmfEvents at the given index.
+ */
+ public com.google.cloud.dialogflow.v2.TelephonyDtmf getDtmfEvents(int index) {
+ return dtmfEvents_converter_.convert(dtmfEvents_.get(index));
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index to set the value at.
+ * @param value The dtmfEvents to set.
+ * @return This builder for chaining.
+ */
+ public Builder setDtmfEvents(int index, com.google.cloud.dialogflow.v2.TelephonyDtmf value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureDtmfEventsIsMutable();
+ dtmfEvents_.set(index, value.getNumber());
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param value The dtmfEvents to add.
+ * @return This builder for chaining.
+ */
+ public Builder addDtmfEvents(com.google.cloud.dialogflow.v2.TelephonyDtmf value) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ ensureDtmfEventsIsMutable();
+ dtmfEvents_.add(value.getNumber());
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param values The dtmfEvents to add.
+ * @return This builder for chaining.
+ */
+ public Builder addAllDtmfEvents(
+ java.lang.Iterable extends com.google.cloud.dialogflow.v2.TelephonyDtmf> values) {
+ ensureDtmfEventsIsMutable();
+ for (com.google.cloud.dialogflow.v2.TelephonyDtmf value : values) {
+ dtmfEvents_.add(value.getNumber());
+ }
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return This builder for chaining.
+ */
+ public Builder clearDtmfEvents() {
+ dtmfEvents_ = java.util.Collections.emptyList();
+ bitField0_ = (bitField0_ & ~0x00000001);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return A list containing the enum numeric values on the wire for dtmfEvents.
+ */
+ public java.util.List+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index of the value to return.
+ * @return The enum numeric value on the wire of dtmfEvents at the given index.
+ */
+ public int getDtmfEventsValue(int index) {
+ return dtmfEvents_.get(index);
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index to set the value at.
+ * @param value The enum numeric value on the wire for dtmfEvents to set.
+ * @return This builder for chaining.
+ */
+ public Builder setDtmfEventsValue(int index, int value) {
+ ensureDtmfEventsIsMutable();
+ dtmfEvents_.set(index, value);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param value The enum numeric value on the wire for dtmfEvents to add.
+ * @return This builder for chaining.
+ */
+ public Builder addDtmfEventsValue(int value) {
+ ensureDtmfEventsIsMutable();
+ dtmfEvents_.add(value);
+ onChanged();
+ return this;
+ }
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param values The enum numeric values on the wire for dtmfEvents to add.
+ * @return This builder for chaining.
+ */
+ public Builder addAllDtmfEventsValue(java.lang.Iterable+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return A list containing the dtmfEvents.
+ */
+ java.util.List+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return The count of dtmfEvents.
+ */
+ int getDtmfEventsCount();
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index of the element to return.
+ * @return The dtmfEvents at the given index.
+ */
+ com.google.cloud.dialogflow.v2.TelephonyDtmf getDtmfEvents(int index);
+ /**
+ *
+ *
+ * + * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @return A list containing the enum numeric values on the wire for dtmfEvents.
+ */
+ java.util.List+ * A sequence of TelephonyDtmf digits. + *+ * + *
repeated .google.cloud.dialogflow.v2.TelephonyDtmf dtmf_events = 1;
+ *
+ * @param index The index of the value to return.
+ * @return The enum numeric value on the wire of dtmfEvents at the given index.
+ */
+ int getDtmfEventsValue(int index);
+}
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/audio_config.proto b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/audio_config.proto
index 98258ee230bd..b86a9d3a1d45 100644
--- a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/audio_config.proto
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/audio_config.proto
@@ -369,6 +369,67 @@ message OutputAudioConfig {
SynthesizeSpeechConfig synthesize_speech_config = 3;
}
+// [DTMF](https://en.wikipedia.org/wiki/Dual-tone_multi-frequency_signaling)
+// digit in Telephony Gateway.
+enum TelephonyDtmf {
+ // Not specified. This value may be used to indicate an absent digit.
+ TELEPHONY_DTMF_UNSPECIFIED = 0;
+
+ // Number: '1'.
+ DTMF_ONE = 1;
+
+ // Number: '2'.
+ DTMF_TWO = 2;
+
+ // Number: '3'.
+ DTMF_THREE = 3;
+
+ // Number: '4'.
+ DTMF_FOUR = 4;
+
+ // Number: '5'.
+ DTMF_FIVE = 5;
+
+ // Number: '6'.
+ DTMF_SIX = 6;
+
+ // Number: '7'.
+ DTMF_SEVEN = 7;
+
+ // Number: '8'.
+ DTMF_EIGHT = 8;
+
+ // Number: '9'.
+ DTMF_NINE = 9;
+
+ // Number: '0'.
+ DTMF_ZERO = 10;
+
+ // Letter: 'A'.
+ DTMF_A = 11;
+
+ // Letter: 'B'.
+ DTMF_B = 12;
+
+ // Letter: 'C'.
+ DTMF_C = 13;
+
+ // Letter: 'D'.
+ DTMF_D = 14;
+
+ // Asterisk/star: '*'.
+ DTMF_STAR = 15;
+
+ // Pound/diamond/hash/square/gate/octothorpe: '#'.
+ DTMF_POUND = 16;
+}
+
+// A wrapper of repeated TelephonyDtmf digits.
+message TelephonyDtmfEvents {
+ // A sequence of TelephonyDtmf digits.
+ repeated TelephonyDtmf dtmf_events = 1;
+}
+
// Configures speech transcription for [ConversationProfile][google.cloud.dialogflow.v2.ConversationProfile].
message SpeechToTextConfig {
// The speech model used in speech to text.
@@ -379,4 +440,13 @@ message SpeechToTextConfig {
// version of the specified model for the language does not exist, then it
// would emit an error.
SpeechModelVariant speech_model_variant = 1;
+
+ // Which Speech model to select. Select the model best suited to your domain
+ // to get best results. If a model is not explicitly specified, then a default
+ // model is used.
+ // Refer to
+ // [Cloud Speech API
+ // documentation](https://cloud.google.com/speech-to-text/docs/basics#select-model)
+ // for more details.
+ string model = 2;
}
diff --git a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/participant.proto b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/participant.proto
index 35b6106e35dd..a39d49fb5278 100644
--- a/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/participant.proto
+++ b/java-dialogflow/proto-google-cloud-dialogflow-v2/src/main/proto/google/cloud/dialogflow/v2/participant.proto
@@ -109,6 +109,24 @@ service Participants {
option (google.api.method_signature) = "participant,event_input";
}
+ // Adds a text (chat, for example), or audio (phone recording, for example)
+ // message from a participant into the conversation.
+ // Note: This method is only available through the gRPC API (not REST).
+ //
+ // The top-level message sent to the client by the server is
+ // `StreamingAnalyzeContentResponse`. Multiple response messages can be
+ // returned in order. The first one or more messages contain the
+ // `recognition_result` field. Each result represents a more complete
+ // transcript of what the user said. The next message contains the
+ // `reply_text` field and potentially the `reply_audio` field. The message can
+ // also contain the `automated_agent_reply` field.
+ //
+ // Note: Always use agent versions for production traffic
+ // sent to virtual agents. See [Versions and
+ // environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).
+ rpc StreamingAnalyzeContent(stream StreamingAnalyzeContentRequest) returns (stream StreamingAnalyzeContentResponse) {
+ }
+
// Gets suggested articles for a participant based on specific historical
// messages.
rpc SuggestArticles(SuggestArticlesRequest) returns (SuggestArticlesResponse) {
@@ -190,6 +208,36 @@ message Participant {
// media stream to this participant. This field can be updated.
string sip_recording_media_label = 6 [(google.api.field_behavior) = OPTIONAL];
+ // Optional. Obfuscated user id that should be associated with the created participant.
+ //
+ // You can specify a user id as follows:
+ //
+ // 1. If you set this field in
+ // [CreateParticipantRequest][google.cloud.dialogflow.v2.CreateParticipantRequest.participant] or
+ // [UpdateParticipantRequest][google.cloud.dialogflow.v2.UpdateParticipantRequest.participant],
+ // Dialogflow adds the obfuscated user id with the participant.
+ //
+ // 2. If you set this field in
+ // [AnalyzeContent][google.cloud.dialogflow.v2.AnalyzeContentRequest.obfuscated_external_user_id] or
+ // [StreamingAnalyzeContent][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.obfuscated_external_user_id],
+ // Dialogflow will update [Participant.obfuscated_external_user_id][google.cloud.dialogflow.v2.Participant.obfuscated_external_user_id].
+ //
+ // Dialogflow returns an error if you try to add a user id for a
+ // non-[END_USER][google.cloud.dialogflow.v2.Participant.Role.END_USER] participant.
+ //
+ // Dialogflow uses this user id for billing and measurement purposes. For
+ // example, Dialogflow determines whether a user in one conversation returned
+ // in a later conversation.
+ //
+ // Note:
+ //
+ // * Please never pass raw user ids to Dialogflow. Always obfuscate your user
+ // id first.
+ // * Dialogflow only accepts a UTF-8 encoded string, e.g., a hex digest of a
+ // hash function like SHA-512.
+ // * The length of the user id must be <= 256 characters.
+ string obfuscated_external_user_id = 7 [(google.api.field_behavior) = OPTIONAL];
+
// Optional. Key-value filters on the metadata of documents returned by article
// suggestion. If specified, article suggestion only returns suggested
// documents that match all filters in their [Document.metadata][google.cloud.dialogflow.v2.Document.metadata]. Multiple
@@ -425,6 +473,171 @@ message AnalyzeContentResponse {
DtmfParameters dtmf_parameters = 9;
}
+// The top-level message sent by the client to the
+// [Participants.StreamingAnalyzeContent][google.cloud.dialogflow.v2.Participants.StreamingAnalyzeContent] method.
+//
+// Multiple request messages should be sent in order:
+//
+// 1. The first message must contain
+// [participant][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.participant],
+// [config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] and optionally
+// [query_params][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.query_params]. If you want
+// to receive an audio response, it should also contain
+// [reply_audio_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.reply_audio_config].
+// The message must not contain
+// [input][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input].
+//
+// 2. If [config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] in the first message
+// was set to [audio_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.audio_config],
+// all subsequent messages must contain
+// [input_audio][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input_audio] to continue
+// with Speech recognition.
+// However, note that:
+//
+// * Dialogflow will bill you for the audio so far.
+// * Dialogflow discards all Speech recognition results in favor of the
+// text input.
+//
+// 3. If [StreamingAnalyzeContentRequest.config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.config] in the first message was set
+// to [StreamingAnalyzeContentRequest.text_config][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.text_config], then the second message
+// must contain only [input_text][google.cloud.dialogflow.v2.StreamingAnalyzeContentRequest.input_text].
+// Moreover, you must not send more than two messages.
+//
+// After you sent all input, you must half-close or abort the request stream.
+message StreamingAnalyzeContentRequest {
+ // Required. The name of the participant this text comes from.
+ // Format: `projects/