<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/compute/v1/compute.proto

namespace Google\Cloud\Compute\V1;

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

/**
 * [Output Only] The facilities used for this group's Attachments'
 * Interconnects.
 *
 * Generated from protobuf message <code>google.cloud.compute.v1.InterconnectAttachmentGroupLogicalStructureRegionMetroFacility</code>
 */
class InterconnectAttachmentGroupLogicalStructureRegionMetroFacility extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. [Output Only] The name of a facility, like "iad-1234".
     *
     * Generated from protobuf field <code>optional string facility = 501116579;</code>
     */
    protected $facility = null;
    /**
     * Generated from protobuf field <code>repeated .google.cloud.compute.v1.InterconnectAttachmentGroupLogicalStructureRegionMetroFacilityZone zones = 116085319;</code>
     */
    private $zones;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $facility
     *           Output only. [Output Only] The name of a facility, like "iad-1234".
     *     @type array<\Google\Cloud\Compute\V1\InterconnectAttachmentGroupLogicalStructureRegionMetroFacilityZone>|\Google\Protobuf\Internal\RepeatedField $zones
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Compute\V1\Compute::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. [Output Only] The name of a facility, like "iad-1234".
     *
     * Generated from protobuf field <code>optional string facility = 501116579;</code>
     * @return string
     */
    public function getFacility()
    {
        return isset($this->facility) ? $this->facility : '';
    }

    public function hasFacility()
    {
        return isset($this->facility);
    }

    public function clearFacility()
    {
        unset($this->facility);
    }

    /**
     * Output only. [Output Only] The name of a facility, like "iad-1234".
     *
     * Generated from protobuf field <code>optional string facility = 501116579;</code>
     * @param string $var
     * @return $this
     */
    public function setFacility($var)
    {
        GPBUtil::checkString($var, True);
        $this->facility = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>repeated .google.cloud.compute.v1.InterconnectAttachmentGroupLogicalStructureRegionMetroFacilityZone zones = 116085319;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getZones()
    {
        return $this->zones;
    }

    /**
     * Generated from protobuf field <code>repeated .google.cloud.compute.v1.InterconnectAttachmentGroupLogicalStructureRegionMetroFacilityZone zones = 116085319;</code>
     * @param array<\Google\Cloud\Compute\V1\InterconnectAttachmentGroupLogicalStructureRegionMetroFacilityZone>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setZones($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Compute\V1\InterconnectAttachmentGroupLogicalStructureRegionMetroFacilityZone::class);
        $this->zones = $arr;

        return $this;
    }

}

