|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.edg.info.sqlutil.parsql.Expression
An SQL Expression, an operator and one or more operands. Example: a AND b AND c -> operator = AND, operands = (a, b, c)
Constructor Summary | |
Expression(java.lang.String operator)
Create an SQL Expression given the operator |
|
Expression(java.lang.String operator,
ExpSelConst operand1)
Create an SQL Expression given the operator and 1st operand |
|
Expression(java.lang.String operator,
ExpSelConst operand1,
ExpSelConst operand2)
Create an SQL Expression given the operator, 1st and 2nd operands |
Method Summary | |
void |
addOperand(ExpSelConst o)
Add an operand to the current expression. |
ExpSelConst |
getOperand(int pos)
Get an operand according to its index (position). |
java.util.Vector |
getOperands()
Get this expression's operands. |
java.lang.String |
getOperator()
Get this expression's operator. |
int |
nbOperands()
Get the number of operands |
void |
setOperands(java.util.Vector v)
Set the operands list. |
java.lang.String |
toReversePolish()
String form of the current expression (reverse polish notation). |
java.lang.String |
toString()
Returns a String representation of this Expression. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Expression(java.lang.String operator)
operator
- The operatorpublic Expression(java.lang.String operator, ExpSelConst operand1)
operator
- The operatoroperand1
- The 1st operandpublic Expression(java.lang.String operator, ExpSelConst operand1, ExpSelConst operand2)
operator
- The operatoroperand1
- The 1st operandoperand2
- The 2nd operandMethod Detail |
public ExpSelConst getOperand(int pos)
pos
- The operand index, starting at 0.
public void setOperands(java.util.Vector v)
v
- A vector that contains all operands (ExpSelConst objects).public java.util.Vector getOperands()
public java.lang.String getOperator()
public void addOperand(ExpSelConst o)
o
- The operand to add.public int nbOperands()
public java.lang.String toReversePolish()
public java.lang.String toString()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |