|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.grogra.task.Solver
public abstract class Solver
A Solver
solves a PartialTask
of a Task
. The process of solving may
be implemented asynchronously, so that multiple processors
or even remote processors can be used.
Constructor Summary | |
---|---|
Solver()
|
Method Summary | |
---|---|
abstract void |
dispose()
This method is invoked by the Task when this solver
is removed from the task. |
PartialTask |
getCurrentPartialTask()
Returns the partial task which is currently solved by this solver. |
Task |
getTask()
Returns the complete task for which this solver is used. |
void |
initialize(Task task)
Initializes this solver to be used for the given task. |
protected abstract void |
solve()
This method has to be implemented by subclasses in order to solve the current partial task synchronously or asynchronously. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Solver()
Method Detail |
---|
public abstract void dispose()
Task
when this solver
is removed from the task. Subclasses have to implement this method
in order to free resources (e.g., created threads).
public final PartialTask getCurrentPartialTask()
null
if the solver has nothing
to do.
public Task getTask()
public void initialize(Task task)
task
- the complete task for which this solver is usedprotected abstract void solve()
Task.partialTaskDone(Solver)
has to be invoked.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |