Class FormulaExpression

  • All Implemented Interfaces:
    Serializable, Cloneable, Expression

    public final class FormulaExpression
    extends AbstractExpression
    The formula expression is used to evaluate a LibFormula/OpenFormula expression. There is generally no need to reference this class directly, as this expression is used automatically if a formula is specified in a element, style-expression or common expression.
    Thomas Morgner
    See Also:
    Serialized Form
    • Constructor Detail

      • FormulaExpression

        public FormulaExpression()
        Default Constructor.
    • Method Detail

      • getFailOnError

        public Boolean getFailOnError()
      • setFailOnError

        public void setFailOnError​(Boolean failOnError)
      • getFormula

        public String getFormula()
        Returns the formula (incuding the optional namespace) as defined by the OpenFormula standard.
        the formula as text.
      • getFormulaNamespace

        public String getFormulaNamespace()
        Returns the formula namespace. If the formula specified by the user starts with "=", then the namespace "report" is assumed.
        the namespace of the formula.
      • getFormulaExpression

        public String getFormulaExpression()
        Returns the formula expression.
        the formula expression.
      • setFormula

        public void setFormula​(String formula)
        Defines the formula (including the optional namespace) as defined by the OpenFormula standard.
        formula - the formula as text.
      • getValue

        public Object getValue()
        Return the computed value of the formula.
        the value of the function.
      • isFormulaError

        public boolean isFormulaError()
      • getFormulaError

        public Exception getFormulaError()
      • getInstance

        public Expression getInstance()
        Return a completly separated copy of this function. The copy does no longer share any changeable objects with the original function.
        Specified by:
        getInstance in interface Expression
        getInstance in class AbstractExpression
        a copy of this function.