Package org.apache.drill.exec.expr.fn
Class HiveFunctionRegistry
java.lang.Object
org.apache.drill.exec.expr.fn.HiveFunctionRegistry
- All Implemented Interfaces:
PluggableFunctionRegistry
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionHiveFunctionRegistry
(DrillConfig config) Scan the classpath for implementation of GenericUDF/UDF interfaces, extracts function annotation and store the (function name) --> (implementation class) mappings. -
Method Summary
Modifier and TypeMethodDescriptiongetFunction
(FunctionCall call) Find the UDF class for given function name and check if it accepts the given input argument types.void
register
(DrillOperatorTable operatorTable) Register functions in given operator table.
-
Constructor Details
-
HiveFunctionRegistry
Scan the classpath for implementation of GenericUDF/UDF interfaces, extracts function annotation and store the (function name) --> (implementation class) mappings.- Parameters:
config
-
-
-
Method Details
-
register
Description copied from interface:PluggableFunctionRegistry
Register functions in given operator table. There are two methods to add operators. One is addOperatorWithInference whose added operators will be used when planner.type_inference.enable is set to true; The other is addOperatorWithoutInference whose added operators will be used when planner.type_inference.enable is set to false;- Specified by:
register
in interfacePluggableFunctionRegistry
-
getFunction
Find the UDF class for given function name and check if it accepts the given input argument types. If a match is found, create a holder and return- Specified by:
getFunction
in interfacePluggableFunctionRegistry
- Parameters:
call
-- Returns:
-