Package org.citydb.concurrent
Class WorkerPool.WorkQueue<E>
- java.lang.Object
-
- org.citydb.concurrent.WorkerPool.WorkQueue<E>
-
- Enclosing class:
- WorkerPool<T>
public static final class WorkerPool.WorkQueue<E> extends java.lang.Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
int
drainTo(java.util.Collection<? super E> collection)
boolean
isEmpty()
boolean
offer(E work)
boolean
offer(E work, long timeout, java.util.concurrent.TimeUnit unit)
E
peek()
E
poll()
E
poll(long timeout, java.util.concurrent.TimeUnit unit)
void
put(E work)
int
remainingCapacity()
boolean
remove(E work)
int
size()
E
take()
-
-
-
Method Detail
-
offer
public boolean offer(E work)
-
offer
public boolean offer(E work, long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException
- Throws:
java.lang.InterruptedException
-
put
public void put(E work)
-
poll
public E poll()
-
poll
public E poll(long timeout, java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException
- Throws:
java.lang.InterruptedException
-
take
public E take() throws java.lang.InterruptedException
- Throws:
java.lang.InterruptedException
-
peek
public E peek()
-
remove
public boolean remove(E work)
-
size
public int size()
-
remainingCapacity
public int remainingCapacity()
-
isEmpty
public boolean isEmpty()
-
clear
public void clear()
-
drainTo
public int drainTo(java.util.Collection<? super E> collection)
-
-