|
||||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
See:
Description
Class Summary | |
---|---|
InterruptControlPanel | A simple control panel holding the control elements necessary to control the InterruptibleNodeModel, that is a "Run"-, "Break"- and "Finish"-Button and a slider to adjust the delay. |
InterruptibleNodeModel | This class provides a generic implementation of a node that can be stopped and resumed during execution. |
InterruptibleNodeView | This class provides a generic view for the InterruptibleNodeModel and all deriving classes, which basically consists in a control panel, with some control elements such as a "Run"-, a "Break"- and a "Finish"-Button and a slider to adjust the delay. |
LayoutHelper | A helper class for the use of the GridBagLayout. |
This package contains the necessary classes for an interruptible framework.
The InterruptibleNodeModel
consists of three abstract methods:
init(DataTable[] input)
executeOneIteration()
DataTable[] getOutput()
init m(DataTable[])
method is called. The model starts with paused = true
.
When this is set to paused = false
the
executeOneIteration
method is called until the model is set to the
paused state again. In this way the model could be run and paused arbitrary often.
When the model is set to finish()
the
getOutput()
method is called and the result is provided at the out-port
and the model is executed and must be reset for a new run.
for-
or while-
loop.
Then the content of this loop has to be put into executeOneIteration
method.
InterruptibleNodeView
is also provided, with
some default control elements always on top. These control elements are contained
in the InterruptControlPanel
. They are a play, break and finish and
a next step button and a slider to adjust the delay how often the
InterruptibleNodeView
is refreshed.
|
||||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |