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

namespace Keyapis\Preset\V1;

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

/**
 * Задача на конфигурирование устройства.
 * Очередь key.preset.configuration
 *
 * Generated from protobuf message <code>keyapis.preset.v1.PresetConfigurationTask</code>
 */
class PresetConfigurationTask 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>.keyapis.preset.v1.Preset preset = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $preset = null;
    /**
     * Идентификатор устройства
     *
     * Generated from protobuf field <code>int32 device_id = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $device_id = 0;
    /**
     * Модель
     *
     * Generated from protobuf field <code>string model = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $model = '';
    /**
     * Адрес устройства
     *
     * Generated from protobuf field <code>string host = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $host = '';
    /**
     * Имя пользователя устройства
     *
     * Generated from protobuf field <code>string username = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $username = '';
    /**
     * Пароль пользователья устройства
     *
     * Generated from protobuf field <code>string password = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $password = '';
    /**
     * Таймзона NTP
     *
     * Generated from protobuf field <code>string ntp_timezone = 8 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $ntp_timezone = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $request_id
     *           Идентификатор запроса
     *     @type \Keyapis\Preset\V1\Preset $preset
     *           Пресет
     *     @type int $device_id
     *           Идентификатор устройства
     *     @type string $model
     *           Модель
     *     @type string $host
     *           Адрес устройства
     *     @type string $username
     *           Имя пользователя устройства
     *     @type string $password
     *           Пароль пользователья устройства
     *     @type string $ntp_timezone
     *           Таймзона NTP
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Keyapis\Preset\V1\KeyapisPresetEventsV1::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>.keyapis.preset.v1.Preset preset = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Keyapis\Preset\V1\Preset|null
     */
    public function getPreset()
    {
        return $this->preset;
    }

    public function hasPreset()
    {
        return isset($this->preset);
    }

    public function clearPreset()
    {
        unset($this->preset);
    }

    /**
     * Пресет
     *
     * Generated from protobuf field <code>.keyapis.preset.v1.Preset preset = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Keyapis\Preset\V1\Preset $var
     * @return $this
     */
    public function setPreset($var)
    {
        GPBUtil::checkMessage($var, \Keyapis\Preset\V1\Preset::class);
        $this->preset = $var;

        return $this;
    }

    /**
     * Идентификатор устройства
     *
     * Generated from protobuf field <code>int32 device_id = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return int
     */
    public function getDeviceId()
    {
        return $this->device_id;
    }

    /**
     * Идентификатор устройства
     *
     * Generated from protobuf field <code>int32 device_id = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param int $var
     * @return $this
     */
    public function setDeviceId($var)
    {
        GPBUtil::checkInt32($var);
        $this->device_id = $var;

        return $this;
    }

    /**
     * Модель
     *
     * Generated from protobuf field <code>string model = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getModel()
    {
        return $this->model;
    }

    /**
     * Модель
     *
     * Generated from protobuf field <code>string model = 4 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setModel($var)
    {
        GPBUtil::checkString($var, True);
        $this->model = $var;

        return $this;
    }

    /**
     * Адрес устройства
     *
     * Generated from protobuf field <code>string host = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getHost()
    {
        return $this->host;
    }

    /**
     * Адрес устройства
     *
     * Generated from protobuf field <code>string host = 5 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setHost($var)
    {
        GPBUtil::checkString($var, True);
        $this->host = $var;

        return $this;
    }

    /**
     * Имя пользователя устройства
     *
     * Generated from protobuf field <code>string username = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getUsername()
    {
        return $this->username;
    }

    /**
     * Имя пользователя устройства
     *
     * Generated from protobuf field <code>string username = 6 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setUsername($var)
    {
        GPBUtil::checkString($var, True);
        $this->username = $var;

        return $this;
    }

    /**
     * Пароль пользователья устройства
     *
     * Generated from protobuf field <code>string password = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getPassword()
    {
        return $this->password;
    }

    /**
     * Пароль пользователья устройства
     *
     * Generated from protobuf field <code>string password = 7 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setPassword($var)
    {
        GPBUtil::checkString($var, True);
        $this->password = $var;

        return $this;
    }

    /**
     * Таймзона NTP
     *
     * Generated from protobuf field <code>string ntp_timezone = 8 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getNtpTimezone()
    {
        return $this->ntp_timezone;
    }

    /**
     * Таймзона NTP
     *
     * Generated from protobuf field <code>string ntp_timezone = 8 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setNtpTimezone($var)
    {
        GPBUtil::checkString($var, True);
        $this->ntp_timezone = $var;

        return $this;
    }

}

