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

namespace Google\Cloud\CapacityPlanner\V1beta\Allocation\SpecificSKUAllocation\AllocatedInstanceProperties;

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

/**
 * A specification of the interface and size of disk attached to
 * the instance.
 *
 * Generated from protobuf message <code>google.cloud.capacityplanner.v1beta.Allocation.SpecificSKUAllocation.AllocatedInstanceProperties.AllocatedDisk</code>
 */
class AllocatedDisk extends \Google\Protobuf\Internal\Message
{
    /**
     * Specifies the size of the disk in base-2 GB.
     *
     * Generated from protobuf field <code>int64 disk_size_gb = 1;</code>
     */
    protected $disk_size_gb = 0;
    /**
     * Specifies the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI.
     *
     * Generated from protobuf field <code>.google.cloud.capacityplanner.v1beta.Allocation.SpecificSKUAllocation.AllocatedInstanceProperties.AllocatedDisk.DiskInterface disk_interface = 2;</code>
     */
    protected $disk_interface = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int|string $disk_size_gb
     *           Specifies the size of the disk in base-2 GB.
     *     @type int $disk_interface
     *           Specifies the disk interface to use for attaching this disk, which is
     *           either SCSI or NVME. The default is SCSI.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Capacityplanner\V1Beta\Allocation::initOnce();
        parent::__construct($data);
    }

    /**
     * Specifies the size of the disk in base-2 GB.
     *
     * Generated from protobuf field <code>int64 disk_size_gb = 1;</code>
     * @return int|string
     */
    public function getDiskSizeGb()
    {
        return $this->disk_size_gb;
    }

    /**
     * Specifies the size of the disk in base-2 GB.
     *
     * Generated from protobuf field <code>int64 disk_size_gb = 1;</code>
     * @param int|string $var
     * @return $this
     */
    public function setDiskSizeGb($var)
    {
        GPBUtil::checkInt64($var);
        $this->disk_size_gb = $var;

        return $this;
    }

    /**
     * Specifies the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI.
     *
     * Generated from protobuf field <code>.google.cloud.capacityplanner.v1beta.Allocation.SpecificSKUAllocation.AllocatedInstanceProperties.AllocatedDisk.DiskInterface disk_interface = 2;</code>
     * @return int
     */
    public function getDiskInterface()
    {
        return $this->disk_interface;
    }

    /**
     * Specifies the disk interface to use for attaching this disk, which is
     * either SCSI or NVME. The default is SCSI.
     *
     * Generated from protobuf field <code>.google.cloud.capacityplanner.v1beta.Allocation.SpecificSKUAllocation.AllocatedInstanceProperties.AllocatedDisk.DiskInterface disk_interface = 2;</code>
     * @param int $var
     * @return $this
     */
    public function setDiskInterface($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\CapacityPlanner\V1beta\Allocation\SpecificSKUAllocation\AllocatedInstanceProperties\AllocatedDisk\DiskInterface::class);
        $this->disk_interface = $var;

        return $this;
    }

}


