<?php
# Generated by the protocol buffer compiler.  DO NOT EDIT!
# NO CHECKED-IN PROTOBUF GENCODE
# source: qa.proto

namespace App\Grpc\Qa;

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

/**
 * 最新问题列表
 *
 * Generated from protobuf message <code>qa.LatestQuestionsRequest</code>
 */
class LatestQuestionsRequest extends \Google\Protobuf\Internal\Message
{
    /**
     * 用户名
     *
     * Generated from protobuf field <code>string username = 1;</code>
     */
    protected $username = '';
    /**
     * 上一次的question_id，第一页默认为0
     *
     * Generated from protobuf field <code>uint64 last_id = 2;</code>
     */
    protected $last_id = 0;
    /**
     * Generated from protobuf field <code>uint64 limit = 3;</code>
     */
    protected $limit = 0;

    /**
     * Constructor.
     *
     * @param array $data {
     *     Optional. Data for populating the Message object.
     *
     *     @type string $username
     *           用户名
     *     @type int|string $last_id
     *           上一次的question_id，第一页默认为0
     *     @type int|string $limit
     * }
     */
    public function __construct($data = NULL) {
        \App\Grpc\GPBMetadata\Qa::initOnce();
        parent::__construct($data);
    }

    /**
     * 用户名
     *
     * Generated from protobuf field <code>string username = 1;</code>
     * @return string
     */
    public function getUsername()
    {
        return $this->username;
    }

    /**
     * 用户名
     *
     * Generated from protobuf field <code>string username = 1;</code>
     * @param string $var
     * @return $this
     */
    public function setUsername($var)
    {
        GPBUtil::checkString($var, True);
        $this->username = $var;

        return $this;
    }

    /**
     * 上一次的question_id，第一页默认为0
     *
     * Generated from protobuf field <code>uint64 last_id = 2;</code>
     * @return int|string
     */
    public function getLastId()
    {
        return $this->last_id;
    }

    /**
     * 上一次的question_id，第一页默认为0
     *
     * Generated from protobuf field <code>uint64 last_id = 2;</code>
     * @param int|string $var
     * @return $this
     */
    public function setLastId($var)
    {
        GPBUtil::checkUint64($var);
        $this->last_id = $var;

        return $this;
    }

    /**
     * Generated from protobuf field <code>uint64 limit = 3;</code>
     * @return int|string
     */
    public function getLimit()
    {
        return $this->limit;
    }

    /**
     * Generated from protobuf field <code>uint64 limit = 3;</code>
     * @param int|string $var
     * @return $this
     */
    public function setLimit($var)
    {
        GPBUtil::checkUint64($var);
        $this->limit = $var;

        return $this;
    }

}

