auth.JwtClaims */ class JwtClaims extends \Google\Protobuf\Internal\Message { /** * 所属应用 * * Generated from protobuf field string app = 1; */ protected $app = ''; /** * 用户id * * Generated from protobuf field string uid = 2; */ protected $uid = ''; /** * 商户id * * Generated from protobuf field string merchant_id = 3; */ protected $merchant_id = ''; /** * 用户在商户下的角色 * * Generated from protobuf field .auth.AccountRole role = 4; */ protected $role = 0; /** * 过期时间戳 * * Generated from protobuf field int64 exp = 5; */ protected $exp = 0; /** * 可刷新时间戳 * * Generated from protobuf field int64 refresh = 6; */ protected $refresh = 0; /** * jwt token版本 * * Generated from protobuf field int64 ver = 7; */ protected $ver = 0; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type string $app * 所属应用 * @type string $uid * 用户id * @type string $merchant_id * 商户id * @type int $role * 用户在商户下的角色 * @type int|string $exp * 过期时间戳 * @type int|string $refresh * 可刷新时间戳 * @type int|string $ver * jwt token版本 * } */ public function __construct($data = NULL) { \GRPC\GPBMetadata\Auth::initOnce(); parent::__construct($data); } /** * 所属应用 * * Generated from protobuf field string app = 1; * @return string */ public function getApp() { return $this->app; } /** * 所属应用 * * Generated from protobuf field string app = 1; * @param string $var * @return $this */ public function setApp($var) { GPBUtil::checkString($var, True); $this->app = $var; return $this; } /** * 用户id * * Generated from protobuf field string uid = 2; * @return string */ public function getUid() { return $this->uid; } /** * 用户id * * Generated from protobuf field string uid = 2; * @param string $var * @return $this */ public function setUid($var) { GPBUtil::checkString($var, True); $this->uid = $var; return $this; } /** * 商户id * * Generated from protobuf field string merchant_id = 3; * @return string */ public function getMerchantId() { return $this->merchant_id; } /** * 商户id * * Generated from protobuf field string merchant_id = 3; * @param string $var * @return $this */ public function setMerchantId($var) { GPBUtil::checkString($var, True); $this->merchant_id = $var; return $this; } /** * 用户在商户下的角色 * * Generated from protobuf field .auth.AccountRole role = 4; * @return int */ public function getRole() { return $this->role; } /** * 用户在商户下的角色 * * Generated from protobuf field .auth.AccountRole role = 4; * @param int $var * @return $this */ public function setRole($var) { GPBUtil::checkEnum($var, \GRPC\Auth\AccountRole::class); $this->role = $var; return $this; } /** * 过期时间戳 * * Generated from protobuf field int64 exp = 5; * @return int|string */ public function getExp() { return $this->exp; } /** * 过期时间戳 * * Generated from protobuf field int64 exp = 5; * @param int|string $var * @return $this */ public function setExp($var) { GPBUtil::checkInt64($var); $this->exp = $var; return $this; } /** * 可刷新时间戳 * * Generated from protobuf field int64 refresh = 6; * @return int|string */ public function getRefresh() { return $this->refresh; } /** * 可刷新时间戳 * * Generated from protobuf field int64 refresh = 6; * @param int|string $var * @return $this */ public function setRefresh($var) { GPBUtil::checkInt64($var); $this->refresh = $var; return $this; } /** * jwt token版本 * * Generated from protobuf field int64 ver = 7; * @return int|string */ public function getVer() { return $this->ver; } /** * jwt token版本 * * Generated from protobuf field int64 ver = 7; * @param int|string $var * @return $this */ public function setVer($var) { GPBUtil::checkInt64($var); $this->ver = $var; return $this; } }