[Add] StringListRedisCacheStore 增加类型为String的RedisListCacheStore实现;

[Change] BotCommandProcess 更换pagesCache的缓存组件(RedisPoolCacheStore<List<String>> -> StringListRedisCacheStore);
This commit is contained in:
2020-04-17 18:25:48 +08:00
parent f844d150e8
commit c1427379c6
2 changed files with 59 additions and 12 deletions

View File

@ -0,0 +1,30 @@
package net.lamgc.cgj.bot.cache;
import redis.clients.jedis.JedisPool;
import redis.clients.jedis.JedisPoolConfig;
import java.net.URI;
public class StringListRedisCacheStore extends RedisListCacheStore<String> {
public StringListRedisCacheStore(URI redisServerUri, String prefix) {
super(redisServerUri, prefix);
}
public StringListRedisCacheStore(URI redisServerUri, JedisPoolConfig config, int timeout, String password, String prefix) {
super(redisServerUri, config, timeout, password, prefix);
}
public StringListRedisCacheStore(JedisPool pool, String prefix) {
super(pool, prefix);
}
@Override
public String parseData(String dataObj) {
return dataObj;
}
@Override
public String analysisData(String str) {
return str;
}
}