Class ConstPropagationMathFunctions


  • public class ConstPropagationMathFunctions
    extends ConceptFunction
    A concept function that returns the Concept result of a math operation between two FlatTokenInfiniteConcepts in the constPropagation ontology.
    Since:
    Ptolemy II 10.0
    Version:
    $Id$
    Author:
    Charles Shelton
    Pt.AcceptedRating:
    Red (cshelton)
    Pt.ProposedRating:
    Green (cshelton)
    • Constructor Detail

      • ConstPropagationMathFunctions

        public ConstPropagationMathFunctions​(Ontology ontology,
                                             java.lang.String mathOperation)
                                      throws IllegalActionException
        Create a new ConstPropagationMathFunctions concept function.
        Parameters:
        ontology - The domain and range unit system ontology for this concept function.
        mathOperation - Indicates whether this concept function will perform addition, subtraction, multiplication or division for the FlatTokenInfiniteConcepts.
        Throws:
        IllegalActionException - Thrown if the concept function cannot be created.
    • Method Detail

      • _evaluateFunction

        protected Concept _evaluateFunction​(java.util.List<Concept> argValues)
                                     throws IllegalActionException
        Return the function output from the given input arguments. The output concept is a FlatTokenInfiniteConcept that is the result of the addition, subtraction, multiplication or division of the two input FlatTokenInfiniteConcepts.
        Specified by:
        _evaluateFunction in class ConceptFunction
        Parameters:
        argValues - The 2 FlatTokenInfiniteConcept input arguments.
        Returns:
        The output FlatTokenInfiniteConcept.
        Throws:
        IllegalActionException - Thrown if there is a problem creating the output FlatTokenInfiniteConcept.