<?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;

/**
 * Represents a sub PublicDelegatedPrefix.
 *
 * Generated from protobuf message <code>google.cloud.compute.v1.PublicDelegatedPrefixPublicDelegatedSubPrefix</code>
 */
class PublicDelegatedPrefixPublicDelegatedSubPrefix extends \Google\Protobuf\Internal\Message
{
    /**
     * Name of the project scoping this PublicDelegatedSubPrefix.
     *
     * Generated from protobuf field <code>optional string delegatee_project = 414860634;</code>
     */
    private $delegatee_project = null;
    /**
     * An optional description of this resource. Provide this property when you create the resource.
     *
     * Generated from protobuf field <code>optional string description = 422937596;</code>
     */
    private $description = null;
    /**
     * The IPv4 address range, in CIDR format, represented by this sub public delegated prefix.
     *
     * Generated from protobuf field <code>optional string ip_cidr_range = 98117322;</code>
     */
    private $ip_cidr_range = null;
    /**
     * Whether the sub prefix is delegated to create Address resources in the delegatee project.
     *
     * Generated from protobuf field <code>optional bool is_address = 352617951;</code>
     */
    private $is_address = null;
    /**
     * The name of the sub public delegated prefix.
     *
     * Generated from protobuf field <code>optional string name = 3373707;</code>
     */
    private $name = null;
    /**
     * [Output Only] The region of the sub public delegated prefix if it is regional. If absent, the sub prefix is global.
     *
     * Generated from protobuf field <code>optional string region = 138946292;</code>
     */
    private $region = null;
    /**
     * [Output Only] The status of the sub public delegated prefix.
     * Check the Status enum for the list of possible values.
     *
     * Generated from protobuf field <code>optional string status = 181260274;</code>
     */
    private $status = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $delegatee_project
     *           Name of the project scoping this PublicDelegatedSubPrefix.
     *     @type string $description
     *           An optional description of this resource. Provide this property when you create the resource.
     *     @type string $ip_cidr_range
     *           The IPv4 address range, in CIDR format, represented by this sub public delegated prefix.
     *     @type bool $is_address
     *           Whether the sub prefix is delegated to create Address resources in the delegatee project.
     *     @type string $name
     *           The name of the sub public delegated prefix.
     *     @type string $region
     *           [Output Only] The region of the sub public delegated prefix if it is regional. If absent, the sub prefix is global.
     *     @type string $status
     *           [Output Only] The status of the sub public delegated prefix.
     *           Check the Status enum for the list of possible values.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Compute\V1\Compute::initOnce();
        parent::__construct($data);
    }

    /**
     * Name of the project scoping this PublicDelegatedSubPrefix.
     *
     * Generated from protobuf field <code>optional string delegatee_project = 414860634;</code>
     * @return string
     */
    public function getDelegateeProject()
    {
        return isset($this->delegatee_project) ? $this->delegatee_project : '';
    }

    public function hasDelegateeProject()
    {
        return isset($this->delegatee_project);
    }

    public function clearDelegateeProject()
    {
        unset($this->delegatee_project);
    }

    /**
     * Name of the project scoping this PublicDelegatedSubPrefix.
     *
     * Generated from protobuf field <code>optional string delegatee_project = 414860634;</code>
     * @param string $var
     * @return $this
     */
    public function setDelegateeProject($var)
    {
        GPBUtil::checkString($var, True);
        $this->delegatee_project = $var;

        return $this;
    }

    /**
     * An optional description of this resource. Provide this property when you create the resource.
     *
     * Generated from protobuf field <code>optional string description = 422937596;</code>
     * @return string
     */
    public function getDescription()
    {
        return isset($this->description) ? $this->description : '';
    }

    public function hasDescription()
    {
        return isset($this->description);
    }

    public function clearDescription()
    {
        unset($this->description);
    }

    /**
     * An optional description of this resource. Provide this property when you create the resource.
     *
     * Generated from protobuf field <code>optional string description = 422937596;</code>
     * @param string $var
     * @return $this
     */
    public function setDescription($var)
    {
        GPBUtil::checkString($var, True);
        $this->description = $var;

        return $this;
    }

    /**
     * The IPv4 address range, in CIDR format, represented by this sub public delegated prefix.
     *
     * Generated from protobuf field <code>optional string ip_cidr_range = 98117322;</code>
     * @return string
     */
    public function getIpCidrRange()
    {
        return isset($this->ip_cidr_range) ? $this->ip_cidr_range : '';
    }

    public function hasIpCidrRange()
    {
        return isset($this->ip_cidr_range);
    }

    public function clearIpCidrRange()
    {
        unset($this->ip_cidr_range);
    }

    /**
     * The IPv4 address range, in CIDR format, represented by this sub public delegated prefix.
     *
     * Generated from protobuf field <code>optional string ip_cidr_range = 98117322;</code>
     * @param string $var
     * @return $this
     */
    public function setIpCidrRange($var)
    {
        GPBUtil::checkString($var, True);
        $this->ip_cidr_range = $var;

        return $this;
    }

    /**
     * Whether the sub prefix is delegated to create Address resources in the delegatee project.
     *
     * Generated from protobuf field <code>optional bool is_address = 352617951;</code>
     * @return bool
     */
    public function getIsAddress()
    {
        return isset($this->is_address) ? $this->is_address : false;
    }

    public function hasIsAddress()
    {
        return isset($this->is_address);
    }

    public function clearIsAddress()
    {
        unset($this->is_address);
    }

    /**
     * Whether the sub prefix is delegated to create Address resources in the delegatee project.
     *
     * Generated from protobuf field <code>optional bool is_address = 352617951;</code>
     * @param bool $var
     * @return $this
     */
    public function setIsAddress($var)
    {
        GPBUtil::checkBool($var);
        $this->is_address = $var;

        return $this;
    }

    /**
     * The name of the sub public delegated prefix.
     *
     * Generated from protobuf field <code>optional string name = 3373707;</code>
     * @return string
     */
    public function getName()
    {
        return isset($this->name) ? $this->name : '';
    }

    public function hasName()
    {
        return isset($this->name);
    }

    public function clearName()
    {
        unset($this->name);
    }

    /**
     * The name of the sub public delegated prefix.
     *
     * Generated from protobuf field <code>optional string name = 3373707;</code>
     * @param string $var
     * @return $this
     */
    public function setName($var)
    {
        GPBUtil::checkString($var, True);
        $this->name = $var;

        return $this;
    }

    /**
     * [Output Only] The region of the sub public delegated prefix if it is regional. If absent, the sub prefix is global.
     *
     * Generated from protobuf field <code>optional string region = 138946292;</code>
     * @return string
     */
    public function getRegion()
    {
        return isset($this->region) ? $this->region : '';
    }

    public function hasRegion()
    {
        return isset($this->region);
    }

    public function clearRegion()
    {
        unset($this->region);
    }

    /**
     * [Output Only] The region of the sub public delegated prefix if it is regional. If absent, the sub prefix is global.
     *
     * Generated from protobuf field <code>optional string region = 138946292;</code>
     * @param string $var
     * @return $this
     */
    public function setRegion($var)
    {
        GPBUtil::checkString($var, True);
        $this->region = $var;

        return $this;
    }

    /**
     * [Output Only] The status of the sub public delegated prefix.
     * Check the Status enum for the list of possible values.
     *
     * Generated from protobuf field <code>optional string status = 181260274;</code>
     * @return string
     */
    public function getStatus()
    {
        return isset($this->status) ? $this->status : '';
    }

    public function hasStatus()
    {
        return isset($this->status);
    }

    public function clearStatus()
    {
        unset($this->status);
    }

    /**
     * [Output Only] The status of the sub public delegated prefix.
     * Check the Status enum for the list of possible values.
     *
     * Generated from protobuf field <code>optional string status = 181260274;</code>
     * @param string $var
     * @return $this
     */
    public function setStatus($var)
    {
        GPBUtil::checkString($var, True);
        $this->status = $var;

        return $this;
    }

}

