class Redis
def zinter(*keys, weights: nil, aggregate: nil, with_scores: false)
-
(Array
-, Array<[String, Float]>)
Parameters:
-
options
(Hash
) -- -
keys
(String, Array
) -- one or more keys to intersect
Other tags:
- Example: Retrieve the intersection of `2*zsetA` and `1*zsetB`, and their scores -
Example: Retrieve the intersection of `2*zsetA` and `1*zsetB` -
def zinter(*keys, weights: nil, aggregate: nil, with_scores: false) args = [:zinter, keys.size, *keys] if weights args << "WEIGHTS" args.concat(weights) end args << "AGGREGATE" << aggregate if aggregate if with_scores args << "WITHSCORES" block = FloatifyPairs end synchronize do |client| client.call(args, &block) end end