com.remedy.arsys.api
Class ArithmeticOperationInfo
java.lang.Object
|
+--com.remedy.arsys.api.ArithmeticOperationInfo
- All Implemented Interfaces:
- java.lang.Cloneable
- public class ArithmeticOperationInfo
- extends java.lang.Object
- implements java.lang.Cloneable
The ArithmeticOperationInfo class represents the
result value from an arithmetic operation
between ArithmeticOrRelationalOperand objects.
It consists
of a tag identifying the operation type and two operands specifying the values to
compare.
Note This operand is used in RelationalOperationInfo operation as well.
Refs: QualifierInfo
| Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
AR_ARITH_OP_ADD
public static final int AR_ARITH_OP_ADD
AR_ARITH_OP_ADD adds the left and right operands.
AR_ARITH_OP_SUBTRACT
public static final int AR_ARITH_OP_SUBTRACT
AR_ARITH_OP_SUBTRACT
subtracts the right operand from the left operand.
AR_ARITH_OP_MULTIPLY
public static final int AR_ARITH_OP_MULTIPLY
AR_ARITH_OP_MULTIPLY
multiplies the left and right operands.
AR_ARITH_OP_DIVIDE
public static final int AR_ARITH_OP_DIVIDE
AR_ARITH_OP_DIVIDE
divides the left operand by the right operand.
AR_ARITH_OP_MODULO
public static final int AR_ARITH_OP_MODULO
AR_ARITH_OP_MODULO
finds the remainder after dividing the left operand by the right operand.
AR_ARITH_OP_NEGATE
public static final int AR_ARITH_OP_NEGATE
AR_ARITH_OP_NEGATE
changes the sign of the right operand (left operand is ignored).
ArithmeticOperationInfo
public ArithmeticOperationInfo()
ArithmeticOperationInfo
public ArithmeticOperationInfo(int operation,
ArithmeticOrRelationalOperand op1,
ArithmeticOrRelationalOperand op2)
throws java.lang.IllegalArgumentException
- Throws:
java.lang.IllegalArgumentException - if invalid operation
getLeftOperand
public ArithmeticOrRelationalOperand getLeftOperand()
- Returns value of left operand of operation.
getRightOperand
public ArithmeticOrRelationalOperand getRightOperand()
- Returns value of right operand of operation.
getOperation
public int getOperation()
- Returns arithmetic operation used in qualification.
clone
public java.lang.Object clone()
throws java.lang.CloneNotSupportedException
- Clone implementation that returns an Object with data cloned from self
- Overrides:
clone in class java.lang.Object
equals
public boolean equals(java.lang.Object anObject)
- Use this method for checking equality. The result is true only
if the argument is not null, is of same type and represents the same
content.
- Overrides:
equals in class java.lang.Object
hashCode
public int hashCode()
- Returns the hash code value for this instance of the current class.
This method is supported as required by the general contract of
Object.hashCode, for the benefit of hash tables such as those provided
by java.util.Hashtable.
- Overrides:
hashCode in class java.lang.Object