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

namespace Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress;

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

/**
 * The basic ingress config for ClientGateways.
 *
 * Generated from protobuf message <code>google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config</code>
 */
class Config extends \Google\Protobuf\Internal\Message
{
    /**
     * Required. Immutable. The transport protocol used between the client and
     * the server.
     *
     * Generated from protobuf field <code>.google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol transport_protocol = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     */
    private $transport_protocol = 0;
    /**
     * Required. The settings used to configure basic ClientGateways.
     *
     * Generated from protobuf field <code>repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute destination_routes = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    private $destination_routes;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type int $transport_protocol
     *           Required. Immutable. The transport protocol used between the client and
     *           the server.
     *     @type array<\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\DestinationRoute>|\Google\Protobuf\Internal\RepeatedField $destination_routes
     *           Required. The settings used to configure basic ClientGateways.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Beyondcorp\Clientconnectorservices\V1\ClientConnectorServicesService::initOnce();
        parent::__construct($data);
    }

    /**
     * Required. Immutable. The transport protocol used between the client and
     * the server.
     *
     * Generated from protobuf field <code>.google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol transport_protocol = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @return int
     */
    public function getTransportProtocol()
    {
        return $this->transport_protocol;
    }

    /**
     * Required. Immutable. The transport protocol used between the client and
     * the server.
     *
     * Generated from protobuf field <code>.google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.TransportProtocol transport_protocol = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE];</code>
     * @param int $var
     * @return $this
     */
    public function setTransportProtocol($var)
    {
        GPBUtil::checkEnum($var, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\TransportProtocol::class);
        $this->transport_protocol = $var;

        return $this;
    }

    /**
     * Required. The settings used to configure basic ClientGateways.
     *
     * Generated from protobuf field <code>repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute destination_routes = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getDestinationRoutes()
    {
        return $this->destination_routes;
    }

    /**
     * Required. The settings used to configure basic ClientGateways.
     *
     * Generated from protobuf field <code>repeated .google.cloud.beyondcorp.clientconnectorservices.v1.ClientConnectorService.Ingress.Config.DestinationRoute destination_routes = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param array<\Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\DestinationRoute>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setDestinationRoutes($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BeyondCorp\ClientConnectorServices\V1\ClientConnectorService\Ingress\Config\DestinationRoute::class);
        $this->destination_routes = $arr;

        return $this;
    }

}


