Package org.redisson
Class RedissonSortedSet<V>
java.lang.Object
org.redisson.RedissonObject
org.redisson.RedissonSortedSet<V>
- Type Parameters:
V- value type
- All Implemented Interfaces:
Iterable<V>,Collection<V>,Set<V>,SortedSet<V>,RObject,RObjectAsync,RSortedSet<V>
- Author:
- Nikita Koksharov
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class org.redisson.RedissonObject
codec, name -
Constructor Summary
ConstructorsModifierConstructorDescriptionRedissonSortedSet(Codec codec, CommandAsyncExecutor commandExecutor, String name, Redisson redisson) protectedRedissonSortedSet(CommandAsyncExecutor commandExecutor, String name, RedissonClient redisson) -
Method Summary
Modifier and TypeMethodDescriptionbooleanbooleanaddAll(Collection<? extends V> c) binarySearch(V value, Codec codec) voidclear()Comparator<? super V>booleanbooleancontainsAll(Collection<?> c) distributedIterator(int count) Returns element iterator that can be shared across multiple applications.distributedIterator(String iteratorName, int count) Returns iterator over elements that match specified pattern.first()booleanisEmpty()iterator()last()<KOut,VOut>
RCollectionMapReduce<V,KOut, VOut> ReturnsRMapReduceobject associated with this objectreadAll()booleanbooleanremoveAll(Collection<?> c) removeAsync(Object value) booleanretainAll(Collection<?> c) intsize()Object[]toArray()<T> T[]toArray(T[] a) toString()booleantrySetComparator(Comparator<? super V> comparator) Sets new comparator only if current set is emptyMethods inherited from class org.redisson.RedissonObject
addListener, addListener, addListenerAsync, addListenerAsync, copy, copyAsync, delete, deleteAsync, deleteAsync, dump, dumpAsync, encode, encode, encode, encode, encodeMapKey, encodeMapKey, encodeMapKeys, encodeMapValue, encodeMapValues, get, getCodec, getIdleTime, getIdleTimeAsync, getLockByMapKey, getLockByValue, getName, getRawName, getRawName, isExists, isExistsAsync, migrate, migrateAsync, move, moveAsync, prefixName, removeListener, removeListenerAsync, rename, renameAsync, renamenx, renamenxAsync, restore, restore, restoreAndReplace, restoreAndReplace, restoreAndReplaceAsync, restoreAndReplaceAsync, restoreAsync, restoreAsync, setName, sizeInMemory, sizeInMemoryAsync, sizeInMemoryAsync, sizeInMemoryAsync, suffixName, toSeconds, toStream, touch, touchAsync, unlink, unlinkAsyncMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArrayMethods inherited from interface org.redisson.api.RObject
addListener, copy, delete, dump, getCodec, getIdleTime, getName, isExists, migrate, move, removeListener, rename, renamenx, restore, restore, restoreAndReplace, restoreAndReplace, sizeInMemory, touch, unlinkMethods inherited from interface org.redisson.api.RObjectAsync
addListenerAsync, copyAsync, deleteAsync, dumpAsync, getIdleTimeAsync, isExistsAsync, migrateAsync, moveAsync, removeListenerAsync, renameAsync, renamenxAsync, restoreAndReplaceAsync, restoreAndReplaceAsync, restoreAsync, restoreAsync, sizeInMemoryAsync, touchAsync, unlinkAsyncMethods inherited from interface java.util.SortedSet
spliterator
-
Constructor Details
-
RedissonSortedSet
protected RedissonSortedSet(CommandAsyncExecutor commandExecutor, String name, RedissonClient redisson) -
RedissonSortedSet
public RedissonSortedSet(Codec codec, CommandAsyncExecutor commandExecutor, String name, Redisson redisson)
-
-
Method Details
-
mapReduce
Description copied from interface:RSortedSetReturnsRMapReduceobject associated with this object- Specified by:
mapReducein interfaceRSortedSet<V>- Type Parameters:
KOut- output keyVOut- output value- Returns:
- MapReduce instance
-
readAll
- Specified by:
readAllin interfaceRSortedSet<V>
-
readAllAsync
- Specified by:
readAllAsyncin interfaceRSortedSet<V>
-
size
public int size() -
isEmpty
public boolean isEmpty() -
contains
-
iterator
-
toArray
-
toArray
public <T> T[] toArray(T[] a) -
add
-
addAsync
- Specified by:
addAsyncin interfaceRSortedSet<V>
-
removeAsync
- Specified by:
removeAsyncin interfaceRSortedSet<V>
-
remove
-
containsAll
- Specified by:
containsAllin interfaceCollection<V>- Specified by:
containsAllin interfaceSet<V>
-
addAll
-
retainAll
-
removeAll
-
clear
public void clear() -
comparator
- Specified by:
comparatorin interfaceSortedSet<V>
-
subSet
-
headSet
-
tailSet
-
first
-
last
-
trySetComparator
Description copied from interface:RSortedSetSets new comparator only if current set is empty- Specified by:
trySetComparatorin interfaceRSortedSet<V>- Parameters:
comparator- for values- Returns:
trueif new comparator settedfalseotherwise
-
distributedIterator
Description copied from interface:RSortedSetReturns element iterator that can be shared across multiple applications. Creating multiple iterators on the same object with this method will result in a single shared iterator. See RList.distributedIterator(String, int) for creating different iterators.- Specified by:
distributedIteratorin interfaceRSortedSet<V>- Parameters:
count- batch size- Returns:
- shared elements iterator
-
distributedIterator
Description copied from interface:RSortedSetReturns iterator over elements that match specified pattern. Iterator can be shared across multiple applications. Creating multiple iterators on the same object with this method will result in a single shared iterator. Iterator name must be resolved to the same hash slot as list name.- Specified by:
distributedIteratorin interfaceRSortedSet<V>- Parameters:
iteratorName- redis object name to which cursor will be savedcount- batch size- Returns:
- shared elements iterator
-
binarySearch
-
toString
-