|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.knime.core.node.AbstractNodeView<T>
org.knime.core.node.NodeView
org.knime.core.node.interrupt.InterruptibleNodeView
public abstract class 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. Additionally, all the listener stuff is done here, that is the status of he InterruptibleNodeModel is set from here to paused or not or finished.
Field Summary |
---|
Fields inherited from class org.knime.core.node.NodeView |
---|
COLOR_BACKGROUND, PROP_CHANGE_CLOSE |
Constructor Summary | |
---|---|
InterruptibleNodeView(InterruptibleNodeModel model)
Constructs an instance of the InterruptibleNodeView with the underlying InterruptibleNodeModel and a title. |
|
InterruptibleNodeView(InterruptibleNodeModel model,
JPanel innerView)
Creates an instance of the interruptible node view with the control elements and a specific additional panel. |
Method Summary | |
---|---|
void |
actionPerformed(ActionEvent e)
Here the control of the InterruptibleNodeModel is done. |
InterruptControlPanel |
getControlPanel()
This method returns the control panel, which provides control elements over the underlying model. |
abstract void |
modelChanged()
Implement here all the view updating methods. |
void |
onClose()
Forces the model to pause and then to finish. |
protected void |
onOpen()
Invoked when the window has been opened. |
void |
refreshInterruptMenu()
Refreshes the enabled status of the control elements depending on the status of the underlying model. |
void |
setEmbeddedComponent(Component toBeSet)
Guarantees that the control panel is always added at the very top of the view. |
void |
updateModel(Object model)
The updateModel(Object model) method is invoked whenever
the NodeModel.notifyViews(Object) method was called and
the NodeView.modelChanged() method is only called when
execution is finished but is the default method to implement the
visualization of the NodeModel. |
Methods inherited from class org.knime.core.node.NodeView |
---|
callCloseView, closeView, createFrame, getComponent, getJMenuBar, getViewTitle, isOpen, openViewComponent, setComponent, setShowNODATALabel, setViewTitleSuffix, warningChanged |
Methods inherited from class org.knime.core.node.AbstractNodeView |
---|
getLogger, getNodeModel |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public InterruptibleNodeView(InterruptibleNodeModel model)
model
- - the underlying InterruptibleNodeModel.public InterruptibleNodeView(InterruptibleNodeModel model, JPanel innerView)
model
- - the underlying interruptible model.innerView
- - an additional view of the model.Method Detail |
---|
public void actionPerformed(ActionEvent e)
actionPerformed
in interface ActionListener
public InterruptControlPanel getControlPanel()
public void refreshInterruptMenu()
public void onClose()
HiLiteListeners
. Dispose internal members. NodeModel
onClose
in class NodeView
protected void onOpen()
onOpen
in class NodeView
public void setEmbeddedComponent(Component toBeSet)
toBeSet
- the panel to be set below the control panel, mind that
all view components necessary for the underlying model have to
be packed in one componentpublic void updateModel(Object model)
updateModel(Object model)
method is invoked whenever
the NodeModel.notifyViews(Object)
method was called and
the NodeView.modelChanged()
method is only called when
execution is finished but is the default method to implement the
visualization of the NodeModel. Therefore this method simply invokes the
NodeView.modelChanged()
method.
This method can be overridden by views that want to receive
events from their assigned models via the
NodeModel.notifyViews(Object)
method. Can be used to
iteratively update the view during execute.
updateModel
in class AbstractNodeView
model
- The argument that is provided in the
notifyViews method.public abstract void modelChanged()
NodeModel
has
changed. Also the HiLightHandler have changed. Note, the
NodeModel
content may be not available. Be sure to
modify GUI components in the EventDispatchThread only.
modelChanged
in class AbstractNodeView
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |