<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# source: google/cloud/maintenance/api/v1beta/maintenance_service.proto

namespace Google\Cloud\Maintenance\Api\V1beta;

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

/**
 * The response structure for the ListResourceMaintenances method.
 *
 * Generated from protobuf message <code>google.cloud.maintenance.api.v1beta.ListResourceMaintenancesResponse</code>
 */
class ListResourceMaintenancesResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * The resulting resource maintenances.
     *
     * Generated from protobuf field <code>repeated .google.cloud.maintenance.api.v1beta.ResourceMaintenance resource_maintenances = 10509;</code>
     */
    private $resource_maintenances;
    /**
     * If present, the next page token can be provided to a subsequent
     * ListResourceMaintenances call to list the next page.
     * If empty, there are no more pages.
     *
     * Generated from protobuf field <code>string next_page_token = 10510;</code>
     */
    protected $next_page_token = '';
    /**
     * Locations that could not be reached.
     *
     * Generated from protobuf field <code>repeated string unreachable = 10511;</code>
     */
    private $unreachable;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type array<\Google\Cloud\Maintenance\Api\V1beta\ResourceMaintenance>|\Google\Protobuf\Internal\RepeatedField $resource_maintenances
     *           The resulting resource maintenances.
     *     @type string $next_page_token
     *           If present, the next page token can be provided to a subsequent
     *           ListResourceMaintenances call to list the next page.
     *           If empty, there are no more pages.
     *     @type array<string>|\Google\Protobuf\Internal\RepeatedField $unreachable
     *           Locations that could not be reached.
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Cloud\Maintenance\Api\V1Beta\MaintenanceService::initOnce();
        parent::__construct($data);
    }

    /**
     * The resulting resource maintenances.
     *
     * Generated from protobuf field <code>repeated .google.cloud.maintenance.api.v1beta.ResourceMaintenance resource_maintenances = 10509;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getResourceMaintenances()
    {
        return $this->resource_maintenances;
    }

    /**
     * The resulting resource maintenances.
     *
     * Generated from protobuf field <code>repeated .google.cloud.maintenance.api.v1beta.ResourceMaintenance resource_maintenances = 10509;</code>
     * @param array<\Google\Cloud\Maintenance\Api\V1beta\ResourceMaintenance>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setResourceMaintenances($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Maintenance\Api\V1beta\ResourceMaintenance::class);
        $this->resource_maintenances = $arr;

        return $this;
    }

    /**
     * If present, the next page token can be provided to a subsequent
     * ListResourceMaintenances call to list the next page.
     * If empty, there are no more pages.
     *
     * Generated from protobuf field <code>string next_page_token = 10510;</code>
     * @return string
     */
    public function getNextPageToken()
    {
        return $this->next_page_token;
    }

    /**
     * If present, the next page token can be provided to a subsequent
     * ListResourceMaintenances call to list the next page.
     * If empty, there are no more pages.
     *
     * Generated from protobuf field <code>string next_page_token = 10510;</code>
     * @param string $var
     * @return $this
     */
    public function setNextPageToken($var)
    {
        GPBUtil::checkString($var, True);
        $this->next_page_token = $var;

        return $this;
    }

    /**
     * Locations that could not be reached.
     *
     * Generated from protobuf field <code>repeated string unreachable = 10511;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getUnreachable()
    {
        return $this->unreachable;
    }

    /**
     * Locations that could not be reached.
     *
     * Generated from protobuf field <code>repeated string unreachable = 10511;</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;
    }

}

