|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.apache.axis.components.threadpool.ThreadPool
Field Summary | |
boolean |
_shutdown
|
static long |
MAX_THREADS
|
protected long |
threadcount
|
protected Map |
threads
|
Constructor Summary | |
ThreadPool()
|
Method Summary | |
void |
addWorker(Runnable worker)
Adds a new worker to the pool |
void |
awaitShutdown()
Await shutdown of the worker |
boolean |
awaitShutdown(long timeout)
Await shutdown of the worker |
void |
cleanup()
|
long |
getWorkerCount()
Returns the total number of currently active workers |
void |
interruptAll()
Forcefully interrupt all workers |
boolean |
isShutdown()
Returns true if all workers have been shutdown |
boolean |
isShuttingDown()
Returns true if all workers are in the process of shutting down |
void |
safeShutdown()
Forcefully shutdown the pool |
void |
shutdown()
Forcefully shutdown the pool |
void |
workerDone(Runnable worker,
boolean restart)
Used by MessageWorkers to notify the pool that it is done |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final long MAX_THREADS
protected Map threads
protected long threadcount
public boolean _shutdown
Constructor Detail |
public ThreadPool()
Method Detail |
public void cleanup() throws InterruptedException
InterruptedException
public boolean isShutdown()
public boolean isShuttingDown()
public long getWorkerCount()
public void addWorker(Runnable worker)
public void interruptAll()
public void shutdown()
public void safeShutdown()
public void awaitShutdown() throws InterruptedException
InterruptedException
public boolean awaitShutdown(long timeout) throws InterruptedException
InterruptedException
public void workerDone(Runnable worker, boolean restart)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |