PriorityTask

public class PriorityTask extends Object
implements Dependency<Task> PriorityProvider Task
Known Direct Subclasses

Base class for Priority based worker Can also be used as delegate for non extensible existing classes, such as AsyncTask

Public Constructor Summary

Public Method Summary

synchronized void
boolean
areDependenciesMet()
Returns true when the dependencies have been met
int
compareTo(Object other)
synchronized Collection<Task>
getDependencies()
fulfilled before the Dependency instance.
Throwable
Priority
boolean
static boolean
isProperDelegate(Object object)
void
setError(Throwable throwable)
synchronized void
setFinished(boolean finished)
Marks Task as finished

Inherited Method Summary

Public Constructors

public PriorityTask ()

Public Methods

public synchronized void addDependency (Task task)

Parameters
task

public boolean areDependenciesMet ()

Returns true when the dependencies have been met

public int compareTo (Object other)

Parameters
other

public synchronized Collection<Task> getDependencies ()

fulfilled before the Dependency instance.

Returns
  • Collection of T to be fulfilled before the Dependency instance.

public Throwable getError ()

public Priority getPriority ()

public boolean isFinished ()

public static boolean isProperDelegate (Object object)

Parameters
object

public void setError (Throwable throwable)

Parameters
throwable

public synchronized void setFinished (boolean finished)

Marks Task as finished

Parameters
finished