public class OrderedTaskQueue extends Thread
Thread.State, Thread.UncaughtExceptionHandlerMAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY| Modifier and Type | Method and Description |
|---|---|
long |
getAvQueue()
Getter for average time waiting
|
long |
getAvRun()
Getter for average time running
|
static OrderedTaskQueue |
getCreateQueue(String name)
grab the queue
|
int |
getDone()
number of already completed tasks
|
long |
getSumQueue()
Getter for sumQueue attribute.
|
long |
getSumRun()
Getter for sumRun attribute.
|
boolean |
interruptCurrent(int minAge) |
boolean |
queue(Runnable task) |
void |
run() |
void |
shutDown() |
static void |
shutDownAll() |
int |
size()
size of the waiting queue
|
String |
toString() |
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, yieldpublic static OrderedTaskQueue getCreateQueue(String name)
name - - must not be nullpublic static void shutDownAll()
public void shutDown()
public boolean interruptCurrent(int minAge)
minAge - minimum age to interruptpublic int size()
public int getDone()
public boolean queue(Runnable task)
task - the thing to send offpublic void run()
run in interface Runnablerun in class ThreadThread.run()public String toString()
toString in class ThreadThread.toString()public long getAvQueue()
public long getSumQueue()
public long getAvRun()
public long getSumRun()
Copyright © 2015. All rights reserved.