getAuthIdentifierName(); return $this->attributes[$name]; } /** * token的附加属性 * @return array */ public function getJWTCustomClaims() { return [ 'api_token'=>$this->attributes['api_token'] ]; } public function offsetExists($offset) { return isset($this->attributes[$offset]); } public function offsetGet($offset) { return $this->attributes[$offset]; } public function offsetSet($offset, $value) { return $this->attributes[$offset] = $value; } public function offsetUnset($offset) { unset($this->attributes[$offset]); } }