Interface RLexSortedSet

  • All Superinterfaces:
    <>, <>, >, >, <>, <>
    All Known Implementing Classes:
    RedissonLexSortedSet

    public interface RLexSortedSet
    extends >, RExpirable
    Sorted set contained values of String type
    Author:
    Nikita Koksharov
    • Method Detail

      • pollFirst

         pollFirst()
        Removes and returns the head element or null if this sorted set is empty.
        Returns:
        the head element, or null if this sorted set is empty
      • pollLast

         pollLast()
        Removes and returns the tail element or null if this sorted set is empty.
        Returns:
        the tail element or null if this sorted set is empty
      • revRank

         revRank​( o)
        Returns rank of value, with the scores ordered from high to low.
        Parameters:
        o - - object
        Returns:
        rank or null if value does not exist
      • removeRangeTail

        int removeRangeTail​( fromElement,
                            boolean fromInclusive)
        Removes tail values range starting with fromElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        Returns:
        number of elements removed
      • removeRangeHead

        int removeRangeHead​( toElement,
                            boolean toInclusive)
        Removes head values range ending with toElement.
        Parameters:
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        number of elements removed
      • removeRange

        int removeRange​( fromElement,
                        boolean fromInclusive,
                         toElement,
                        boolean toInclusive)
        Removes values range starting with fromElement and ending with toElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        number of elements removed
      • countTail

        int countTail​( fromElement,
                      boolean fromInclusive)
        Returns the number of tail values starting with fromElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        Returns:
        number of elements
      • countHead

        int countHead​( toElement,
                      boolean toInclusive)
        Returns the number of head values ending with toElement.
        Parameters:
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        number of elements
      • rangeTail

        <> rangeTail​( fromElement,
                                     boolean fromInclusive)
        Returns tail values range starting with fromElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        Returns:
        collection of elements
      • rangeHead

        <> rangeHead​( toElement,
                                     boolean toInclusive)
        Returns head values range ending with toElement.
        Parameters:
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        collection of elements
      • range

        <> range​( fromElement,
                                 boolean fromInclusive,
                                  toElement,
                                 boolean toInclusive)
        Returns values range starting with fromElement and ending with toElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        collection of elements
      • rangeTail

        <> rangeTail​( fromElement,
                                     boolean fromInclusive,
                                     int offset,
                                     int count)
        Returns tail values range starting with fromElement. Returned collection limited by count and starts with offset.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        offset - - offset of result collection
        count - - amount of result collection
        Returns:
        collection of elements
      • rangeHead

        <> rangeHead​( toElement,
                                     boolean toInclusive,
                                     int offset,
                                     int count)
        Returns head values range ending with toElement. Returned collection limited by count and starts with offset.
        Parameters:
        toElement - - end element
        toInclusive - - end element inclusive
        offset - - offset of result collection
        count - - amount of result collection
        Returns:
        collection of elements
      • range

        <> range​( fromElement,
                                 boolean fromInclusive,
                                  toElement,
                                 boolean toInclusive,
                                 int offset,
                                 int count)
        Returns values range starting with fromElement and ending with toElement. Returned collection limited by count and starts with offset.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        toElement - - end element
        toInclusive - - end element inclusive
        offset - - offset of result collection
        count - - amount of result collection
        Returns:
        collection of elements
      • rangeTailReversed

        <> rangeTailReversed​( fromElement,
                                             boolean fromInclusive)
        Returns tail values range in reverse order starting with fromElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        Returns:
        collection of elements
      • rangeHeadReversed

        <> rangeHeadReversed​( toElement,
                                             boolean toInclusive)
        Returns head values range in reverse order ending with toElement.
        Parameters:
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        collection of elements
      • rangeReversed

        <> rangeReversed​( fromElement,
                                         boolean fromInclusive,
                                          toElement,
                                         boolean toInclusive)
        Returns values range in reverse order starting with fromElement and ending with toElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        collection of elements
      • rangeTailReversed

        <> rangeTailReversed​( fromElement,
                                             boolean fromInclusive,
                                             int offset,
                                             int count)
        Returns tail values range in reverse order starting with fromElement. Returned collection limited by count and starts with offset.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        offset - - offset of result collection
        count - - amount of result collection
        Returns:
        collection of elements
      • rangeHeadReversed

        <> rangeHeadReversed​( toElement,
                                             boolean toInclusive,
                                             int offset,
                                             int count)
        Returns head values range in reverse order ending with toElement. Returned collection limited by count and starts with offset.
        Parameters:
        toElement - - end element
        toInclusive - - end element inclusive
        offset - - offset of result collection
        count - - amount of result collection
        Returns:
        collection of elements
      • rangeReversed

        <> rangeReversed​( fromElement,
                                         boolean fromInclusive,
                                          toElement,
                                         boolean toInclusive,
                                         int offset,
                                         int count)
        Returns values range in reverse order starting with fromElement and ending with toElement. Returned collection limited by count and starts with offset.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        toElement - - end element
        toInclusive - - end element inclusive
        offset - - offset of result collection
        count - - amount of result collection
        Returns:
        collection of elements
      • count

        int count​( fromElement,
                  boolean fromInclusive,
                   toElement,
                  boolean toInclusive)
        Returns the number of elements between fromElement and toElement.
        Parameters:
        fromElement - - start element
        fromInclusive - - start element inclusive
        toElement - - end element
        toInclusive - - end element inclusive
        Returns:
        number of elements
      • rank

         rank​( o)
        Returns rank of the element
        Parameters:
        o - - element to rank
        Returns:
        rank or null if element does not exist
      • range

        <> range​(int startIndex,
                                 int endIndex)
        Returns values by rank range. Indexes are zero based. -1 means the highest score, -2 means the second highest score.
        Parameters:
        startIndex - - start index
        endIndex - - end index
        Returns:
        collection of elements