Package com.nt.udc.io
Class COSARExprBinaryNumOp
java.lang.Object
com.nt.udc.io.COSARExpr
com.nt.udc.io.COSARExprBinaryNumOp
- Direct Known Subclasses:
COSARExprDivide
,COSARExprMinus
,COSARExprMultiply
,COSARExprPlus
,COSARExprPower
This class represents a binary numeric operation.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected COSARExpr
This member represents the left operand.protected COSARExpr
This member represents the right operand.Fields inherited from class com.nt.udc.io.COSARExpr
m_bIsConstant
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionThis function is used to evaluate the expression.protected abstract double
getComputedValue
(double val1, double val2) This function does the actual computation.protected abstract String
This function returns a string representation of the operation.toString()
Methods inherited from class com.nt.udc.io.COSARExpr
isConstant
-
Field Details
-
m_left
This member represents the left operand. -
m_right
This member represents the right operand.
-
-
Constructor Details
-
COSARExprBinaryNumOp
- Throws:
Exception
-
-
Method Details
-
eval
Description copied from class:COSARExpr
This function is used to evaluate the expression. A symbol table is passed to help in retrieving the value of referenced symbols. The HashMap should contain values stored as COSARAttr objects, keyed by their associated symbol's name. -
toString
-
getComputedValue
protected abstract double getComputedValue(double val1, double val2) This function does the actual computation. -
getOpString
This function returns a string representation of the operation.
-