<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: action.proto

namespace Rv\Data\Action\CommunicationType;

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

/**
 * Generated from protobuf message <code>rv.data.Action.CommunicationType.Command</code>
 */
class Command extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>string name = 1;</code>
     */
    protected $name = '';
    /**
     * Generated from protobuf field <code>string value = 2;</code>
     */
    protected $value = '';
    /**
     * Generated from protobuf field <code>.rv.data.IntRange replacement_range = 3;</code>
     */
    protected $replacement_range = null;
    /**
     * Generated from protobuf field <code>repeated string possible_values = 4;</code>
     */
    private $possible_values;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $name
     *     @type string $value
     *     @type \Rv\Data\IntRange $replacement_range
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $possible_values
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Action::initOnce();
        parent::__construct($data);
    }

    /**
     * Generated from protobuf field <code>string name = 1;</code>
     * @return string
     */
    public function getName()
    {
        return $this->name;
    }

    /**
     * Generated from protobuf field <code>string name = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>string value = 2;</code>
     * @return string
     */
    public function getValue()
    {
        return $this->value;
    }

    /**
     * Generated from protobuf field <code>string value = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setValue($var)
    {
        GPBUtil::checkString($var, True);
        $this->value = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>.rv.data.IntRange replacement_range = 3;</code>
     * @return \Rv\Data\IntRange|null
     */
    public function getReplacementRange()
    {
        return $this->replacement_range;
    }

    public function hasReplacementRange()
    {
        return isset($this->replacement_range);
    }

    public function clearReplacementRange()
    {
        unset($this->replacement_range);
    }

    /**
     * Generated from protobuf field <code>.rv.data.IntRange replacement_range = 3;</code>
     * @param \Rv\Data\IntRange $var
     * @return $this
     */
    public function setReplacementRange($var)
    {
        GPBUtil::checkMessage($var, \Rv\Data\IntRange::class);
        $this->replacement_range = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated string possible_values = 4;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getPossibleValues()
    {
        return $this->possible_values;
    }

    /**
     * Generated from protobuf field <code>repeated string possible_values = 4;</code>
     * @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setPossibleValues($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->possible_values = $arr;

        return $this;
    }

}

