Module org.apache.lucene.core
Package org.apache.lucene.index
Class LockableConcurrentApproximatePriorityQueue<T extends Lock>
java.lang.Object
org.apache.lucene.index.LockableConcurrentApproximatePriorityQueue<T>
A
ConcurrentApproximatePriorityQueue of Lock objects.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AtomicIntegerprivate final ConcurrentApproximatePriorityQueue<T> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) voidaddAndUnlock(T entry, long weight) Add an entry to the queue and unlock it, in that order.(package private) boolean(package private) TLock an entry, and poll it from the queue, in that order.(package private) booleanRemove an entry from the queue.
-
Field Details
-
queue
-
addAndUnlockCounter
-
-
Constructor Details
-
LockableConcurrentApproximatePriorityQueue
LockableConcurrentApproximatePriorityQueue(int concurrency) -
LockableConcurrentApproximatePriorityQueue
LockableConcurrentApproximatePriorityQueue()
-
-
Method Details
-
lockAndPoll
T lockAndPoll()Lock an entry, and poll it from the queue, in that order. If no entry can be found and locked,nullis returned. -
remove
Remove an entry from the queue. -
contains
-
addAndUnlock
Add an entry to the queue and unlock it, in that order.
-