Package org.redisson.api
Interface RBlockingDequeRx<V>
-
- Type Parameters:
V
- the type of elements held in this collection
- All Superinterfaces:
RBlockingQueueRx<V>
,RCollectionRx<V>
,RDequeRx<V>
,RExpirableRx
,RObjectRx
,RQueueRx<V>
public interface RBlockingDequeRx<V> extends RDequeRx<V>, RBlockingQueueRx<V>
RxJava2 interface for Redis based BlockingDeque object- Author:
- Nikita Koksharov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description io.reactivex.rxjava3.core.Maybe<V>
pollFirst(long timeout, TimeUnit unit)
Retrieves and removes value at the head of queue.io.reactivex.rxjava3.core.Maybe<V>
pollFirstFromAny(long timeout, TimeUnit unit, String... queueNames)
Retrieves and removes first available head element of any queue in reactive mode, waiting up to the specified wait time if necessary for an element to become available in any of defined queues including queue own.io.reactivex.rxjava3.core.Maybe<V>
pollLast(long timeout, TimeUnit unit)
Retrieves and removes value at the tail of queue.io.reactivex.rxjava3.core.Maybe<V>
pollLastFromAny(long timeout, TimeUnit unit, String... queueNames)
Retrieves and removes first available tail element of any queue in reactive mode, waiting up to the specified wait time if necessary for an element to become available in any of defined queues including queue own.io.reactivex.rxjava3.core.Completable
putFirst(V e)
Adds value to the head of queue.io.reactivex.rxjava3.core.Completable
putLast(V e)
Adds value to the tail of queue.io.reactivex.rxjava3.core.Single<V>
takeFirst()
Retrieves and removes value at the head of queue.io.reactivex.rxjava3.core.Flowable<V>
takeFirstElements()
Retrieves and removes continues stream of elements from the head of this queue.io.reactivex.rxjava3.core.Single<V>
takeLast()
Retrieves and removes value at the tail of queue.io.reactivex.rxjava3.core.Flowable<V>
takeLastElements()
Retrieves and removes continues stream of elements from the tail of this queue.-
Methods inherited from interface org.redisson.api.RBlockingQueueRx
drainTo, drainTo, poll, pollFromAny, pollLastAndOfferFirstTo, put, take, takeElements, takeLastAndOfferFirstTo
-
Methods inherited from interface org.redisson.api.RCollectionRx
add, addAll, addAll, contains, containsAll, iterator, remove, removeAll, retainAll, size
-
Methods inherited from interface org.redisson.api.RDequeRx
addFirst, addFirstIfExists, addLast, addLastIfExists, descendingIterator, getLast, move, offerFirst, offerLast, peekFirst, peekLast, pollFirst, pollFirst, pollLast, pollLast, pop, push, removeFirst, removeFirstOccurrence, removeLast, removeLastOccurrence
-
Methods inherited from interface org.redisson.api.RExpirableRx
clearExpire, expire, expireAt, expireAt, expireAt, remainTimeToLive
-
Methods inherited from interface org.redisson.api.RObjectRx
addListener, copy, delete, dump, getCodec, getIdleTime, getName, isExists, migrate, move, removeListener, rename, renamenx, restore, restore, restoreAndReplace, restoreAndReplace, sizeInMemory, touch, unlink
-
-
-
-
Method Detail
-
pollFirstFromAny
io.reactivex.rxjava3.core.Maybe<V> pollFirstFromAny(long timeout, TimeUnit unit, String... queueNames)
Retrieves and removes first available head element of any queue in reactive mode, waiting up to the specified wait time if necessary for an element to become available in any of defined queues including queue own.- Parameters:
queueNames
- - names of queuetimeout
- how long to wait before giving up, in units ofunit
unit
- aTimeUnit
determining how to interpret thetimeout
parameter- Returns:
- the head of this queue, or
null
if the specified waiting time elapses before an element is available
-
pollLastFromAny
io.reactivex.rxjava3.core.Maybe<V> pollLastFromAny(long timeout, TimeUnit unit, String... queueNames)
Retrieves and removes first available tail element of any queue in reactive mode, waiting up to the specified wait time if necessary for an element to become available in any of defined queues including queue own.- Parameters:
queueNames
- - names of queuetimeout
- how long to wait before giving up, in units ofunit
unit
- aTimeUnit
determining how to interpret thetimeout
parameter- Returns:
- the head of this queue, or
null
if the specified waiting time elapses before an element is available
-
putFirst
io.reactivex.rxjava3.core.Completable putFirst(V e)
Adds value to the head of queue.- Parameters:
e
- value- Returns:
- void
-
putLast
io.reactivex.rxjava3.core.Completable putLast(V e)
Adds value to the tail of queue.- Parameters:
e
- value- Returns:
- void
-
pollLast
io.reactivex.rxjava3.core.Maybe<V> pollLast(long timeout, TimeUnit unit)
Retrieves and removes value at the tail of queue. If necessary waits up to definedtimeout
for an element become available.- Parameters:
timeout
- how long to wait before giving up, in units ofunit
unit
- aTimeUnit
determining how to interpret thetimeout
parameter- Returns:
- the element at the head of this queue, or
null
if the specified waiting time elapses before an element is available
-
takeLast
io.reactivex.rxjava3.core.Single<V> takeLast()
Retrieves and removes value at the tail of queue. Waits for an element become available.- Returns:
- the tail element of this queue
-
pollFirst
io.reactivex.rxjava3.core.Maybe<V> pollFirst(long timeout, TimeUnit unit)
Retrieves and removes value at the head of queue. If necessary waits up to definedtimeout
for an element become available.- Parameters:
timeout
- how long to wait before giving up, in units ofunit
unit
- aTimeUnit
determining how to interpret thetimeout
parameter- Returns:
- the element at the tail of this queue, or
null
if the specified waiting time elapses before an element is available
-
takeFirst
io.reactivex.rxjava3.core.Single<V> takeFirst()
Retrieves and removes value at the head of queue. Waits for an element become available.- Returns:
- the head element of this queue
-
takeFirstElements
io.reactivex.rxjava3.core.Flowable<V> takeFirstElements()
Retrieves and removes continues stream of elements from the head of this queue. Waits for next element become available.- Returns:
- stream of head elements
-
takeLastElements
io.reactivex.rxjava3.core.Flowable<V> takeLastElements()
Retrieves and removes continues stream of elements from the tail of this queue. Waits for next element become available.- Returns:
- stream of tail elements
-
-