final class SetCommands[K, V] extends AnyRef
Exposes the set of redis **set** commands available.
- Source
- SetCommands.scala
- See also
- Alphabetic
- By Inheritance
- SetCommands
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def sAdd(key: K, members: Iterable[V]): Task[Long]
- def sAdd(key: K, members: V*): Task[Long]
Add one or more members to a set.
Add one or more members to a set.
- returns
The number of elements that were added to the set, not including all the elements already present into the set.
- See also
SADD.
- def sCard(key: K): Task[Long]
Get the number of members in a set.
Get the number of members in a set.
- returns
The cardinality (number of elements) of the set, 0 if the key does not exist.
- See also
- def sDiff(first: K, rest: Iterable[K]): Observable[V]
- def sDiff(first: K, rest: K*): Observable[V]
Subtract the first set with all the successive sets.
Subtract the first set with all the successive sets.
- returns
A list with members of the resulting set.
- See also
- def sDiffStore(destination: K, first: K, rest: Iterable[K]): Task[Long]
- def sDiffStore(destination: K, first: K, rest: K*): Task[Long]
Subtract multiple sets and store the resulting set in a key.
Subtract multiple sets and store the resulting set in a key.
- returns
The number of elements in the resulting set.
- See also
- def sInter(keys: Iterable[K]): Observable[V]
- def sInter(keys: K*): Observable[V]
Intersect multiple sets.
- def sInterStore(destination: K, keys: Iterable[K]): Task[Long]
- def sInterStore(destination: K, keys: K*): Task[Long]
Intersect multiple sets and store the resulting set in a key.
Intersect multiple sets and store the resulting set in a key.
- returns
The number of elements in the resulting set.
- See also
- def sIsMember(key: K, member: V): Task[Boolean]
Determine if a given value is a member of a set.
Determine if a given value is a member of a set.
- returns
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.
- See also
- def sMembers(key: K): Observable[V]
Get all the members in a set.
- def sMove(source: K, destination: K, member: V): Task[Boolean]
Move a member from one set to another.
Move a member from one set to another.
- returns
True if the element is moved. False if the element is not a member of source and no operation was performed.
- See also
- def sPop(key: K, count: Long): Observable[V]
Remove and return one or multiple random members from a set.
Remove and return one or multiple random members from a set.
- returns
The removed element, or null when key does not exist.
- See also
SPOP.
- def sPop(key: K): Task[Option[V]]
Remove and return a random member from a set.
Remove and return a random member from a set.
- returns
The removed element, or
None when key does not exist.
- See also
SPOP.
- def sRandMember(key: K, count: Long): Observable[V]
Get one or multiple random members from a set.
Get one or multiple random members from a set.
- returns
The randomly selected elements.
- See also
- def sRandMember(key: K): Task[Option[V]]
Get one random member from a set.
Get one random member from a set.
- returns
The randomly selected element, if the key exists, otherwise None
- See also
- def sRem(key: K, members: Iterable[V]): Task[Long]
- def sRem(key: K, members: V*): Task[Long]
Remove one or more members from a set.
Remove one or more members from a set.
- returns
The number of members that were removed from the set, not including non existing members.
- See also
SREM.
- def sUnion(keys: Iterable[K]): Observable[V]
- def sUnion(keys: K*): Observable[V]
Add multiple sets.
- def sUnionStore(destination: K, keys: Iterable[K]): Task[Long]
- def sUnionStore(destination: K, keys: K*): Task[Long]
Add multiple sets and store the resulting set in a key.
Add multiple sets and store the resulting set in a key.
- returns
Long that represents the number of elements in the resulting set.
- See also
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()