freegraph
Class ExpressionItem.UnOperator
java.lang.Object
|
+--freegraph.ExpressionItem
|
+--freegraph.ExpressionItem.UnOperator
- Enclosing class:
- ExpressionItem
- public static class ExpressionItem.UnOperator
- extends ExpressionItem
A UnOperator is an ExpressionItem used to hold a
all unary operators. (Operators with one operand.) The doOperation
method is used by ExpressionEvaluator
|
Field Summary |
static int |
ABS
|
static int |
COS
|
static int |
EXP
|
static int |
LN
|
static int |
LOG
|
static int |
NEG
|
static java.lang.String[] |
OPERATORS
|
static int |
SIN
|
static int |
SQR
|
static int |
SQRT
|
static int |
TAN
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
SIN
public static final int SIN
- See Also:
- Constant Field Values
COS
public static final int COS
- See Also:
- Constant Field Values
TAN
public static final int TAN
- See Also:
- Constant Field Values
NEG
public static final int NEG
- See Also:
- Constant Field Values
SQRT
public static final int SQRT
- See Also:
- Constant Field Values
SQR
public static final int SQR
- See Also:
- Constant Field Values
LOG
public static final int LOG
- See Also:
- Constant Field Values
LN
public static final int LN
- See Also:
- Constant Field Values
EXP
public static final int EXP
- See Also:
- Constant Field Values
ABS
public static final int ABS
- See Also:
- Constant Field Values
OPERATORS
public static final java.lang.String[] OPERATORS
ExpressionItem.UnOperator
public ExpressionItem.UnOperator(int kind)
getAction
public int getAction(ExpressionItem exprItem)
- Always moves this to the RPN stack.
- Specified by:
getAction in class ExpressionItem
doOperation
public double doOperation(double x)
toString
public java.lang.String toString()
- Overrides:
toString in class java.lang.Object