summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/go-redis/redis/commands.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/go-redis/redis/commands.go')
-rw-r--r--vendor/github.com/go-redis/redis/commands.go32
1 files changed, 28 insertions, 4 deletions
diff --git a/vendor/github.com/go-redis/redis/commands.go b/vendor/github.com/go-redis/redis/commands.go
index 4ea78777c..83b3824f8 100644
--- a/vendor/github.com/go-redis/redis/commands.go
+++ b/vendor/github.com/go-redis/redis/commands.go
@@ -159,6 +159,7 @@ type Cmdable interface {
ZIncrXX(key string, member Z) *FloatCmd
ZCard(key string) *IntCmd
ZCount(key, min, max string) *IntCmd
+ ZLexCount(key, min, max string) *IntCmd
ZIncrBy(key string, increment float64, member string) *FloatCmd
ZInterStore(destination string, store ZStore, keys ...string) *IntCmd
ZRange(key string, start, stop int64) *StringSliceCmd
@@ -190,7 +191,7 @@ type Cmdable interface {
ConfigGet(parameter string) *SliceCmd
ConfigResetStat() *StatusCmd
ConfigSet(parameter, value string) *StatusCmd
- DbSize() *IntCmd
+ DBSize() *IntCmd
FlushAll() *StatusCmd
FlushAllAsync() *StatusCmd
FlushDB() *StatusCmd
@@ -234,7 +235,9 @@ type Cmdable interface {
GeoAdd(key string, geoLocation ...*GeoLocation) *IntCmd
GeoPos(key string, members ...string) *GeoPosCmd
GeoRadius(key string, longitude, latitude float64, query *GeoRadiusQuery) *GeoLocationCmd
+ GeoRadiusRO(key string, longitude, latitude float64, query *GeoRadiusQuery) *GeoLocationCmd
GeoRadiusByMember(key, member string, query *GeoRadiusQuery) *GeoLocationCmd
+ GeoRadiusByMemberRO(key, member string, query *GeoRadiusQuery) *GeoLocationCmd
GeoDist(key string, member1, member2, unit string) *FloatCmd
GeoHash(key string, members ...string) *StringSliceCmd
Command() *CommandsInfoCmd
@@ -1350,6 +1353,12 @@ func (c *cmdable) ZCount(key, min, max string) *IntCmd {
return cmd
}
+func (c *cmdable) ZLexCount(key, min, max string) *IntCmd {
+ cmd := NewIntCmd("zlexcount", key, min, max)
+ c.process(cmd)
+ return cmd
+}
+
func (c *cmdable) ZIncrBy(key string, increment float64, member string) *FloatCmd {
cmd := NewFloatCmd("zincrby", key, increment, member)
c.process(cmd)
@@ -1675,7 +1684,12 @@ func (c *cmdable) ConfigSet(parameter, value string) *StatusCmd {
return cmd
}
+// Deperecated. Use DBSize instead.
func (c *cmdable) DbSize() *IntCmd {
+ return c.DBSize()
+}
+
+func (c *cmdable) DBSize() *IntCmd {
cmd := NewIntCmd("dbsize")
c.process(cmd)
return cmd
@@ -1695,9 +1709,7 @@ func (c *cmdable) FlushAllAsync() *StatusCmd {
// Deprecated. Use FlushDB instead.
func (c *cmdable) FlushDb() *StatusCmd {
- cmd := NewStatusCmd("flushdb")
- c.process(cmd)
- return cmd
+ return c.FlushDB()
}
func (c *cmdable) FlushDB() *StatusCmd {
@@ -2061,12 +2073,24 @@ func (c *cmdable) GeoRadius(key string, longitude, latitude float64, query *GeoR
return cmd
}
+func (c *cmdable) GeoRadiusRO(key string, longitude, latitude float64, query *GeoRadiusQuery) *GeoLocationCmd {
+ cmd := NewGeoLocationCmd(query, "georadius_ro", key, longitude, latitude)
+ c.process(cmd)
+ return cmd
+}
+
func (c *cmdable) GeoRadiusByMember(key, member string, query *GeoRadiusQuery) *GeoLocationCmd {
cmd := NewGeoLocationCmd(query, "georadiusbymember", key, member)
c.process(cmd)
return cmd
}
+func (c *cmdable) GeoRadiusByMemberRO(key, member string, query *GeoRadiusQuery) *GeoLocationCmd {
+ cmd := NewGeoLocationCmd(query, "georadiusbymember_ro", key, member)
+ c.process(cmd)
+ return cmd
+}
+
func (c *cmdable) GeoDist(key string, member1, member2, unit string) *FloatCmd {
if unit == "" {
unit = "km"