jwo.utils.expression
Class MathOperator
java.lang.Object
jwo.utils.expression.MathOperator
- public final class MathOperator
- extends Object
Stores an enumerated list of operators that may be parsed by
the MathParser. Modified from original code described at
www.devx.com/premier/mgznarch/javapro/2001/05may01/ps0105/ps0105.asp.
- Version:
- 2.1, 14th February, 2001, modified 5th August, 2004.
- Author:
- Daniel Savarese, modified by Jo Wood.
ADD
public static final MathOperator ADD
SUBTRACT
public static final MathOperator SUBTRACT
MULTIPLY
public static final MathOperator MULTIPLY
DIVIDE
public static final MathOperator DIVIDE
EXPONENT
public static final MathOperator EXPONENT
SIN
public static final MathOperator SIN
COS
public static final MathOperator COS
TAN
public static final MathOperator TAN
ASIN
public static final MathOperator ASIN
ACOS
public static final MathOperator ACOS
ATAN
public static final MathOperator ATAN
SQRT
public static final MathOperator SQRT
LN
public static final MathOperator LN
RAND
public static final MathOperator RAND
GAUSS
public static final MathOperator GAUSS
Z1
public static final MathOperator Z1
Z2
public static final MathOperator Z2
X
public static final MathOperator X
Y
public static final MathOperator Y
PI
public static final MathOperator PI
E
public static final MathOperator E
MathOperator
public MathOperator()
getOperator
public static final MathOperator getOperator(Object token)
- Retrieves the operator matching the given type.
- Parameters:
token
- Type of operator to retrieve.
- Returns:
- Matched operator.
toString
public String toString()
- Reports a string representation of this operator.
- Returns:
- String representation of this operator.
Copyright Jo Wood, 1996-2004, last modified, 3rd September, 2004