Method: Redis#sscan

Defined in:
lib/redis.rb

#sscan(key, cursor, options = {}) ⇒ String+

Scan a set

Examples:

Retrieve the first batch of keys in a set

redis.sscan("set", 0)

Parameters:

  • cursor: (String, Integer)

    the cursor of the iteration

  • options (Hash) (defaults to: {})
    • :match => String: only return keys matching the pattern
    • :count => Integer: return count keys at most per iteration

Returns:

  • (String, Array<String>)

    the next cursor and all found members



2414
2415
2416
# File 'lib/redis.rb', line 2414

def sscan(key, cursor, options={})
  _scan(:sscan, cursor, [key], options)
end