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

namespace Google\Cloud\Eventarc\V1;

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

/**
 * The response message for the `ListChannelConnections` method.
 *
 * Generated from protobuf message <code>google.cloud.eventarc.v1.ListChannelConnectionsResponse</code>
 */
class ListChannelConnectionsResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * The requested channel connections, up to the number specified in
     * `page_size`.
     *
     * Generated from protobuf field <code>repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;</code>
     */
    private $channel_connections;
    /**
     * A page token that can be sent to `ListChannelConnections` to request the
     * next page.
     * If this is empty, then there are no more pages.
     *
     * Generated from protobuf field <code>string next_page_token = 2;</code>
     */
    private $next_page_token = '';
    /**
     * Unreachable resources, if any.
     *
     * Generated from protobuf field <code>repeated string unreachable = 3;</code>
     */
    private $unreachable;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type array<\Google\Cloud\Eventarc\V1\ChannelConnection>|\Google\Protobuf\Internal\RepeatedField $channel_connections
     *           The requested channel connections, up to the number specified in
     *           `page_size`.
     *     @type string $next_page_token
     *           A page token that can be sent to `ListChannelConnections` to request the
     *           next page.
     *           If this is empty, then there are no more pages.
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $unreachable
     *           Unreachable resources, if any.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Eventarc\V1\Eventarc::initOnce();
        parent::__construct($data);
    }

    /**
     * The requested channel connections, up to the number specified in
     * `page_size`.
     *
     * Generated from protobuf field <code>repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getChannelConnections()
    {
        return $this->channel_connections;
    }

    /**
     * The requested channel connections, up to the number specified in
     * `page_size`.
     *
     * Generated from protobuf field <code>repeated .google.cloud.eventarc.v1.ChannelConnection channel_connections = 1;</code>
     * @param array<\Google\Cloud\Eventarc\V1\ChannelConnection>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setChannelConnections($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Eventarc\V1\ChannelConnection::class);
        $this->channel_connections = $arr;

        return $this;
    }

    /**
     * A page token that can be sent to `ListChannelConnections` to request the
     * next page.
     * If this is empty, then there are no more pages.
     *
     * Generated from protobuf field <code>string next_page_token = 2;</code>
     * @return string
     */
    public function getNextPageToken()
    {
        return $this->next_page_token;
    }

    /**
     * A page token that can be sent to `ListChannelConnections` to request the
     * next page.
     * If this is empty, then there are no more pages.
     *
     * Generated from protobuf field <code>string next_page_token = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setNextPageToken($var)
    {
        GPBUtil::checkString($var, True);
        $this->next_page_token = $var;

        return $this;
    }

    /**
     * Unreachable resources, if any.
     *
     * Generated from protobuf field <code>repeated string unreachable = 3;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getUnreachable()
    {
        return $this->unreachable;
    }

    /**
     * Unreachable resources, if any.
     *
     * Generated from protobuf field <code>repeated string unreachable = 3;</code>
     * @param array<string>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setUnreachable($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING);
        $this->unreachable = $arr;

        return $this;
    }

}

