本文整理了Java中org.redisson.config.Config.toJSON()
方法的一些代码示例,展示了Config.toJSON()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Config.toJSON()
方法的具体详情如下:
包路径:org.redisson.config.Config
类名称:Config
方法名:toJSON
[英]Convert current configuration to JSON format
[中]将当前配置转换为JSON格式
代码示例来源:origin: debop/hibernate-redis
@SneakyThrows
public RedisClient(@NonNull RedissonClient redisson, int expiryInSeconds) {
log.trace("RedisClient created. config={}, expiryInSeconds={}", redisson.getConfig().toJSON(), expiryInSeconds);
this.redisson = redisson;
if (expiryInSeconds >= 0) {
this.expiryInSeconds = expiryInSeconds;
}
}
代码示例来源:origin: debop/hibernate-redis
@SneakyThrows
public RedisClient(@NonNull RedissonClient redisson, int expiryInSeconds) {
log.trace("RedisClient created. config={}, expiryInSeconds={}", redisson.getConfig().toJSON(), expiryInSeconds);
this.redisson = redisson;
if (expiryInSeconds >= 0) {
this.expiryInSeconds = expiryInSeconds;
}
}
代码示例来源:origin: com.github.debop/hibernate-redis
@SneakyThrows
public RedisClient(@NonNull RedissonClient redisson, int expiryInSeconds) {
log.trace("RedisClient created. config={}, expiryInSeconds={}", redisson.getConfig().toJSON(), expiryInSeconds);
this.redisson = redisson;
if (expiryInSeconds >= 0) {
this.expiryInSeconds = expiryInSeconds;
}
}
代码示例来源:origin: com.github.jsimone/webapp-runner-redis
File configFile = File.createTempFile("redisson", ".json");
try (BufferedWriter bw = new BufferedWriter(new FileWriter(configFile));) {
bw.write(config.toJSON());
RedissonSessionManager redisManager = new RedissonSessionManager();
redisManager.setConfigPath(configFile.getAbsolutePath());
代码示例来源:origin: jsimone/webapp-runner
File configFile = File.createTempFile("redisson", ".json");
try (BufferedWriter bw = new BufferedWriter(new FileWriter(configFile));) {
bw.write(config.toJSON());
RedissonSessionManager redisManager = new RedissonSessionManager();
redisManager.setConfigPath(configFile.getAbsolutePath());
内容来源于网络,如有侵权,请联系作者删除!