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

namespace Google\Cloud\Asset\V1;

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

/**
 * Search all resources response.
 *
 * Generated from protobuf message <code>google.cloud.asset.v1.SearchAllResourcesResponse</code>
 */
class SearchAllResourcesResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * A list of Resources that match the search query. It contains the resource
     * standard metadata information.
     *
     * Generated from protobuf field <code>repeated .google.cloud.asset.v1.ResourceSearchResult results = 1;</code>
     */
    private $results;
    /**
     * If there are more results than those appearing in this response, then
     * `next_page_token` is included. To get the next set of results, call this
     * method again using the value of `next_page_token` as `page_token`.
     *
     * Generated from protobuf field <code>string next_page_token = 2;</code>
     */
    private $next_page_token = '';

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type \Google\Cloud\Asset\V1\ResourceSearchResult[]|\Google\Protobuf\Internal\RepeatedField $results
     *           A list of Resources that match the search query. It contains the resource
     *           standard metadata information.
     *     @type string $next_page_token
     *           If there are more results than those appearing in this response, then
     *           `next_page_token` is included. To get the next set of results, call this
     *           method again using the value of `next_page_token` as `page_token`.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Asset\V1\AssetService::initOnce();
        parent::__construct($data);
    }

    /**
     * A list of Resources that match the search query. It contains the resource
     * standard metadata information.
     *
     * Generated from protobuf field <code>repeated .google.cloud.asset.v1.ResourceSearchResult results = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getResults()
    {
        return $this->results;
    }

    /**
     * A list of Resources that match the search query. It contains the resource
     * standard metadata information.
     *
     * Generated from protobuf field <code>repeated .google.cloud.asset.v1.ResourceSearchResult results = 1;</code>
     * @param \Google\Cloud\Asset\V1\ResourceSearchResult[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setResults($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Asset\V1\ResourceSearchResult::class);
        $this->results = $arr;

        return $this;
    }

    /**
     * If there are more results than those appearing in this response, then
     * `next_page_token` is included. To get the next set of results, call this
     * method again using the value of `next_page_token` as `page_token`.
     *
     * Generated from protobuf field <code>string next_page_token = 2;</code>
     * @return string
     */
    public function getNextPageToken()
    {
        return $this->next_page_token;
    }

    /**
     * If there are more results than those appearing in this response, then
     * `next_page_token` is included. To get the next set of results, call this
     * method again using the value of `next_page_token` as `page_token`.
     *
     * 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;
    }

}

