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

namespace OS\PB;

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

/**
 **
 * \@brief   A config is when data or settings needs to be added, updated or deleted
 * \@details When a device receives a config, persistent memory is updated with the change.
 *          It is possible the device also doesn't permit certain values pertaining to its logic, therefore a ConfigRejectedEvent message might be generated.
 *
 * Generated from protobuf message <code>OS.PB.ConfigMessage</code>
 */
class ConfigMessage extends \Google\Protobuf\Internal\Message
{
    /**
     * Which interface to update. By default 0 is for first interface or main interfaces. Only used for oneof interface configs.
     *
     * Generated from protobuf field <code>uint32 InterfaceIndex = 1;</code>
     */
    protected $InterfaceIndex = 0;
    protected $ConfigType;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int $InterfaceIndex
     *           Which interface to update. By default 0 is for first interface or main interfaces. Only used for oneof interface configs.
     *     @type \OS\PB\AccessMethodConfig $AccessMethodUpdate
     *           0.9 Update or create an AccessMethod in the database.
     *     @type \OS\PB\AccessMethodConfig $AccessMethodDelete
     *           0.9 Delete an AccessMethod from the database.
     *     @type \OS\PB\AccessUserConfig $AccessUserUpdate
     *           0.9 Update or create an AccessUser in the database.
     *     @type \OS\PB\AccessUserConfig $AccessUserDelete
     *           0.9 Delete an AccessUser from the database.
     *     @type \OS\PB\AccessRightsConfig $AccessRightsUpdate
     *           0.9 Update or create an AccessRights in the database.
     *     @type \OS\PB\AccessRightsConfig $AccessRightsDelete
     *           0.9 Delete an AccessRights from the database.
     *     @type \OS\PB\AccessConfig $AccessGateway
     *           Configures the access gateway device
     *     @type \OS\PB\HealthLinkConfig $HealthLink
     *           Configures the health link device
     *     @type \OS\PB\HealthButtonConfig $HealthButtonUpdate
     *           Add/Update a OneHealth Button on the Buttons table
     *     @type \OS\PB\HealthButtonConfig $HealthButtonDelete
     *           Delete a OneHealth Button from the Buttons table
     *     @type \OS\PB\RelayConfig $Relay
     *           Configure the Relay interface
     *     @type \OS\PB\WiegandConfig $Wiegand
     *           1.4 Configure the Wiegand Reader 
     *     @type \OS\PB\InputConfig $Input
     *           1.4 Configure the Input interface
     *     @type \OS\PB\CodeHopConfig $CodeHop
     *           1.4 Configure the CodeHop interface
     *     @type \OS\PB\RS485Config $RS485
     *           ExpansionConfig          Expansion               = 150;  // Configure the expansion interface
     *     @type \OS\PB\BLEConfig $BLE
     *           0.9 Configure the BLE interface
     *     @type \OS\PB\BLEConfig $BLELongRange
     *           1.4 Configure the BLE Long Range interface
     *     @type \OS\PB\ModemConfig $Modem
     *           0.9 Configure the Modem interface
     *     @type \OS\PB\EthernetConfig $Ethernet
     *           0.9 Configure the Ethernet interface
     *     @type \OS\PB\DeviceConfig $DeviceParameters
     *           0.9 Configure the Device either in Production or Developer mode
     *     @type \OS\PB\DeviceRoutingConfig $DeviceRouteUpdate
     *           0.9 Update or create a network route for an id
     *     @type \OS\PB\DeviceRoutingConfig $DeviceRouteDelete
     *           1.4 Delete a network route from the device
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Config::initOnce();
        parent::__construct($data);
    }

    /**
     * Which interface to update. By default 0 is for first interface or main interfaces. Only used for oneof interface configs.
     *
     * Generated from protobuf field <code>uint32 InterfaceIndex = 1;</code>
     * @return int
     */
    public function getInterfaceIndex()
    {
        return $this->InterfaceIndex;
    }

    /**
     * Which interface to update. By default 0 is for first interface or main interfaces. Only used for oneof interface configs.
     *
     * Generated from protobuf field <code>uint32 InterfaceIndex = 1;</code>
     * @param int $var
     * @return $this
     */
    public function setInterfaceIndex($var)
    {
        GPBUtil::checkUint32($var);
        $this->InterfaceIndex = $var;

        return $this;
    }

    /**
     * 0.9 Update or create an AccessMethod in the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessMethodConfig AccessMethodUpdate = 5;</code>
     * @return \OS\PB\AccessMethodConfig|null
     */
    public function getAccessMethodUpdate()
    {
        return $this->readOneof(5);
    }

    public function hasAccessMethodUpdate()
    {
        return $this->hasOneof(5);
    }

    /**
     * 0.9 Update or create an AccessMethod in the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessMethodConfig AccessMethodUpdate = 5;</code>
     * @param \OS\PB\AccessMethodConfig $var
     * @return $this
     */
    public function setAccessMethodUpdate($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessMethodConfig::class);
        $this->writeOneof(5, $var);

        return $this;
    }

    /**
     * 0.9 Delete an AccessMethod from the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessMethodConfig AccessMethodDelete = 6;</code>
     * @return \OS\PB\AccessMethodConfig|null
     */
    public function getAccessMethodDelete()
    {
        return $this->readOneof(6);
    }

    public function hasAccessMethodDelete()
    {
        return $this->hasOneof(6);
    }

    /**
     * 0.9 Delete an AccessMethod from the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessMethodConfig AccessMethodDelete = 6;</code>
     * @param \OS\PB\AccessMethodConfig $var
     * @return $this
     */
    public function setAccessMethodDelete($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessMethodConfig::class);
        $this->writeOneof(6, $var);

        return $this;
    }

    /**
     * 0.9 Update or create an AccessUser in the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessUserConfig AccessUserUpdate = 7;</code>
     * @return \OS\PB\AccessUserConfig|null
     */
    public function getAccessUserUpdate()
    {
        return $this->readOneof(7);
    }

    public function hasAccessUserUpdate()
    {
        return $this->hasOneof(7);
    }

    /**
     * 0.9 Update or create an AccessUser in the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessUserConfig AccessUserUpdate = 7;</code>
     * @param \OS\PB\AccessUserConfig $var
     * @return $this
     */
    public function setAccessUserUpdate($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessUserConfig::class);
        $this->writeOneof(7, $var);

        return $this;
    }

    /**
     * 0.9 Delete an AccessUser from the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessUserConfig AccessUserDelete = 8;</code>
     * @return \OS\PB\AccessUserConfig|null
     */
    public function getAccessUserDelete()
    {
        return $this->readOneof(8);
    }

    public function hasAccessUserDelete()
    {
        return $this->hasOneof(8);
    }

    /**
     * 0.9 Delete an AccessUser from the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessUserConfig AccessUserDelete = 8;</code>
     * @param \OS\PB\AccessUserConfig $var
     * @return $this
     */
    public function setAccessUserDelete($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessUserConfig::class);
        $this->writeOneof(8, $var);

        return $this;
    }

    /**
     * 0.9 Update or create an AccessRights in the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessRightsConfig AccessRightsUpdate = 9;</code>
     * @return \OS\PB\AccessRightsConfig|null
     */
    public function getAccessRightsUpdate()
    {
        return $this->readOneof(9);
    }

    public function hasAccessRightsUpdate()
    {
        return $this->hasOneof(9);
    }

    /**
     * 0.9 Update or create an AccessRights in the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessRightsConfig AccessRightsUpdate = 9;</code>
     * @param \OS\PB\AccessRightsConfig $var
     * @return $this
     */
    public function setAccessRightsUpdate($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessRightsConfig::class);
        $this->writeOneof(9, $var);

        return $this;
    }

    /**
     * 0.9 Delete an AccessRights from the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessRightsConfig AccessRightsDelete = 10;</code>
     * @return \OS\PB\AccessRightsConfig|null
     */
    public function getAccessRightsDelete()
    {
        return $this->readOneof(10);
    }

    public function hasAccessRightsDelete()
    {
        return $this->hasOneof(10);
    }

    /**
     * 0.9 Delete an AccessRights from the database.
     *
     * Generated from protobuf field <code>.OS.PB.AccessRightsConfig AccessRightsDelete = 10;</code>
     * @param \OS\PB\AccessRightsConfig $var
     * @return $this
     */
    public function setAccessRightsDelete($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessRightsConfig::class);
        $this->writeOneof(10, $var);

        return $this;
    }

    /**
     * Configures the access gateway device
     *
     * Generated from protobuf field <code>.OS.PB.AccessConfig AccessGateway = 20;</code>
     * @return \OS\PB\AccessConfig|null
     */
    public function getAccessGateway()
    {
        return $this->readOneof(20);
    }

    public function hasAccessGateway()
    {
        return $this->hasOneof(20);
    }

    /**
     * Configures the access gateway device
     *
     * Generated from protobuf field <code>.OS.PB.AccessConfig AccessGateway = 20;</code>
     * @param \OS\PB\AccessConfig $var
     * @return $this
     */
    public function setAccessGateway($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\AccessConfig::class);
        $this->writeOneof(20, $var);

        return $this;
    }

    /**
     * Configures the health link device
     *
     * Generated from protobuf field <code>.OS.PB.HealthLinkConfig HealthLink = 40;</code>
     * @return \OS\PB\HealthLinkConfig|null
     */
    public function getHealthLink()
    {
        return $this->readOneof(40);
    }

    public function hasHealthLink()
    {
        return $this->hasOneof(40);
    }

    /**
     * Configures the health link device
     *
     * Generated from protobuf field <code>.OS.PB.HealthLinkConfig HealthLink = 40;</code>
     * @param \OS\PB\HealthLinkConfig $var
     * @return $this
     */
    public function setHealthLink($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\HealthLinkConfig::class);
        $this->writeOneof(40, $var);

        return $this;
    }

    /**
     * Add/Update a OneHealth Button on the Buttons table
     *
     * Generated from protobuf field <code>.OS.PB.HealthButtonConfig HealthButtonUpdate = 50;</code>
     * @return \OS\PB\HealthButtonConfig|null
     */
    public function getHealthButtonUpdate()
    {
        return $this->readOneof(50);
    }

    public function hasHealthButtonUpdate()
    {
        return $this->hasOneof(50);
    }

    /**
     * Add/Update a OneHealth Button on the Buttons table
     *
     * Generated from protobuf field <code>.OS.PB.HealthButtonConfig HealthButtonUpdate = 50;</code>
     * @param \OS\PB\HealthButtonConfig $var
     * @return $this
     */
    public function setHealthButtonUpdate($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\HealthButtonConfig::class);
        $this->writeOneof(50, $var);

        return $this;
    }

    /**
     * Delete a OneHealth Button from the Buttons table
     *
     * Generated from protobuf field <code>.OS.PB.HealthButtonConfig HealthButtonDelete = 51;</code>
     * @return \OS\PB\HealthButtonConfig|null
     */
    public function getHealthButtonDelete()
    {
        return $this->readOneof(51);
    }

    public function hasHealthButtonDelete()
    {
        return $this->hasOneof(51);
    }

    /**
     * Delete a OneHealth Button from the Buttons table
     *
     * Generated from protobuf field <code>.OS.PB.HealthButtonConfig HealthButtonDelete = 51;</code>
     * @param \OS\PB\HealthButtonConfig $var
     * @return $this
     */
    public function setHealthButtonDelete($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\HealthButtonConfig::class);
        $this->writeOneof(51, $var);

        return $this;
    }

    /**
     * Configure the Relay interface
     *
     * Generated from protobuf field <code>.OS.PB.RelayConfig Relay = 110;</code>
     * @return \OS\PB\RelayConfig|null
     */
    public function getRelay()
    {
        return $this->readOneof(110);
    }

    public function hasRelay()
    {
        return $this->hasOneof(110);
    }

    /**
     * Configure the Relay interface
     *
     * Generated from protobuf field <code>.OS.PB.RelayConfig Relay = 110;</code>
     * @param \OS\PB\RelayConfig $var
     * @return $this
     */
    public function setRelay($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\RelayConfig::class);
        $this->writeOneof(110, $var);

        return $this;
    }

    /**
     * 1.4 Configure the Wiegand Reader 
     *
     * Generated from protobuf field <code>.OS.PB.WiegandConfig Wiegand = 120;</code>
     * @return \OS\PB\WiegandConfig|null
     */
    public function getWiegand()
    {
        return $this->readOneof(120);
    }

    public function hasWiegand()
    {
        return $this->hasOneof(120);
    }

    /**
     * 1.4 Configure the Wiegand Reader 
     *
     * Generated from protobuf field <code>.OS.PB.WiegandConfig Wiegand = 120;</code>
     * @param \OS\PB\WiegandConfig $var
     * @return $this
     */
    public function setWiegand($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\WiegandConfig::class);
        $this->writeOneof(120, $var);

        return $this;
    }

    /**
     * 1.4 Configure the Input interface
     *
     * Generated from protobuf field <code>.OS.PB.InputConfig Input = 130;</code>
     * @return \OS\PB\InputConfig|null
     */
    public function getInput()
    {
        return $this->readOneof(130);
    }

    public function hasInput()
    {
        return $this->hasOneof(130);
    }

    /**
     * 1.4 Configure the Input interface
     *
     * Generated from protobuf field <code>.OS.PB.InputConfig Input = 130;</code>
     * @param \OS\PB\InputConfig $var
     * @return $this
     */
    public function setInput($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\InputConfig::class);
        $this->writeOneof(130, $var);

        return $this;
    }

    /**
     * 1.4 Configure the CodeHop interface
     *
     * Generated from protobuf field <code>.OS.PB.CodeHopConfig CodeHop = 140;</code>
     * @return \OS\PB\CodeHopConfig|null
     */
    public function getCodeHop()
    {
        return $this->readOneof(140);
    }

    public function hasCodeHop()
    {
        return $this->hasOneof(140);
    }

    /**
     * 1.4 Configure the CodeHop interface
     *
     * Generated from protobuf field <code>.OS.PB.CodeHopConfig CodeHop = 140;</code>
     * @param \OS\PB\CodeHopConfig $var
     * @return $this
     */
    public function setCodeHop($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\CodeHopConfig::class);
        $this->writeOneof(140, $var);

        return $this;
    }

    /**
     * ExpansionConfig          Expansion               = 150;  // Configure the expansion interface
     *
     * Generated from protobuf field <code>.OS.PB.RS485Config RS485 = 180;</code>
     * @return \OS\PB\RS485Config|null
     */
    public function getRS485()
    {
        return $this->readOneof(180);
    }

    public function hasRS485()
    {
        return $this->hasOneof(180);
    }

    /**
     * ExpansionConfig          Expansion               = 150;  // Configure the expansion interface
     *
     * Generated from protobuf field <code>.OS.PB.RS485Config RS485 = 180;</code>
     * @param \OS\PB\RS485Config $var
     * @return $this
     */
    public function setRS485($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\RS485Config::class);
        $this->writeOneof(180, $var);

        return $this;
    }

    /**
     * 0.9 Configure the BLE interface
     *
     * Generated from protobuf field <code>.OS.PB.BLEConfig BLE = 190;</code>
     * @return \OS\PB\BLEConfig|null
     */
    public function getBLE()
    {
        return $this->readOneof(190);
    }

    public function hasBLE()
    {
        return $this->hasOneof(190);
    }

    /**
     * 0.9 Configure the BLE interface
     *
     * Generated from protobuf field <code>.OS.PB.BLEConfig BLE = 190;</code>
     * @param \OS\PB\BLEConfig $var
     * @return $this
     */
    public function setBLE($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\BLEConfig::class);
        $this->writeOneof(190, $var);

        return $this;
    }

    /**
     * 1.4 Configure the BLE Long Range interface
     *
     * Generated from protobuf field <code>.OS.PB.BLEConfig BLELongRange = 200;</code>
     * @return \OS\PB\BLEConfig|null
     */
    public function getBLELongRange()
    {
        return $this->readOneof(200);
    }

    public function hasBLELongRange()
    {
        return $this->hasOneof(200);
    }

    /**
     * 1.4 Configure the BLE Long Range interface
     *
     * Generated from protobuf field <code>.OS.PB.BLEConfig BLELongRange = 200;</code>
     * @param \OS\PB\BLEConfig $var
     * @return $this
     */
    public function setBLELongRange($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\BLEConfig::class);
        $this->writeOneof(200, $var);

        return $this;
    }

    /**
     * 0.9 Configure the Modem interface
     *
     * Generated from protobuf field <code>.OS.PB.ModemConfig Modem = 210;</code>
     * @return \OS\PB\ModemConfig|null
     */
    public function getModem()
    {
        return $this->readOneof(210);
    }

    public function hasModem()
    {
        return $this->hasOneof(210);
    }

    /**
     * 0.9 Configure the Modem interface
     *
     * Generated from protobuf field <code>.OS.PB.ModemConfig Modem = 210;</code>
     * @param \OS\PB\ModemConfig $var
     * @return $this
     */
    public function setModem($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\ModemConfig::class);
        $this->writeOneof(210, $var);

        return $this;
    }

    /**
     * 0.9 Configure the Ethernet interface
     *
     * Generated from protobuf field <code>.OS.PB.EthernetConfig Ethernet = 220;</code>
     * @return \OS\PB\EthernetConfig|null
     */
    public function getEthernet()
    {
        return $this->readOneof(220);
    }

    public function hasEthernet()
    {
        return $this->hasOneof(220);
    }

    /**
     * 0.9 Configure the Ethernet interface
     *
     * Generated from protobuf field <code>.OS.PB.EthernetConfig Ethernet = 220;</code>
     * @param \OS\PB\EthernetConfig $var
     * @return $this
     */
    public function setEthernet($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\EthernetConfig::class);
        $this->writeOneof(220, $var);

        return $this;
    }

    /**
     * 0.9 Configure the Device either in Production or Developer mode
     *
     * Generated from protobuf field <code>.OS.PB.DeviceConfig DeviceParameters = 400;</code>
     * @return \OS\PB\DeviceConfig|null
     */
    public function getDeviceParameters()
    {
        return $this->readOneof(400);
    }

    public function hasDeviceParameters()
    {
        return $this->hasOneof(400);
    }

    /**
     * 0.9 Configure the Device either in Production or Developer mode
     *
     * Generated from protobuf field <code>.OS.PB.DeviceConfig DeviceParameters = 400;</code>
     * @param \OS\PB\DeviceConfig $var
     * @return $this
     */
    public function setDeviceParameters($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\DeviceConfig::class);
        $this->writeOneof(400, $var);

        return $this;
    }

    /**
     * 0.9 Update or create a network route for an id
     *
     * Generated from protobuf field <code>.OS.PB.DeviceRoutingConfig DeviceRouteUpdate = 410;</code>
     * @return \OS\PB\DeviceRoutingConfig|null
     */
    public function getDeviceRouteUpdate()
    {
        return $this->readOneof(410);
    }

    public function hasDeviceRouteUpdate()
    {
        return $this->hasOneof(410);
    }

    /**
     * 0.9 Update or create a network route for an id
     *
     * Generated from protobuf field <code>.OS.PB.DeviceRoutingConfig DeviceRouteUpdate = 410;</code>
     * @param \OS\PB\DeviceRoutingConfig $var
     * @return $this
     */
    public function setDeviceRouteUpdate($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\DeviceRoutingConfig::class);
        $this->writeOneof(410, $var);

        return $this;
    }

    /**
     * 1.4 Delete a network route from the device
     *
     * Generated from protobuf field <code>.OS.PB.DeviceRoutingConfig DeviceRouteDelete = 411;</code>
     * @return \OS\PB\DeviceRoutingConfig|null
     */
    public function getDeviceRouteDelete()
    {
        return $this->readOneof(411);
    }

    public function hasDeviceRouteDelete()
    {
        return $this->hasOneof(411);
    }

    /**
     * 1.4 Delete a network route from the device
     *
     * Generated from protobuf field <code>.OS.PB.DeviceRoutingConfig DeviceRouteDelete = 411;</code>
     * @param \OS\PB\DeviceRoutingConfig $var
     * @return $this
     */
    public function setDeviceRouteDelete($var)
    {
        GPBUtil::checkMessage($var, \OS\PB\DeviceRoutingConfig::class);
        $this->writeOneof(411, $var);

        return $this;
    }

    /**
     * @return string
     */
    public function getConfigType()
    {
        return $this->whichOneof("ConfigType");
    }

}

