Package io.toro.martini.redis
Class RedisSetMethods
- java.lang.Object
-
- io.toro.martini.redis.RedisBaseMethods
-
- io.toro.martini.redis.RedisSetMethods
-
public class RedisSetMethods extends io.toro.martini.redis.RedisBaseMethods
Methods for Sets.
-
-
Constructor Summary
Constructors Constructor Description RedisSetMethods(io.toro.martini.database.DataSourceManager dataSourceManager)
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Long
sadd(String connectionName, Object key, GloopExecutionContext context, Object... members)
Add one or more members to a set.static Future<Long>
saddAsync(String connectionName, Object key, GloopExecutionContext context, Object... members)
Asynchronously add one or more members to a set.static Long
scard(String connectionName, Object key, GloopExecutionContext context)
Get the number of members in a set.static Future<Long>
scardAsync(String connectionName, Object key, GloopExecutionContext context)
Asynchronously get the number of members in a set.static Long
sdiff(String connectionName, ValueStreamingChannel<Object> channel, GloopExecutionContext context, Object... keys)
Subtract multiple sets.static Set<Object>
sdiff(String connectionName, GloopExecutionContext context, Object... keys)
Subtract multiple sets.static Future<Long>
sdiffAsync(String connectionName, ValueStreamingChannel<Object> channel, GloopExecutionContext context, Object... keys)
Asynchronously subtract multiple sets.static Future<Set<Object>>
sdiffAsync(String connectionName, GloopExecutionContext context, Object... keys)
Asynchronously subtract multiple sets.static Long
sdiffstore(String connectionName, Object destination, GloopExecutionContext context, Object... keys)
Subtract multiple sets and store the resulting set in a key.static Future<Long>
sdiffstoreAsync(String connectionName, Object destination, GloopExecutionContext context, Object... keys)
Asynchronously subtract multiple sets and store the resulting set in a key.static Long
sinter(String connectionName, ValueStreamingChannel<Object> channel, GloopExecutionContext context, Object... keys)
Intersect multiple sets.static Set<Object>
sinter(String connectionName, GloopExecutionContext context, Object... keys)
Intersect multiple sets.static Future<Long>
sinterAsync(String connectionName, ValueStreamingChannel<Object> channel, GloopExecutionContext context, Object... keys)
Asynchronously intersect multiple sets.static Future<Set<Object>>
sinterAsync(String connectionName, GloopExecutionContext context, Object... keys)
Asynchronously intersect multiple sets.static Long
sinterstore(String connectionName, Object destination, GloopExecutionContext context, Object... keys)
Intersect multiple sets and store the resulting set in a key.static Future<Long>
sinterstoreAsync(String connectionName, Object destination, GloopExecutionContext context, Object... keys)
Asynchronously intersect multiple sets and store the resulting set in a key.static Boolean
sismember(String connectionName, Object key, Object member, GloopExecutionContext context)
Determine if a given value is a member of a set.static Future<Boolean>
sismemberAsync(String connectionName, Object key, Object member, GloopExecutionContext context)
Asynchronously determine if a given value is a member of a set.static Long
smembers(String connectionName, ValueStreamingChannel<Object> channel, Object key, GloopExecutionContext context)
Get all the members in a set.static Set<Object>
smembers(String connectionName, Object key, GloopExecutionContext context)
Get all the members in a set.static Future<Long>
smembersAsync(String connectionName, ValueStreamingChannel<Object> channel, Object key, GloopExecutionContext context)
Asynchronously get all the members in a set.static Future<Set<Object>>
smembersAsync(String connectionName, Object key, GloopExecutionContext context)
Asynchronously get all the members in a set.static Boolean
smove(String connectionName, Object source, Object destination, Object member, GloopExecutionContext context)
Move a member from one set to another.static Future<Boolean>
smoveAsync(String connectionName, Object source, Object destination, Object member, GloopExecutionContext context)
Asynchronously move a member from one set to another.static Set<Object>
spop(String connectionName, Object key, long count, GloopExecutionContext context)
Remove and return one or multiple random members from a set.static Object
spop(String connectionName, Object key, GloopExecutionContext context)
Remove and return a random member from a set.static Future<Set<Object>>
spopAsync(String connectionName, Object key, long count, GloopExecutionContext context)
Asynchronously remove and return one or multiple random members from a set.static Future<Object>
spopAsync(String connectionName, Object key, GloopExecutionContext context)
Asynchronously remove and return a random member from a set.static Long
srandmember(String connectionName, ValueStreamingChannel<Object> channel, Object key, long count, GloopExecutionContext context)
Get one or multiple random members from a set.static List<Object>
srandmember(String connectionName, Object key, long count, GloopExecutionContext context)
Get one or multiple random members from a set.static Object
srandmember(String connectionName, Object key, GloopExecutionContext context)
Get one random member from a set.static Future<Long>
srandmemberAsync(String connectionName, ValueStreamingChannel<Object> channel, Object key, long count, GloopExecutionContext context)
Asynchronously get one or multiple random members from a set.static Future<List<Object>>
srandmemberAsync(String connectionName, Object key, long count, GloopExecutionContext context)
Asynchronously get one or multiple random members from a set.static Future<Object>
srandmemberAsync(String connectionName, Object key, GloopExecutionContext context)
Asynchronously get one random member from a set.static Long
srem(String connectionName, Object key, GloopExecutionContext context, Object... members)
Remove one or more members from a set.static Future<Long>
sremAsync(String connectionName, Object key, GloopExecutionContext context, Object... members)
Asynchronously remove one or more members from a set.static StreamScanCursor
sscan(String connectionName, ValueStreamingChannel<Object> channel, Object key, ScanCursor scanCursor, GloopExecutionContext context)
Incrementally iterate Set elements.static StreamScanCursor
sscan(String connectionName, ValueStreamingChannel<Object> channel, Object key, ScanCursor scanCursor, GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.static StreamScanCursor
sscan(String connectionName, ValueStreamingChannel<Object> channel, Object key, GloopExecutionContext context)
Incrementally iterate Set elements.static StreamScanCursor
sscan(String connectionName, ValueStreamingChannel<Object> channel, Object key, GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.static ValueScanCursor<Object>
sscan(String connectionName, Object key, ScanCursor scanCursor, GloopExecutionContext context)
Incrementally iterate Set elements.static ValueScanCursor<Object>
sscan(String connectionName, Object key, ScanCursor scanCursor, GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.static ValueScanCursor<Object>
sscan(String connectionName, Object key, GloopExecutionContext context)
Incrementally iterate Set elements.static ValueScanCursor<Object>
sscan(String connectionName, Object key, GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.static Future<StreamScanCursor>
sscanAsync(String connectionName, ValueStreamingChannel<Object> channel, Object key, ScanCursor scanCursor, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<StreamScanCursor>
sscanAsync(String connectionName, ValueStreamingChannel<Object> channel, Object key, ScanCursor scanCursor, GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<StreamScanCursor>
sscanAsync(String connectionName, ValueStreamingChannel<Object> channel, Object key, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<StreamScanCursor>
sscanAsync(String connectionName, ValueStreamingChannel<Object> channel, Object key, GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<ValueScanCursor<Object>>
sscanAsync(String connectionName, Object key, ScanCursor scanCursor, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<ValueScanCursor<Object>>
sscanAsync(String connectionName, Object key, ScanCursor scanCursor, GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<ValueScanCursor<Object>>
sscanAsync(String connectionName, Object key, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Future<ValueScanCursor<Object>>
sscanAsync(String connectionName, Object key, GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.static Long
sunion(String connectionName, ValueStreamingChannel<Object> channel, GloopExecutionContext context, Object... keys)
Add multiple sets.static Set<Object>
sunion(String connectionName, GloopExecutionContext context, Object... keys)
Add multiple sets.static Future<Long>
sunionAsync(String connectionName, ValueStreamingChannel<Object> channel, GloopExecutionContext context, Object... keys)
Asynchronously add multiple sets.static Future<Set<Object>>
sunionAsync(String connectionName, GloopExecutionContext context, Object... keys)
Asynchronously add multiple sets.static Long
sunionstore(String connectionName, Object destination, GloopExecutionContext context, Object... keys)
Add multiple sets and store the resulting set in a key.static Future<Long>
sunionstoreAsync(String connectionName, Object destination, GloopExecutionContext context, Object... keys)
Asynchronously add multiple sets and store the resulting set in a key.
-
-
-
Constructor Detail
-
RedisSetMethods
@Autowired RedisSetMethods(io.toro.martini.database.DataSourceManager dataSourceManager)
-
-
Method Detail
-
sadd
@GloopParameter(name="redisSaddOutput") public static Long sadd(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... members)
Add one or more members to a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keymembers
- the member type: value- Returns:
- Long integer-reply the number of elements that were added to the set, not including all the elements already present into the set.
-
saddAsync
@GloopParameter(name="redisFutureSaddOutput") public static Future<Long> saddAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... members)
Asynchronously add one or more members to a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keymembers
- the member type: value- Returns:
- long integer-reply the number of elements that were added to the set, not including all the elements already present into the set.
-
scard
@GloopParameter(name="redisScardOutput") public static Long scard(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Get the number of members in a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- Long integer-reply the cardinality (number of elements) of the set, or false if
key
does not exist.
-
scardAsync
@GloopParameter(name="redisFutureScardOutput") public static Future<Long> scardAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously get the number of members in a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- long integer-reply the cardinality (number of elements) of the set, or false if
key
does not exist.
-
sdiff
@GloopParameter(name="redisSdiffOutput") public static Set<Object> sdiff(@GloopParameter(allowNull=false) String connectionName, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Subtract multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekeys
- the key- Returns:
- Set<V> array-reply list with members of the resulting set.
-
sdiff
@GloopParameter(name="redisSdiffOutput") public static Long sdiff(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Subtract multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- the channelkeys
- the keys- Returns:
- Long count of members of the resulting set.
-
sdiffAsync
@GloopParameter(name="redisFutureSdiffOutput") public static Future<Set<Object>> sdiffAsync(@GloopParameter(allowNull=false) String connectionName, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously subtract multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekeys
- the key- Returns:
- set<V> array-reply list with members of the resulting set.
-
sdiffAsync
@GloopParameter(name="redisFutureSdiffOutput") public static Future<Long> sdiffAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously subtract multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- the channelkeys
- the keys- Returns:
- long count of members of the resulting set.
-
sdiffstore
@GloopParameter(name="redisSdiffstoreOutput") public static Long sdiffstore(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object destination, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Subtract multiple sets and store the resulting set in a key.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namedestination
- the destination type: keykeys
- the key- Returns:
- Long integer-reply the number of elements in the resulting set.
-
sdiffstoreAsync
@GloopParameter(name="redisFutureSdiffstoreOutput") public static Future<Long> sdiffstoreAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object destination, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously subtract multiple sets and store the resulting set in a key.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namedestination
- the destination type: keykeys
- the key- Returns:
- long integer-reply the number of elements in the resulting set.
-
sinter
@GloopParameter(name="redisSinterOutput") public static Set<Object> sinter(@GloopParameter(allowNull=false) String connectionName, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Intersect multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekeys
- the key- Returns:
- Set<V> array-reply list with members of the resulting set.
-
sinter
@GloopParameter(name="redisSinterOutput") public static Long sinter(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Intersect multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- the channelkeys
- the keys- Returns:
- Long count of members of the resulting set.
-
sinterAsync
@GloopParameter(name="redisFutureSinterOutput") public static Future<Set<Object>> sinterAsync(@GloopParameter(allowNull=false) String connectionName, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously intersect multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekeys
- the key- Returns:
- set<V> array-reply list with members of the resulting set.
-
sinterAsync
@GloopParameter(name="redisFutureSinterOutput") public static Future<Long> sinterAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously intersect multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- the channelkeys
- the keys- Returns:
- long count of members of the resulting set.
-
sinterstore
@GloopParameter(name="redisSinterstoreOutput") public static Long sinterstore(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object destination, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Intersect multiple sets and store the resulting set in a key.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namedestination
- the destination type: keykeys
- the key- Returns:
- Long integer-reply the number of elements in the resulting set.
-
sinterstoreAsync
@GloopParameter(name="redisFutureSinterstoreOutput") public static Future<Long> sinterstoreAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object destination, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously intersect multiple sets and store the resulting set in a key.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namedestination
- the destination type: keykeys
- the key- Returns:
- long integer-reply the number of elements in the resulting set.
-
sismember
@GloopParameter(name="redisSismemberOutput") public static Boolean sismember(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) Object member, GloopExecutionContext context)
Determine if a given value is a member of a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keymember
- the member type: value- Returns:
- Boolean integer-reply specifically: true if the element is a member of the set.
false if the element is not a member of the set, or if
key
does not exist.
-
sismemberAsync
@GloopParameter(name="redisFutureSismemberOutput") public static Future<Boolean> sismemberAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) Object member, GloopExecutionContext context)
Asynchronously determine if a given value is a member of a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keymember
- the member type: value- Returns:
- boolean integer-reply specifically: true if the element is a member of the set.
false if the element is not a member of the set, or if
key
does not exist.
-
smove
@GloopParameter(name="redisSmoveOutput") public static Boolean smove(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object source, @GloopParameter(allowNull=false) Object destination, @GloopParameter(allowNull=false) Object member, GloopExecutionContext context)
Move a member from one set to another.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namesource
- the source keydestination
- the destination type: keymember
- the member type: value- Returns:
- Boolean integer-reply specifically: true if the element is moved. false if
the element is not a member of
source
and no operation was performed.
-
smoveAsync
@GloopParameter(name="redisFutureSmoveOutput") public static Future<Boolean> smoveAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object source, @GloopParameter(allowNull=false) Object destination, @GloopParameter(allowNull=false) Object member, GloopExecutionContext context)
Asynchronously move a member from one set to another.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namesource
- the source keydestination
- the destination type: keymember
- the member type: value- Returns:
- boolean integer-reply specifically: true if the element is moved. false if
the element is not a member of
source
and no operation was performed.
-
smembers
@GloopParameter(name="redisSmembersOutput") public static Set<Object> smembers(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Get all the members in a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- Set<V> array-reply all elements of the set.
-
smembers
@GloopParameter(name="redisSmembersOutput") public static Long smembers(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Get all the members in a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- the channelkey
- the keys- Returns:
- Long count of members of the resulting set.
-
smembersAsync
@GloopParameter(name="redisFutureSmembersOutput") public static Future<Set<Object>> smembersAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously get all the members in a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- set<V> array-reply all elements of the set.
-
smembersAsync
@GloopParameter(name="redisFutureSmembersOutput") public static Future<Long> smembersAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously get all the members in a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- the channelkey
- the keys- Returns:
- long count of members of the resulting set.
-
spop
@GloopParameter(name="redisSpopOutput") public static Object spop(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Remove and return a random member from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- V bulk-string-reply the removed element, or null when
key
does not exist.
-
spop
@GloopParameter(name="redisSpopOutput") public static Set<Object> spop(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) long count, GloopExecutionContext context)
Remove and return one or multiple random members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keycount
- number of members to pop- Returns:
- V bulk-string-reply the removed element, or null when
key
does not exist.
-
spopAsync
@GloopParameter(name="redisFutureSpopOutput") public static Future<Object> spopAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously remove and return a random member from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- v bulk-string-reply the removed element, or null when
key
does not exist.
-
spopAsync
@GloopParameter(name="redisFutureSpopOutput") public static Future<Set<Object>> spopAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) long count, GloopExecutionContext context)
Asynchronously remove and return one or multiple random members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keycount
- number of members to pop- Returns:
- v bulk-string-reply the removed element, or null when
key
does not exist.
-
srandmember
@GloopParameter(name="redisSrandmemberOutput") public static Object srandmember(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Get one random member from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- V bulk-string-reply without the additional
count
argument the command returns a Bulk Reply with the randomly selected element, or null whenkey
does not exist.
-
srandmember
@GloopParameter(name="redisSrandmemberOutput") public static List<Object> srandmember(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) long count, GloopExecutionContext context)
Get one or multiple random members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keycount
- the count type: long- Returns:
- Set<V> bulk-string-reply without the additional
count
argument the command returns a Bulk Reply with the randomly selected element, or null whenkey
does not exist.
-
srandmember
@GloopParameter(name="redisSrandmemberOutput") public static Long srandmember(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) long count, GloopExecutionContext context)
Get one or multiple random members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keycount
- the count- Returns:
- Long count of members of the resulting set.
-
srandmemberAsync
@GloopParameter(name="redisFutureSrandmemberOutput") public static Future<Object> srandmemberAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously get one random member from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- v bulk-string-reply without the additional
count
argument the command returns a bulk reply with the randomly selected element, or null whenkey
does not exist.
-
srandmemberAsync
@GloopParameter(name="redisFutureSrandmemberOutput") public static Future<List<Object>> srandmemberAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) long count, GloopExecutionContext context)
Asynchronously get one or multiple random members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keycount
- the count type: long- Returns:
- set<V> bulk-string-reply without the additional
count
argument the command returns a bulk reply with the randomly selected element, or null whenkey
does not exist.
-
srandmemberAsync
@GloopParameter(name="redisFutureSrandmemberOutput") public static Future<Long> srandmemberAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) long count, GloopExecutionContext context)
Asynchronously get one or multiple random members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keycount
- the count- Returns:
- long count of members of the resulting set.
-
srem
@GloopParameter(name="redisSremOutput") public static Long srem(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... members)
Remove one or more members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keymembers
- the member type: value- Returns:
- Long integer-reply the number of members that were removed from the set, not including non existing members.
-
sremAsync
@GloopParameter(name="redisFutureSremOutput") public static Future<Long> sremAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... members)
Asynchronously remove one or more members from a set.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keymembers
- the member type: value- Returns:
- long integer-reply the number of members that were removed from the set, not including non existing members.
-
sunion
@GloopParameter(name="redisSunionOutput") public static Set<Object> sunion(@GloopParameter(allowNull=false) String connectionName, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Add multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekeys
- the key- Returns:
- Set<V> array-reply list with members of the resulting set.
-
sunion
@GloopParameter(name="redisSunionOutput") public static Long sunion(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Add multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekeys
- the keys- Returns:
- Long count of members of the resulting set.
-
sunionAsync
@GloopParameter(name="redisFutureSunionOutput") public static Future<Set<Object>> sunionAsync(@GloopParameter(allowNull=false) String connectionName, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously add multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekeys
- the key- Returns:
- set<V> array-reply list with members of the resulting set.
-
sunionAsync
@GloopParameter(name="redisFutureSunionOutput") public static Future<Long> sunionAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously add multiple sets.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekeys
- the keys- Returns:
- long count of members of the resulting set.
-
sunionstore
@GloopParameter(name="redisSunionstoreOutput") public static Long sunionstore(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object destination, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Add multiple sets and store the resulting set in a key.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namedestination
- the destination type: keykeys
- the key- Returns:
- Long integer-reply the number of elements in the resulting set.
-
sunionstoreAsync
@GloopParameter(name="redisFutureSunionstoreOutput") public static Future<Long> sunionstoreAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object destination, GloopExecutionContext context, @GloopParameter(allowNull=false) Object... keys)
Asynchronously add multiple sets and store the resulting set in a key.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namedestination
- the destination type: keykeys
- the key- Returns:
- long integer-reply the number of elements in the resulting set.
-
sscan
@GloopParameter(name="redisSscanOutput") public static ValueScanCursor<Object> sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- ValueScanCursor<V> scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static ValueScanCursor<Object> sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keyscanArgs
- scan arguments- Returns:
- ValueScanCursor<V> scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static ValueScanCursor<Object> sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be nullscanArgs
- scan arguments- Returns:
- ValueScanCursor<V> scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static ValueScanCursor<Object> sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be null- Returns:
- ValueScanCursor<V> scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static StreamScanCursor sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the key- Returns:
- StreamScanCursor scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static StreamScanCursor sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keyscanArgs
- scan arguments- Returns:
- StreamScanCursor scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static StreamScanCursor sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be nullscanArgs
- scan arguments- Returns:
- StreamScanCursor scan cursor.
-
sscan
@GloopParameter(name="redisSscanOutput") public static StreamScanCursor sscan(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, GloopExecutionContext context)
Incrementally iterate Set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be null- Returns:
- StreamScanCursor scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<ValueScanCursor<Object>> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the key- Returns:
- valueScanCursor<V> scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<ValueScanCursor<Object>> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keyscanArgs
- scan arguments- Returns:
- valueScanCursor<V> scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<ValueScanCursor<Object>> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be nullscanArgs
- scan arguments- Returns:
- valueScanCursor<V> scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<ValueScanCursor<Object>> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be null- Returns:
- valueScanCursor<V> scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<StreamScanCursor> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the key- Returns:
- streamScanCursor scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<StreamScanCursor> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keyscanArgs
- scan arguments- Returns:
- streamScanCursor scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<StreamScanCursor> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, @GloopObjectParameter("scanArgs{\n limit:long:Limit the scan by count:false\n match::Set the match filter:false\n}\n") GloopModel scanArgs, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be nullscanArgs
- scan arguments- Returns:
- streamScanCursor scan cursor.
-
sscanAsync
@GloopParameter(name="redisFutureSscanOutput") public static Future<StreamScanCursor> sscanAsync(@GloopParameter(allowNull=false) String connectionName, @GloopParameter(allowNull=false) ValueStreamingChannel<Object> channel, @GloopParameter(allowNull=false) Object key, @GloopParameter(allowNull=false) ScanCursor scanCursor, GloopExecutionContext context)
Asynchronously incrementally iterate set elements.- Parameters:
connectionName
- The Martini Runtime Redis connection pool namechannel
- streaming channel that receives a call for every valuekey
- the keyscanCursor
- cursor to resume from a previous scan, must not be null- Returns:
- streamScanCursor scan cursor.
-
-