Class PtolemyTableauFactory

  • All Implemented Interfaces:
    java.lang.Cloneable, Changeable, Configurable, Debuggable, DebugListener, Derivable, ModelErrorHandler, MoMLExportable, Moveable, Nameable

    public class PtolemyTableauFactory
    extends TableauFactory
    This is an intermediate container tableau factory that is designed to contain all tableau factories in a configuration that are capable of displaying a Ptolemy II model. This class sets up the effigy with a set of available views. Tableaux can use that to set up a View menu which offers alternative views besides the default view. Subclasses of this class will usually be inner classes of a Tableau, and will create the Tableau.
    Since:
    Ptolemy II 1.0
    Version:
    $Id$
    Author:
    Steve Neuendorffer and Edward A. Lee
    See Also:
    Configuration, Effigy, Tableau
    Pt.AcceptedRating:
    Red (cxh)
    Pt.ProposedRating:
    Yellow (eal)
    • Method Detail

      • createTableau

        public Tableau createTableau​(Effigy effigy)
                              throws java.lang.Exception
        Create a tableau for the specified effigy. The tableau will created with a new unique name with the specified effigy as its container. If the effigy is not an instance of PtolemyEffigy, then return null. Otherwise, set up the list of alternative views in the PtolemyEffigy and then delegate to the first contained factory that can display the model.
        Overrides:
        createTableau in class TableauFactory
        Parameters:
        effigy - The model effigy.
        Returns:
        A tableau for the effigy, or null if one cannot be created.
        Throws:
        java.lang.Exception - If the factory should be able to create a Tableau for the effigy, but something goes wrong.