polish up RedisAtomicInteger

This commit is contained in:
Costin Leau
2010-11-08 16:19:01 +02:00
parent 75341a7bba
commit f165dd6574

View File

@@ -48,12 +48,12 @@ public class RedisAtomicInteger extends Number implements Serializable {
*
* @param redisCounter
* @param commands
* @param value
* @param initialValue
*/
public RedisAtomicInteger(String redisCounter, RedisCommands commands, int value) {
public RedisAtomicInteger(String redisCounter, RedisCommands commands, int initialValue) {
this.key = redisCounter;
this.commands = commands;
commands.set(redisCounter, Integer.toString(value));
commands.set(redisCounter, Integer.toString(initialValue));
}
/**
@@ -84,7 +84,6 @@ public class RedisAtomicInteger extends Number implements Serializable {
return Integer.valueOf(commands.getSet(key, Integer.toString(newValue)));
}
/**
* Atomically set the value to the given updated value
* if the current value <tt>==</tt> the expected value.