All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.google.cloud.dialogflow.cx.v3.QueryResult Maven / Gradle / Ivy

There is a newer version: 0.66.0
Show newest version
/*
 * Copyright 2020 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/cloud/dialogflow/cx/v3/session.proto

package com.google.cloud.dialogflow.cx.v3;

/**
 *
 *
 * 
 * Represents the result of a conversational query.
 * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3.QueryResult} */ public final class QueryResult extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.cloud.dialogflow.cx.v3.QueryResult) QueryResultOrBuilder { private static final long serialVersionUID = 0L; // Use QueryResult.newBuilder() to construct. private QueryResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private QueryResult() { languageCode_ = ""; responseMessages_ = java.util.Collections.emptyList(); webhookStatuses_ = java.util.Collections.emptyList(); webhookPayloads_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance(UnusedPrivateParameter unused) { return new QueryResult(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private QueryResult( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { java.lang.String s = input.readStringRequireUtf8(); queryCase_ = 1; query_ = s; break; } case 18: { java.lang.String s = input.readStringRequireUtf8(); languageCode_ = s; break; } case 26: { com.google.protobuf.Struct.Builder subBuilder = null; if (parameters_ != null) { subBuilder = parameters_.toBuilder(); } parameters_ = input.readMessage(com.google.protobuf.Struct.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(parameters_); parameters_ = subBuilder.buildPartial(); } break; } case 34: { if (!((mutable_bitField0_ & 0x00000001) != 0)) { responseMessages_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000001; } responseMessages_.add( input.readMessage( com.google.cloud.dialogflow.cx.v3.ResponseMessage.parser(), extensionRegistry)); break; } case 50: { if (!((mutable_bitField0_ & 0x00000004) != 0)) { webhookPayloads_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000004; } webhookPayloads_.add( input.readMessage(com.google.protobuf.Struct.parser(), extensionRegistry)); break; } case 58: { com.google.cloud.dialogflow.cx.v3.Page.Builder subBuilder = null; if (currentPage_ != null) { subBuilder = currentPage_.toBuilder(); } currentPage_ = input.readMessage( com.google.cloud.dialogflow.cx.v3.Page.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(currentPage_); currentPage_ = subBuilder.buildPartial(); } break; } case 66: { com.google.cloud.dialogflow.cx.v3.Intent.Builder subBuilder = null; if (intent_ != null) { subBuilder = intent_.toBuilder(); } intent_ = input.readMessage( com.google.cloud.dialogflow.cx.v3.Intent.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(intent_); intent_ = subBuilder.buildPartial(); } break; } case 77: { intentDetectionConfidence_ = input.readFloat(); break; } case 82: { com.google.protobuf.Struct.Builder subBuilder = null; if (diagnosticInfo_ != null) { subBuilder = diagnosticInfo_.toBuilder(); } diagnosticInfo_ = input.readMessage(com.google.protobuf.Struct.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(diagnosticInfo_); diagnosticInfo_ = subBuilder.buildPartial(); } break; } case 90: { java.lang.String s = input.readStringRequireUtf8(); queryCase_ = 11; query_ = s; break; } case 98: { java.lang.String s = input.readStringRequireUtf8(); queryCase_ = 12; query_ = s; break; } case 106: { if (!((mutable_bitField0_ & 0x00000002) != 0)) { webhookStatuses_ = new java.util.ArrayList(); mutable_bitField0_ |= 0x00000002; } webhookStatuses_.add( input.readMessage(com.google.rpc.Status.parser(), extensionRegistry)); break; } case 114: { java.lang.String s = input.readStringRequireUtf8(); queryCase_ = 14; query_ = s; break; } case 122: { com.google.cloud.dialogflow.cx.v3.Match.Builder subBuilder = null; if (match_ != null) { subBuilder = match_.toBuilder(); } match_ = input.readMessage( com.google.cloud.dialogflow.cx.v3.Match.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(match_); match_ = subBuilder.buildPartial(); } break; } case 138: { com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.Builder subBuilder = null; if (sentimentAnalysisResult_ != null) { subBuilder = sentimentAnalysisResult_.toBuilder(); } sentimentAnalysisResult_ = input.readMessage( com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(sentimentAnalysisResult_); sentimentAnalysisResult_ = subBuilder.buildPartial(); } break; } default: { if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { done = true; } break; } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00000001) != 0)) { responseMessages_ = java.util.Collections.unmodifiableList(responseMessages_); } if (((mutable_bitField0_ & 0x00000004) != 0)) { webhookPayloads_ = java.util.Collections.unmodifiableList(webhookPayloads_); } if (((mutable_bitField0_ & 0x00000002) != 0)) { webhookStatuses_ = java.util.Collections.unmodifiableList(webhookStatuses_); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.dialogflow.cx.v3.SessionProto .internal_static_google_cloud_dialogflow_cx_v3_QueryResult_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.dialogflow.cx.v3.SessionProto .internal_static_google_cloud_dialogflow_cx_v3_QueryResult_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.dialogflow.cx.v3.QueryResult.class, com.google.cloud.dialogflow.cx.v3.QueryResult.Builder.class); } private int queryCase_ = 0; private java.lang.Object query_; public enum QueryCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { TEXT(1), TRIGGER_INTENT(11), TRANSCRIPT(12), TRIGGER_EVENT(14), QUERY_NOT_SET(0); private final int value; private QueryCase(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 QueryCase valueOf(int value) { return forNumber(value); } public static QueryCase forNumber(int value) { switch (value) { case 1: return TEXT; case 11: return TRIGGER_INTENT; case 12: return TRANSCRIPT; case 14: return TRIGGER_EVENT; case 0: return QUERY_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public QueryCase getQueryCase() { return QueryCase.forNumber(queryCase_); } public static final int TEXT_FIELD_NUMBER = 1; /** * * *
   * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
   * will contain a copy of the text.
   * 
* * string text = 1; * * @return Whether the text field is set. */ public boolean hasText() { return queryCase_ == 1; } /** * * *
   * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
   * will contain a copy of the text.
   * 
* * string text = 1; * * @return The text. */ public java.lang.String getText() { java.lang.Object ref = ""; if (queryCase_ == 1) { ref = query_; } if (ref instanceof java.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 (queryCase_ == 1) { query_ = s; } return s; } } /** * * *
   * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
   * will contain a copy of the text.
   * 
* * string text = 1; * * @return The bytes for text. */ public com.google.protobuf.ByteString getTextBytes() { java.lang.Object ref = ""; if (queryCase_ == 1) { ref = query_; } if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 1) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int TRIGGER_INTENT_FIELD_NUMBER = 11; /** * * *
   * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
   * contain a copy of the intent identifier.
   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
   * ID>/intents/<Intent ID>`.
   * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return Whether the triggerIntent field is set. */ public boolean hasTriggerIntent() { return queryCase_ == 11; } /** * * *
   * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
   * contain a copy of the intent identifier.
   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
   * ID>/intents/<Intent ID>`.
   * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return The triggerIntent. */ public java.lang.String getTriggerIntent() { java.lang.Object ref = ""; if (queryCase_ == 11) { ref = query_; } if (ref instanceof java.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 (queryCase_ == 11) { query_ = s; } return s; } } /** * * *
   * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
   * contain a copy of the intent identifier.
   * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
   * ID>/intents/<Intent ID>`.
   * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return The bytes for triggerIntent. */ public com.google.protobuf.ByteString getTriggerIntentBytes() { java.lang.Object ref = ""; if (queryCase_ == 11) { ref = query_; } if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 11) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int TRANSCRIPT_FIELD_NUMBER = 12; /** * * *
   * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
   * this field will contain the transcript for the audio.
   * 
* * string transcript = 12; * * @return Whether the transcript field is set. */ public boolean hasTranscript() { return queryCase_ == 12; } /** * * *
   * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
   * this field will contain the transcript for the audio.
   * 
* * string transcript = 12; * * @return The transcript. */ public java.lang.String getTranscript() { java.lang.Object ref = ""; if (queryCase_ == 12) { ref = query_; } if (ref instanceof java.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 (queryCase_ == 12) { query_ = s; } return s; } } /** * * *
   * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
   * this field will contain the transcript for the audio.
   * 
* * string transcript = 12; * * @return The bytes for transcript. */ public com.google.protobuf.ByteString getTranscriptBytes() { java.lang.Object ref = ""; if (queryCase_ == 12) { ref = query_; } if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 12) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int TRIGGER_EVENT_FIELD_NUMBER = 14; /** * * *
   * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
   * the name of the event.
   * 
* * string trigger_event = 14; * * @return Whether the triggerEvent field is set. */ public boolean hasTriggerEvent() { return queryCase_ == 14; } /** * * *
   * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
   * the name of the event.
   * 
* * string trigger_event = 14; * * @return The triggerEvent. */ public java.lang.String getTriggerEvent() { java.lang.Object ref = ""; if (queryCase_ == 14) { ref = query_; } if (ref instanceof java.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 (queryCase_ == 14) { query_ = s; } return s; } } /** * * *
   * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
   * the name of the event.
   * 
* * string trigger_event = 14; * * @return The bytes for triggerEvent. */ public com.google.protobuf.ByteString getTriggerEventBytes() { java.lang.Object ref = ""; if (queryCase_ == 14) { ref = query_; } if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 14) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int LANGUAGE_CODE_FIELD_NUMBER = 2; private volatile java.lang.Object languageCode_; /** * * *
   * The language that was triggered during intent detection.
   * See [Language
   * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
   * for a list of the currently supported language codes.
   * 
* * string language_code = 2; * * @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; } } /** * * *
   * The language that was triggered during intent detection.
   * See [Language
   * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
   * for a list of the currently supported language codes.
   * 
* * string language_code = 2; * * @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; } } public static final int PARAMETERS_FIELD_NUMBER = 3; private com.google.protobuf.Struct parameters_; /** * * *
   * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
   * Depending on your protocol or client library language, this is a
   * map, associative array, symbol table, dictionary, or JSON object
   * composed of a collection of (MapKey, MapValue) pairs:
   * -   MapKey type: string
   * -   MapKey value: parameter name
   * -   MapValue type:
   *     -   If parameter's entity type is a composite entity: map
   *     -   Else: depending on parameter value type, could be one of string,
   *         number, boolean, null, list or map
   * -   MapValue value:
   *     -   If parameter's entity type is a composite entity:
   *         map from composite entity property names to property values
   *     -   Else: parameter value
   * 
* * .google.protobuf.Struct parameters = 3; * * @return Whether the parameters field is set. */ @java.lang.Override public boolean hasParameters() { return parameters_ != null; } /** * * *
   * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
   * Depending on your protocol or client library language, this is a
   * map, associative array, symbol table, dictionary, or JSON object
   * composed of a collection of (MapKey, MapValue) pairs:
   * -   MapKey type: string
   * -   MapKey value: parameter name
   * -   MapValue type:
   *     -   If parameter's entity type is a composite entity: map
   *     -   Else: depending on parameter value type, could be one of string,
   *         number, boolean, null, list or map
   * -   MapValue value:
   *     -   If parameter's entity type is a composite entity:
   *         map from composite entity property names to property values
   *     -   Else: parameter value
   * 
* * .google.protobuf.Struct parameters = 3; * * @return The parameters. */ @java.lang.Override public com.google.protobuf.Struct getParameters() { return parameters_ == null ? com.google.protobuf.Struct.getDefaultInstance() : parameters_; } /** * * *
   * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
   * Depending on your protocol or client library language, this is a
   * map, associative array, symbol table, dictionary, or JSON object
   * composed of a collection of (MapKey, MapValue) pairs:
   * -   MapKey type: string
   * -   MapKey value: parameter name
   * -   MapValue type:
   *     -   If parameter's entity type is a composite entity: map
   *     -   Else: depending on parameter value type, could be one of string,
   *         number, boolean, null, list or map
   * -   MapValue value:
   *     -   If parameter's entity type is a composite entity:
   *         map from composite entity property names to property values
   *     -   Else: parameter value
   * 
* * .google.protobuf.Struct parameters = 3; */ @java.lang.Override public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { return getParameters(); } public static final int RESPONSE_MESSAGES_FIELD_NUMBER = 4; private java.util.List responseMessages_; /** * * *
   * The list of rich messages returned to the client. Responses vary from
   * simple text messages to more sophisticated, structured payloads used
   * to drive complex logic.
   * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ @java.lang.Override public java.util.List getResponseMessagesList() { return responseMessages_; } /** * * *
   * The list of rich messages returned to the client. Responses vary from
   * simple text messages to more sophisticated, structured payloads used
   * to drive complex logic.
   * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ @java.lang.Override public java.util.List getResponseMessagesOrBuilderList() { return responseMessages_; } /** * * *
   * The list of rich messages returned to the client. Responses vary from
   * simple text messages to more sophisticated, structured payloads used
   * to drive complex logic.
   * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ @java.lang.Override public int getResponseMessagesCount() { return responseMessages_.size(); } /** * * *
   * The list of rich messages returned to the client. Responses vary from
   * simple text messages to more sophisticated, structured payloads used
   * to drive complex logic.
   * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.ResponseMessage getResponseMessages(int index) { return responseMessages_.get(index); } /** * * *
   * The list of rich messages returned to the client. Responses vary from
   * simple text messages to more sophisticated, structured payloads used
   * to drive complex logic.
   * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.ResponseMessageOrBuilder getResponseMessagesOrBuilder( int index) { return responseMessages_.get(index); } public static final int WEBHOOK_STATUSES_FIELD_NUMBER = 13; private java.util.List webhookStatuses_; /** * * *
   * The list of webhook call status in the order of call sequence.
   * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ @java.lang.Override public java.util.List getWebhookStatusesList() { return webhookStatuses_; } /** * * *
   * The list of webhook call status in the order of call sequence.
   * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ @java.lang.Override public java.util.List getWebhookStatusesOrBuilderList() { return webhookStatuses_; } /** * * *
   * The list of webhook call status in the order of call sequence.
   * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ @java.lang.Override public int getWebhookStatusesCount() { return webhookStatuses_.size(); } /** * * *
   * The list of webhook call status in the order of call sequence.
   * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ @java.lang.Override public com.google.rpc.Status getWebhookStatuses(int index) { return webhookStatuses_.get(index); } /** * * *
   * The list of webhook call status in the order of call sequence.
   * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ @java.lang.Override public com.google.rpc.StatusOrBuilder getWebhookStatusesOrBuilder(int index) { return webhookStatuses_.get(index); } public static final int WEBHOOK_PAYLOADS_FIELD_NUMBER = 6; private java.util.List webhookPayloads_; /** * * *
   * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
   * the order of call sequence. If some webhook call fails or doesn't return
   * any payload, an empty `Struct` would be used instead.
   * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ @java.lang.Override public java.util.List getWebhookPayloadsList() { return webhookPayloads_; } /** * * *
   * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
   * the order of call sequence. If some webhook call fails or doesn't return
   * any payload, an empty `Struct` would be used instead.
   * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ @java.lang.Override public java.util.List getWebhookPayloadsOrBuilderList() { return webhookPayloads_; } /** * * *
   * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
   * the order of call sequence. If some webhook call fails or doesn't return
   * any payload, an empty `Struct` would be used instead.
   * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ @java.lang.Override public int getWebhookPayloadsCount() { return webhookPayloads_.size(); } /** * * *
   * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
   * the order of call sequence. If some webhook call fails or doesn't return
   * any payload, an empty `Struct` would be used instead.
   * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ @java.lang.Override public com.google.protobuf.Struct getWebhookPayloads(int index) { return webhookPayloads_.get(index); } /** * * *
   * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
   * the order of call sequence. If some webhook call fails or doesn't return
   * any payload, an empty `Struct` would be used instead.
   * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ @java.lang.Override public com.google.protobuf.StructOrBuilder getWebhookPayloadsOrBuilder(int index) { return webhookPayloads_.get(index); } public static final int CURRENT_PAGE_FIELD_NUMBER = 7; private com.google.cloud.dialogflow.cx.v3.Page currentPage_; /** * * *
   * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
   * including but not limited to `name` and `display_name`.
   * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; * * @return Whether the currentPage field is set. */ @java.lang.Override public boolean hasCurrentPage() { return currentPage_ != null; } /** * * *
   * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
   * including but not limited to `name` and `display_name`.
   * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; * * @return The currentPage. */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.Page getCurrentPage() { return currentPage_ == null ? com.google.cloud.dialogflow.cx.v3.Page.getDefaultInstance() : currentPage_; } /** * * *
   * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
   * including but not limited to `name` and `display_name`.
   * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.PageOrBuilder getCurrentPageOrBuilder() { return getCurrentPage(); } public static final int INTENT_FIELD_NUMBER = 8; private com.google.cloud.dialogflow.cx.v3.Intent intent_; /** * * *
   * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
   * are filled in this message, including but not limited to: `name` and
   * `display_name`.
   * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
   * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; * * @return Whether the intent field is set. */ @java.lang.Override @java.lang.Deprecated public boolean hasIntent() { return intent_ != null; } /** * * *
   * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
   * are filled in this message, including but not limited to: `name` and
   * `display_name`.
   * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
   * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; * * @return The intent. */ @java.lang.Override @java.lang.Deprecated public com.google.cloud.dialogflow.cx.v3.Intent getIntent() { return intent_ == null ? com.google.cloud.dialogflow.cx.v3.Intent.getDefaultInstance() : intent_; } /** * * *
   * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
   * are filled in this message, including but not limited to: `name` and
   * `display_name`.
   * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
   * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Override @java.lang.Deprecated public com.google.cloud.dialogflow.cx.v3.IntentOrBuilder getIntentOrBuilder() { return getIntent(); } public static final int INTENT_DETECTION_CONFIDENCE_FIELD_NUMBER = 9; private float intentDetectionConfidence_; /** * * *
   * The intent detection confidence. Values range from 0.0 (completely
   * uncertain) to 1.0 (completely certain).
   * This value is for informational purpose only and is only used to
   * help match the best intent within the classification threshold.
   * This value may change for the same end-user expression at any time due to a
   * model retraining or change in implementation.
   * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
   * 
* * float intent_detection_confidence = 9 [deprecated = true]; * * @return The intentDetectionConfidence. */ @java.lang.Override @java.lang.Deprecated public float getIntentDetectionConfidence() { return intentDetectionConfidence_; } public static final int MATCH_FIELD_NUMBER = 15; private com.google.cloud.dialogflow.cx.v3.Match match_; /** * * *
   * Intent match result, could be an intent or an event.
   * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; * * @return Whether the match field is set. */ @java.lang.Override public boolean hasMatch() { return match_ != null; } /** * * *
   * Intent match result, could be an intent or an event.
   * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; * * @return The match. */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.Match getMatch() { return match_ == null ? com.google.cloud.dialogflow.cx.v3.Match.getDefaultInstance() : match_; } /** * * *
   * Intent match result, could be an intent or an event.
   * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.MatchOrBuilder getMatchOrBuilder() { return getMatch(); } public static final int DIAGNOSTIC_INFO_FIELD_NUMBER = 10; private com.google.protobuf.Struct diagnosticInfo_; /** * * *
   * The free-form diagnostic info. For example, this field could contain
   * webhook call latency. The string keys of the Struct's fields map can change
   * without notice.
   * 
* * .google.protobuf.Struct diagnostic_info = 10; * * @return Whether the diagnosticInfo field is set. */ @java.lang.Override public boolean hasDiagnosticInfo() { return diagnosticInfo_ != null; } /** * * *
   * The free-form diagnostic info. For example, this field could contain
   * webhook call latency. The string keys of the Struct's fields map can change
   * without notice.
   * 
* * .google.protobuf.Struct diagnostic_info = 10; * * @return The diagnosticInfo. */ @java.lang.Override public com.google.protobuf.Struct getDiagnosticInfo() { return diagnosticInfo_ == null ? com.google.protobuf.Struct.getDefaultInstance() : diagnosticInfo_; } /** * * *
   * The free-form diagnostic info. For example, this field could contain
   * webhook call latency. The string keys of the Struct's fields map can change
   * without notice.
   * 
* * .google.protobuf.Struct diagnostic_info = 10; */ @java.lang.Override public com.google.protobuf.StructOrBuilder getDiagnosticInfoOrBuilder() { return getDiagnosticInfo(); } public static final int SENTIMENT_ANALYSIS_RESULT_FIELD_NUMBER = 17; private com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentimentAnalysisResult_; /** * * *
   * The sentiment analyss result, which depends on
   * [`analyze_query_text_sentiment`]
   * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
   * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * * * @return Whether the sentimentAnalysisResult field is set. */ @java.lang.Override public boolean hasSentimentAnalysisResult() { return sentimentAnalysisResult_ != null; } /** * * *
   * The sentiment analyss result, which depends on
   * [`analyze_query_text_sentiment`]
   * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
   * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * * * @return The sentimentAnalysisResult. */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult getSentimentAnalysisResult() { return sentimentAnalysisResult_ == null ? com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.getDefaultInstance() : sentimentAnalysisResult_; } /** * * *
   * The sentiment analyss result, which depends on
   * [`analyze_query_text_sentiment`]
   * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
   * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ @java.lang.Override public com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResultOrBuilder getSentimentAnalysisResultOrBuilder() { return getSentimentAnalysisResult(); } 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 (queryCase_ == 1) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, query_); } if (!getLanguageCodeBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, languageCode_); } if (parameters_ != null) { output.writeMessage(3, getParameters()); } for (int i = 0; i < responseMessages_.size(); i++) { output.writeMessage(4, responseMessages_.get(i)); } for (int i = 0; i < webhookPayloads_.size(); i++) { output.writeMessage(6, webhookPayloads_.get(i)); } if (currentPage_ != null) { output.writeMessage(7, getCurrentPage()); } if (intent_ != null) { output.writeMessage(8, getIntent()); } if (intentDetectionConfidence_ != 0F) { output.writeFloat(9, intentDetectionConfidence_); } if (diagnosticInfo_ != null) { output.writeMessage(10, getDiagnosticInfo()); } if (queryCase_ == 11) { com.google.protobuf.GeneratedMessageV3.writeString(output, 11, query_); } if (queryCase_ == 12) { com.google.protobuf.GeneratedMessageV3.writeString(output, 12, query_); } for (int i = 0; i < webhookStatuses_.size(); i++) { output.writeMessage(13, webhookStatuses_.get(i)); } if (queryCase_ == 14) { com.google.protobuf.GeneratedMessageV3.writeString(output, 14, query_); } if (match_ != null) { output.writeMessage(15, getMatch()); } if (sentimentAnalysisResult_ != null) { output.writeMessage(17, getSentimentAnalysisResult()); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (queryCase_ == 1) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, query_); } if (!getLanguageCodeBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, languageCode_); } if (parameters_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getParameters()); } for (int i = 0; i < responseMessages_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, responseMessages_.get(i)); } for (int i = 0; i < webhookPayloads_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, webhookPayloads_.get(i)); } if (currentPage_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getCurrentPage()); } if (intent_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getIntent()); } if (intentDetectionConfidence_ != 0F) { size += com.google.protobuf.CodedOutputStream.computeFloatSize(9, intentDetectionConfidence_); } if (diagnosticInfo_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getDiagnosticInfo()); } if (queryCase_ == 11) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, query_); } if (queryCase_ == 12) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, query_); } for (int i = 0; i < webhookStatuses_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(13, webhookStatuses_.get(i)); } if (queryCase_ == 14) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(14, query_); } if (match_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(15, getMatch()); } if (sentimentAnalysisResult_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize( 17, getSentimentAnalysisResult()); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof com.google.cloud.dialogflow.cx.v3.QueryResult)) { return super.equals(obj); } com.google.cloud.dialogflow.cx.v3.QueryResult other = (com.google.cloud.dialogflow.cx.v3.QueryResult) obj; if (!getLanguageCode().equals(other.getLanguageCode())) return false; if (hasParameters() != other.hasParameters()) return false; if (hasParameters()) { if (!getParameters().equals(other.getParameters())) return false; } if (!getResponseMessagesList().equals(other.getResponseMessagesList())) return false; if (!getWebhookStatusesList().equals(other.getWebhookStatusesList())) return false; if (!getWebhookPayloadsList().equals(other.getWebhookPayloadsList())) return false; if (hasCurrentPage() != other.hasCurrentPage()) return false; if (hasCurrentPage()) { if (!getCurrentPage().equals(other.getCurrentPage())) return false; } if (hasIntent() != other.hasIntent()) return false; if (hasIntent()) { if (!getIntent().equals(other.getIntent())) return false; } if (java.lang.Float.floatToIntBits(getIntentDetectionConfidence()) != java.lang.Float.floatToIntBits(other.getIntentDetectionConfidence())) return false; if (hasMatch() != other.hasMatch()) return false; if (hasMatch()) { if (!getMatch().equals(other.getMatch())) return false; } if (hasDiagnosticInfo() != other.hasDiagnosticInfo()) return false; if (hasDiagnosticInfo()) { if (!getDiagnosticInfo().equals(other.getDiagnosticInfo())) return false; } if (hasSentimentAnalysisResult() != other.hasSentimentAnalysisResult()) return false; if (hasSentimentAnalysisResult()) { if (!getSentimentAnalysisResult().equals(other.getSentimentAnalysisResult())) return false; } if (!getQueryCase().equals(other.getQueryCase())) return false; switch (queryCase_) { case 1: if (!getText().equals(other.getText())) return false; break; case 11: if (!getTriggerIntent().equals(other.getTriggerIntent())) return false; break; case 12: if (!getTranscript().equals(other.getTranscript())) return false; break; case 14: if (!getTriggerEvent().equals(other.getTriggerEvent())) return false; break; case 0: default: } if (!unknownFields.equals(other.unknownFields)) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + LANGUAGE_CODE_FIELD_NUMBER; hash = (53 * hash) + getLanguageCode().hashCode(); if (hasParameters()) { hash = (37 * hash) + PARAMETERS_FIELD_NUMBER; hash = (53 * hash) + getParameters().hashCode(); } if (getResponseMessagesCount() > 0) { hash = (37 * hash) + RESPONSE_MESSAGES_FIELD_NUMBER; hash = (53 * hash) + getResponseMessagesList().hashCode(); } if (getWebhookStatusesCount() > 0) { hash = (37 * hash) + WEBHOOK_STATUSES_FIELD_NUMBER; hash = (53 * hash) + getWebhookStatusesList().hashCode(); } if (getWebhookPayloadsCount() > 0) { hash = (37 * hash) + WEBHOOK_PAYLOADS_FIELD_NUMBER; hash = (53 * hash) + getWebhookPayloadsList().hashCode(); } if (hasCurrentPage()) { hash = (37 * hash) + CURRENT_PAGE_FIELD_NUMBER; hash = (53 * hash) + getCurrentPage().hashCode(); } if (hasIntent()) { hash = (37 * hash) + INTENT_FIELD_NUMBER; hash = (53 * hash) + getIntent().hashCode(); } hash = (37 * hash) + INTENT_DETECTION_CONFIDENCE_FIELD_NUMBER; hash = (53 * hash) + java.lang.Float.floatToIntBits(getIntentDetectionConfidence()); if (hasMatch()) { hash = (37 * hash) + MATCH_FIELD_NUMBER; hash = (53 * hash) + getMatch().hashCode(); } if (hasDiagnosticInfo()) { hash = (37 * hash) + DIAGNOSTIC_INFO_FIELD_NUMBER; hash = (53 * hash) + getDiagnosticInfo().hashCode(); } if (hasSentimentAnalysisResult()) { hash = (37 * hash) + SENTIMENT_ANALYSIS_RESULT_FIELD_NUMBER; hash = (53 * hash) + getSentimentAnalysisResult().hashCode(); } switch (queryCase_) { case 1: hash = (37 * hash) + TEXT_FIELD_NUMBER; hash = (53 * hash) + getText().hashCode(); break; case 11: hash = (37 * hash) + TRIGGER_INTENT_FIELD_NUMBER; hash = (53 * hash) + getTriggerIntent().hashCode(); break; case 12: hash = (37 * hash) + TRANSCRIPT_FIELD_NUMBER; hash = (53 * hash) + getTranscript().hashCode(); break; case 14: hash = (37 * hash) + TRIGGER_EVENT_FIELD_NUMBER; hash = (53 * hash) + getTriggerEvent().hashCode(); break; case 0: default: } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseDelimitedFrom( java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseDelimitedFrom( java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( PARSER, input, extensionRegistry); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } public static com.google.cloud.dialogflow.cx.v3.QueryResult parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3.parseWithIOException( PARSER, input, extensionRegistry); } @java.lang.Override public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } public static Builder newBuilder(com.google.cloud.dialogflow.cx.v3.QueryResult prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** * * *
   * Represents the result of a conversational query.
   * 
* * Protobuf type {@code google.cloud.dialogflow.cx.v3.QueryResult} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.cloud.dialogflow.cx.v3.QueryResult) com.google.cloud.dialogflow.cx.v3.QueryResultOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloud.dialogflow.cx.v3.SessionProto .internal_static_google_cloud_dialogflow_cx_v3_QueryResult_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.cloud.dialogflow.cx.v3.SessionProto .internal_static_google_cloud_dialogflow_cx_v3_QueryResult_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.cloud.dialogflow.cx.v3.QueryResult.class, com.google.cloud.dialogflow.cx.v3.QueryResult.Builder.class); } // Construct using com.google.cloud.dialogflow.cx.v3.QueryResult.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getResponseMessagesFieldBuilder(); getWebhookStatusesFieldBuilder(); getWebhookPayloadsFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); languageCode_ = ""; if (parametersBuilder_ == null) { parameters_ = null; } else { parameters_ = null; parametersBuilder_ = null; } if (responseMessagesBuilder_ == null) { responseMessages_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); } else { responseMessagesBuilder_.clear(); } if (webhookStatusesBuilder_ == null) { webhookStatuses_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); } else { webhookStatusesBuilder_.clear(); } if (webhookPayloadsBuilder_ == null) { webhookPayloads_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000004); } else { webhookPayloadsBuilder_.clear(); } if (currentPageBuilder_ == null) { currentPage_ = null; } else { currentPage_ = null; currentPageBuilder_ = null; } if (intentBuilder_ == null) { intent_ = null; } else { intent_ = null; intentBuilder_ = null; } intentDetectionConfidence_ = 0F; if (matchBuilder_ == null) { match_ = null; } else { match_ = null; matchBuilder_ = null; } if (diagnosticInfoBuilder_ == null) { diagnosticInfo_ = null; } else { diagnosticInfo_ = null; diagnosticInfoBuilder_ = null; } if (sentimentAnalysisResultBuilder_ == null) { sentimentAnalysisResult_ = null; } else { sentimentAnalysisResult_ = null; sentimentAnalysisResultBuilder_ = null; } queryCase_ = 0; query_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.cloud.dialogflow.cx.v3.SessionProto .internal_static_google_cloud_dialogflow_cx_v3_QueryResult_descriptor; } @java.lang.Override public com.google.cloud.dialogflow.cx.v3.QueryResult getDefaultInstanceForType() { return com.google.cloud.dialogflow.cx.v3.QueryResult.getDefaultInstance(); } @java.lang.Override public com.google.cloud.dialogflow.cx.v3.QueryResult build() { com.google.cloud.dialogflow.cx.v3.QueryResult result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.cloud.dialogflow.cx.v3.QueryResult buildPartial() { com.google.cloud.dialogflow.cx.v3.QueryResult result = new com.google.cloud.dialogflow.cx.v3.QueryResult(this); int from_bitField0_ = bitField0_; if (queryCase_ == 1) { result.query_ = query_; } if (queryCase_ == 11) { result.query_ = query_; } if (queryCase_ == 12) { result.query_ = query_; } if (queryCase_ == 14) { result.query_ = query_; } result.languageCode_ = languageCode_; if (parametersBuilder_ == null) { result.parameters_ = parameters_; } else { result.parameters_ = parametersBuilder_.build(); } if (responseMessagesBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { responseMessages_ = java.util.Collections.unmodifiableList(responseMessages_); bitField0_ = (bitField0_ & ~0x00000001); } result.responseMessages_ = responseMessages_; } else { result.responseMessages_ = responseMessagesBuilder_.build(); } if (webhookStatusesBuilder_ == null) { if (((bitField0_ & 0x00000002) != 0)) { webhookStatuses_ = java.util.Collections.unmodifiableList(webhookStatuses_); bitField0_ = (bitField0_ & ~0x00000002); } result.webhookStatuses_ = webhookStatuses_; } else { result.webhookStatuses_ = webhookStatusesBuilder_.build(); } if (webhookPayloadsBuilder_ == null) { if (((bitField0_ & 0x00000004) != 0)) { webhookPayloads_ = java.util.Collections.unmodifiableList(webhookPayloads_); bitField0_ = (bitField0_ & ~0x00000004); } result.webhookPayloads_ = webhookPayloads_; } else { result.webhookPayloads_ = webhookPayloadsBuilder_.build(); } if (currentPageBuilder_ == null) { result.currentPage_ = currentPage_; } else { result.currentPage_ = currentPageBuilder_.build(); } if (intentBuilder_ == null) { result.intent_ = intent_; } else { result.intent_ = intentBuilder_.build(); } result.intentDetectionConfidence_ = intentDetectionConfidence_; if (matchBuilder_ == null) { result.match_ = match_; } else { result.match_ = matchBuilder_.build(); } if (diagnosticInfoBuilder_ == null) { result.diagnosticInfo_ = diagnosticInfo_; } else { result.diagnosticInfo_ = diagnosticInfoBuilder_.build(); } if (sentimentAnalysisResultBuilder_ == null) { result.sentimentAnalysisResult_ = sentimentAnalysisResult_; } else { result.sentimentAnalysisResult_ = sentimentAnalysisResultBuilder_.build(); } result.queryCase_ = queryCase_; onBuilt(); return result; } @java.lang.Override public Builder clone() { return super.clone(); } @java.lang.Override public Builder setField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } @java.lang.Override public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } @java.lang.Override public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } @java.lang.Override public Builder setRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } @java.lang.Override public Builder addRepeatedField( com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof com.google.cloud.dialogflow.cx.v3.QueryResult) { return mergeFrom((com.google.cloud.dialogflow.cx.v3.QueryResult) other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.cloud.dialogflow.cx.v3.QueryResult other) { if (other == com.google.cloud.dialogflow.cx.v3.QueryResult.getDefaultInstance()) return this; if (!other.getLanguageCode().isEmpty()) { languageCode_ = other.languageCode_; onChanged(); } if (other.hasParameters()) { mergeParameters(other.getParameters()); } if (responseMessagesBuilder_ == null) { if (!other.responseMessages_.isEmpty()) { if (responseMessages_.isEmpty()) { responseMessages_ = other.responseMessages_; bitField0_ = (bitField0_ & ~0x00000001); } else { ensureResponseMessagesIsMutable(); responseMessages_.addAll(other.responseMessages_); } onChanged(); } } else { if (!other.responseMessages_.isEmpty()) { if (responseMessagesBuilder_.isEmpty()) { responseMessagesBuilder_.dispose(); responseMessagesBuilder_ = null; responseMessages_ = other.responseMessages_; bitField0_ = (bitField0_ & ~0x00000001); responseMessagesBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getResponseMessagesFieldBuilder() : null; } else { responseMessagesBuilder_.addAllMessages(other.responseMessages_); } } } if (webhookStatusesBuilder_ == null) { if (!other.webhookStatuses_.isEmpty()) { if (webhookStatuses_.isEmpty()) { webhookStatuses_ = other.webhookStatuses_; bitField0_ = (bitField0_ & ~0x00000002); } else { ensureWebhookStatusesIsMutable(); webhookStatuses_.addAll(other.webhookStatuses_); } onChanged(); } } else { if (!other.webhookStatuses_.isEmpty()) { if (webhookStatusesBuilder_.isEmpty()) { webhookStatusesBuilder_.dispose(); webhookStatusesBuilder_ = null; webhookStatuses_ = other.webhookStatuses_; bitField0_ = (bitField0_ & ~0x00000002); webhookStatusesBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getWebhookStatusesFieldBuilder() : null; } else { webhookStatusesBuilder_.addAllMessages(other.webhookStatuses_); } } } if (webhookPayloadsBuilder_ == null) { if (!other.webhookPayloads_.isEmpty()) { if (webhookPayloads_.isEmpty()) { webhookPayloads_ = other.webhookPayloads_; bitField0_ = (bitField0_ & ~0x00000004); } else { ensureWebhookPayloadsIsMutable(); webhookPayloads_.addAll(other.webhookPayloads_); } onChanged(); } } else { if (!other.webhookPayloads_.isEmpty()) { if (webhookPayloadsBuilder_.isEmpty()) { webhookPayloadsBuilder_.dispose(); webhookPayloadsBuilder_ = null; webhookPayloads_ = other.webhookPayloads_; bitField0_ = (bitField0_ & ~0x00000004); webhookPayloadsBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getWebhookPayloadsFieldBuilder() : null; } else { webhookPayloadsBuilder_.addAllMessages(other.webhookPayloads_); } } } if (other.hasCurrentPage()) { mergeCurrentPage(other.getCurrentPage()); } if (other.hasIntent()) { mergeIntent(other.getIntent()); } if (other.getIntentDetectionConfidence() != 0F) { setIntentDetectionConfidence(other.getIntentDetectionConfidence()); } if (other.hasMatch()) { mergeMatch(other.getMatch()); } if (other.hasDiagnosticInfo()) { mergeDiagnosticInfo(other.getDiagnosticInfo()); } if (other.hasSentimentAnalysisResult()) { mergeSentimentAnalysisResult(other.getSentimentAnalysisResult()); } switch (other.getQueryCase()) { case TEXT: { queryCase_ = 1; query_ = other.query_; onChanged(); break; } case TRIGGER_INTENT: { queryCase_ = 11; query_ = other.query_; onChanged(); break; } case TRANSCRIPT: { queryCase_ = 12; query_ = other.query_; onChanged(); break; } case TRIGGER_EVENT: { queryCase_ = 14; query_ = other.query_; onChanged(); break; } case QUERY_NOT_SET: { break; } } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { com.google.cloud.dialogflow.cx.v3.QueryResult parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.google.cloud.dialogflow.cx.v3.QueryResult) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private int queryCase_ = 0; private java.lang.Object query_; public QueryCase getQueryCase() { return QueryCase.forNumber(queryCase_); } public Builder clearQuery() { queryCase_ = 0; query_ = null; onChanged(); return this; } private int bitField0_; /** * * *
     * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
     * will contain a copy of the text.
     * 
* * string text = 1; * * @return Whether the text field is set. */ @java.lang.Override public boolean hasText() { return queryCase_ == 1; } /** * * *
     * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
     * will contain a copy of the text.
     * 
* * string text = 1; * * @return The text. */ @java.lang.Override public java.lang.String getText() { java.lang.Object ref = ""; if (queryCase_ == 1) { ref = query_; } if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (queryCase_ == 1) { query_ = s; } return s; } else { return (java.lang.String) ref; } } /** * * *
     * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
     * will contain a copy of the text.
     * 
* * string text = 1; * * @return The bytes for text. */ @java.lang.Override public com.google.protobuf.ByteString getTextBytes() { java.lang.Object ref = ""; if (queryCase_ == 1) { ref = query_; } if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 1) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
     * will contain a copy of the text.
     * 
