Class TypeInferenceExtractor
java.lang.Object
org.apache.flink.table.types.extraction.TypeInferenceExtractor
Reflection-based utility for extracting a
TypeInference from a supported subclass of
UserDefinedFunction.
The behavior of this utility can be influenced by DataTypeHints and FunctionHints which have higher precedence than the reflective information.
Note: This utility assumes that functions have been validated before regarding accessibility of class/methods and serializability.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic TypeInferenceforAggregateFunction(DataTypeFactory typeFactory, Class<? extends AggregateFunction<?, ?>> function) Extracts a type inference from aAggregateFunction.static TypeInferenceforAsyncScalarFunction(DataTypeFactory typeFactory, Class<? extends AsyncScalarFunction> function) Extracts a type inference from aAsyncScalarFunction.static TypeInferenceforAsyncTableFunction(DataTypeFactory typeFactory, Class<? extends AsyncTableFunction<?>> function) Extracts a type inference from aAsyncTableFunction.static TypeInferenceforProcedure(DataTypeFactory typeFactory, Class<? extends Procedure> procedure) Extracts a type in inference from aProcedure.static TypeInferenceforProcessTableFunction(DataTypeFactory typeFactory, Class<? extends ProcessTableFunction<?>> function) Extracts a type inference from aProcessTableFunction.static TypeInferenceforScalarFunction(DataTypeFactory typeFactory, Class<? extends ScalarFunction> function) Extracts a type inference from aScalarFunction.static TypeInferenceforTableAggregateFunction(DataTypeFactory typeFactory, Class<? extends TableAggregateFunction<?, ?>> function) Extracts a type inference from aTableAggregateFunction.static TypeInferenceforTableFunction(DataTypeFactory typeFactory, Class<? extends TableFunction<?>> function) Extracts a type inference from aTableFunction.
-
Constructor Details
-
TypeInferenceExtractor
public TypeInferenceExtractor()
-
-
Method Details
-
forScalarFunction
public static TypeInference forScalarFunction(DataTypeFactory typeFactory, Class<? extends ScalarFunction> function) Extracts a type inference from aScalarFunction. -
forAsyncScalarFunction
public static TypeInference forAsyncScalarFunction(DataTypeFactory typeFactory, Class<? extends AsyncScalarFunction> function) Extracts a type inference from aAsyncScalarFunction. -
forAggregateFunction
public static TypeInference forAggregateFunction(DataTypeFactory typeFactory, Class<? extends AggregateFunction<?, ?>> function) Extracts a type inference from aAggregateFunction. -
forTableFunction
public static TypeInference forTableFunction(DataTypeFactory typeFactory, Class<? extends TableFunction<?>> function) Extracts a type inference from aTableFunction. -
forTableAggregateFunction
public static TypeInference forTableAggregateFunction(DataTypeFactory typeFactory, Class<? extends TableAggregateFunction<?, ?>> function) Extracts a type inference from aTableAggregateFunction. -
forAsyncTableFunction
public static TypeInference forAsyncTableFunction(DataTypeFactory typeFactory, Class<? extends AsyncTableFunction<?>> function) Extracts a type inference from aAsyncTableFunction. -
forProcessTableFunction
public static TypeInference forProcessTableFunction(DataTypeFactory typeFactory, Class<? extends ProcessTableFunction<?>> function) Extracts a type inference from aProcessTableFunction. -
forProcedure
public static TypeInference forProcedure(DataTypeFactory typeFactory, Class<? extends Procedure> procedure) Extracts a type in inference from aProcedure.
-