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

namespace Google\Cloud\BigQuery\DataTransfer\V1;

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

/**
 * Returns list of supported data sources and their metadata.
 *
 * Generated from protobuf message <code>google.cloud.bigquery.datatransfer.v1.ListDataSourcesResponse</code>
 */
class ListDataSourcesResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * List of supported data sources and their transfer settings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.bigquery.datatransfer.v1.DataSource data_sources = 1;</code>
     */
    private $data_sources;
    /**
     * Output only. The next-pagination token. For multiple-page list results,
     * this token can be used as the
     * `ListDataSourcesRequest.page_token`
     * to request the next page of list results.
     *
     * Generated from protobuf field <code>string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     */
    private $next_page_token = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\BigQuery\DataTransfer\V1\DataSource[]|\Google\Protobuf\Internal\RepeatedField $data_sources
     *           List of supported data sources and their transfer settings.
     *     @type string $next_page_token
     *           Output only. The next-pagination token. For multiple-page list results,
     *           this token can be used as the
     *           `ListDataSourcesRequest.page_token`
     *           to request the next page of list results.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Bigquery\Datatransfer\V1\Datatransfer::initOnce();
        parent::__construct($data);
    }

    /**
     * List of supported data sources and their transfer settings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.bigquery.datatransfer.v1.DataSource data_sources = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getDataSources()
    {
        return $this->data_sources;
    }

    /**
     * List of supported data sources and their transfer settings.
     *
     * Generated from protobuf field <code>repeated .google.cloud.bigquery.datatransfer.v1.DataSource data_sources = 1;</code>
     * @param \Google\Cloud\BigQuery\DataTransfer\V1\DataSource[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setDataSources($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\BigQuery\DataTransfer\V1\DataSource::class);
        $this->data_sources = $arr;

        return $this;
    }

    /**
     * Output only. The next-pagination token. For multiple-page list results,
     * this token can be used as the
     * `ListDataSourcesRequest.page_token`
     * to request the next page of list results.
     *
     * Generated from protobuf field <code>string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @return string
     */
    public function getNextPageToken()
    {
        return $this->next_page_token;
    }

    /**
     * Output only. The next-pagination token. For multiple-page list results,
     * this token can be used as the
     * `ListDataSourcesRequest.page_token`
     * to request the next page of list results.
     *
     * Generated from protobuf field <code>string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];</code>
     * @param string $var
     * @return $this
     */
    public function setNextPageToken($var)
    {
        GPBUtil::checkString($var, True);
        $this->next_page_token = $var;

        return $this;
    }

}

