Package jmri.jmrit.logixng.util.parser
Interface Function
-
- All Known Implementing Classes:
AbstractFunction
public interface Function
Definition of a function used in expressions.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.Object
calculate(SymbolTable symbolTable, java.util.List<ExpressionNode> parameterList)
Calculate the functionjava.lang.String
getConstantDescriptions()
Get the descriptions of the constants in the module.java.lang.String
getDescription()
Get the description of the function in Markdown formatjava.lang.String
getModule()
Get the module of the function, for example "Math" or "Conversion".java.lang.String
getName()
Get name of the function, for example "sin" or "int"
-
-
-
Method Detail
-
getModule
java.lang.String getModule()
Get the module of the function, for example "Math" or "Conversion".- Returns:
- the module name
-
getConstantDescriptions
java.lang.String getConstantDescriptions()
Get the descriptions of the constants in the module.- Returns:
- the description of the constants
-
getName
java.lang.String getName()
Get name of the function, for example "sin" or "int"- Returns:
- the name
-
calculate
java.lang.Object calculate(SymbolTable symbolTable, java.util.List<ExpressionNode> parameterList) throws JmriException
Calculate the function- Parameters:
symbolTable
- the symbol tableparameterList
- a list of parameters for the function- Returns:
- the result
- Throws:
JmriException
- in case of an error
-
getDescription
java.lang.String getDescription()
Get the description of the function in Markdown format- Returns:
- the description
-
-