List of usage examples for org.springframework.data.redis.connection RedisConnection move
@Nullable Boolean move(byte[] key, int dbIndex);
From source file:com.zxy.commons.cache.RedisUtils.java
/** * Move given {@code key} to database with {@code index}. * <p>/* w w w.j a v a 2 s . c o m*/ * See http://redis.io/commands/move * * @param key key * @param dbIndex dbIndex * @return Boolean */ public static Boolean move(byte[] key, int dbIndex) { return redisTemplate.execute(new RedisCallback<Boolean>() { @Override public Boolean doInRedis(RedisConnection redis) throws DataAccessException { return redis.move(key, dbIndex); } }); }
From source file:com.zxy.commons.cache.RedisHelper.java
/** * Move given {@code key} to database with {@code index}. * <p>/* ww w . ja v a2s . co m*/ * See http://redis.io/commands/move * * @param key key * @param dbIndex dbIndex * @return Boolean */ public Boolean move(byte[] key, int dbIndex) { return redisTemplate.execute(new RedisCallback<Boolean>() { @Override public Boolean doInRedis(RedisConnection redis) throws DataAccessException { return redis.move(key, dbIndex); } }); }