Class SentimentAnalysisResult.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<SentimentAnalysisResult.Builder>
com.google.cloud.dialogflow.v2.SentimentAnalysisResult.Builder
All Implemented Interfaces:
SentimentAnalysisResultOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
SentimentAnalysisResult

public static final class SentimentAnalysisResult.Builder extends com.google.protobuf.GeneratedMessage.Builder<SentimentAnalysisResult.Builder> implements SentimentAnalysisResultOrBuilder
 The result of sentiment analysis. Sentiment analysis inspects user input
 and identifies the prevailing subjective opinion, especially to determine a
 user's attitude as positive, negative, or neutral.
 For [DetectIntent][], it needs to be configured in
 [DetectIntentRequest.query_params][google.cloud.dialogflow.v2.DetectIntentRequest.query_params].
 For [StreamingDetectIntent][], it needs to be configured in
 [StreamingDetectIntentRequest.query_params][google.cloud.dialogflow.v2.StreamingDetectIntentRequest.query_params].
 And for
 [Participants.AnalyzeContent][google.cloud.dialogflow.v2.Participants.AnalyzeContent]
 and
 [Participants.StreamingAnalyzeContent][google.cloud.dialogflow.v2.Participants.StreamingAnalyzeContent],
 it needs to be configured in
 [ConversationProfile.human_agent_assistant_config][google.cloud.dialogflow.v2.ConversationProfile.human_agent_assistant_config]
 
Protobuf type google.cloud.dialogflow.v2.SentimentAnalysisResult
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<SentimentAnalysisResult.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<SentimentAnalysisResult.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<SentimentAnalysisResult.Builder>
    • getDefaultInstanceForType

      public SentimentAnalysisResult getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public SentimentAnalysisResult build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public SentimentAnalysisResult buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public SentimentAnalysisResult.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<SentimentAnalysisResult.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<SentimentAnalysisResult.Builder>
    • mergeFrom

      public SentimentAnalysisResult.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<SentimentAnalysisResult.Builder>
      Throws:
      IOException
    • hasQueryTextSentiment

      public boolean hasQueryTextSentiment()
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
      Specified by:
      hasQueryTextSentiment in interface SentimentAnalysisResultOrBuilder
      Returns:
      Whether the queryTextSentiment field is set.
    • getQueryTextSentiment

      public Sentiment getQueryTextSentiment()
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
      Specified by:
      getQueryTextSentiment in interface SentimentAnalysisResultOrBuilder
      Returns:
      The queryTextSentiment.
    • setQueryTextSentiment

      public SentimentAnalysisResult.Builder setQueryTextSentiment(Sentiment value)
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
    • setQueryTextSentiment

      public SentimentAnalysisResult.Builder setQueryTextSentiment(Sentiment.Builder builderForValue)
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
    • mergeQueryTextSentiment

      public SentimentAnalysisResult.Builder mergeQueryTextSentiment(Sentiment value)
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
    • clearQueryTextSentiment

      public SentimentAnalysisResult.Builder clearQueryTextSentiment()
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
    • getQueryTextSentimentBuilder

      public Sentiment.Builder getQueryTextSentimentBuilder()
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
    • getQueryTextSentimentOrBuilder

      public SentimentOrBuilder getQueryTextSentimentOrBuilder()
       The sentiment analysis result for `query_text`.
       
      .google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;
      Specified by:
      getQueryTextSentimentOrBuilder in interface SentimentAnalysisResultOrBuilder