<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: keyapis/exchange/v1/keyapis_exchange_events_v1.proto

namespace Keyapis\Exchange\V1;

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

/**
 * Задача на отправку СМС.
 * Очередь key.exchange.sending_sms
 *
 * Generated from protobuf message <code>keyapis.exchange.v1.SendingSmsTask</code>
 */
class SendingSmsTask extends \Google\Protobuf\Internal\Message
{
    /**
     * Идентификатор запроса
     *
     * Generated from protobuf field <code>string request_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $request_id = '';
    /**
     * Тип шаблона
     *
     * Generated from protobuf field <code>string template_kind = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $template_kind = '';
    /**
     * Назначение
     *
     * Generated from protobuf field <code>string destination = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $destination = '';
    /**
     * Переменные шаблона
     *
     * Generated from protobuf field <code>repeated .keyapis.exchange.v1.SendingSmsTask.TemplateVariable template_variables = 4;</code>
     */
    private $template_variables;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $request_id
     *           Идентификатор запроса
     *     @type string $template_kind
     *           Тип шаблона
     *     @type string $destination
     *           Назначение
     *     @type array<\Keyapis\Exchange\V1\SendingSmsTask\TemplateVariable>|\Google\Protobuf\Internal\RepeatedField $template_variables
     *           Переменные шаблона
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Keyapis\Exchange\V1\KeyapisExchangeEventsV1::initOnce();
        parent::__construct($data);
    }

    /**
     * Идентификатор запроса
     *
     * Generated from protobuf field <code>string request_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getRequestId()
    {
        return $this->request_id;
    }

    /**
     * Идентификатор запроса
     *
     * Generated from protobuf field <code>string request_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setRequestId($var)
    {
        GPBUtil::checkString($var, True);
        $this->request_id = $var;

        return $this;
    }

    /**
     * Тип шаблона
     *
     * Generated from protobuf field <code>string template_kind = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getTemplateKind()
    {
        return $this->template_kind;
    }

    /**
     * Тип шаблона
     *
     * Generated from protobuf field <code>string template_kind = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setTemplateKind($var)
    {
        GPBUtil::checkString($var, True);
        $this->template_kind = $var;

        return $this;
    }

    /**
     * Назначение
     *
     * Generated from protobuf field <code>string destination = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getDestination()
    {
        return $this->destination;
    }

    /**
     * Назначение
     *
     * Generated from protobuf field <code>string destination = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setDestination($var)
    {
        GPBUtil::checkString($var, True);
        $this->destination = $var;

        return $this;
    }

    /**
     * Переменные шаблона
     *
     * Generated from protobuf field <code>repeated .keyapis.exchange.v1.SendingSmsTask.TemplateVariable template_variables = 4;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getTemplateVariables()
    {
        return $this->template_variables;
    }

    /**
     * Переменные шаблона
     *
     * Generated from protobuf field <code>repeated .keyapis.exchange.v1.SendingSmsTask.TemplateVariable template_variables = 4;</code>
     * @param array<\Keyapis\Exchange\V1\SendingSmsTask\TemplateVariable>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setTemplateVariables($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Keyapis\Exchange\V1\SendingSmsTask\TemplateVariable::class);
        $this->template_variables = $arr;

        return $this;
    }

}

