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

namespace Google\Cloud\Compute\V1;

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

/**
 * A request message for ReservationSlots.Get. See the method description for details.
 *
 * Generated from protobuf message <code>google.cloud.compute.v1.GetReservationSlotRequest</code>
 */
class GetReservationSlotRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * The name of the parent reservation and parent block, formatted as
     * reservations/{reservation_name}/reservationBlocks/{reservation_block_name}/reservationSubBlocks/{reservation_sub_block_name}
     *
     * Generated from protobuf field <code>string parent_name = 478151936 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $parent_name = '';
    /**
     * The project ID for this request.
     *
     * Generated from protobuf field <code>string project = 227560217 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $project = '';
    /**
     * The name of the reservation slot, formatted as RFC1035 or a resource ID
     * number.
     *
     * Generated from protobuf field <code>string reservation_slot = 277470865 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $reservation_slot = '';
    /**
     * The name of the zone for this request, formatted as RFC1035.
     *
     * Generated from protobuf field <code>string zone = 3744684 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    protected $zone = '';

    /**
     * @param string $project         The project ID for this request.
     * @param string $zone            The name of the zone for this request, formatted as RFC1035.
     * @param string $parentName      The name of the parent reservation and parent block, formatted as
     *                                reservations/{reservation_name}/reservationBlocks/{reservation_block_name}/reservationSubBlocks/{reservation_sub_block_name}
     * @param string $reservationSlot The name of the reservation slot, formatted as RFC1035 or a resource ID
     *                                number.
     *
     * @return \Google\Cloud\Compute\V1\GetReservationSlotRequest
     *
     * @experimental
     */
    public static function build(string $project, string $zone, string $parentName, string $reservationSlot): self
    {
        return (new self())
            ->setProject($project)
            ->setZone($zone)
            ->setParentName($parentName)
            ->setReservationSlot($reservationSlot);
    }

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $parent_name
     *           The name of the parent reservation and parent block, formatted as
     *           reservations/{reservation_name}/reservationBlocks/{reservation_block_name}/reservationSubBlocks/{reservation_sub_block_name}
     *     @type string $project
     *           The project ID for this request.
     *     @type string $reservation_slot
     *           The name of the reservation slot, formatted as RFC1035 or a resource ID
     *           number.
     *     @type string $zone
     *           The name of the zone for this request, formatted as RFC1035.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Compute\V1\Compute::initOnce();
        parent::__construct($data);
    }

    /**
     * The name of the parent reservation and parent block, formatted as
     * reservations/{reservation_name}/reservationBlocks/{reservation_block_name}/reservationSubBlocks/{reservation_sub_block_name}
     *
     * Generated from protobuf field <code>string parent_name = 478151936 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getParentName()
    {
        return $this->parent_name;
    }

    /**
     * The name of the parent reservation and parent block, formatted as
     * reservations/{reservation_name}/reservationBlocks/{reservation_block_name}/reservationSubBlocks/{reservation_sub_block_name}
     *
     * Generated from protobuf field <code>string parent_name = 478151936 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setParentName($var)
    {
        GPBUtil::checkString($var, True);
        $this->parent_name = $var;

        return $this;
    }

    /**
     * The project ID for this request.
     *
     * Generated from protobuf field <code>string project = 227560217 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getProject()
    {
        return $this->project;
    }

    /**
     * The project ID for this request.
     *
     * Generated from protobuf field <code>string project = 227560217 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setProject($var)
    {
        GPBUtil::checkString($var, True);
        $this->project = $var;

        return $this;
    }

    /**
     * The name of the reservation slot, formatted as RFC1035 or a resource ID
     * number.
     *
     * Generated from protobuf field <code>string reservation_slot = 277470865 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getReservationSlot()
    {
        return $this->reservation_slot;
    }

    /**
     * The name of the reservation slot, formatted as RFC1035 or a resource ID
     * number.
     *
     * Generated from protobuf field <code>string reservation_slot = 277470865 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setReservationSlot($var)
    {
        GPBUtil::checkString($var, True);
        $this->reservation_slot = $var;

        return $this;
    }

    /**
     * The name of the zone for this request, formatted as RFC1035.
     *
     * Generated from protobuf field <code>string zone = 3744684 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return string
     */
    public function getZone()
    {
        return $this->zone;
    }

    /**
     * The name of the zone for this request, formatted as RFC1035.
     *
     * Generated from protobuf field <code>string zone = 3744684 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param string $var
     * @return $this
     */
    public function setZone($var)
    {
        GPBUtil::checkString($var, True);
        $this->zone = $var;

        return $this;
    }

}

