public interface UsersConnectionTokenRepository
| 限定符和类型 | 方法和说明 |
|---|---|
void |
delAuthTokenById(String tokenId)
删除 id = tokenId 的记录
|
List<AuthTokenPo> |
findAuthTokenByExpireTimeAndBetweenId(Long expiredTime,
Long startId,
Long endId)
获取 ID 范围在 startId(包含) 与 endId(包含) 之间且过期时间小于等于 expiredTime 且 enableRefresh=1 的 token 数据.
|
AuthTokenPo |
findAuthTokenById(String tokenId)
根据 tokenId 获取 tokenId
|
Long |
getMaxTokenId()
获取最大 TokenId
|
AuthTokenPo |
saveAuthToken(AuthTokenPo authToken)
持久化 authToken, 并把返回的 authToken id 保存在 authToken 中
|
AuthTokenPo |
updateAuthToken(AuthTokenPo authToken)
更新
AuthTokenPo |
void |
updateEnableRefreshByTokenId(EnableRefresh enableRefresh,
Long tokenId)
根据 tokenId 更新 auth_token 表中的 enableRefresh 字段
|
AuthTokenPo findAuthTokenById(String tokenId) throws Exception
tokenId - tokenIdException - 查询错误AuthTokenPo saveAuthToken(AuthTokenPo authToken) throws Exception
authToken - authTokenException - 持久化 authToken 异常AuthTokenPo updateAuthToken(AuthTokenPo authToken) throws Exception
AuthTokenPoauthToken - 更新 AuthTokenPoException - 数据更新异常void delAuthTokenById(String tokenId) throws Exception
tokenId - tokenIdException - 删除错误Long getMaxTokenId() throws Exception
Exception - sql 执行错误List<AuthTokenPo> findAuthTokenByExpireTimeAndBetweenId(@NonNull Long expiredTime, @NonNull Long startId, @NonNull Long endId) throws Exception
expiredTime - 过期时间startId - 起始 id, 包含endId - 结束 id, 包含AuthTokenPo 列表Exception - 查询错误void updateEnableRefreshByTokenId(@NonNull
EnableRefresh enableRefresh,
@NonNull
Long tokenId)
throws Exception
enableRefresh - EnableRefreshtokenId - token idException - 更新异常Copyright © 2021. All rights reserved.