Package org.apache.calcite.sql.type
Class SqlTypeTransformCascade
- java.lang.Object
-
- org.apache.calcite.sql.type.SqlTypeTransformCascade
-
- All Implemented Interfaces:
SqlReturnTypeInference
public class SqlTypeTransformCascade extends java.lang.Object implements SqlReturnTypeInference
Strategy to infer the type of an operator call from the type of the operands by using oneSqlReturnTypeInference
rule and a combination ofSqlTypeTransform
s
-
-
Field Summary
Fields Modifier and Type Field Description private SqlReturnTypeInference
rule
private com.google.common.collect.ImmutableList<SqlTypeTransform>
transforms
-
Constructor Summary
Constructors Constructor Description SqlTypeTransformCascade(SqlReturnTypeInference rule, SqlTypeTransform... transforms)
Creates a SqlTypeTransformCascade from a rule and an array of one or more transforms.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RelDataType
inferReturnType(SqlOperatorBinding opBinding)
Infers the return type of a call to anSqlOperator
.
-
-
-
Field Detail
-
rule
private final SqlReturnTypeInference rule
-
transforms
private final com.google.common.collect.ImmutableList<SqlTypeTransform> transforms
-
-
Constructor Detail
-
SqlTypeTransformCascade
public SqlTypeTransformCascade(SqlReturnTypeInference rule, SqlTypeTransform... transforms)
Creates a SqlTypeTransformCascade from a rule and an array of one or more transforms.
-
-
Method Detail
-
inferReturnType
public RelDataType inferReturnType(SqlOperatorBinding opBinding)
Description copied from interface:SqlReturnTypeInference
Infers the return type of a call to anSqlOperator
.- Specified by:
inferReturnType
in interfaceSqlReturnTypeInference
- Parameters:
opBinding
- description of operator binding- Returns:
- inferred type; may be null
-
-