<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: device.proto

namespace OS\PB;

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

/**
 ** 
 * \@brief   DeviceMQTTAddress is used for changing the MQTT credentials to the server.
 * \@version from 0.9
 * \@details When the MQTT Config is changed, it will attempt to connect with the server using that username and password. 
 *
 * Generated from protobuf message <code>OS.PB.DeviceMQTTAddress</code>
 */
class DeviceMQTTAddress extends \Google\Protobuf\Internal\Message
{
    /**
     * default is mqtt.1s.co.za:1883
     *
     * Generated from protobuf field <code>string BrokerURL = 1;</code>
     */
    protected $BrokerURL = '';
    /**
     * username on server. If ExcludeVHost is false, then prefixes "/:" or "dev:", if true, then not included
     *
     * Generated from protobuf field <code>string Username = 2;</code>
     */
    protected $Username = '';
    /**
     * password on server
     *
     * Generated from protobuf field <code>string Password = 3;</code>
     */
    protected $Password = '';
    /**
     * refer to enums above   
     *
     * Generated from protobuf field <code>bool ExcludeVHost = 4;</code>
     */
    protected $ExcludeVHost = false;
    /**
     * (Optional) With OneAccess platform, the endpoint is "gw", in OneHealth the endpoint is "link"
     *
     * Generated from protobuf field <code>string EndPoint = 5;</code>
     */
    protected $EndPoint = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $BrokerURL
     *           default is mqtt.1s.co.za:1883
     *     @type string $Username
     *           username on server. If ExcludeVHost is false, then prefixes "/:" or "dev:", if true, then not included
     *     @type string $Password
     *           password on server
     *     @type bool $ExcludeVHost
     *           refer to enums above   
     *     @type string $EndPoint
     *           (Optional) With OneAccess platform, the endpoint is "gw", in OneHealth the endpoint is "link"
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Device::initOnce();
        parent::__construct($data);
    }

    /**
     * default is mqtt.1s.co.za:1883
     *
     * Generated from protobuf field <code>string BrokerURL = 1;</code>
     * @return string
     */
    public function getBrokerURL()
    {
        return $this->BrokerURL;
    }

    /**
     * default is mqtt.1s.co.za:1883
     *
     * Generated from protobuf field <code>string BrokerURL = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setBrokerURL($var)
    {
        GPBUtil::checkString($var, True);
        $this->BrokerURL = $var;

        return $this;
    }

    /**
     * username on server. If ExcludeVHost is false, then prefixes "/:" or "dev:", if true, then not included
     *
     * Generated from protobuf field <code>string Username = 2;</code>
     * @return string
     */
    public function getUsername()
    {
        return $this->Username;
    }

    /**
     * username on server. If ExcludeVHost is false, then prefixes "/:" or "dev:", if true, then not included
     *
     * Generated from protobuf field <code>string Username = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setUsername($var)
    {
        GPBUtil::checkString($var, True);
        $this->Username = $var;

        return $this;
    }

    /**
     * password on server
     *
     * Generated from protobuf field <code>string Password = 3;</code>
     * @return string
     */
    public function getPassword()
    {
        return $this->Password;
    }

    /**
     * password on server
     *
     * Generated from protobuf field <code>string Password = 3;</code>
     * @param string $var
     * @return $this
     */
    public function setPassword($var)
    {
        GPBUtil::checkString($var, True);
        $this->Password = $var;

        return $this;
    }

    /**
     * refer to enums above   
     *
     * Generated from protobuf field <code>bool ExcludeVHost = 4;</code>
     * @return bool
     */
    public function getExcludeVHost()
    {
        return $this->ExcludeVHost;
    }

    /**
     * refer to enums above   
     *
     * Generated from protobuf field <code>bool ExcludeVHost = 4;</code>
     * @param bool $var
     * @return $this
     */
    public function setExcludeVHost($var)
    {
        GPBUtil::checkBool($var);
        $this->ExcludeVHost = $var;

        return $this;
    }

    /**
     * (Optional) With OneAccess platform, the endpoint is "gw", in OneHealth the endpoint is "link"
     *
     * Generated from protobuf field <code>string EndPoint = 5;</code>
     * @return string
     */
    public function getEndPoint()
    {
        return $this->EndPoint;
    }

    /**
     * (Optional) With OneAccess platform, the endpoint is "gw", in OneHealth the endpoint is "link"
     *
     * Generated from protobuf field <code>string EndPoint = 5;</code>
     * @param string $var
     * @return $this
     */
    public function setEndPoint($var)
    {
        GPBUtil::checkString($var, True);
        $this->EndPoint = $var;

        return $this;
    }

}

