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

namespace Keyapis\AccessControl\V1;

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

/**
 * Фильтр по квартирам
 *
 * Generated from protobuf message <code>keyapis.access_control.v1.RoomFilter</code>
 */
class RoomFilter extends \Google\Protobuf\Internal\Message
{
    /**
     * По идентификаторам домов
     *
     * Generated from protobuf field <code>repeated int32 building_ids = 1;</code>
     */
    private $building_ids;
    /**
     * По подъездам
     *
     * Generated from protobuf field <code>repeated int32 entrances = 2;</code>
     */
    private $entrances;
    /**
     * По этажам
     *
     * Generated from protobuf field <code>repeated int32 floors = 3;</code>
     */
    private $floors;
    /**
     * По идентификаторам компаний
     *
     * Generated from protobuf field <code>repeated int32 company_ids = 4;</code>
     */
    private $company_ids;
    /**
     * По типам
     *
     * Generated from protobuf field <code>repeated .keyapis.access_control.v1.Room.Type types = 5;</code>
     */
    private $types;
    /**
     * По идентификаторам устройств
     *
     * Generated from protobuf field <code>repeated int32 device_ids = 6;</code>
     */
    private $device_ids;
    /**
     * По ОРПОНам
     *
     * Generated from protobuf field <code>repeated int64 orpons = 7;</code>
     */
    private $orpons;
    /**
     * По признаку служебной квартиры
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_service_flag = 8;</code>
     */
    protected $is_service_flag = null;
    /**
     * По номерам квартир
     *
     * Generated from protobuf field <code>repeated string room_numbers = 9;</code>
     */
    private $room_numbers;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $building_ids
     *           По идентификаторам домов
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $entrances
     *           По подъездам
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $floors
     *           По этажам
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $company_ids
     *           По идентификаторам компаний
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $types
     *           По типам
     *     @type array<int>|\Google\Protobuf\Internal\RepeatedField $device_ids
     *           По идентификаторам устройств
     *     @type array<int>|array<string>|\Google\Protobuf\Internal\RepeatedField $orpons
     *           По ОРПОНам
     *     @type \Google\Protobuf\BoolValue $is_service_flag
     *           По признаку служебной квартиры
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $room_numbers
     *           По номерам квартир
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Keyapis\AccessControl\V1\KeyapisAccessControlAccessControlV1::initOnce();
        parent::__construct($data);
    }

    /**
     * По идентификаторам домов
     *
     * Generated from protobuf field <code>repeated int32 building_ids = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getBuildingIds()
    {
        return $this->building_ids;
    }

    /**
     * По идентификаторам домов
     *
     * Generated from protobuf field <code>repeated int32 building_ids = 1;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setBuildingIds($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
        $this->building_ids = $arr;

        return $this;
    }

    /**
     * По подъездам
     *
     * Generated from protobuf field <code>repeated int32 entrances = 2;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getEntrances()
    {
        return $this->entrances;
    }

    /**
     * По подъездам
     *
     * Generated from protobuf field <code>repeated int32 entrances = 2;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setEntrances($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
        $this->entrances = $arr;

        return $this;
    }

    /**
     * По этажам
     *
     * Generated from protobuf field <code>repeated int32 floors = 3;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getFloors()
    {
        return $this->floors;
    }

    /**
     * По этажам
     *
     * Generated from protobuf field <code>repeated int32 floors = 3;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setFloors($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
        $this->floors = $arr;

        return $this;
    }

    /**
     * По идентификаторам компаний
     *
     * Generated from protobuf field <code>repeated int32 company_ids = 4;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getCompanyIds()
    {
        return $this->company_ids;
    }

    /**
     * По идентификаторам компаний
     *
     * Generated from protobuf field <code>repeated int32 company_ids = 4;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setCompanyIds($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
        $this->company_ids = $arr;

        return $this;
    }

    /**
     * По типам
     *
     * Generated from protobuf field <code>repeated .keyapis.access_control.v1.Room.Type types = 5;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getTypes()
    {
        return $this->types;
    }

    /**
     * По типам
     *
     * Generated from protobuf field <code>repeated .keyapis.access_control.v1.Room.Type types = 5;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setTypes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Keyapis\AccessControl\V1\Room\Type::class);
        $this->types = $arr;

        return $this;
    }

    /**
     * По идентификаторам устройств
     *
     * Generated from protobuf field <code>repeated int32 device_ids = 6;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getDeviceIds()
    {
        return $this->device_ids;
    }

    /**
     * По идентификаторам устройств
     *
     * Generated from protobuf field <code>repeated int32 device_ids = 6;</code>
     * @param array<int>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setDeviceIds($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32);
        $this->device_ids = $arr;

        return $this;
    }

    /**
     * По ОРПОНам
     *
     * Generated from protobuf field <code>repeated int64 orpons = 7;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getOrpons()
    {
        return $this->orpons;
    }

    /**
     * По ОРПОНам
     *
     * Generated from protobuf field <code>repeated int64 orpons = 7;</code>
     * @param array<int>|array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setOrpons($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT64);
        $this->orpons = $arr;

        return $this;
    }

    /**
     * По признаку служебной квартиры
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_service_flag = 8;</code>
     * @return \Google\Protobuf\BoolValue|null
     */
    public function getIsServiceFlag()
    {
        return $this->is_service_flag;
    }

    public function hasIsServiceFlag()
    {
        return isset($this->is_service_flag);
    }

    public function clearIsServiceFlag()
    {
        unset($this->is_service_flag);
    }

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

     * По признаку служебной квартиры
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_service_flag = 8;</code>
     * @return bool|null
     */
    public function getIsServiceFlagUnwrapped()
    {
        return $this->readWrapperValue("is_service_flag");
    }

    /**
     * По признаку служебной квартиры
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_service_flag = 8;</code>
     * @param \Google\Protobuf\BoolValue $var
     * @return $this
     */
    public function setIsServiceFlag($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\BoolValue::class);
        $this->is_service_flag = $var;

        return $this;
    }

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

     * По признаку служебной квартиры
     *
     * Generated from protobuf field <code>.google.protobuf.BoolValue is_service_flag = 8;</code>
     * @param bool|null $var
     * @return $this
     */
    public function setIsServiceFlagUnwrapped($var)
    {
        $this->writeWrapperValue("is_service_flag", $var);
        return $this;}

    /**
     * По номерам квартир
     *
     * Generated from protobuf field <code>repeated string room_numbers = 9;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getRoomNumbers()
    {
        return $this->room_numbers;
    }

    /**
     * По номерам квартир
     *
     * Generated from protobuf field <code>repeated string room_numbers = 9;</code>
     * @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setRoomNumbers($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->room_numbers = $arr;

        return $this;
    }

}

