Package org.apache.calcite.rex
Class RexSqlStandardConvertletTable
- java.lang.Object
-
- org.apache.calcite.rex.RexSqlReflectiveConvertletTable
-
- org.apache.calcite.rex.RexSqlStandardConvertletTable
-
- All Implemented Interfaces:
RexSqlConvertletTable
public class RexSqlStandardConvertletTable extends RexSqlReflectiveConvertletTable
Standard implementation ofRexSqlConvertletTable
.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private class
RexSqlStandardConvertletTable.EquivConvertlet
-
Constructor Summary
Constructors Constructor Description RexSqlStandardConvertletTable()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SqlNode
convertCall(RexToSqlNodeConverter converter, RexCall call)
Converts a call to an operator into aSqlCall
to the same operator.private SqlNode[]
convertExpressionList(RexToSqlNodeConverter converter, java.util.List<RexNode> nodes)
private void
registerCaseOp(SqlOperator op)
Creates and registers a convertlet for the CASE operator, which takes different forms for SQL vs Rex.protected void
registerEquivOp(SqlOperator op)
Creates and registers a convertlet for an operator in which the SQL and Rex representations are structurally equivalent.private void
registerTypeAppendOp(SqlOperator op)
Creates and registers a convertlet for an operator in which the SQL representation needs the result type appended as an extra argument (e.g.-
Methods inherited from class org.apache.calcite.rex.RexSqlReflectiveConvertletTable
get, registerOp
-
-
-
-
Method Detail
-
convertCall
public SqlNode convertCall(RexToSqlNodeConverter converter, RexCall call)
Converts a call to an operator into aSqlCall
to the same operator.Called automatically via reflection.
- Parameters:
converter
- Convertercall
- Call- Returns:
- Sql call
-
convertExpressionList
private SqlNode[] convertExpressionList(RexToSqlNodeConverter converter, java.util.List<RexNode> nodes)
-
registerEquivOp
protected void registerEquivOp(SqlOperator op)
Creates and registers a convertlet for an operator in which the SQL and Rex representations are structurally equivalent.- Parameters:
op
- operator instance
-
registerTypeAppendOp
private void registerTypeAppendOp(SqlOperator op)
Creates and registers a convertlet for an operator in which the SQL representation needs the result type appended as an extra argument (e.g. CAST).- Parameters:
op
- operator instance
-
registerCaseOp
private void registerCaseOp(SqlOperator op)
Creates and registers a convertlet for the CASE operator, which takes different forms for SQL vs Rex.- Parameters:
op
- instance of CASE operator
-
-