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

namespace Google\Cloud\NetworkConnectivity\V1\SpokeSummary;

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

/**
 * The number of spokes of a given type that are associated
 * with a specific hub. The type indicates what kind of
 * resource is associated with the spoke.
 *
 * Generated from protobuf message <code>google.cloud.networkconnectivity.v1.SpokeSummary.SpokeTypeCount</code>
 */
class SpokeTypeCount extends \Google\Protobuf\Internal\Message
{
    /**
     * Output only. The type of the spokes.
     *
     * Generated from protobuf field <code>.google.cloud.networkconnectivity.v1.SpokeType spoke_type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $spoke_type = 0;
    /**
     * Output only. The total number of spokes of this type that are
     * associated with the hub.
     *
     * Generated from protobuf field <code>int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    protected $count = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int $spoke_type
     *           Output only. The type of the spokes.
     *     @type int|string $count
     *           Output only. The total number of spokes of this type that are
     *           associated with the hub.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Networkconnectivity\V1\Hub::initOnce();
        parent::__construct($data);
    }

    /**
     * Output only. The type of the spokes.
     *
     * Generated from protobuf field <code>.google.cloud.networkconnectivity.v1.SpokeType spoke_type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int
     */
    public function getSpokeType()
    {
        return $this->spoke_type;
    }

    /**
     * Output only. The type of the spokes.
     *
     * Generated from protobuf field <code>.google.cloud.networkconnectivity.v1.SpokeType spoke_type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int $var
     * @return $this
     */
    public function setSpokeType($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\NetworkConnectivity\V1\SpokeType::class);
        $this->spoke_type = $var;

        return $this;
    }

    /**
     * Output only. The total number of spokes of this type that are
     * associated with the hub.
     *
     * Generated from protobuf field <code>int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return int|string
     */
    public function getCount()
    {
        return $this->count;
    }

    /**
     * Output only. The total number of spokes of this type that are
     * associated with the hub.
     *
     * Generated from protobuf field <code>int64 count = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param int|string $var
     * @return $this
     */
    public function setCount($var)
    {
        GPBUtil::checkInt64($var);
        $this->count = $var;

        return $this;
    }

}


