<?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 VPN gateway interface.
 *
 * Generated from protobuf message <code>google.cloud.compute.v1.VpnGatewayVpnGatewayInterface</code>
 */
class VpnGatewayVpnGatewayInterface extends \Google\Protobuf\Internal\Message
{
    /**
     * [Output Only] Numeric identifier for this VPN interface associated with the VPN gateway.
     *
     * Generated from protobuf field <code>optional uint32 id = 3355;</code>
     */
    private $id = null;
    /**
     * URL of the VLAN attachment (interconnectAttachment) resource for this VPN gateway interface. When the value of this field is present, the VPN gateway is used for HA VPN over Cloud Interconnect; all egress or ingress traffic for this VPN gateway interface goes through the specified VLAN attachment resource.
     *
     * Generated from protobuf field <code>optional string interconnect_attachment = 308135284;</code>
     */
    private $interconnect_attachment = null;
    /**
     * [Output Only] IP address for this VPN interface associated with the VPN gateway. The IP address could be either a regional external IP address or a regional internal IP address. The two IP addresses for a VPN gateway must be all regional external or regional internal IP addresses. There cannot be a mix of regional external IP addresses and regional internal IP addresses. For HA VPN over Cloud Interconnect, the IP addresses for both interfaces could either be regional internal IP addresses or regional external IP addresses. For regular (non HA VPN over Cloud Interconnect) HA VPN tunnels, the IP address must be a regional external IP address.
     *
     * Generated from protobuf field <code>optional string ip_address = 406272220;</code>
     */
    private $ip_address = null;
    /**
     * [Output Only] IPv6 address for this VPN interface associated with the VPN gateway. The IPv6 address must be a regional external IPv6 address. The format is RFC 5952 format (e.g. 2001:db8::2d9:51:0:0).
     *
     * Generated from protobuf field <code>optional string ipv6_address = 341563804;</code>
     */
    private $ipv6_address = null;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int $id
     *           [Output Only] Numeric identifier for this VPN interface associated with the VPN gateway.
     *     @type string $interconnect_attachment
     *           URL of the VLAN attachment (interconnectAttachment) resource for this VPN gateway interface. When the value of this field is present, the VPN gateway is used for HA VPN over Cloud Interconnect; all egress or ingress traffic for this VPN gateway interface goes through the specified VLAN attachment resource.
     *     @type string $ip_address
     *           [Output Only] IP address for this VPN interface associated with the VPN gateway. The IP address could be either a regional external IP address or a regional internal IP address. The two IP addresses for a VPN gateway must be all regional external or regional internal IP addresses. There cannot be a mix of regional external IP addresses and regional internal IP addresses. For HA VPN over Cloud Interconnect, the IP addresses for both interfaces could either be regional internal IP addresses or regional external IP addresses. For regular (non HA VPN over Cloud Interconnect) HA VPN tunnels, the IP address must be a regional external IP address.
     *     @type string $ipv6_address
     *           [Output Only] IPv6 address for this VPN interface associated with the VPN gateway. The IPv6 address must be a regional external IPv6 address. The format is RFC 5952 format (e.g. 2001:db8::2d9:51:0:0).
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Compute\V1\Compute::initOnce();
        parent::__construct($data);
    }

    /**
     * [Output Only] Numeric identifier for this VPN interface associated with the VPN gateway.
     *
     * Generated from protobuf field <code>optional uint32 id = 3355;</code>
     * @return int
     */
    public function getId()
    {
        return isset($this->id) ? $this->id : 0;
    }

    public function hasId()
    {
        return isset($this->id);
    }

    public function clearId()
    {
        unset($this->id);
    }

    /**
     * [Output Only] Numeric identifier for this VPN interface associated with the VPN gateway.
     *
     * Generated from protobuf field <code>optional uint32 id = 3355;</code>
     * @param int $var
     * @return $this
     */
    public function setId($var)
    {
        GPBUtil::checkUint32($var);
        $this->id = $var;

        return $this;
    }

    /**
     * URL of the VLAN attachment (interconnectAttachment) resource for this VPN gateway interface. When the value of this field is present, the VPN gateway is used for HA VPN over Cloud Interconnect; all egress or ingress traffic for this VPN gateway interface goes through the specified VLAN attachment resource.
     *
     * Generated from protobuf field <code>optional string interconnect_attachment = 308135284;</code>
     * @return string
     */
    public function getInterconnectAttachment()
    {
        return isset($this->interconnect_attachment) ? $this->interconnect_attachment : '';
    }

    public function hasInterconnectAttachment()
    {
        return isset($this->interconnect_attachment);
    }

    public function clearInterconnectAttachment()
    {
        unset($this->interconnect_attachment);
    }

    /**
     * URL of the VLAN attachment (interconnectAttachment) resource for this VPN gateway interface. When the value of this field is present, the VPN gateway is used for HA VPN over Cloud Interconnect; all egress or ingress traffic for this VPN gateway interface goes through the specified VLAN attachment resource.
     *
     * Generated from protobuf field <code>optional string interconnect_attachment = 308135284;</code>
     * @param string $var
     * @return $this
     */
    public function setInterconnectAttachment($var)
    {
        GPBUtil::checkString($var, True);
        $this->interconnect_attachment = $var;

        return $this;
    }

    /**
     * [Output Only] IP address for this VPN interface associated with the VPN gateway. The IP address could be either a regional external IP address or a regional internal IP address. The two IP addresses for a VPN gateway must be all regional external or regional internal IP addresses. There cannot be a mix of regional external IP addresses and regional internal IP addresses. For HA VPN over Cloud Interconnect, the IP addresses for both interfaces could either be regional internal IP addresses or regional external IP addresses. For regular (non HA VPN over Cloud Interconnect) HA VPN tunnels, the IP address must be a regional external IP address.
     *
     * Generated from protobuf field <code>optional string ip_address = 406272220;</code>
     * @return string
     */
    public function getIpAddress()
    {
        return isset($this->ip_address) ? $this->ip_address : '';
    }

    public function hasIpAddress()
    {
        return isset($this->ip_address);
    }

    public function clearIpAddress()
    {
        unset($this->ip_address);
    }

    /**
     * [Output Only] IP address for this VPN interface associated with the VPN gateway. The IP address could be either a regional external IP address or a regional internal IP address. The two IP addresses for a VPN gateway must be all regional external or regional internal IP addresses. There cannot be a mix of regional external IP addresses and regional internal IP addresses. For HA VPN over Cloud Interconnect, the IP addresses for both interfaces could either be regional internal IP addresses or regional external IP addresses. For regular (non HA VPN over Cloud Interconnect) HA VPN tunnels, the IP address must be a regional external IP address.
     *
     * Generated from protobuf field <code>optional string ip_address = 406272220;</code>
     * @param string $var
     * @return $this
     */
    public function setIpAddress($var)
    {
        GPBUtil::checkString($var, True);
        $this->ip_address = $var;

        return $this;
    }

    /**
     * [Output Only] IPv6 address for this VPN interface associated with the VPN gateway. The IPv6 address must be a regional external IPv6 address. The format is RFC 5952 format (e.g. 2001:db8::2d9:51:0:0).
     *
     * Generated from protobuf field <code>optional string ipv6_address = 341563804;</code>
     * @return string
     */
    public function getIpv6Address()
    {
        return isset($this->ipv6_address) ? $this->ipv6_address : '';
    }

    public function hasIpv6Address()
    {
        return isset($this->ipv6_address);
    }

    public function clearIpv6Address()
    {
        unset($this->ipv6_address);
    }

    /**
     * [Output Only] IPv6 address for this VPN interface associated with the VPN gateway. The IPv6 address must be a regional external IPv6 address. The format is RFC 5952 format (e.g. 2001:db8::2d9:51:0:0).
     *
     * Generated from protobuf field <code>optional string ipv6_address = 341563804;</code>
     * @param string $var
     * @return $this
     */
    public function setIpv6Address($var)
    {
        GPBUtil::checkString($var, True);
        $this->ipv6_address = $var;

        return $this;
    }

}

