add 增加 RedisUtils 获取缓存Map的key列表
This commit is contained in:
parent
842af57d74
commit
dca5d69dd2
@ -3,6 +3,7 @@ package com.ruoyi.common.utils.redis;
|
||||
import com.ruoyi.common.utils.spring.SpringUtils;
|
||||
import lombok.AccessLevel;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.apache.poi.ss.formula.functions.T;
|
||||
import org.redisson.api.*;
|
||||
import org.redisson.config.Config;
|
||||
|
||||
@ -327,6 +328,17 @@ public class RedisUtils {
|
||||
return rMap.getAll(rMap.keySet());
|
||||
}
|
||||
|
||||
/**
|
||||
* 获得缓存Map的key列表
|
||||
*
|
||||
* @param key 缓存的键值
|
||||
* @return key列表
|
||||
*/
|
||||
public static Set<String> getCacheMapKeySet(final String key) {
|
||||
RMap<String, T> rMap = CLIENT.getMap(key);
|
||||
return rMap.keySet();
|
||||
}
|
||||
|
||||
/**
|
||||
* 往Hash中存入数据
|
||||
*
|
||||
|
Loading…
x
Reference in New Issue
Block a user