redis.clients.jedis.params.LPosParams Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jedis_preview Show documentation
Show all versions of jedis_preview Show documentation
Jedis is a blazingly small and sane Redis java client.
The newest version!
package redis.clients.jedis.params;
import redis.clients.jedis.CommandArguments;
import redis.clients.jedis.Protocol.Keyword;
public class LPosParams implements IParams {
private Integer rank;
private Integer maxlen;
public static LPosParams lPosParams() {
return new LPosParams();
}
public LPosParams rank(int rank) {
this.rank = rank;
return this;
}
public LPosParams maxlen(int maxLen) {
this.maxlen = maxLen;
return this;
}
@Override
public void addParams(CommandArguments args) {
if (rank != null) {
args.add(Keyword.RANK).add(rank);
}
if (maxlen != null) {
args.add(Keyword.MAXLEN).add(maxlen);
}
}
}