Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
35816a2e
Commit
35816a2e
authored
Oct 28, 2013
by
antirez
Browse files
ZSCAN implemented.
parent
1cc7e646
Changes
3
Show whitespace changes
Inline
Side-by-side
src/redis.c
View file @
35816a2e
...
@@ -179,6 +179,7 @@ struct redisCommand redisCommandTable[] = {
...
@@ -179,6 +179,7 @@ struct redisCommand redisCommandTable[] = {
{"zscore",zscoreCommand,3,"r",0,NULL,1,1,1,0,0},
{"zscore",zscoreCommand,3,"r",0,NULL,1,1,1,0,0},
{"zrank",zrankCommand,3,"r",0,NULL,1,1,1,0,0},
{"zrank",zrankCommand,3,"r",0,NULL,1,1,1,0,0},
{"zrevrank",zrevrankCommand,3,"r",0,NULL,1,1,1,0,0},
{"zrevrank",zrevrankCommand,3,"r",0,NULL,1,1,1,0,0},
{"zscan",zscanCommand,-3,"rR",0,NULL,1,1,1,0,0},
{"hset",hsetCommand,4,"wm",0,NULL,1,1,1,0,0},
{"hset",hsetCommand,4,"wm",0,NULL,1,1,1,0,0},
{"hsetnx",hsetnxCommand,4,"wm",0,NULL,1,1,1,0,0},
{"hsetnx",hsetnxCommand,4,"wm",0,NULL,1,1,1,0,0},
{"hget",hgetCommand,3,"r",0,NULL,1,1,1,0,0},
{"hget",hgetCommand,3,"r",0,NULL,1,1,1,0,0},
...
...
src/redis.h
View file @
35816a2e
...
@@ -1304,6 +1304,7 @@ void hlenCommand(redisClient *c);
...
@@ -1304,6 +1304,7 @@ void hlenCommand(redisClient *c);
void
zremrangebyrankCommand
(
redisClient
*
c
);
void
zremrangebyrankCommand
(
redisClient
*
c
);
void
zunionstoreCommand
(
redisClient
*
c
);
void
zunionstoreCommand
(
redisClient
*
c
);
void
zinterstoreCommand
(
redisClient
*
c
);
void
zinterstoreCommand
(
redisClient
*
c
);
void
zscanCommand
(
redisClient
*
c
);
void
hkeysCommand
(
redisClient
*
c
);
void
hkeysCommand
(
redisClient
*
c
);
void
hvalsCommand
(
redisClient
*
c
);
void
hvalsCommand
(
redisClient
*
c
);
void
hgetallCommand
(
redisClient
*
c
);
void
hgetallCommand
(
redisClient
*
c
);
...
...
src/t_zset.c
View file @
35816a2e
...
@@ -2204,3 +2204,11 @@ void zrankCommand(redisClient *c) {
...
@@ -2204,3 +2204,11 @@ void zrankCommand(redisClient *c) {
void zrevrankCommand(redisClient *c) {
void zrevrankCommand(redisClient *c) {
zrankGenericCommand(c, 1);
zrankGenericCommand(c, 1);
}
}
void zscanCommand(redisClient *c) {
robj *o;
if ((o= lookupKeyReadOrReply(c,c->argv[1],shared.emptyscan)) == NULL ||
checkType(c,o,REDIS_ZSET)) return;
scanGenericCommand(c,o);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment