The user may provide a customized interface for the model. This is done by manually writing a Java application, which instantiates the model class and provides input/output channels to it.
A general applet interface is written to be used with any DCharts model. It is embedded in webpages and executed in a JVM, as shown in Figure 8.4. This interface has a similar look as the SVM simulator. The state hierarchy is shown as a tree in the left panel. All the enabled events are listed in the ``Events'' list. The ``Output'' box displays the output from the model. The ``Command'' box accepts commands from the user. Accepted commands are limited to enabled events. Debugging is not supported. Exiting the program is not applicable for an applet.
This applet is written in Java source file svmapplet.java in the test/applet/ subdirectory of the SVM directory. It supports a model parameter. Its value is the name of the model class to be loaded. The applet automatically looks for the model class and instantiates an instance of it. If an error occurs, an error message is displayed.