* * string text = 1; * * @param value The text to set. * @return This builder for chaining. */ public Builder setText(java.lang.String value) { if (value == null) { throw new NullPointerException(); } queryCase_ = 1; query_ = value; onChanged(); return this; } /** * * *
     * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
     * will contain a copy of the text.
     * 
* * string text = 1; * * @return This builder for chaining. */ public Builder clearText() { if (queryCase_ == 1) { queryCase_ = 0; query_ = null; onChanged(); } return this; } /** * * *
     * If [natural language text][google.cloud.dialogflow.cx.v3.TextInput] was provided as input, this field
     * will contain a copy of the text.
     * 
* * string text = 1; * * @param value The bytes for text to set. * @return This builder for chaining. */ public Builder setTextBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); queryCase_ = 1; query_ = value; onChanged(); return this; } /** * * *
     * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
     * contain a copy of the intent identifier.
     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
     * ID>/intents/<Intent ID>`.
     * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return Whether the triggerIntent field is set. */ @java.lang.Override public boolean hasTriggerIntent() { return queryCase_ == 11; } /** * * *
     * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
     * contain a copy of the intent identifier.
     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
     * ID>/intents/<Intent ID>`.
     * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return The triggerIntent. */ @java.lang.Override public java.lang.String getTriggerIntent() { java.lang.Object ref = ""; if (queryCase_ == 11) { ref = query_; } if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (queryCase_ == 11) { query_ = s; } return s; } else { return (java.lang.String) ref; } } /** * * *
     * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
     * contain a copy of the intent identifier.
     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
     * ID>/intents/<Intent ID>`.
     * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return The bytes for triggerIntent. */ @java.lang.Override public com.google.protobuf.ByteString getTriggerIntentBytes() { java.lang.Object ref = ""; if (queryCase_ == 11) { ref = query_; } if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 11) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
     * contain a copy of the intent identifier.
     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
     * ID>/intents/<Intent ID>`.
     * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @param value The triggerIntent to set. * @return This builder for chaining. */ public Builder setTriggerIntent(java.lang.String value) { if (value == null) { throw new NullPointerException(); } queryCase_ = 11; query_ = value; onChanged(); return this; } /** * * *
     * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
     * contain a copy of the intent identifier.
     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
     * ID>/intents/<Intent ID>`.
     * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @return This builder for chaining. */ public Builder clearTriggerIntent() { if (queryCase_ == 11) { queryCase_ = 0; query_ = null; onChanged(); } return this; } /** * * *
     * If an [intent][google.cloud.dialogflow.cx.v3.IntentInput] was provided as input, this field will
     * contain a copy of the intent identifier.
     * Format: `projects/<Project ID>/locations/<Location ID>/agents/<Agent
     * ID>/intents/<Intent ID>`.
     * 
* * string trigger_intent = 11 [(.google.api.resource_reference) = { ... } * * @param value The bytes for triggerIntent to set. * @return This builder for chaining. */ public Builder setTriggerIntentBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); queryCase_ = 11; query_ = value; onChanged(); return this; } /** * * *
     * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
     * this field will contain the transcript for the audio.
     * 
* * string transcript = 12; * * @return Whether the transcript field is set. */ @java.lang.Override public boolean hasTranscript() { return queryCase_ == 12; } /** * * *
     * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
     * this field will contain the transcript for the audio.
     * 
* * string transcript = 12; * * @return The transcript. */ @java.lang.Override public java.lang.String getTranscript() { java.lang.Object ref = ""; if (queryCase_ == 12) { ref = query_; } if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (queryCase_ == 12) { query_ = s; } return s; } else { return (java.lang.String) ref; } } /** * * *
     * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
     * this field will contain the transcript for the audio.
     * 
* * string transcript = 12; * * @return The bytes for transcript. */ @java.lang.Override public com.google.protobuf.ByteString getTranscriptBytes() { java.lang.Object ref = ""; if (queryCase_ == 12) { ref = query_; } if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 12) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
     * this field will contain the transcript for the audio.
     * 
