Package fr.esrf.tangoatk.widget.util.interlock

Contains a set of classes to handle a network graph viewer and its editor.

See: Description

Package fr.esrf.tangoatk.widget.util.interlock Description

Contains a set of classes to handle a network graph viewer and its editor. It is possible to customize the editor in order to add exteneded parameters to bubble object. The following sample applications show how to subclass the NetEditor and NetEditorFrame classes in order to propduce a customized viewer or editor.

Sample application 1 : A simple graph browser example.

The Default Editor This is the default NetEditor. It is launched by calling the main() function of the NetEditorFrame class.
The Dijkstra viewer This application demonstrates how to subclass the NetEditor class to produce a customized graph viewer and how to use functionality of the NetObject class to the compute the Dijkstra result.
 
Dijkstra.java : The main frame
DjNetViewer.java : The viewer componet (subclass of NetEditor)
Dijkstra.net : The net file
 

Sample application 2 : An interlock network simulator.

A customized NetEditor This application shows how to subclass the NetEditorFrame and the NetEditor classes to build a specific interlock network editor. For this application, We need 5 types of bubbles: The VCC object which is the startpoint for logic evaluation (see the viewer) , The Interlock object which represents a physical interlock (a switch), The Sensor object which represents the state of the line , The ground object (endpoint) and the Join object which provides the possibilty to create intersection. For the need of the sensor evaluation algorithm we have to ensure that there is only one startpoint and the link must be oriented as the current (from VCC to Ground). The editor also add 2 extended parameters "Type" and "Address" to Interlock object.
 
ItlkEditor.java : The main frame (subclass of NetEditorFrame)
ItlkNetEditor.java : The editor component (subclass of NetEditor)
Interlock.net : The net file
 
Sample application 4 This is the corresponding player. It draws link according to the presence of current in the line. A red bubble can be shown as an open switch and a green bubble as a closed switch. Logical sensor just represents the state of the line.
 
ItlkViewer.java : The main frame
ItlkNetViewer.java : The viewer component (subclass of ItlkNetEditor)