Package org.redisson.api
Interface RCollectionReactive<V>
-
- Type Parameters:
V- value
- All Superinterfaces:
RExpirableReactive,RObjectReactive
- All Known Subinterfaces:
RBlockingDequeReactive<V>,RBlockingQueueReactive<V>,RDequeReactive<V>,RLexSortedSetReactive,RListReactive<V>,RQueueReactive<V>,RRingBufferReactive<V>,RSetCacheReactive<V>,RSetReactive<V>,RTransferQueueReactive<V>
public interface RCollectionReactive<V> extends RExpirableReactive
Common reactive interface for collection object- Author:
- Nikita Koksharov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description reactor.core.publisher.Mono<Boolean>add(V e)Adds element into this collection.reactor.core.publisher.Mono<Boolean>addAll(Collection<? extends V> c)Adds all elements contained in the specified collectionreactor.core.publisher.Mono<Boolean>addAll(org.reactivestreams.Publisher<? extends V> c)Adds all elements contained in the specified collectionreactor.core.publisher.Mono<Boolean>contains(V o)Returnstrueif this collection contains encoded state of the specified element.reactor.core.publisher.Mono<Boolean>containsAll(Collection<?> c)Returnstrueif this collection contains all of the elements in the specified collection.reactor.core.publisher.Flux<V>iterator()Returns iterator over collection elementsreactor.core.publisher.Mono<Boolean>remove(V o)Removes a single instance of the specified element from this collection, if it is present (optional operation).reactor.core.publisher.Mono<Boolean>removeAll(Collection<?> c)Removes all of this collection's elements that are also contained in the specified collection (optional operation).reactor.core.publisher.Mono<Boolean>retainAll(Collection<?> c)Retains only the elements in this collection that are contained in the specified collection (optional operation).reactor.core.publisher.Mono<Integer>size()Returns number of elements in this collection.-
Methods inherited from interface org.redisson.api.RExpirableReactive
clearExpire, expire, expireAt, expireAt, expireAt, remainTimeToLive
-
Methods inherited from interface org.redisson.api.RObjectReactive
addListener, copy, delete, dump, getCodec, getIdleTime, getName, isExists, migrate, move, removeListener, rename, renamenx, restore, restore, restoreAndReplace, restoreAndReplace, sizeInMemory, touch, unlink
-
-
-
-
Method Detail
-
iterator
reactor.core.publisher.Flux<V> iterator()
Returns iterator over collection elements- Returns:
- iterator
-
retainAll
reactor.core.publisher.Mono<Boolean> retainAll(Collection<?> c)
Retains only the elements in this collection that are contained in the specified collection (optional operation).- Parameters:
c- collection containing elements to be retained in this collection- Returns:
trueif this collection changed as a result of the call
-
removeAll
reactor.core.publisher.Mono<Boolean> removeAll(Collection<?> c)
Removes all of this collection's elements that are also contained in the specified collection (optional operation).- Parameters:
c- collection containing elements to be removed from this collection- Returns:
trueif this collection changed as a result of the call
-
contains
reactor.core.publisher.Mono<Boolean> contains(V o)
Returnstrueif this collection contains encoded state of the specified element.- Parameters:
o- element whose presence in this collection is to be tested- Returns:
trueif this collection contains the specified element andfalseotherwise
-
containsAll
reactor.core.publisher.Mono<Boolean> containsAll(Collection<?> c)
Returnstrueif this collection contains all of the elements in the specified collection.- Parameters:
c- collection to be checked for containment in this collection- Returns:
trueif this collection contains all of the elements in the specified collection
-
remove
reactor.core.publisher.Mono<Boolean> remove(V o)
Removes a single instance of the specified element from this collection, if it is present (optional operation).- Parameters:
o- element to be removed from this collection, if present- Returns:
trueif an element was removed as a result of this call
-
size
reactor.core.publisher.Mono<Integer> size()
Returns number of elements in this collection.- Returns:
- size of collection
-
add
reactor.core.publisher.Mono<Boolean> add(V e)
Adds element into this collection.- Parameters:
e- - element to add- Returns:
trueif an element was added andfalseif it is already present
-
addAll
reactor.core.publisher.Mono<Boolean> addAll(org.reactivestreams.Publisher<? extends V> c)
Adds all elements contained in the specified collection- Parameters:
c- - collection of elements to add- Returns:
trueif at least one element was added andfalseif all elements are already present
-
addAll
reactor.core.publisher.Mono<Boolean> addAll(Collection<? extends V> c)
Adds all elements contained in the specified collection- Parameters:
c- - collection of elements to add- Returns:
trueif at least one element was added andfalseif all elements are already present
-
-