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

namespace Google\Cloud\BareMetalSolution\V2;

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

/**
 * Message requesting to updating a NFS share.
 *
 * Generated from protobuf message <code>google.cloud.baremetalsolution.v2.UpdateNfsShareRequest</code>
 */
class UpdateNfsShareRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. The NFS share to update.
     * The `name` field is used to identify the NFS share to update.
     * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share}
     *
     * Generated from protobuf field <code>.google.cloud.baremetalsolution.v2.NfsShare nfs_share = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $nfs_share = null;
    /**
     * The list of fields to update.
     * The only currently supported fields are:
     *   `labels`
     *
     * Generated from protobuf field <code>.google.protobuf.FieldMask update_mask = 2;</code>
     */
    private $update_mask = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\BareMetalSolution\V2\NfsShare $nfs_share
     *           Required. The NFS share to update.
     *           The `name` field is used to identify the NFS share to update.
     *           Format: projects/{project}/locations/{location}/nfsShares/{nfs_share}
     *     @type \Google\Protobuf\FieldMask $update_mask
     *           The list of fields to update.
     *           The only currently supported fields are:
     *             `labels`
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Baremetalsolution\V2\NfsShare::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. The NFS share to update.
     * The `name` field is used to identify the NFS share to update.
     * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share}
     *
     * Generated from protobuf field <code>.google.cloud.baremetalsolution.v2.NfsShare nfs_share = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Cloud\BareMetalSolution\V2\NfsShare|null
     */
    public function getNfsShare()
    {
        return $this->nfs_share;
    }

    public function hasNfsShare()
    {
        return isset($this->nfs_share);
    }

    public function clearNfsShare()
    {
        unset($this->nfs_share);
    }

    /**
     * Required. The NFS share to update.
     * The `name` field is used to identify the NFS share to update.
     * Format: projects/{project}/locations/{location}/nfsShares/{nfs_share}
     *
     * Generated from protobuf field <code>.google.cloud.baremetalsolution.v2.NfsShare nfs_share = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param \Google\Cloud\BareMetalSolution\V2\NfsShare $var
     * @return $this
     */
    public function setNfsShare($var)
    {
        GPBUtil::checkMessage($var, \Google\Cloud\BareMetalSolution\V2\NfsShare::class);
        $this->nfs_share = $var;

        return $this;
    }

    /**
     * The list of fields to update.
     * The only currently supported fields are:
     *   `labels`
     *
     * Generated from protobuf field <code>.google.protobuf.FieldMask update_mask = 2;</code>
     * @return \Google\Protobuf\FieldMask|null
     */
    public function getUpdateMask()
    {
        return $this->update_mask;
    }

    public function hasUpdateMask()
    {
        return isset($this->update_mask);
    }

    public function clearUpdateMask()
    {
        unset($this->update_mask);
    }

    /**
     * The list of fields to update.
     * The only currently supported fields are:
     *   `labels`
     *
     * Generated from protobuf field <code>.google.protobuf.FieldMask update_mask = 2;</code>
     * @param \Google\Protobuf\FieldMask $var
     * @return $this
     */
    public function setUpdateMask($var)
    {
        GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class);
        $this->update_mask = $var;

        return $this;
    }

}

