Package org.apache.calcite.sql.type
Class MatchReturnTypeInference
java.lang.Object
org.apache.calcite.sql.type.MatchReturnTypeInference
- All Implemented Interfaces:
SqlReturnTypeInference
Returns the first type that matches a set of given
SqlTypeName
s. If
no match could be found, null is returned.-
Constructor Summary
ConstructorDescriptionMatchReturnTypeInference
(int start, Iterable<SqlTypeName> typeNames) Returns the first type matching any type in typeNames at or after position start (zero based).MatchReturnTypeInference
(int start, SqlTypeName... typeNames) Returns the first type of typeName at or after position start (zero based). -
Method Summary
Modifier and TypeMethodDescription@Nullable RelDataType
inferReturnType
(SqlOperatorBinding opBinding) Infers the return type of a call to anSqlOperator
.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.calcite.sql.type.SqlReturnTypeInference
andThen, orElse
-
Constructor Details
-
MatchReturnTypeInference
Returns the first type of typeName at or after position start (zero based). -
MatchReturnTypeInference
Returns the first type matching any type in typeNames at or after position start (zero based).
-
-
Method Details
-
inferReturnType
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
-