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.

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.

Method Detail

actionPerformed

Here the control of the InterruptibleNodeModel is done. Either from the
menu or the buttons coming events to control the InterruptibleNodeModel
are processed here. Basically these events are "run", "break" and
"finish".

getControlPanel

This method returns the control panel, which provides control elements
over the underlying model. It also realizes a lazy initialization of the
control panel.

Returns:

- the controlPanel which itself provides getters to its
components.

refreshInterruptMenu

public void refreshInterruptMenu()

Refreshes the enabled status of the control elements depending on the
status of the underlying model. It makes no sense to have an enabled
"Break"-Button, when the status is paused, and so on. Call it whenever
the status of the underlying method changes without the influence of the
control elements in order to set their right status again.

onClose

public void onClose()

Forces the model to pause and then to finish. Since it makes no sense to
let the model run without watching at it.
Invoked when the window is about to be closed. Unregister
HiLiteListeners. Dispose internal members.
This method is the first to be called on a close request (right after
the view is unregistered from the NodeModel

updateModel

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. 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.

modelChanged

public abstract void modelChanged()

Implement here all the view updating methods. This method is called
whenever the underlying model triggers a refresh (that is every delay-th
iteration).
Method is invoked when the underlying NodeModel has
changed. Also the HiLightHandler have changed. Note, the
NodeModel content may be not available. The framework
calls this method in the EventDispatchThread (GUI updates can be done
directly in the calling thread).

Copyright, 2003 - 2016. All rights reserved.KNIME GmbH, Konstanz, GermanyYou may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.