Class ProductLatticeOntology

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

    public class ProductLatticeOntology
    extends Ontology
    A product lattice-based ontologies. Represents an ontology based on a lattice derived from the cross product of a set of other lattice-based ontologies. Given the specified ontologies, the list of concepts for the product lattice ontology is automatically generated by taking all possible tuple combinations for each individual lattice ontology.
    Since:
    Ptolemy II 10.0
    Version:
    $Id$
    Author:
    Charles Shelton
    Pt.AcceptedRating:
    Red (cshelton)
    Pt.ProposedRating:
    Red (cshelton)
    • Field Detail

      • latticeOntologies

        public Parameter latticeOntologies
        The parameter that holds the user-specified array of ontologies from which the product lattice ontology is derived.
    • Method Detail

      • attributeChanged

        public void attributeChanged​(Attribute attribute)
                              throws IllegalActionException
        React to a change in an attribute. This method is called by a contained attribute when its value changes. When the latticeOntologies parameter is changed, a new list of ProductLatticeConcepts is generated based on the array of Ontologies contained in that parameter.
        Overrides:
        attributeChanged in class NamedObj
        Parameters:
        attribute - The attribute that changed.
        Throws:
        IllegalActionException - If the product lattice concepts cannot be generated.
      • getColorOntology

        public Ontology getColorOntology()
        Return the current ontology from which concepts derive their highlight color definitions.
        Returns:
        The current ontology from which concepts derive their highlight color definitions.
        See Also:
        setColorOntology(Ontology)
      • getProductLatticeConceptFromTuple

        public ProductLatticeConcept getProductLatticeConceptFromTuple​(java.util.List<Concept> conceptTuple)
                                                                throws IllegalActionException
        Return the product lattice concept in this ontology derived from the specified tuple of concepts.
        Parameters:
        conceptTuple - The list of concepts from which to create a product lattice concept in this ontology.
        Returns:
        The result product lattice concept.
        Throws:
        IllegalActionException - Thrown if the input list of concepts is not composed of concepts from the component ontologies of this product lattice ontology.
      • getLatticeOntologies

        public java.util.List<Ontology> getLatticeOntologies()
                                                      throws IllegalActionException
        Return the list of lattice ontologies that comprise the product lattice ontology.
        Returns:
        The list of lattice ontology objects.
        Throws:
        IllegalActionException - If the latticeOntologies parameter does not return an array token that contains the ontology objects, or at least one of the specified component ontologies is not a lattice.
      • setColorOntology

        public void setColorOntology​(Ontology colorOntology)
                              throws IllegalActionException
        Set the component ontology from which the colors will be derived for the concepts in this product lattice ontology. If the specified ontology is not a part of this product lattice ontology, the color ontology will be set to null.
        Parameters:
        colorOntology - The specified ontology to use for the color definitions for each product lattice concept. Or null if the concepts should have no color highlighting.
        Throws:
        IllegalActionException - Thrown if the specified ontology is not part of the product lattice ontology.
        See Also:
        getColorOntology()