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

namespace Google\Cloud\HypercomputeCluster\V1beta;

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

/**
 * When set in a
 * [StorageResourceConfig][google.cloud.hypercomputecluster.v1beta.StorageResourceConfig],
 * indicates that a new [Filestore](https://cloud.google.com/filestore) instance
 * should be created.
 *
 * Generated from protobuf message <code>google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig</code>
 */
class NewFilestoreConfig extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. Immutable. Name of the Filestore instance to create, in the
     * format `projects/{project}/locations/{location}/instances/{instance}`
     *
     * Generated from protobuf field <code>string filestore = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = {</code>
     */
    protected $filestore = '';
    /**
     * Optional. Immutable. Description of the instance. Maximum of 2048
     * characters.
     *
     * Generated from protobuf field <code>string description = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    protected $description = '';
    /**
     * Required. Immutable. File system shares on the instance. Exactly one file
     * share must be specified.
     *
     * Generated from protobuf field <code>repeated .google.cloud.hypercomputecluster.v1beta.FileShareConfig file_shares = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    private $file_shares;
    /**
     * Required. Immutable. Service tier to use for the instance.
     *
     * Generated from protobuf field <code>.google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig.Tier tier = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    protected $tier = 0;
    /**
     * Optional. Immutable. Access protocol to use for all file shares in the
     * instance. Defaults to NFS V3 if not set.
     *
     * Generated from protobuf field <code>.google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig.Protocol protocol = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    protected $protocol = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $filestore
     *           Required. Immutable. Name of the Filestore instance to create, in the
     *           format `projects/{project}/locations/{location}/instances/{instance}`
     *     @type string $description
     *           Optional. Immutable. Description of the instance. Maximum of 2048
     *           characters.
     *     @type array<\Google\Cloud\HypercomputeCluster\V1beta\FileShareConfig>|\Google\Protobuf\Internal\RepeatedField $file_shares
     *           Required. Immutable. File system shares on the instance. Exactly one file
     *           share must be specified.
     *     @type int $tier
     *           Required. Immutable. Service tier to use for the instance.
     *     @type int $protocol
     *           Optional. Immutable. Access protocol to use for all file shares in the
     *           instance. Defaults to NFS V3 if not set.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Hypercomputecluster\V1Beta\HypercomputeCluster::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. Immutable. Name of the Filestore instance to create, in the
     * format `projects/{project}/locations/{location}/instances/{instance}`
     *
     * Generated from protobuf field <code>string filestore = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = {</code>
     * @return string
     */
    public function getFilestore()
    {
        return $this->filestore;
    }

    /**
     * Required. Immutable. Name of the Filestore instance to create, in the
     * format `projects/{project}/locations/{location}/instances/{instance}`
     *
     * Generated from protobuf field <code>string filestore = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = {</code>
     * @param string $var
     * @return $this
     */
    public function setFilestore($var)
    {
        GPBUtil::checkString($var, True);
        $this->filestore = $var;

        return $this;
    }

    /**
     * Optional. Immutable. Description of the instance. Maximum of 2048
     * characters.
     *
     * Generated from protobuf field <code>string description = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return string
     */
    public function getDescription()
    {
        return $this->description;
    }

    /**
     * Optional. Immutable. Description of the instance. Maximum of 2048
     * characters.
     *
     * Generated from protobuf field <code>string description = 4 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * Required. Immutable. File system shares on the instance. Exactly one file
     * share must be specified.
     *
     * Generated from protobuf field <code>repeated .google.cloud.hypercomputecluster.v1beta.FileShareConfig file_shares = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getFileShares()
    {
        return $this->file_shares;
    }

    /**
     * Required. Immutable. File system shares on the instance. Exactly one file
     * share must be specified.
     *
     * Generated from protobuf field <code>repeated .google.cloud.hypercomputecluster.v1beta.FileShareConfig file_shares = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param array<\Google\Cloud\HypercomputeCluster\V1beta\FileShareConfig>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setFileShares($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\HypercomputeCluster\V1beta\FileShareConfig::class);
        $this->file_shares = $arr;

        return $this;
    }

    /**
     * Required. Immutable. Service tier to use for the instance.
     *
     * Generated from protobuf field <code>.google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig.Tier tier = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return int
     */
    public function getTier()
    {
        return $this->tier;
    }

    /**
     * Required. Immutable. Service tier to use for the instance.
     *
     * Generated from protobuf field <code>.google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig.Tier tier = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param int $var
     * @return $this
     */
    public function setTier($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\HypercomputeCluster\V1beta\NewFilestoreConfig\Tier::class);
        $this->tier = $var;

        return $this;
    }

    /**
     * Optional. Immutable. Access protocol to use for all file shares in the
     * instance. Defaults to NFS V3 if not set.
     *
     * Generated from protobuf field <code>.google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig.Protocol protocol = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return int
     */
    public function getProtocol()
    {
        return $this->protocol;
    }

    /**
     * Optional. Immutable. Access protocol to use for all file shares in the
     * instance. Defaults to NFS V3 if not set.
     *
     * Generated from protobuf field <code>.google.cloud.hypercomputecluster.v1beta.NewFilestoreConfig.Protocol protocol = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = OPTIONAL, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param int $var
     * @return $this
     */
    public function setProtocol($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\HypercomputeCluster\V1beta\NewFilestoreConfig\Protocol::class);
        $this->protocol = $var;

        return $this;
    }

}

