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

namespace Keyapis\Multiapp\V1;

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

/**
 * Облегчённое приложение
 *
 * Generated from protobuf message <code>keyapis.multiapp.v1.AppLite</code>
 */
class AppLite extends \Google\Protobuf\Internal\Message
{
    /**
     * Идентификатор.
     * # Тип: Guid
     *
     * Generated from protobuf field <code>string id = 1;</code>
     */
    protected $id = '';
    /**
     * Наименование.
     * Не отображается пользователям.
     * # Диапазон: 3..256
     *
     * Generated from protobuf field <code>string title = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $title = '';
    /**
     * Заголовок.
     * # Диапазон: 3..30
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue header = 3;</code>
     */
    protected $header = null;
    /**
     * Подзаголовок.
     * # Диапазон: 3..60
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue subtitle = 4;</code>
     */
    protected $subtitle = null;
    /**
     * Цвет заднего плана(подложки).
     * Все цвета должны быть в формате hex #RRGGBBAA.
     * Пример: #7e00c380.
     * # Диапазон: 9..9.
     * # Паттерн: /^#[0-9a-fA-F]{8}$/
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue background_color = 5;</code>
     */
    protected $background_color = null;
    /**
     * Статус приложения
     *
     * Generated from protobuf field <code>.keyapis.multiapp.v1.App.StatusType status_type = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $status_type = 0;
    /**
     * Ссылки для переходов
     *
     * Generated from protobuf field <code>repeated .keyapis.multiapp.v1.AppLite.LinkLite links = 7;</code>
     */
    private $links;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $id
     *           Идентификатор.
     *           # Тип: Guid
     *     @type string $title
     *           Наименование.
     *           Не отображается пользователям.
     *           # Диапазон: 3..256
     *     @type \Google\Protobuf\StringValue $header
     *           Заголовок.
     *           # Диапазон: 3..30
     *     @type \Google\Protobuf\StringValue $subtitle
     *           Подзаголовок.
     *           # Диапазон: 3..60
     *     @type \Google\Protobuf\StringValue $background_color
     *           Цвет заднего плана(подложки).
     *           Все цвета должны быть в формате hex #RRGGBBAA.
     *           Пример: #7e00c380.
     *           # Диапазон: 9..9.
     *           # Паттерн: /^#[0-9a-fA-F]{8}$/
     *     @type int $status_type
     *           Статус приложения
     *     @type array<\Keyapis\Multiapp\V1\AppLite\LinkLite>|\Google\Protobuf\Internal\RepeatedField $links
     *           Ссылки для переходов
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Keyapis\Multiapp\V1\KeyapisMultiappAppV1::initOnce();
        parent::__construct($data);
    }

    /**
     * Идентификатор.
     * # Тип: Guid
     *
     * Generated from protobuf field <code>string id = 1;</code>
     * @return string
     */
    public function getId()
    {
        return $this->id;
    }

    /**
     * Идентификатор.
     * # Тип: Guid
     *
     * Generated from protobuf field <code>string id = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setId($var)
    {
        GPBUtil::checkString($var, True);
        $this->id = $var;

        return $this;
    }

    /**
     * Наименование.
     * Не отображается пользователям.
     * # Диапазон: 3..256
     *
     * Generated from protobuf field <code>string title = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getTitle()
    {
        return $this->title;
    }

    /**
     * Наименование.
     * Не отображается пользователям.
     * # Диапазон: 3..256
     *
     * Generated from protobuf field <code>string title = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setTitle($var)
    {
        GPBUtil::checkString($var, True);
        $this->title = $var;

        return $this;
    }

    /**
     * Заголовок.
     * # Диапазон: 3..30
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue header = 3;</code>
     * @return \Google\Protobuf\StringValue|null
     */
    public function getHeader()
    {
        return $this->header;
    }

    public function hasHeader()
    {
        return isset($this->header);
    }

    public function clearHeader()
    {
        unset($this->header);
    }

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

     * Заголовок.
     * # Диапазон: 3..30
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue header = 3;</code>
     * @return string|null
     */
    public function getHeaderUnwrapped()
    {
        return $this->readWrapperValue("header");
    }

    /**
     * Заголовок.
     * # Диапазон: 3..30
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue header = 3;</code>
     * @param \Google\Protobuf\StringValue $var
     * @return $this
     */
    public function setHeader($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class);
        $this->header = $var;

        return $this;
    }

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

     * Заголовок.
     * # Диапазон: 3..30
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue header = 3;</code>
     * @param string|null $var
     * @return $this
     */
    public function setHeaderUnwrapped($var)
    {
        $this->writeWrapperValue("header", $var);
        return $this;}

    /**
     * Подзаголовок.
     * # Диапазон: 3..60
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue subtitle = 4;</code>
     * @return \Google\Protobuf\StringValue|null
     */
    public function getSubtitle()
    {
        return $this->subtitle;
    }

    public function hasSubtitle()
    {
        return isset($this->subtitle);
    }

    public function clearSubtitle()
    {
        unset($this->subtitle);
    }

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

     * Подзаголовок.
     * # Диапазон: 3..60
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue subtitle = 4;</code>
     * @return string|null
     */
    public function getSubtitleUnwrapped()
    {
        return $this->readWrapperValue("subtitle");
    }

    /**
     * Подзаголовок.
     * # Диапазон: 3..60
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue subtitle = 4;</code>
     * @param \Google\Protobuf\StringValue $var
     * @return $this
     */
    public function setSubtitle($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class);
        $this->subtitle = $var;

        return $this;
    }

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

     * Подзаголовок.
     * # Диапазон: 3..60
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue subtitle = 4;</code>
     * @param string|null $var
     * @return $this
     */
    public function setSubtitleUnwrapped($var)
    {
        $this->writeWrapperValue("subtitle", $var);
        return $this;}

    /**
     * Цвет заднего плана(подложки).
     * Все цвета должны быть в формате hex #RRGGBBAA.
     * Пример: #7e00c380.
     * # Диапазон: 9..9.
     * # Паттерн: /^#[0-9a-fA-F]{8}$/
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue background_color = 5;</code>
     * @return \Google\Protobuf\StringValue|null
     */
    public function getBackgroundColor()
    {
        return $this->background_color;
    }

    public function hasBackgroundColor()
    {
        return isset($this->background_color);
    }

    public function clearBackgroundColor()
    {
        unset($this->background_color);
    }

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

     * Цвет заднего плана(подложки).
     * Все цвета должны быть в формате hex #RRGGBBAA.
     * Пример: #7e00c380.
     * # Диапазон: 9..9.
     * # Паттерн: /^#[0-9a-fA-F]{8}$/
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue background_color = 5;</code>
     * @return string|null
     */
    public function getBackgroundColorUnwrapped()
    {
        return $this->readWrapperValue("background_color");
    }

    /**
     * Цвет заднего плана(подложки).
     * Все цвета должны быть в формате hex #RRGGBBAA.
     * Пример: #7e00c380.
     * # Диапазон: 9..9.
     * # Паттерн: /^#[0-9a-fA-F]{8}$/
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue background_color = 5;</code>
     * @param \Google\Protobuf\StringValue $var
     * @return $this
     */
    public function setBackgroundColor($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\StringValue::class);
        $this->background_color = $var;

        return $this;
    }

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

     * Цвет заднего плана(подложки).
     * Все цвета должны быть в формате hex #RRGGBBAA.
     * Пример: #7e00c380.
     * # Диапазон: 9..9.
     * # Паттерн: /^#[0-9a-fA-F]{8}$/
     *
     * Generated from protobuf field <code>.google.protobuf.StringValue background_color = 5;</code>
     * @param string|null $var
     * @return $this
     */
    public function setBackgroundColorUnwrapped($var)
    {
        $this->writeWrapperValue("background_color", $var);
        return $this;}

    /**
     * Статус приложения
     *
     * Generated from protobuf field <code>.keyapis.multiapp.v1.App.StatusType status_type = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getStatusType()
    {
        return $this->status_type;
    }

    /**
     * Статус приложения
     *
     * Generated from protobuf field <code>.keyapis.multiapp.v1.App.StatusType status_type = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setStatusType($var)
    {
        GPBUtil::checkEnum($var, \Keyapis\Multiapp\V1\App\StatusType::class);
        $this->status_type = $var;

        return $this;
    }

    /**
     * Ссылки для переходов
     *
     * Generated from protobuf field <code>repeated .keyapis.multiapp.v1.AppLite.LinkLite links = 7;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getLinks()
    {
        return $this->links;
    }

    /**
     * Ссылки для переходов
     *
     * Generated from protobuf field <code>repeated .keyapis.multiapp.v1.AppLite.LinkLite links = 7;</code>
     * @param array<\Keyapis\Multiapp\V1\AppLite\LinkLite>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setLinks($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Keyapis\Multiapp\V1\AppLite\LinkLite::class);
        $this->links = $arr;

        return $this;
    }

}

