Documentation ¶
Index ¶
- type RedisStore
- func (rs *RedisStore) Exist(license string) bool
- func (rs *RedisStore) Expired(license string) error
- func (rs *RedisStore) ExpiredAll(uType guard.UserType, uid int64) error
- func (rs *RedisStore) GetTokenInfo(license string) (*guard.TokenInfo, error)
- func (rs *RedisStore) GetUserTokens(uType guard.UserType, uid int64) ([]string, error)
- func (rs *RedisStore) Provide(ctx context.Context) interface{}
- func (rs *RedisStore) Save(license string, tokenInfo *guard.TokenInfo) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type RedisStore ¶
type RedisStore struct {
// contains filtered or unexported fields
}
func (*RedisStore) ExpiredAll ¶
func (rs *RedisStore) ExpiredAll(uType guard.UserType, uid int64) error
func (*RedisStore) GetTokenInfo ¶
func (rs *RedisStore) GetTokenInfo(license string) (*guard.TokenInfo, error)
GetTokenInfo 通过 token 获取 token 详情
func (*RedisStore) GetUserTokens ¶
GetUserTokens 通过用户类型及用户的 uid 获取用户的 token 列表
func (*RedisStore) Provide ¶
func (rs *RedisStore) Provide(ctx context.Context) interface{}
Click to show internal directories.
Click to hide internal directories.