<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: deviceapis/device/v1/deviceapis_device_encryption_profile_v1.proto

namespace Deviceapis\Device\V1;

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

/**
 * Профиль шифрования
 *
 * Generated from protobuf message <code>deviceapis.device.v1.EncryptionProfile</code>
 */
class EncryptionProfile extends \Google\Protobuf\Internal\Message
{
    /**
     * Идентификатор.
     * Тип: Guid
     *
     * Generated from protobuf field <code>string id = 1;</code>
     */
    protected $id = '';
    /**
     * Наименование
     *
     * Generated from protobuf field <code>string title = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $title = '';
    /**
     * Тип
     *
     * Generated from protobuf field <code>.deviceapis.device.v1.EncryptionProfile.Type type = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $type = 0;
    /**
     * Номер сектора
     *
     * Generated from protobuf field <code>int32 sector_number = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $sector_number = 0;
    /**
     * Номер блока
     *
     * Generated from protobuf field <code>int32 block_number = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $block_number = 0;
    /**
     * Первый байт в блоке
     *
     * Generated from protobuf field <code>int32 start_index = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $start_index = 0;
    /**
     * Последний байт в блоке
     *
     * Generated from protobuf field <code>int32 end_index = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $end_index = 0;
    /**
     * Пароль.
     * Не возвращается с сервера.
     * TODO: в генерации сваггера не показывать INPUT_ONLY поля в ответах
     *
     * Generated from protobuf field <code>string password = 8 [(.google.api.field_behavior) = INPUT_ONLY];</code>
     */
    protected $password = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $id
     *           Идентификатор.
     *           Тип: Guid
     *     @type string $title
     *           Наименование
     *     @type int $type
     *           Тип
     *     @type int $sector_number
     *           Номер сектора
     *     @type int $block_number
     *           Номер блока
     *     @type int $start_index
     *           Первый байт в блоке
     *     @type int $end_index
     *           Последний байт в блоке
     *     @type string $password
     *           Пароль.
     *           Не возвращается с сервера.
     *           TODO: в генерации сваггера не показывать INPUT_ONLY поля в ответах
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Deviceapis\Device\V1\DeviceapisDeviceEncryptionProfileV1::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;
    }

    /**
     * Наименование
     *
     * Generated from protobuf field <code>string title = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getTitle()
    {
        return $this->title;
    }

    /**
     * Наименование
     *
     * 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;
    }

    /**
     * Тип
     *
     * Generated from protobuf field <code>.deviceapis.device.v1.EncryptionProfile.Type type = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getType()
    {
        return $this->type;
    }

    /**
     * Тип
     *
     * Generated from protobuf field <code>.deviceapis.device.v1.EncryptionProfile.Type type = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setType($var)
    {
        GPBUtil::checkEnum($var, \Deviceapis\Device\V1\EncryptionProfile\Type::class);
        $this->type = $var;

        return $this;
    }

    /**
     * Номер сектора
     *
     * Generated from protobuf field <code>int32 sector_number = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getSectorNumber()
    {
        return $this->sector_number;
    }

    /**
     * Номер сектора
     *
     * Generated from protobuf field <code>int32 sector_number = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setSectorNumber($var)
    {
        GPBUtil::checkInt32($var);
        $this->sector_number = $var;

        return $this;
    }

    /**
     * Номер блока
     *
     * Generated from protobuf field <code>int32 block_number = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getBlockNumber()
    {
        return $this->block_number;
    }

    /**
     * Номер блока
     *
     * Generated from protobuf field <code>int32 block_number = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setBlockNumber($var)
    {
        GPBUtil::checkInt32($var);
        $this->block_number = $var;

        return $this;
    }

    /**
     * Первый байт в блоке
     *
     * Generated from protobuf field <code>int32 start_index = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getStartIndex()
    {
        return $this->start_index;
    }

    /**
     * Первый байт в блоке
     *
     * Generated from protobuf field <code>int32 start_index = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setStartIndex($var)
    {
        GPBUtil::checkInt32($var);
        $this->start_index = $var;

        return $this;
    }

    /**
     * Последний байт в блоке
     *
     * Generated from protobuf field <code>int32 end_index = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getEndIndex()
    {
        return $this->end_index;
    }

    /**
     * Последний байт в блоке
     *
     * Generated from protobuf field <code>int32 end_index = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setEndIndex($var)
    {
        GPBUtil::checkInt32($var);
        $this->end_index = $var;

        return $this;
    }

    /**
     * Пароль.
     * Не возвращается с сервера.
     * TODO: в генерации сваггера не показывать INPUT_ONLY поля в ответах
     *
     * Generated from protobuf field <code>string password = 8 [(.google.api.field_behavior) = INPUT_ONLY];</code>
     * @return string
     */
    public function getPassword()
    {
        return $this->password;
    }

    /**
     * Пароль.
     * Не возвращается с сервера.
     * TODO: в генерации сваггера не показывать INPUT_ONLY поля в ответах
     *
     * Generated from protobuf field <code>string password = 8 [(.google.api.field_behavior) = INPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setPassword($var)
    {
        GPBUtil::checkString($var, True);
        $this->password = $var;

        return $this;
    }

}

