feat: 增加ZADD ZADDWithOption
This commit is contained in:
10
wrapper.go
10
wrapper.go
@@ -132,3 +132,13 @@ func (w *wrapper) ZRangeAndRemByScore(ctx context.Context, instanceFlag string,
|
||||
}
|
||||
return rangeRes
|
||||
}
|
||||
|
||||
// ZAdd ...
|
||||
func (w *wrapper) ZAdd(ctx context.Context, instanceFlag string, key string, score int64, data any) *define.RedisResult {
|
||||
return Client.Exec(ctx, instanceFlag, consts.RedisCommandZadd, key, score, data)
|
||||
}
|
||||
|
||||
// ZAddWithOption ...
|
||||
func (w *wrapper) ZAddWithOption(ctx context.Context, instanceFlag string, key string, option string, score int64, data any) *define.RedisResult {
|
||||
return Client.Exec(ctx, instanceFlag, consts.RedisCommandZadd, key, option, score, data)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user