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

namespace Google\Cloud\Firestore\V1;

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

/**
 * Planning phase information for the query.
 *
 * Generated from protobuf message <code>google.firestore.v1.PlanSummary</code>
 */
class PlanSummary extends \Google\Protobuf\Internal\Message
{
    /**
     * The indexes selected for the query. For example:
     *  [
     *    {"query_scope": "Collection", "properties": "(foo ASC, __name__ ASC)"},
     *    {"query_scope": "Collection", "properties": "(bar ASC, __name__ ASC)"}
     *  ]
     *
     * Generated from protobuf field <code>repeated .google.protobuf.Struct indexes_used = 1;</code>
     */
    private $indexes_used;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type array<\Google\Protobuf\Struct>|\Google\Protobuf\Internal\RepeatedField $indexes_used
     *           The indexes selected for the query. For example:
     *            [
     *              {"query_scope": "Collection", "properties": "(foo ASC, __name__ ASC)"},
     *              {"query_scope": "Collection", "properties": "(bar ASC, __name__ ASC)"}
     *            ]
     * }
     */
    public function __construct($data = NULL) {
        \GPBMetadata\Google\Firestore\V1\QueryProfile::initOnce();
        parent::__construct($data);
    }

    /**
     * The indexes selected for the query. For example:
     *  [
     *    {"query_scope": "Collection", "properties": "(foo ASC, __name__ ASC)"},
     *    {"query_scope": "Collection", "properties": "(bar ASC, __name__ ASC)"}
     *  ]
     *
     * Generated from protobuf field <code>repeated .google.protobuf.Struct indexes_used = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getIndexesUsed()
    {
        return $this->indexes_used;
    }

    /**
     * The indexes selected for the query. For example:
     *  [
     *    {"query_scope": "Collection", "properties": "(foo ASC, __name__ ASC)"},
     *    {"query_scope": "Collection", "properties": "(bar ASC, __name__ ASC)"}
     *  ]
     *
     * Generated from protobuf field <code>repeated .google.protobuf.Struct indexes_used = 1;</code>
     * @param array<\Google\Protobuf\Struct>|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setIndexesUsed($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Struct::class);
        $this->indexes_used = $arr;

        return $this;
    }

}

