| |
|
| java.lang.Object java.lang.Thread net.suberic.util.thread.ActionThread
ActionThread | public class ActionThread extends Thread (Code) | | This is a Thread which handles ActionEvents. Instead of having the
Action handled by the main thread, it is put into a queue on
this thread, which will then handle the Action.
|
Inner Class :public class ActionEventPair | |
Constructor Summary | |
public | ActionThread(String threadName) Creates an ActionThread with the given threadName. |
PRIORITY_HIGH | public static int PRIORITY_HIGH(Code) | | |
PRIORITY_LOW | public static int PRIORITY_LOW(Code) | | |
PRIORITY_NORMAL | public static int PRIORITY_NORMAL(Code) | | |
ActionThread | public ActionThread(String threadName)(Code) | | Creates an ActionThread with the given threadName.
|
addToQueue | public synchronized void addToQueue(Action action, ActionEvent event)(Code) | | This adds an item to the queue. It also starts up the Thread if it's
not already running.
|
addToQueue | public synchronized void addToQueue(Action action, ActionEvent event, int priority)(Code) | | This adds an item to the queue. It also starts up the Thread if it's
not already running.
|
getCurrentActionName | public String getCurrentActionName()(Code) | | Returns the name of the current action.
|
getQueueSize | public int getQueueSize()(Code) | | Returns the queue size for this thread.
|
getRunLock | public Object getRunLock()(Code) | | Returns the run lock for this thread.
|
getStopped | public boolean getStopped()(Code) | | Returns whether or not this thread has been stopped.
|
popQueue | public synchronized ActionEventPair popQueue()(Code) | | This returns the top item in the action queue, if one is available.
If not, the method returns null.
|
setCurrentActionName | public void setCurrentActionName(String pCurrentActionName)(Code) | | Sets the name of the current action.
|
setStop | public void setStop(boolean newValue)(Code) | | Stops the ActionThread.
|
|
|
|