Class VariableExpression

  • All Implemented Interfaces:
    java.io.Serializable

    public class VariableExpression
    extends com.jscape.util.functor.UnaryFunction<ExpressionContext,​java.lang.Object>
    Variable expression.
    Author:
    Alex
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.jscape.util.functor.UnaryFunction

        com.jscape.util.functor.UnaryFunction.Chain<T,​R,​U>, com.jscape.util.functor.UnaryFunction.Constant<T,​U>, com.jscape.util.functor.UnaryFunction.Evaluator<V,​R>
    • Constructor Summary

      Constructors 
      Constructor Description
      VariableExpression()
      Creates a new expression instance.
      VariableExpression​(java.lang.String variableName)
      Creates a new expression instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object evaluate​(ExpressionContext context)
      Computes expression value.
      java.lang.String getVariableName()
      Returns variable name.
      void setVariableName​(java.lang.String value)
      Sets variable name.
      java.lang.String toString()  
      • Methods inherited from class com.jscape.util.functor.UnaryFunction

        constant, then
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • VariableExpression

        public VariableExpression​(java.lang.String variableName)
        Creates a new expression instance.
        Parameters:
        variableName - the variable name
      • VariableExpression

        public VariableExpression()
        Creates a new expression instance.
    • Method Detail

      • getVariableName

        public java.lang.String getVariableName()
        Returns variable name.
        Returns:
        variable name
      • setVariableName

        public void setVariableName​(java.lang.String value)
        Sets variable name.
        Parameters:
        value - the variable name
      • evaluate

        public java.lang.Object evaluate​(ExpressionContext context)
        Computes expression value.
        Specified by:
        evaluate in class com.jscape.util.functor.UnaryFunction<ExpressionContext,​java.lang.Object>
        Parameters:
        context - the workflow context
        Returns:
        computed value
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object