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

namespace Keyapis\TelemetryControl\V1;

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

/**
 * Элемент справочника Регионы (РФ)
 *
 * Generated from protobuf message <code>keyapis.telemetry_control.v1.DictionaryRf</code>
 */
class DictionaryRf extends \Google\Protobuf\Internal\Message
{
    /**
     * Идентификатор
     *
     * Generated from protobuf field <code>int32 id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $id = 0;
    /**
     * Дата создания
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp created_at = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $created_at = null;
    /**
     * Дата последнего изменения.
     * Заполняется и обновляется сервером.
     * Заполняется при создании и изменении
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp changed_at = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $changed_at = null;
    /**
     * Локализованный заголовок элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue title = 4;</code>
     */
    protected $title = null;
    /**
     * Техническое наименование элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue code = 5;</code>
     */
    protected $code = null;
    /**
     * Принадлежность региона к Макрорегиону (МРФ)
     *
     * Generated from protobuf field <code>int32 mrf_id = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $mrf_id = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int $id
     *           Идентификатор
     *     @type \Google\Protobuf\Timestamp $created_at
     *           Дата создания
     *     @type \Google\Protobuf\Timestamp $changed_at
     *           Дата последнего изменения.
     *           Заполняется и обновляется сервером.
     *           Заполняется при создании и изменении
     *     @type \Google\Protobuf\StringValue $title
     *           Локализованный заголовок элемента
     *     @type \Google\Protobuf\StringValue $code
     *           Техническое наименование элемента
     *     @type int $mrf_id
     *           Принадлежность региона к Макрорегиону (МРФ)
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Keyapis\TelemetryControl\V1\KeyapisTelemetryControlDictionaryV1::initOnce();
        parent::__construct($data);
    }

    /**
     * Идентификатор
     *
     * Generated from protobuf field <code>int32 id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Идентификатор
     *
     * Generated from protobuf field <code>int32 id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int $var
     * @return $this
     */
    public function setId($var)
    {
        GPBUtil::checkInt32($var);
        $this->id = $var;

        return $this;
    }

    /**
     * Дата создания
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp created_at = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getCreatedAt()
    {
        return $this->created_at;
    }

    public function hasCreatedAt()
    {
        return isset($this->created_at);
    }

    public function clearCreatedAt()
    {
        unset($this->created_at);
    }

    /**
     * Дата создания
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp created_at = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setCreatedAt($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->created_at = $var;

        return $this;
    }

    /**
     * Дата последнего изменения.
     * Заполняется и обновляется сервером.
     * Заполняется при создании и изменении
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp changed_at = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return \Google\Protobuf\Timestamp|null
     */
    public function getChangedAt()
    {
        return $this->changed_at;
    }

    public function hasChangedAt()
    {
        return isset($this->changed_at);
    }

    public function clearChangedAt()
    {
        unset($this->changed_at);
    }

    /**
     * Дата последнего изменения.
     * Заполняется и обновляется сервером.
     * Заполняется при создании и изменении
     *
     * Generated from protobuf field <code>.google.protobuf.Timestamp changed_at = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param \Google\Protobuf\Timestamp $var
     * @return $this
     */
    public function setChangedAt($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class);
        $this->changed_at = $var;

        return $this;
    }

    /**
     * Локализованный заголовок элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue title = 4;</code>
     * @return \Google\Protobuf\StringValue|null
     */
    public function getTitle()
    {
        return $this->title;
    }

    public function hasTitle()
    {
        return isset($this->title);
    }

    public function clearTitle()
    {
        unset($this->title);
    }

    /**
     * Returns the unboxed value from <code>getTitle()</code>

     * Локализованный заголовок элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue title = 4;</code>
     * @return string|null
     */
    public function getTitleUnwrapped()
    {
        return $this->readWrapperValue("title");
    }

    /**
     * Локализованный заголовок элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue title = 4;</code>
     * @param \Google\Protobuf\StringValue $var
     * @return $this
     */
    public function setTitle($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class);
        $this->title = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object.

     * Локализованный заголовок элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue title = 4;</code>
     * @param string|null $var
     * @return $this
     */
    public function setTitleUnwrapped($var)
    {
        $this->writeWrapperValue("title", $var);
        return $this;}

    /**
     * Техническое наименование элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue code = 5;</code>
     * @return \Google\Protobuf\StringValue|null
     */
    public function getCode()
    {
        return $this->code;
    }

    public function hasCode()
    {
        return isset($this->code);
    }

    public function clearCode()
    {
        unset($this->code);
    }

    /**
     * Returns the unboxed value from <code>getCode()</code>

     * Техническое наименование элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue code = 5;</code>
     * @return string|null
     */
    public function getCodeUnwrapped()
    {
        return $this->readWrapperValue("code");
    }

    /**
     * Техническое наименование элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue code = 5;</code>
     * @param \Google\Protobuf\StringValue $var
     * @return $this
     */
    public function setCode($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class);
        $this->code = $var;

        return $this;
    }

    /**
     * Sets the field by wrapping a primitive type in a Google\Protobuf\StringValue object.

     * Техническое наименование элемента
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue code = 5;</code>
     * @param string|null $var
     * @return $this
     */
    public function setCodeUnwrapped($var)
    {
        $this->writeWrapperValue("code", $var);
        return $this;}

    /**
     * Принадлежность региона к Макрорегиону (МРФ)
     *
     * Generated from protobuf field <code>int32 mrf_id = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getMrfId()
    {
        return $this->mrf_id;
    }

    /**
     * Принадлежность региона к Макрорегиону (МРФ)
     *
     * Generated from protobuf field <code>int32 mrf_id = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setMrfId($var)
    {
        GPBUtil::checkInt32($var);
        $this->mrf_id = $var;

        return $this;
    }

}

