gov.nasa.worldwind.util
Class ThreadedTaskService
java.lang.Object
gov.nasa.worldwind.avlist.AVListImpl
gov.nasa.worldwind.WWObjectImpl
gov.nasa.worldwind.util.ThreadedTaskService
- All Implemented Interfaces:
- AVList, TaskService, WWObject, PropertyChangeListener, Thread.UncaughtExceptionHandler, EventListener
public class ThreadedTaskService
- extends WWObjectImpl
- implements TaskService, Thread.UncaughtExceptionHandler
Methods inherited from class gov.nasa.worldwind.avlist.AVListImpl |
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getDoubleValue, getDoubleValue, getEntries, getIntegerValue, getIntegerValue, getLongValue, getLongValue, getStringValue, getStringValue, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface gov.nasa.worldwind.avlist.AVList |
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getEntries, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues |
ThreadedTaskService
public ThreadedTaskService()
addTask
public void addTask(Runnable runnable)
- Enqueues a task to run.
- Specified by:
addTask
in interface TaskService
- Parameters:
runnable
- the task to add
- Throws:
IllegalArgumentException
- if runnable
is null
contains
public boolean contains(Runnable runnable)
- Specified by:
contains
in interface TaskService
hasActiveTasks
public boolean hasActiveTasks()
- Specified by:
hasActiveTasks
in interface TaskService
isFull
public boolean isFull()
- Specified by:
isFull
in interface TaskService
shutdown
public void shutdown(boolean immediately)
- Specified by:
shutdown
in interface TaskService
uncaughtException
public void uncaughtException(Thread thread,
Throwable throwable)
- Specified by:
uncaughtException
in interface Thread.UncaughtExceptionHandler