* * string transcript = 12; * * @param value The transcript to set. * @return This builder for chaining. */ public Builder setTranscript(java.lang.String value) { if (value == null) { throw new NullPointerException(); } queryCase_ = 12; query_ = value; onChanged(); return this; } /** * * *
     * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
     * this field will contain the transcript for the audio.
     * 
* * string transcript = 12; * * @return This builder for chaining. */ public Builder clearTranscript() { if (queryCase_ == 12) { queryCase_ = 0; query_ = null; onChanged(); } return this; } /** * * *
     * If [natural language speech audio][google.cloud.dialogflow.cx.v3.AudioInput] was provided as input,
     * this field will contain the transcript for the audio.
     * 
* * string transcript = 12; * * @param value The bytes for transcript to set. * @return This builder for chaining. */ public Builder setTranscriptBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); queryCase_ = 12; query_ = value; onChanged(); return this; } /** * * *
     * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
     * the name of the event.
     * 
* * string trigger_event = 14; * * @return Whether the triggerEvent field is set. */ @java.lang.Override public boolean hasTriggerEvent() { return queryCase_ == 14; } /** * * *
     * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
     * the name of the event.
     * 
* * string trigger_event = 14; * * @return The triggerEvent. */ @java.lang.Override public java.lang.String getTriggerEvent() { java.lang.Object ref = ""; if (queryCase_ == 14) { ref = query_; } if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); if (queryCase_ == 14) { query_ = s; } return s; } else { return (java.lang.String) ref; } } /** * * *
     * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
     * the name of the event.
     * 
* * string trigger_event = 14; * * @return The bytes for triggerEvent. */ @java.lang.Override public com.google.protobuf.ByteString getTriggerEventBytes() { java.lang.Object ref = ""; if (queryCase_ == 14) { ref = query_; } if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); if (queryCase_ == 14) { query_ = b; } return b; } else { return (com.google.protobuf.ByteString) ref; } } /** * * *
     * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
     * the name of the event.
     * 
* * string trigger_event = 14; * * @param value The triggerEvent to set. * @return This builder for chaining. */ public Builder setTriggerEvent(java.lang.String value) { if (value == null) { throw new NullPointerException(); } queryCase_ = 14; query_ = value; onChanged(); return this; } /** * * *
     * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
     * the name of the event.
     * 
* * string trigger_event = 14; * * @return This builder for chaining. */ public Builder clearTriggerEvent() { if (queryCase_ == 14) { queryCase_ = 0; query_ = null; onChanged(); } return this; } /** * * *
     * If an [event][google.cloud.dialogflow.cx.v3.EventInput] was provided as input, this field will contain
     * the name of the event.
     * 
* * string trigger_event = 14; * * @param value The bytes for triggerEvent to set. * @return This builder for chaining. */ public Builder setTriggerEventBytes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); queryCase_ = 14; query_ = value; onChanged(); return this; } private java.lang.Object languageCode_ = ""; /** * * *
     * The language that was triggered during intent detection.
     * See [Language
     * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
     * for a list of the currently supported language codes.
     * 
* * string language_code = 2; * * @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; } } /** * * *
     * The language that was triggered during intent detection.
     * See [Language
     * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
     * for a list of the currently supported language codes.
     * 
* * string language_code = 2; * * @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; } } /** * * *
     * The language that was triggered during intent detection.
     * See [Language
     * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
     * for a list of the currently supported language codes.
     * 
* * string language_code = 2; * * @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; } /** * * *
     * The language that was triggered during intent detection.
     * See [Language
     * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
     * for a list of the currently supported language codes.
     * 
* * string language_code = 2; * * @return This builder for chaining. */ public Builder clearLanguageCode() { languageCode_ = getDefaultInstance().getLanguageCode(); onChanged(); return this; } /** * * *
     * The language that was triggered during intent detection.
     * See [Language
     * Support](https://cloud.google.com/dialogflow/cx/docs/reference/language)
     * for a list of the currently supported language codes.
     * 
* * string language_code = 2; * * @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; } private com.google.protobuf.Struct parameters_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> parametersBuilder_; /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; * * @return Whether the parameters field is set. */ public boolean hasParameters() { return parametersBuilder_ != null || parameters_ != null; } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; * * @return The parameters. */ public com.google.protobuf.Struct getParameters() { if (parametersBuilder_ == null) { return parameters_ == null ? com.google.protobuf.Struct.getDefaultInstance() : parameters_; } else { return parametersBuilder_.getMessage(); } } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ public Builder setParameters(com.google.protobuf.Struct value) { if (parametersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } parameters_ = value; onChanged(); } else { parametersBuilder_.setMessage(value); } return this; } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ public Builder setParameters(com.google.protobuf.Struct.Builder builderForValue) { if (parametersBuilder_ == null) { parameters_ = builderForValue.build(); onChanged(); } else { parametersBuilder_.setMessage(builderForValue.build()); } return this; } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ public Builder mergeParameters(com.google.protobuf.Struct value) { if (parametersBuilder_ == null) { if (parameters_ != null) { parameters_ = com.google.protobuf.Struct.newBuilder(parameters_).mergeFrom(value).buildPartial(); } else { parameters_ = value; } onChanged(); } else { parametersBuilder_.mergeFrom(value); } return this; } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ public Builder clearParameters() { if (parametersBuilder_ == null) { parameters_ = null; onChanged(); } else { parameters_ = null; parametersBuilder_ = null; } return this; } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ public com.google.protobuf.Struct.Builder getParametersBuilder() { onChanged(); return getParametersFieldBuilder().getBuilder(); } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ public com.google.protobuf.StructOrBuilder getParametersOrBuilder() { if (parametersBuilder_ != null) { return parametersBuilder_.getMessageOrBuilder(); } else { return parameters_ == null ? com.google.protobuf.Struct.getDefaultInstance() : parameters_; } } /** * * *
     * The collected [session parameters][google.cloud.dialogflow.cx.v3.SessionInfo.parameters].
     * Depending on your protocol or client library language, this is a
     * map, associative array, symbol table, dictionary, or JSON object
     * composed of a collection of (MapKey, MapValue) pairs:
     * -   MapKey type: string
     * -   MapKey value: parameter name
     * -   MapValue type:
     *     -   If parameter's entity type is a composite entity: map
     *     -   Else: depending on parameter value type, could be one of string,
     *         number, boolean, null, list or map
     * -   MapValue value:
     *     -   If parameter's entity type is a composite entity:
     *         map from composite entity property names to property values
     *     -   Else: parameter value
     * 
* * .google.protobuf.Struct parameters = 3; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> getParametersFieldBuilder() { if (parametersBuilder_ == null) { parametersBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>( getParameters(), getParentForChildren(), isClean()); parameters_ = null; } return parametersBuilder_; } private java.util.List responseMessages_ = java.util.Collections.emptyList(); private void ensureResponseMessagesIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { responseMessages_ = new java.util.ArrayList( responseMessages_); bitField0_ |= 0x00000001; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.ResponseMessage, com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder, com.google.cloud.dialogflow.cx.v3.ResponseMessageOrBuilder> responseMessagesBuilder_; /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public java.util.List getResponseMessagesList() { if (responseMessagesBuilder_ == null) { return java.util.Collections.unmodifiableList(responseMessages_); } else { return responseMessagesBuilder_.getMessageList(); } } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public int getResponseMessagesCount() { if (responseMessagesBuilder_ == null) { return responseMessages_.size(); } else { return responseMessagesBuilder_.getCount(); } } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public com.google.cloud.dialogflow.cx.v3.ResponseMessage getResponseMessages(int index) { if (responseMessagesBuilder_ == null) { return responseMessages_.get(index); } else { return responseMessagesBuilder_.getMessage(index); } } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder setResponseMessages( int index, com.google.cloud.dialogflow.cx.v3.ResponseMessage value) { if (responseMessagesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResponseMessagesIsMutable(); responseMessages_.set(index, value); onChanged(); } else { responseMessagesBuilder_.setMessage(index, value); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder setResponseMessages( int index, com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder builderForValue) { if (responseMessagesBuilder_ == null) { ensureResponseMessagesIsMutable(); responseMessages_.set(index, builderForValue.build()); onChanged(); } else { responseMessagesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder addResponseMessages(com.google.cloud.dialogflow.cx.v3.ResponseMessage value) { if (responseMessagesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResponseMessagesIsMutable(); responseMessages_.add(value); onChanged(); } else { responseMessagesBuilder_.addMessage(value); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder addResponseMessages( int index, com.google.cloud.dialogflow.cx.v3.ResponseMessage value) { if (responseMessagesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureResponseMessagesIsMutable(); responseMessages_.add(index, value); onChanged(); } else { responseMessagesBuilder_.addMessage(index, value); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder addResponseMessages( com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder builderForValue) { if (responseMessagesBuilder_ == null) { ensureResponseMessagesIsMutable(); responseMessages_.add(builderForValue.build()); onChanged(); } else { responseMessagesBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder addResponseMessages( int index, com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder builderForValue) { if (responseMessagesBuilder_ == null) { ensureResponseMessagesIsMutable(); responseMessages_.add(index, builderForValue.build()); onChanged(); } else { responseMessagesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder addAllResponseMessages( java.lang.Iterable values) { if (responseMessagesBuilder_ == null) { ensureResponseMessagesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, responseMessages_); onChanged(); } else { responseMessagesBuilder_.addAllMessages(values); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder clearResponseMessages() { if (responseMessagesBuilder_ == null) { responseMessages_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); } else { responseMessagesBuilder_.clear(); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public Builder removeResponseMessages(int index) { if (responseMessagesBuilder_ == null) { ensureResponseMessagesIsMutable(); responseMessages_.remove(index); onChanged(); } else { responseMessagesBuilder_.remove(index); } return this; } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder getResponseMessagesBuilder( int index) { return getResponseMessagesFieldBuilder().getBuilder(index); } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public com.google.cloud.dialogflow.cx.v3.ResponseMessageOrBuilder getResponseMessagesOrBuilder( int index) { if (responseMessagesBuilder_ == null) { return responseMessages_.get(index); } else { return responseMessagesBuilder_.getMessageOrBuilder(index); } } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public java.util.List getResponseMessagesOrBuilderList() { if (responseMessagesBuilder_ != null) { return responseMessagesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(responseMessages_); } } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder addResponseMessagesBuilder() { return getResponseMessagesFieldBuilder() .addBuilder(com.google.cloud.dialogflow.cx.v3.ResponseMessage.getDefaultInstance()); } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder addResponseMessagesBuilder( int index) { return getResponseMessagesFieldBuilder() .addBuilder( index, com.google.cloud.dialogflow.cx.v3.ResponseMessage.getDefaultInstance()); } /** * * *
     * The list of rich messages returned to the client. Responses vary from
     * simple text messages to more sophisticated, structured payloads used
     * to drive complex logic.
     * 
* * repeated .google.cloud.dialogflow.cx.v3.ResponseMessage response_messages = 4; */ public java.util.List getResponseMessagesBuilderList() { return getResponseMessagesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.ResponseMessage, com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder, com.google.cloud.dialogflow.cx.v3.ResponseMessageOrBuilder> getResponseMessagesFieldBuilder() { if (responseMessagesBuilder_ == null) { responseMessagesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.ResponseMessage, com.google.cloud.dialogflow.cx.v3.ResponseMessage.Builder, com.google.cloud.dialogflow.cx.v3.ResponseMessageOrBuilder>( responseMessages_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); responseMessages_ = null; } return responseMessagesBuilder_; } private java.util.List webhookStatuses_ = java.util.Collections.emptyList(); private void ensureWebhookStatusesIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { webhookStatuses_ = new java.util.ArrayList(webhookStatuses_); bitField0_ |= 0x00000002; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> webhookStatusesBuilder_; /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public java.util.List getWebhookStatusesList() { if (webhookStatusesBuilder_ == null) { return java.util.Collections.unmodifiableList(webhookStatuses_); } else { return webhookStatusesBuilder_.getMessageList(); } } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public int getWebhookStatusesCount() { if (webhookStatusesBuilder_ == null) { return webhookStatuses_.size(); } else { return webhookStatusesBuilder_.getCount(); } } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public com.google.rpc.Status getWebhookStatuses(int index) { if (webhookStatusesBuilder_ == null) { return webhookStatuses_.get(index); } else { return webhookStatusesBuilder_.getMessage(index); } } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder setWebhookStatuses(int index, com.google.rpc.Status value) { if (webhookStatusesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureWebhookStatusesIsMutable(); webhookStatuses_.set(index, value); onChanged(); } else { webhookStatusesBuilder_.setMessage(index, value); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder setWebhookStatuses(int index, com.google.rpc.Status.Builder builderForValue) { if (webhookStatusesBuilder_ == null) { ensureWebhookStatusesIsMutable(); webhookStatuses_.set(index, builderForValue.build()); onChanged(); } else { webhookStatusesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder addWebhookStatuses(com.google.rpc.Status value) { if (webhookStatusesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureWebhookStatusesIsMutable(); webhookStatuses_.add(value); onChanged(); } else { webhookStatusesBuilder_.addMessage(value); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder addWebhookStatuses(int index, com.google.rpc.Status value) { if (webhookStatusesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureWebhookStatusesIsMutable(); webhookStatuses_.add(index, value); onChanged(); } else { webhookStatusesBuilder_.addMessage(index, value); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder addWebhookStatuses(com.google.rpc.Status.Builder builderForValue) { if (webhookStatusesBuilder_ == null) { ensureWebhookStatusesIsMutable(); webhookStatuses_.add(builderForValue.build()); onChanged(); } else { webhookStatusesBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder addWebhookStatuses(int index, com.google.rpc.Status.Builder builderForValue) { if (webhookStatusesBuilder_ == null) { ensureWebhookStatusesIsMutable(); webhookStatuses_.add(index, builderForValue.build()); onChanged(); } else { webhookStatusesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder addAllWebhookStatuses( java.lang.Iterable values) { if (webhookStatusesBuilder_ == null) { ensureWebhookStatusesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, webhookStatuses_); onChanged(); } else { webhookStatusesBuilder_.addAllMessages(values); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder clearWebhookStatuses() { if (webhookStatusesBuilder_ == null) { webhookStatuses_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); } else { webhookStatusesBuilder_.clear(); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public Builder removeWebhookStatuses(int index) { if (webhookStatusesBuilder_ == null) { ensureWebhookStatusesIsMutable(); webhookStatuses_.remove(index); onChanged(); } else { webhookStatusesBuilder_.remove(index); } return this; } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public com.google.rpc.Status.Builder getWebhookStatusesBuilder(int index) { return getWebhookStatusesFieldBuilder().getBuilder(index); } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public com.google.rpc.StatusOrBuilder getWebhookStatusesOrBuilder(int index) { if (webhookStatusesBuilder_ == null) { return webhookStatuses_.get(index); } else { return webhookStatusesBuilder_.getMessageOrBuilder(index); } } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public java.util.List getWebhookStatusesOrBuilderList() { if (webhookStatusesBuilder_ != null) { return webhookStatusesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(webhookStatuses_); } } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public com.google.rpc.Status.Builder addWebhookStatusesBuilder() { return getWebhookStatusesFieldBuilder() .addBuilder(com.google.rpc.Status.getDefaultInstance()); } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public com.google.rpc.Status.Builder addWebhookStatusesBuilder(int index) { return getWebhookStatusesFieldBuilder() .addBuilder(index, com.google.rpc.Status.getDefaultInstance()); } /** * * *
     * The list of webhook call status in the order of call sequence.
     * 
* * repeated .google.rpc.Status webhook_statuses = 13; */ public java.util.List getWebhookStatusesBuilderList() { return getWebhookStatusesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder> getWebhookStatusesFieldBuilder() { if (webhookStatusesBuilder_ == null) { webhookStatusesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.rpc.Status, com.google.rpc.Status.Builder, com.google.rpc.StatusOrBuilder>( webhookStatuses_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); webhookStatuses_ = null; } return webhookStatusesBuilder_; } private java.util.List webhookPayloads_ = java.util.Collections.emptyList(); private void ensureWebhookPayloadsIsMutable() { if (!((bitField0_ & 0x00000004) != 0)) { webhookPayloads_ = new java.util.ArrayList(webhookPayloads_); bitField0_ |= 0x00000004; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> webhookPayloadsBuilder_; /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public java.util.List getWebhookPayloadsList() { if (webhookPayloadsBuilder_ == null) { return java.util.Collections.unmodifiableList(webhookPayloads_); } else { return webhookPayloadsBuilder_.getMessageList(); } } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public int getWebhookPayloadsCount() { if (webhookPayloadsBuilder_ == null) { return webhookPayloads_.size(); } else { return webhookPayloadsBuilder_.getCount(); } } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public com.google.protobuf.Struct getWebhookPayloads(int index) { if (webhookPayloadsBuilder_ == null) { return webhookPayloads_.get(index); } else { return webhookPayloadsBuilder_.getMessage(index); } } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder setWebhookPayloads(int index, com.google.protobuf.Struct value) { if (webhookPayloadsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureWebhookPayloadsIsMutable(); webhookPayloads_.set(index, value); onChanged(); } else { webhookPayloadsBuilder_.setMessage(index, value); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder setWebhookPayloads( int index, com.google.protobuf.Struct.Builder builderForValue) { if (webhookPayloadsBuilder_ == null) { ensureWebhookPayloadsIsMutable(); webhookPayloads_.set(index, builderForValue.build()); onChanged(); } else { webhookPayloadsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder addWebhookPayloads(com.google.protobuf.Struct value) { if (webhookPayloadsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureWebhookPayloadsIsMutable(); webhookPayloads_.add(value); onChanged(); } else { webhookPayloadsBuilder_.addMessage(value); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder addWebhookPayloads(int index, com.google.protobuf.Struct value) { if (webhookPayloadsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureWebhookPayloadsIsMutable(); webhookPayloads_.add(index, value); onChanged(); } else { webhookPayloadsBuilder_.addMessage(index, value); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder addWebhookPayloads(com.google.protobuf.Struct.Builder builderForValue) { if (webhookPayloadsBuilder_ == null) { ensureWebhookPayloadsIsMutable(); webhookPayloads_.add(builderForValue.build()); onChanged(); } else { webhookPayloadsBuilder_.addMessage(builderForValue.build()); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder addWebhookPayloads( int index, com.google.protobuf.Struct.Builder builderForValue) { if (webhookPayloadsBuilder_ == null) { ensureWebhookPayloadsIsMutable(); webhookPayloads_.add(index, builderForValue.build()); onChanged(); } else { webhookPayloadsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder addAllWebhookPayloads( java.lang.Iterable values) { if (webhookPayloadsBuilder_ == null) { ensureWebhookPayloadsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll(values, webhookPayloads_); onChanged(); } else { webhookPayloadsBuilder_.addAllMessages(values); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder clearWebhookPayloads() { if (webhookPayloadsBuilder_ == null) { webhookPayloads_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); } else { webhookPayloadsBuilder_.clear(); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public Builder removeWebhookPayloads(int index) { if (webhookPayloadsBuilder_ == null) { ensureWebhookPayloadsIsMutable(); webhookPayloads_.remove(index); onChanged(); } else { webhookPayloadsBuilder_.remove(index); } return this; } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public com.google.protobuf.Struct.Builder getWebhookPayloadsBuilder(int index) { return getWebhookPayloadsFieldBuilder().getBuilder(index); } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public com.google.protobuf.StructOrBuilder getWebhookPayloadsOrBuilder(int index) { if (webhookPayloadsBuilder_ == null) { return webhookPayloads_.get(index); } else { return webhookPayloadsBuilder_.getMessageOrBuilder(index); } } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public java.util.List getWebhookPayloadsOrBuilderList() { if (webhookPayloadsBuilder_ != null) { return webhookPayloadsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(webhookPayloads_); } } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public com.google.protobuf.Struct.Builder addWebhookPayloadsBuilder() { return getWebhookPayloadsFieldBuilder() .addBuilder(com.google.protobuf.Struct.getDefaultInstance()); } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public com.google.protobuf.Struct.Builder addWebhookPayloadsBuilder(int index) { return getWebhookPayloadsFieldBuilder() .addBuilder(index, com.google.protobuf.Struct.getDefaultInstance()); } /** * * *
     * The list of webhook payload in [WebhookResponse.payload][google.cloud.dialogflow.cx.v3.WebhookResponse.payload], in
     * the order of call sequence. If some webhook call fails or doesn't return
     * any payload, an empty `Struct` would be used instead.
     * 
* * repeated .google.protobuf.Struct webhook_payloads = 6; */ public java.util.List getWebhookPayloadsBuilderList() { return getWebhookPayloadsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> getWebhookPayloadsFieldBuilder() { if (webhookPayloadsBuilder_ == null) { webhookPayloadsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>( webhookPayloads_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); webhookPayloads_ = null; } return webhookPayloadsBuilder_; } private com.google.cloud.dialogflow.cx.v3.Page currentPage_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Page, com.google.cloud.dialogflow.cx.v3.Page.Builder, com.google.cloud.dialogflow.cx.v3.PageOrBuilder> currentPageBuilder_; /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; * * @return Whether the currentPage field is set. */ public boolean hasCurrentPage() { return currentPageBuilder_ != null || currentPage_ != null; } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; * * @return The currentPage. */ public com.google.cloud.dialogflow.cx.v3.Page getCurrentPage() { if (currentPageBuilder_ == null) { return currentPage_ == null ? com.google.cloud.dialogflow.cx.v3.Page.getDefaultInstance() : currentPage_; } else { return currentPageBuilder_.getMessage(); } } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ public Builder setCurrentPage(com.google.cloud.dialogflow.cx.v3.Page value) { if (currentPageBuilder_ == null) { if (value == null) { throw new NullPointerException(); } currentPage_ = value; onChanged(); } else { currentPageBuilder_.setMessage(value); } return this; } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ public Builder setCurrentPage(com.google.cloud.dialogflow.cx.v3.Page.Builder builderForValue) { if (currentPageBuilder_ == null) { currentPage_ = builderForValue.build(); onChanged(); } else { currentPageBuilder_.setMessage(builderForValue.build()); } return this; } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ public Builder mergeCurrentPage(com.google.cloud.dialogflow.cx.v3.Page value) { if (currentPageBuilder_ == null) { if (currentPage_ != null) { currentPage_ = com.google.cloud.dialogflow.cx.v3.Page.newBuilder(currentPage_) .mergeFrom(value) .buildPartial(); } else { currentPage_ = value; } onChanged(); } else { currentPageBuilder_.mergeFrom(value); } return this; } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ public Builder clearCurrentPage() { if (currentPageBuilder_ == null) { currentPage_ = null; onChanged(); } else { currentPage_ = null; currentPageBuilder_ = null; } return this; } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ public com.google.cloud.dialogflow.cx.v3.Page.Builder getCurrentPageBuilder() { onChanged(); return getCurrentPageFieldBuilder().getBuilder(); } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ public com.google.cloud.dialogflow.cx.v3.PageOrBuilder getCurrentPageOrBuilder() { if (currentPageBuilder_ != null) { return currentPageBuilder_.getMessageOrBuilder(); } else { return currentPage_ == null ? com.google.cloud.dialogflow.cx.v3.Page.getDefaultInstance() : currentPage_; } } /** * * *
     * The current [Page][google.cloud.dialogflow.cx.v3.Page]. Some, not all fields are filled in this message,
     * including but not limited to `name` and `display_name`.
     * 
* * .google.cloud.dialogflow.cx.v3.Page current_page = 7; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Page, com.google.cloud.dialogflow.cx.v3.Page.Builder, com.google.cloud.dialogflow.cx.v3.PageOrBuilder> getCurrentPageFieldBuilder() { if (currentPageBuilder_ == null) { currentPageBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Page, com.google.cloud.dialogflow.cx.v3.Page.Builder, com.google.cloud.dialogflow.cx.v3.PageOrBuilder>( getCurrentPage(), getParentForChildren(), isClean()); currentPage_ = null; } return currentPageBuilder_; } private com.google.cloud.dialogflow.cx.v3.Intent intent_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Intent, com.google.cloud.dialogflow.cx.v3.Intent.Builder, com.google.cloud.dialogflow.cx.v3.IntentOrBuilder> intentBuilder_; /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; * * @return Whether the intent field is set. */ @java.lang.Deprecated public boolean hasIntent() { return intentBuilder_ != null || intent_ != null; } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; * * @return The intent. */ @java.lang.Deprecated public com.google.cloud.dialogflow.cx.v3.Intent getIntent() { if (intentBuilder_ == null) { return intent_ == null ? com.google.cloud.dialogflow.cx.v3.Intent.getDefaultInstance() : intent_; } else { return intentBuilder_.getMessage(); } } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Deprecated public Builder setIntent(com.google.cloud.dialogflow.cx.v3.Intent value) { if (intentBuilder_ == null) { if (value == null) { throw new NullPointerException(); } intent_ = value; onChanged(); } else { intentBuilder_.setMessage(value); } return this; } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Deprecated public Builder setIntent(com.google.cloud.dialogflow.cx.v3.Intent.Builder builderForValue) { if (intentBuilder_ == null) { intent_ = builderForValue.build(); onChanged(); } else { intentBuilder_.setMessage(builderForValue.build()); } return this; } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Deprecated public Builder mergeIntent(com.google.cloud.dialogflow.cx.v3.Intent value) { if (intentBuilder_ == null) { if (intent_ != null) { intent_ = com.google.cloud.dialogflow.cx.v3.Intent.newBuilder(intent_) .mergeFrom(value) .buildPartial(); } else { intent_ = value; } onChanged(); } else { intentBuilder_.mergeFrom(value); } return this; } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Deprecated public Builder clearIntent() { if (intentBuilder_ == null) { intent_ = null; onChanged(); } else { intent_ = null; intentBuilder_ = null; } return this; } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Deprecated public com.google.cloud.dialogflow.cx.v3.Intent.Builder getIntentBuilder() { onChanged(); return getIntentFieldBuilder().getBuilder(); } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ @java.lang.Deprecated public com.google.cloud.dialogflow.cx.v3.IntentOrBuilder getIntentOrBuilder() { if (intentBuilder_ != null) { return intentBuilder_.getMessageOrBuilder(); } else { return intent_ == null ? com.google.cloud.dialogflow.cx.v3.Intent.getDefaultInstance() : intent_; } } /** * * *
     * The [Intent][google.cloud.dialogflow.cx.v3.Intent] that matched the conversational query. Some, not all fields
     * are filled in this message, including but not limited to: `name` and
     * `display_name`.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * .google.cloud.dialogflow.cx.v3.Intent intent = 8 [deprecated = true]; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Intent, com.google.cloud.dialogflow.cx.v3.Intent.Builder, com.google.cloud.dialogflow.cx.v3.IntentOrBuilder> getIntentFieldBuilder() { if (intentBuilder_ == null) { intentBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Intent, com.google.cloud.dialogflow.cx.v3.Intent.Builder, com.google.cloud.dialogflow.cx.v3.IntentOrBuilder>( getIntent(), getParentForChildren(), isClean()); intent_ = null; } return intentBuilder_; } private float intentDetectionConfidence_; /** * * *
     * The intent detection confidence. Values range from 0.0 (completely
     * uncertain) to 1.0 (completely certain).
     * This value is for informational purpose only and is only used to
     * help match the best intent within the classification threshold.
     * This value may change for the same end-user expression at any time due to a
     * model retraining or change in implementation.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * float intent_detection_confidence = 9 [deprecated = true]; * * @return The intentDetectionConfidence. */ @java.lang.Override @java.lang.Deprecated public float getIntentDetectionConfidence() { return intentDetectionConfidence_; } /** * * *
     * The intent detection confidence. Values range from 0.0 (completely
     * uncertain) to 1.0 (completely certain).
     * This value is for informational purpose only and is only used to
     * help match the best intent within the classification threshold.
     * This value may change for the same end-user expression at any time due to a
     * model retraining or change in implementation.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * float intent_detection_confidence = 9 [deprecated = true]; * * @param value The intentDetectionConfidence to set. * @return This builder for chaining. */ @java.lang.Deprecated public Builder setIntentDetectionConfidence(float value) { intentDetectionConfidence_ = value; onChanged(); return this; } /** * * *
     * The intent detection confidence. Values range from 0.0 (completely
     * uncertain) to 1.0 (completely certain).
     * This value is for informational purpose only and is only used to
     * help match the best intent within the classification threshold.
     * This value may change for the same end-user expression at any time due to a
     * model retraining or change in implementation.
     * This field is deprecated, please use [QueryResult.match][google.cloud.dialogflow.cx.v3.QueryResult.match] instead.
     * 
* * float intent_detection_confidence = 9 [deprecated = true]; * * @return This builder for chaining. */ @java.lang.Deprecated public Builder clearIntentDetectionConfidence() { intentDetectionConfidence_ = 0F; onChanged(); return this; } private com.google.cloud.dialogflow.cx.v3.Match match_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Match, com.google.cloud.dialogflow.cx.v3.Match.Builder, com.google.cloud.dialogflow.cx.v3.MatchOrBuilder> matchBuilder_; /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; * * @return Whether the match field is set. */ public boolean hasMatch() { return matchBuilder_ != null || match_ != null; } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; * * @return The match. */ public com.google.cloud.dialogflow.cx.v3.Match getMatch() { if (matchBuilder_ == null) { return match_ == null ? com.google.cloud.dialogflow.cx.v3.Match.getDefaultInstance() : match_; } else { return matchBuilder_.getMessage(); } } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ public Builder setMatch(com.google.cloud.dialogflow.cx.v3.Match value) { if (matchBuilder_ == null) { if (value == null) { throw new NullPointerException(); } match_ = value; onChanged(); } else { matchBuilder_.setMessage(value); } return this; } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ public Builder setMatch(com.google.cloud.dialogflow.cx.v3.Match.Builder builderForValue) { if (matchBuilder_ == null) { match_ = builderForValue.build(); onChanged(); } else { matchBuilder_.setMessage(builderForValue.build()); } return this; } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ public Builder mergeMatch(com.google.cloud.dialogflow.cx.v3.Match value) { if (matchBuilder_ == null) { if (match_ != null) { match_ = com.google.cloud.dialogflow.cx.v3.Match.newBuilder(match_) .mergeFrom(value) .buildPartial(); } else { match_ = value; } onChanged(); } else { matchBuilder_.mergeFrom(value); } return this; } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ public Builder clearMatch() { if (matchBuilder_ == null) { match_ = null; onChanged(); } else { match_ = null; matchBuilder_ = null; } return this; } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ public com.google.cloud.dialogflow.cx.v3.Match.Builder getMatchBuilder() { onChanged(); return getMatchFieldBuilder().getBuilder(); } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ public com.google.cloud.dialogflow.cx.v3.MatchOrBuilder getMatchOrBuilder() { if (matchBuilder_ != null) { return matchBuilder_.getMessageOrBuilder(); } else { return match_ == null ? com.google.cloud.dialogflow.cx.v3.Match.getDefaultInstance() : match_; } } /** * * *
     * Intent match result, could be an intent or an event.
     * 
* * .google.cloud.dialogflow.cx.v3.Match match = 15; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Match, com.google.cloud.dialogflow.cx.v3.Match.Builder, com.google.cloud.dialogflow.cx.v3.MatchOrBuilder> getMatchFieldBuilder() { if (matchBuilder_ == null) { matchBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.Match, com.google.cloud.dialogflow.cx.v3.Match.Builder, com.google.cloud.dialogflow.cx.v3.MatchOrBuilder>( getMatch(), getParentForChildren(), isClean()); match_ = null; } return matchBuilder_; } private com.google.protobuf.Struct diagnosticInfo_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> diagnosticInfoBuilder_; /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; * * @return Whether the diagnosticInfo field is set. */ public boolean hasDiagnosticInfo() { return diagnosticInfoBuilder_ != null || diagnosticInfo_ != null; } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; * * @return The diagnosticInfo. */ public com.google.protobuf.Struct getDiagnosticInfo() { if (diagnosticInfoBuilder_ == null) { return diagnosticInfo_ == null ? com.google.protobuf.Struct.getDefaultInstance() : diagnosticInfo_; } else { return diagnosticInfoBuilder_.getMessage(); } } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ public Builder setDiagnosticInfo(com.google.protobuf.Struct value) { if (diagnosticInfoBuilder_ == null) { if (value == null) { throw new NullPointerException(); } diagnosticInfo_ = value; onChanged(); } else { diagnosticInfoBuilder_.setMessage(value); } return this; } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ public Builder setDiagnosticInfo(com.google.protobuf.Struct.Builder builderForValue) { if (diagnosticInfoBuilder_ == null) { diagnosticInfo_ = builderForValue.build(); onChanged(); } else { diagnosticInfoBuilder_.setMessage(builderForValue.build()); } return this; } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ public Builder mergeDiagnosticInfo(com.google.protobuf.Struct value) { if (diagnosticInfoBuilder_ == null) { if (diagnosticInfo_ != null) { diagnosticInfo_ = com.google.protobuf.Struct.newBuilder(diagnosticInfo_) .mergeFrom(value) .buildPartial(); } else { diagnosticInfo_ = value; } onChanged(); } else { diagnosticInfoBuilder_.mergeFrom(value); } return this; } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ public Builder clearDiagnosticInfo() { if (diagnosticInfoBuilder_ == null) { diagnosticInfo_ = null; onChanged(); } else { diagnosticInfo_ = null; diagnosticInfoBuilder_ = null; } return this; } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ public com.google.protobuf.Struct.Builder getDiagnosticInfoBuilder() { onChanged(); return getDiagnosticInfoFieldBuilder().getBuilder(); } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ public com.google.protobuf.StructOrBuilder getDiagnosticInfoOrBuilder() { if (diagnosticInfoBuilder_ != null) { return diagnosticInfoBuilder_.getMessageOrBuilder(); } else { return diagnosticInfo_ == null ? com.google.protobuf.Struct.getDefaultInstance() : diagnosticInfo_; } } /** * * *
     * The free-form diagnostic info. For example, this field could contain
     * webhook call latency. The string keys of the Struct's fields map can change
     * without notice.
     * 
* * .google.protobuf.Struct diagnostic_info = 10; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder> getDiagnosticInfoFieldBuilder() { if (diagnosticInfoBuilder_ == null) { diagnosticInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Struct, com.google.protobuf.Struct.Builder, com.google.protobuf.StructOrBuilder>( getDiagnosticInfo(), getParentForChildren(), isClean()); diagnosticInfo_ = null; } return diagnosticInfoBuilder_; } private com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentimentAnalysisResult_; private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult, com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.Builder, com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResultOrBuilder> sentimentAnalysisResultBuilder_; /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * * * @return Whether the sentimentAnalysisResult field is set. */ public boolean hasSentimentAnalysisResult() { return sentimentAnalysisResultBuilder_ != null || sentimentAnalysisResult_ != null; } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * * * @return The sentimentAnalysisResult. */ public com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult getSentimentAnalysisResult() { if (sentimentAnalysisResultBuilder_ == null) { return sentimentAnalysisResult_ == null ? com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.getDefaultInstance() : sentimentAnalysisResult_; } else { return sentimentAnalysisResultBuilder_.getMessage(); } } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ public Builder setSentimentAnalysisResult( com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult value) { if (sentimentAnalysisResultBuilder_ == null) { if (value == null) { throw new NullPointerException(); } sentimentAnalysisResult_ = value; onChanged(); } else { sentimentAnalysisResultBuilder_.setMessage(value); } return this; } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ public Builder setSentimentAnalysisResult( com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.Builder builderForValue) { if (sentimentAnalysisResultBuilder_ == null) { sentimentAnalysisResult_ = builderForValue.build(); onChanged(); } else { sentimentAnalysisResultBuilder_.setMessage(builderForValue.build()); } return this; } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ public Builder mergeSentimentAnalysisResult( com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult value) { if (sentimentAnalysisResultBuilder_ == null) { if (sentimentAnalysisResult_ != null) { sentimentAnalysisResult_ = com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.newBuilder( sentimentAnalysisResult_) .mergeFrom(value) .buildPartial(); } else { sentimentAnalysisResult_ = value; } onChanged(); } else { sentimentAnalysisResultBuilder_.mergeFrom(value); } return this; } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ public Builder clearSentimentAnalysisResult() { if (sentimentAnalysisResultBuilder_ == null) { sentimentAnalysisResult_ = null; onChanged(); } else { sentimentAnalysisResult_ = null; sentimentAnalysisResultBuilder_ = null; } return this; } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ public com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.Builder getSentimentAnalysisResultBuilder() { onChanged(); return getSentimentAnalysisResultFieldBuilder().getBuilder(); } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ public com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResultOrBuilder getSentimentAnalysisResultOrBuilder() { if (sentimentAnalysisResultBuilder_ != null) { return sentimentAnalysisResultBuilder_.getMessageOrBuilder(); } else { return sentimentAnalysisResult_ == null ? com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.getDefaultInstance() : sentimentAnalysisResult_; } } /** * * *
     * The sentiment analyss result, which depends on
     * [`analyze_query_text_sentiment`]
     * [google.cloud.dialogflow.cx.v3.QueryParameters.analyze_query_text_sentiment], specified in the request.
     * 
* * .google.cloud.dialogflow.cx.v3.SentimentAnalysisResult sentiment_analysis_result = 17; * */ private com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult, com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.Builder, com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResultOrBuilder> getSentimentAnalysisResultFieldBuilder() { if (sentimentAnalysisResultBuilder_ == null) { sentimentAnalysisResultBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult, com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResult.Builder, com.google.cloud.dialogflow.cx.v3.SentimentAnalysisResultOrBuilder>( getSentimentAnalysisResult(), getParentForChildren(), isClean()); sentimentAnalysisResult_ = null; } return sentimentAnalysisResultBuilder_; } @java.lang.Override public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.cloud.dialogflow.cx.v3.QueryResult) } // @@protoc_insertion_point(class_scope:google.cloud.dialogflow.cx.v3.QueryResult) private static final com.google.cloud.dialogflow.cx.v3.QueryResult DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.cloud.dialogflow.cx.v3.QueryResult(); } public static com.google.cloud.dialogflow.cx.v3.QueryResult getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public QueryResult parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new QueryResult(input, extensionRegistry); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public com.google.cloud.dialogflow.cx.v3.QueryResult getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy