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

namespace Google\Cloud\MigrationCenter\V1;

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

/**
 * Disk Partition details.
 *
 * Generated from protobuf message <code>google.cloud.migrationcenter.v1.DiskPartition</code>
 */
class DiskPartition extends \Google\Protobuf\Internal\Message
{
    /**
     * Partition type.
     *
     * Generated from protobuf field <code>string type = 1;</code>
     */
    protected $type = '';
    /**
     * Partition file system.
     *
     * Generated from protobuf field <code>string file_system = 2;</code>
     */
    protected $file_system = '';
    /**
     * Mount pount (Linux/Windows) or drive letter (Windows).
     *
     * Generated from protobuf field <code>string mount_point = 3;</code>
     */
    protected $mount_point = '';
    /**
     * Partition capacity.
     *
     * Generated from protobuf field <code>int64 capacity_bytes = 4;</code>
     */
    protected $capacity_bytes = 0;
    /**
     * Partition free space.
     *
     * Generated from protobuf field <code>int64 free_bytes = 5;</code>
     */
    protected $free_bytes = 0;
    /**
     * Partition UUID.
     *
     * Generated from protobuf field <code>string uuid = 6;</code>
     */
    protected $uuid = '';
    /**
     * Sub-partitions.
     *
     * Generated from protobuf field <code>.google.cloud.migrationcenter.v1.DiskPartitionList sub_partitions = 7;</code>
     */
    protected $sub_partitions = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $type
     *           Partition type.
     *     @type string $file_system
     *           Partition file system.
     *     @type string $mount_point
     *           Mount pount (Linux/Windows) or drive letter (Windows).
     *     @type int|string $capacity_bytes
     *           Partition capacity.
     *     @type int|string $free_bytes
     *           Partition free space.
     *     @type string $uuid
     *           Partition UUID.
     *     @type \Google\Cloud\MigrationCenter\V1\DiskPartitionList $sub_partitions
     *           Sub-partitions.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Migrationcenter\V1\Migrationcenter::initOnce();
        parent::__construct($data);
    }

    /**
     * Partition type.
     *
     * Generated from protobuf field <code>string type = 1;</code>
     * @return string
     */
    public function getType()
    {
        return $this->type;
    }

    /**
     * Partition type.
     *
     * Generated from protobuf field <code>string type = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setType($var)
    {
        GPBUtil::checkString($var, True);
        $this->type = $var;

        return $this;
    }

    /**
     * Partition file system.
     *
     * Generated from protobuf field <code>string file_system = 2;</code>
     * @return string
     */
    public function getFileSystem()
    {
        return $this->file_system;
    }

    /**
     * Partition file system.
     *
     * Generated from protobuf field <code>string file_system = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setFileSystem($var)
    {
        GPBUtil::checkString($var, True);
        $this->file_system = $var;

        return $this;
    }

    /**
     * Mount pount (Linux/Windows) or drive letter (Windows).
     *
     * Generated from protobuf field <code>string mount_point = 3;</code>
     * @return string
     */
    public function getMountPoint()
    {
        return $this->mount_point;
    }

    /**
     * Mount pount (Linux/Windows) or drive letter (Windows).
     *
     * Generated from protobuf field <code>string mount_point = 3;</code>
     * @param string $var
     * @return $this
     */
    public function setMountPoint($var)
    {
        GPBUtil::checkString($var, True);
        $this->mount_point = $var;

        return $this;
    }

    /**
     * Partition capacity.
     *
     * Generated from protobuf field <code>int64 capacity_bytes = 4;</code>
     * @return int|string
     */
    public function getCapacityBytes()
    {
        return $this->capacity_bytes;
    }

    /**
     * Partition capacity.
     *
     * Generated from protobuf field <code>int64 capacity_bytes = 4;</code>
     * @param int|string $var
     * @return $this
     */
    public function setCapacityBytes($var)
    {
        GPBUtil::checkInt64($var);
        $this->capacity_bytes = $var;

        return $this;
    }

    /**
     * Partition free space.
     *
     * Generated from protobuf field <code>int64 free_bytes = 5;</code>
     * @return int|string
     */
    public function getFreeBytes()
    {
        return $this->free_bytes;
    }

    /**
     * Partition free space.
     *
     * Generated from protobuf field <code>int64 free_bytes = 5;</code>
     * @param int|string $var
     * @return $this
     */
    public function setFreeBytes($var)
    {
        GPBUtil::checkInt64($var);
        $this->free_bytes = $var;

        return $this;
    }

    /**
     * Partition UUID.
     *
     * Generated from protobuf field <code>string uuid = 6;</code>
     * @return string
     */
    public function getUuid()
    {
        return $this->uuid;
    }

    /**
     * Partition UUID.
     *
     * Generated from protobuf field <code>string uuid = 6;</code>
     * @param string $var
     * @return $this
     */
    public function setUuid($var)
    {
        GPBUtil::checkString($var, True);
        $this->uuid = $var;

        return $this;
    }

    /**
     * Sub-partitions.
     *
     * Generated from protobuf field <code>.google.cloud.migrationcenter.v1.DiskPartitionList sub_partitions = 7;</code>
     * @return \Google\Cloud\MigrationCenter\V1\DiskPartitionList|null
     */
    public function getSubPartitions()
    {
        return $this->sub_partitions;
    }

    public function hasSubPartitions()
    {
        return isset($this->sub_partitions);
    }

    public function clearSubPartitions()
    {
        unset($this->sub_partitions);
    }

    /**
     * Sub-partitions.
     *
     * Generated from protobuf field <code>.google.cloud.migrationcenter.v1.DiskPartitionList sub_partitions = 7;</code>
     * @param \Google\Cloud\MigrationCenter\V1\DiskPartitionList $var
     * @return $this
     */
    public function setSubPartitions($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\MigrationCenter\V1\DiskPartitionList::class);
        $this->sub_partitions = $var;

        return $this;
    }

}

