Package io.trino.type
Class TypeCoercion
java.lang.Object
io.trino.type.TypeCoercion
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancoerceTypeBase(Type sourceType, String resultTypeBase) coerceTypeBase and isCovariantParametrizedType defines all hand-coded rules for type coercion.getCommonSuperType(Type firstType, Type secondType) booleanisCompatible(Type fromType, Type toType) static booleanisCovariantTypeBase(String typeBase) booleanisInjectiveCoercion(Type source, Type result) booleanisTypeOnlyCoercion(Type source, Type result)
-
Constructor Details
-
TypeCoercion
-
-
Method Details
-
isTypeOnlyCoercion
-
isInjectiveCoercion
-
getCommonSuperType
-
isCompatible
-
canCoerce
-
coerceTypeBase
coerceTypeBase and isCovariantParametrizedType defines all hand-coded rules for type coercion. Other methods should reference these two functions instead of hand-code new rules. -
isCovariantTypeBase
-