Trait

scredis.commands

SetCommands

Related Doc: package commands

Permalink

trait SetCommands extends AnyRef

This trait implements set commands.

Self Type
SetCommands with NonBlockingConnection
Linear Supertypes
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. SetCommands
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  8. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  9. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  10. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  11. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  12. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  13. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  14. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  15. def sAdd[W](key: String, members: W*)(implicit arg0: Writer[W]): Future[Long]

    Permalink

    Adds one or more members to a set.

    Adds one or more members to a set.

    key

    set key

    members

    member(s) to add

    returns

    the number of members added to the set, not including all the members that were already present

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

  16. def sCard(key: String): Future[Long]

    Permalink

    Returns the number of members in a set.

    Returns the number of members in a set.

    key

    set key

    returns

    the cardinality (number of members) of the set, or 0 if key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

  17. def sDiff[R](key: String, keys: String*)(implicit arg0: Reader[R]): Future[Set[R]]

    Permalink

    Returns the set resulting from the difference between the first set and all the successive sets.

    Returns the set resulting from the difference between the first set and all the successive sets.

    key

    the key of the first set

    keys

    key(s) of successive set(s) whose members will be substracted from the first one

    returns

    the resulting set, or the empty set if the first key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if some keys contain a value that is not a set

  18. def sDiffStore(destKey: String, key: String, keys: String*): Future[Long]

    Permalink

    Stores the set resulting from the difference between the first set and all the successive sets.

    Stores the set resulting from the difference between the first set and all the successive sets.

    destKey

    key where to store the resulting set

    key

    key of first set

    keys

    keys of sets to be substracted from first set, if empty, first set is simply copied to destKey

    returns

    the cardinality of the resulting set

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if some keys contain a value that is not a set

    Note

    If destKey already exists, it is overwritten.

  19. def sInter[R](keys: String*)(implicit arg0: Reader[R]): Future[Set[R]]

    Permalink

    Intersects multiple sets.

    Intersects multiple sets.

    keys

    keys of sets to be intersected together

    returns

    the resulting set, or the empty set if the first key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if some keys contain a value that is not a set

  20. def sInterStore(destKey: String, keys: String*): Future[Long]

    Permalink

    Intersects multiple sets and stores the resulting set in a key.

    Intersects multiple sets and stores the resulting set in a key.

    destKey

    key where to store the resulting set

    keys

    keys of sets to be intersected together, if only one is specified, it is simply copied to destKey

    returns

    the cardinality of the resulting set

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if some keys contain a value that is not a set

    Note

    If destKey already exists, it is overwritten.

  21. def sIsMember[W](key: String, member: W)(implicit arg0: Writer[W]): Future[Boolean]

    Permalink

    Determines if a given value is a member of a set.

    Determines if a given value is a member of a set.

    key

    set key

    member

    value to be tested

    returns

    true if the provided value is a member of the set stored at key, false otherwise

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

  22. def sMembers[R](key: String)(implicit arg0: Reader[R]): Future[Set[R]]

    Permalink

    Returns all the members of a set.

    Returns all the members of a set.

    key

    set key

    returns

    set stored at key, or the empty set if key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

  23. def sMove[W](sourceKey: String, destKey: String, member: W)(implicit arg0: Writer[W]): Future[Boolean]

    Permalink

    Moves a member from one set to another.

    Moves a member from one set to another.

    sourceKey

    key of source set

    member

    value to be moved from source set to destination set

    returns

    true if the member was moved, false if the element is not a member of source set and no operation was performed

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if sourceKey or destKey contains a value that is not a set

  24. def sPop[R](key: String)(implicit arg0: Reader[R]): Future[Option[R]]

    Permalink

    Removes and returns a random member from a set.

    Removes and returns a random member from a set.

    key

    set key

    returns

    random member, or None if key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

    Note

    This operation is similar to SRANDMEMBER, that returns a random element from a set but does not remove it.

  25. def sRandMember[R](key: String)(implicit arg0: Reader[R]): Future[Option[R]]

    Permalink

    Returns a random member from a set (without removing it).

    Returns a random member from a set (without removing it).

    key

    set key

    returns

    random member, or None if key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

  26. def sRandMembers[R](key: String, count: Int = 1)(implicit arg0: Reader[R]): Future[Set[R]]

    Permalink

    Returns a random member from a set (without removing it).

    Returns a random member from a set (without removing it).

    key

    set key

    count

    number of member to randomly retrieve

    returns

    set of random members, or the empty set if key does not exist

    Since

    2.6.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

  27. def sRem[W](key: String, members: W*)(implicit arg0: Writer[W]): Future[Long]

    Permalink

    Removes one or more members from a set.

    Removes one or more members from a set.

    key

    set key

    members

    members to remove from set

    returns

    the number of members that were removed from the set, not including non-existing members

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if key contains a value that is not a set

    Note

    Redis versions older than 2.4 can only remove one member per call.

  28. def sScan[R](key: String, cursor: Long, matchOpt: Option[String] = None, countOpt: Option[Int] = None)(implicit arg0: Reader[R]): Future[(Long, Set[R])]

    Permalink

    Incrementally iterates the elements of a set.

    Incrementally iterates the elements of a set.

    cursor

    the offset

    matchOpt

    when defined, the command only returns elements matching the pattern

    countOpt

    when defined, provides a hint of how many elements should be returned

    returns

    a pair containing the next cursor as its first element and the set of elements as its second element

    Since

    2.8.0

  29. def sUnion[R](keys: String*)(implicit arg0: Reader[R]): Future[Set[R]]

    Permalink

    Computes the union of multiple sets.

    Computes the union of multiple sets.

    keys

    keys of sets to be included in the union computation

    returns

    the resulting set, or the empty set if the first key does not exist

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if some keys contain a value that is not a set

  30. def sUnionStore(destKey: String, keys: String*): Future[Long]

    Permalink

    Computes the union of multiple sets and stores the resulting set in a key.

    Computes the union of multiple sets and stores the resulting set in a key.

    destKey

    key where to store the resulting set

    keys

    keys of sets to be included in the union computation, if only one is specified, it is simply copied to destKey

    returns

    the cardinality of the resulting set

    Since

    1.0.0

    Exceptions thrown

    [[scredis.exceptions.RedisErrorResponseException]] if some keys contain a value that is not a set

    Note

    If destKey already exists, it is overwritten.

  31. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  32. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  33. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  34. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  35. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Ungrouped