edu.wpi.cs.dsrg.xmldb.xat.common.expression
Interface Expression
- All Known Subinterfaces:
- BinANDExpression, BinArithExpression, BinBoolExpression, BinCOMPExpression, BinExpression, BinORExpression, TerminalExpression, UniExpression, UniMinusExpression, UniNotExpression
- public interface Expression
- extends Visitable
This class defines an expression.
Expression can be
used in the Join and Select operators as a condition.
It can also be used in the LET clause to do a variable change.
We take the design from the xacute.quilt.Operator and their
subclasses.
- Since:
- 1.0
eval
public java.lang.Object eval(XATOperator xopOper,
int[] iPositions)
- Evaluate the expression of the XATOperator.
- Parameters:
xopOper
- The operator evaluated.iPositions
- The position of tuple in the XATTable.- Returns:
- The evaluate result of expression, it could be Integer, Float, Double, String, Boolean.
- Since:
- 1.0
getRelatedColumnNames
public ColumnName[] getRelatedColumnNames()
- get column names related with expression.
- Returns:
- ColumnName[] The array containing all the related column names.
- Since:
- 1.0
toSQL
public java.lang.String toSQL(OperatorEvaluator soe)
- Convert the expression as a SQL statement.
- Parameters:
soe
- The operator evaluator for SQL generation.- Returns:
- java.lang.String The converted string.
- Since:
- 1.0