Class ReflectiveConvertletTable

java.lang.Object
org.apache.calcite.sql2rel.ReflectiveConvertletTable
All Implemented Interfaces:
SqlRexConvertletTable
Direct Known Subclasses:
StandardConvertletTable

public class ReflectiveConvertletTable extends Object implements SqlRexConvertletTable
Implementation of SqlRexConvertletTable which uses reflection to call any method of the form public RexNode convertXxx(ConvertletContext, SqlNode) or public RexNode convertXxx(ConvertletContext, SqlOperator, SqlCall).
  • Constructor Details

    • ReflectiveConvertletTable

      public ReflectiveConvertletTable()
  • Method Details

    • get

      public @Nullable SqlRexConvertlet get(SqlCall call)
      Description copied from interface: SqlRexConvertletTable
      Returns the convertlet applicable to a given expression.
      Specified by:
      get in interface SqlRexConvertletTable
    • registerOp

      protected void registerOp(@UnderInitialization ReflectiveConvertletTable this, SqlOperator op, SqlRexConvertlet convertlet)
      Registers a convertlet for a given operator instance.
      Parameters:
      op - Operator instance, say SqlStdOperatorTable.MINUS
      convertlet - Convertlet
    • addAlias

      protected void addAlias(@UnderInitialization ReflectiveConvertletTable this, SqlOperator alias, SqlOperator target)
      Registers that one operator is an alias for another.
      Parameters:
      alias - Operator which is alias
      target - Operator to translate calls to