The value of trueExpr will be returned if condExpr is >0 or true and value of negExpr will be returned if condExpr is <= 0 or true. If condExpr is NaN then NaN is returned.
This function performs lazy evaluation so that only posExpr or negExpr will be evaluated. For Complex numbers only the real part is used.
An alternate form if(condExpr, posExpr, negExpr, zeroExpr) is also available. Note most computations are carried out over floating point doubles so testing for zero can be dangerous.
This function implements the SpecialEvaluationI interface so that it handles setting the value of a variable.
Assembly: Jep (in Jep.dll) Version: 1.1.0.0 (1.0.0)
Syntax
C# |
---|
public class If : PostfixMathCommand, ICallbackEvaluation |
Visual Basic (Declaration) |
---|
Public Class If _ Inherits PostfixMathCommand _ Implements ICallbackEvaluation |
Visual C++ |
---|
public ref class If : public PostfixMathCommand, ICallbackEvaluation |