Class SmileDiagramApp

  • java.lang.Object
    • DiagramEditorApp
      • uk.ac.qmul.eecs.ccmi.examples.framework.SmileDiagramApp


  • public class SmileDiagramApp
    extends DiagramEditorApp
    A Smile Diagram Application. an instance of the CCmI Diagram Editor which adds the "Smile Diagram" among the diagrams available.
    • Constructor Summary

      Constructors 
      Constructor and Description
      SmileDiagramApp() 
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      protected Diagram[] getDiagrams()
      Overrides the method in DiagramEditorApp, which returns an empty array.
      protected TemplateEditor[] getTemplateEditors()
      Returns an empty array, so that template editors are ignored in this application.
      protected java.io.File[] getTemplateFiles()
      Calls super.getTemplateFiles().
      static void main(java.lang.String[] argv)
      Main method.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SmileDiagramApp

        public SmileDiagramApp()
    • Method Detail

      • main

        public static void main(java.lang.String[] argv)
        Main method. Creates a new SmileDiagramApp and calls super.mainImplementation()
        Parameters:
        argv - arguments vector
      • getTemplateEditors

        protected TemplateEditor[] getTemplateEditors()
        Returns an empty array, so that template editors are ignored in this application. No template wizard related menu items appear in the menu.
      • getTemplateFiles

        protected java.io.File[] getTemplateFiles()
        Calls super.getTemplateFiles(). This makes the application compatible with an instance of the CCmI Editor and the templates created therein. The templates created with the CCmI Editor instance will appear in the File->New Diagram menu.
        Returns:
        the array of template files
      • getDiagrams

        protected Diagram[] getDiagrams()
        Overrides the method in DiagramEditorApp, which returns an empty array. This method allows to define your own diagrams to be used within the editor. In this class an array with one instance of SmileDiagram is returned. The diagram contains two nodes and one edge prototypes, whose types are respectively "Happy Node", "Sad Node" and "Smile Edge".
        Returns:
        the array of diagrams