Class StreamAssign

java.lang.Object
com.singularsys.jep.functions.PostfixMathCommand
com.singularsys.extensions.stream.StreamAssign
All Implemented Interfaces:
CallbackEvaluationI, JepComponent, PostfixMathCommandI, Serializable

public class StreamAssign extends PostfixMathCommand implements CallbackEvaluationI, JepComponent
An assignment operator that converts rhs streams values to Vector<Object> using the List.
See Also:
  • Constructor Details

    • StreamAssign

      public StreamAssign()
  • Method Details

    • evaluate

      public Object evaluate(Node node, Evaluator pv) throws EvaluationException
      For assignment set the value of the variable on the lhs to value returned by evaluating the right-hand side.
      Specified by:
      evaluate in interface CallbackEvaluationI
      Parameters:
      node - The current node
      pv - The visitor, can be used evaluate the children
      Returns:
      the value after evaluation. This value will be passed to other functions higher up the node tree. The value can be any type including Double or Vector<Object>
      Throws:
      EvaluationException - if the calculation cannot be performed
      See Also:
    • init

      public void init(Jep jep)
      Description copied from interface: JepComponent
      Initialize the component. This method is called whenever a component is added to Jep. Hence, it allows components to keep track of the other components they may rely on.
      Specified by:
      init in interface JepComponent
      Parameters:
      jep - the current Jep instance
    • getLightWeightInstance

      public JepComponent getLightWeightInstance()
      Description copied from interface: JepComponent
      Gets a light-weight instance suitable for using in multiple threads.
      Specified by:
      getLightWeightInstance in interface JepComponent
      Returns:
      either a new instance, null or 'this'.