<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/contactcenterinsights/v1/resources.proto

namespace Google\Cloud\ContactCenterInsights\V1\QaScorecardResult;

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

/**
 * Tags and their corresponding results.
 *
 * Generated from protobuf message <code>google.cloud.contactcenterinsights.v1.QaScorecardResult.QaTagResult</code>
 */
class QaTagResult extends \Google\Protobuf\Internal\Message
{
    /**
     * The tag the score applies to.
     *
     * Generated from protobuf field <code>string tag = 1;</code>
     */
    protected $tag = '';
    /**
     * The score the tag applies to.
     *
     * Generated from protobuf field <code>optional double score = 2;</code>
     */
    protected $score = null;
    /**
     * The potential score the tag applies to.
     *
     * Generated from protobuf field <code>optional double potential_score = 3;</code>
     */
    protected $potential_score = null;
    /**
     * The normalized score the tag applies to.
     *
     * Generated from protobuf field <code>optional double normalized_score = 4;</code>
     */
    protected $normalized_score = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $tag
     *           The tag the score applies to.
     *     @type float $score
     *           The score the tag applies to.
     *     @type float $potential_score
     *           The potential score the tag applies to.
     *     @type float $normalized_score
     *           The normalized score the tag applies to.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Contactcenterinsights\V1\Resources::initOnce();
        parent::__construct($data);
    }

    /**
     * The tag the score applies to.
     *
     * Generated from protobuf field <code>string tag = 1;</code>
     * @return string
     */
    public function getTag()
    {
        return $this->tag;
    }

    /**
     * The tag the score applies to.
     *
     * Generated from protobuf field <code>string tag = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setTag($var)
    {
        GPBUtil::checkString($var, True);
        $this->tag = $var;

        return $this;
    }

    /**
     * The score the tag applies to.
     *
     * Generated from protobuf field <code>optional double score = 2;</code>
     * @return float
     */
    public function getScore()
    {
        return isset($this->score) ? $this->score : 0.0;
    }

    public function hasScore()
    {
        return isset($this->score);
    }

    public function clearScore()
    {
        unset($this->score);
    }

    /**
     * The score the tag applies to.
     *
     * Generated from protobuf field <code>optional double score = 2;</code>
     * @param float $var
     * @return $this
     */
    public function setScore($var)
    {
        GPBUtil::checkDouble($var);
        $this->score = $var;

        return $this;
    }

    /**
     * The potential score the tag applies to.
     *
     * Generated from protobuf field <code>optional double potential_score = 3;</code>
     * @return float
     */
    public function getPotentialScore()
    {
        return isset($this->potential_score) ? $this->potential_score : 0.0;
    }

    public function hasPotentialScore()
    {
        return isset($this->potential_score);
    }

    public function clearPotentialScore()
    {
        unset($this->potential_score);
    }

    /**
     * The potential score the tag applies to.
     *
     * Generated from protobuf field <code>optional double potential_score = 3;</code>
     * @param float $var
     * @return $this
     */
    public function setPotentialScore($var)
    {
        GPBUtil::checkDouble($var);
        $this->potential_score = $var;

        return $this;
    }

    /**
     * The normalized score the tag applies to.
     *
     * Generated from protobuf field <code>optional double normalized_score = 4;</code>
     * @return float
     */
    public function getNormalizedScore()
    {
        return isset($this->normalized_score) ? $this->normalized_score : 0.0;
    }

    public function hasNormalizedScore()
    {
        return isset($this->normalized_score);
    }

    public function clearNormalizedScore()
    {
        unset($this->normalized_score);
    }

    /**
     * The normalized score the tag applies to.
     *
     * Generated from protobuf field <code>optional double normalized_score = 4;</code>
     * @param float $var
     * @return $this
     */
    public function setNormalizedScore($var)
    {
        GPBUtil::checkDouble($var);
        $this->normalized_score = $var;

        return $this;
    }

}

