Package com.singularsys.jeptests.system
Class JepTest.Square
java.lang.Object
com.singularsys.jep.functions.PostfixMathCommand
com.singularsys.jeptests.system.JepTest.Square
- All Implemented Interfaces:
PostfixMathCommandI
,RealUnaryFunction
,Serializable
- Enclosing class:
JepTest
- See Also:
-
Field Summary
Fields inherited from class com.singularsys.jep.functions.PostfixMathCommand
curNumberOfParameters, name, NaN, numberOfParameters
-
Constructor Summary
-
Method Summary
Methods inherited from class com.singularsys.jep.functions.PostfixMathCommand
asArray, asBool, asDouble, asInt, asLong, asStrictInt, asString, checkNumberOfParameters, getName, getNumberOfParameters, setCurNumberOfParameters, setName, toString, toString
-
Constructor Details
-
Square
public Square()
-
-
Method Details
-
evaluate
public double evaluate(double l) - Specified by:
evaluate
in interfaceRealUnaryFunction
-
run
Description copied from class:PostfixMathCommand
Throws an exception because this method should never be called under normal circumstances. Each function should use its ownrun()
method for evaluating the function. This includes popping off the parameters from the stack, and pushing the result back on the stack.- Specified by:
run
in interfacePostfixMathCommandI
- Overrides:
run
in classPostfixMathCommand
- Parameters:
s
- arguments for function
-