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

namespace Google\Cloud\Bigtable\V2;

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

/**
 * Response message for Bigtable.ReadRows.
 *
 * Generated from protobuf message <code>google.bigtable.v2.ReadRowsResponse</code>
 */
class ReadRowsResponse extends \Google\Protobuf\Internal\Message
{
    /**
     * Generated from protobuf field <code>repeated .google.bigtable.v2.ReadRowsResponse.CellChunk chunks = 1;</code>
     */
    private $chunks;
    /**
     * Optionally the server might return the row key of the last row it
     * has scanned.  The client can use this to construct a more
     * efficient retry request if needed: any row keys or portions of
     * ranges less than this row key can be dropped from the request.
     * This is primarily useful for cases where the server has read a
     * lot of data that was filtered out since the last committed row
     * key, allowing the client to skip that work on a retry.
     *
     * Generated from protobuf field <code>bytes last_scanned_row_key = 2;</code>
     */
    private $last_scanned_row_key = '';

    public function __construct() {
        \GPBMetadata\Google\Bigtable\V2\Bigtable::initOnce();
        parent::__construct();
    }

    /**
     * Generated from protobuf field <code>repeated .google.bigtable.v2.ReadRowsResponse.CellChunk chunks = 1;</code>
     * @return \Google\Protobuf\Internal\RepeatedField
     */
    public function getChunks()
    {
        return $this->chunks;
    }

    /**
     * Generated from protobuf field <code>repeated .google.bigtable.v2.ReadRowsResponse.CellChunk chunks = 1;</code>
     * @param \Google\Cloud\Bigtable\V2\ReadRowsResponse_CellChunk[]|\Google\Protobuf\Internal\RepeatedField $var
     * @return $this
     */
    public function setChunks($var)
    {
        $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Bigtable\V2\ReadRowsResponse_CellChunk::class);
        $this->chunks = $arr;

        return $this;
    }

    /**
     * Optionally the server might return the row key of the last row it
     * has scanned.  The client can use this to construct a more
     * efficient retry request if needed: any row keys or portions of
     * ranges less than this row key can be dropped from the request.
     * This is primarily useful for cases where the server has read a
     * lot of data that was filtered out since the last committed row
     * key, allowing the client to skip that work on a retry.
     *
     * Generated from protobuf field <code>bytes last_scanned_row_key = 2;</code>
     * @return string
     */
    public function getLastScannedRowKey()
    {
        return $this->last_scanned_row_key;
    }

    /**
     * Optionally the server might return the row key of the last row it
     * has scanned.  The client can use this to construct a more
     * efficient retry request if needed: any row keys or portions of
     * ranges less than this row key can be dropped from the request.
     * This is primarily useful for cases where the server has read a
     * lot of data that was filtered out since the last committed row
     * key, allowing the client to skip that work on a retry.
     *
     * Generated from protobuf field <code>bytes last_scanned_row_key = 2;</code>
     * @param string $var
     * @return $this
     */
    public function setLastScannedRowKey($var)
    {
        GPBUtil::checkString($var, False);
        $this->last_scanned_row_key = $var;

        return $this;
    }

}

