<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/dialogflow/v2/session.proto

namespace Google\Cloud\Dialogflow\V2;

use Google\Protobuf\Internal\GPBType;
use Google\Protobuf\Internal\RepeatedField;
use Google\Protobuf\Internal\GPBUtil;

/**
 * The result of sentiment analysis as configured by
 * `sentiment_analysis_request_config`.
 *
 * Generated from protobuf message <code>google.cloud.dialogflow.v2.SentimentAnalysisResult</code>
 */
class SentimentAnalysisResult extends \Google\Protobuf\Internal\Message
{
    /**
     * The sentiment analysis result for `query_text`.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;</code>
     */
    private $query_text_sentiment = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\Dialogflow\V2\Sentiment $query_text_sentiment
     *           The sentiment analysis result for `query_text`.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Dialogflow\V2\Session::initOnce();
        parent::__construct($data);
    }

    /**
     * The sentiment analysis result for `query_text`.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;</code>
     * @return \Google\Cloud\Dialogflow\V2\Sentiment
     */
    public function getQueryTextSentiment()
    {
        return $this->query_text_sentiment;
    }

    /**
     * The sentiment analysis result for `query_text`.
     *
     * Generated from protobuf field <code>.google.cloud.dialogflow.v2.Sentiment query_text_sentiment = 1;</code>
     * @param \Google\Cloud\Dialogflow\V2\Sentiment $var
     * @return $this
     */
    public function setQueryTextSentiment($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\Dialogflow\V2\Sentiment::class);
        $this->query_text_sentiment = $var;

        return $this;
    }

}

