RBatch.getKeys added

pull/243/head
Nikita 10 years ago
parent 85ce7b285d
commit 76ae4784a6

@ -24,6 +24,7 @@ import org.redisson.core.RBlockingQueueAsync;
import org.redisson.core.RBucketAsync;
import org.redisson.core.RDequeAsync;
import org.redisson.core.RHyperLogLogAsync;
import org.redisson.core.RKeysAsync;
import org.redisson.core.RListAsync;
import org.redisson.core.RMapAsync;
import org.redisson.core.RQueueAsync;
@ -35,10 +36,9 @@ import io.netty.util.concurrent.Future;
public class RedissonBatch implements RBatch {
CommandBatchExecutorService executorService;
private final CommandBatchExecutorService executorService;
public RedissonBatch(ConnectionManager connectionManager) {
super();
this.executorService = new CommandBatchExecutorService(connectionManager);
}
@ -97,6 +97,11 @@ public class RedissonBatch implements RBatch {
return new RedissonScript(executorService);
}
@Override
public RKeysAsync getKeys() {
return new RedissonKeys(executorService);
}
@Override
public List<?> execute() {
return executorService.execute();

@ -120,6 +120,14 @@ public interface RBatch {
*/
RScriptAsync getScript();
/**
* Returns keys operations.
* Each of Redis/Redisson object associated with own key
*
* @return
*/
RKeysAsync getKeys();
/**
* Executes all operations accumulated during async methods invocations.
*

Loading…
Cancel
Save