org.apache.hadoop.hive.ql.exec
Class DefaultUDAFEvaluatorResolver
java.lang.Object
org.apache.hadoop.hive.ql.exec.DefaultUDAFEvaluatorResolver
- All Implemented Interfaces:
- UDAFEvaluatorResolver
- Direct Known Subclasses:
- NumericUDAFEvaluatorResolver
public class DefaultUDAFEvaluatorResolver
- extends Object
- implements UDAFEvaluatorResolver
The default UDAF Method resolver. This resolver is used for resolving the UDAF methods are
used for partial and final evaluation given the list of the argument types. The getEvalMethod goes through all the
evaluate methods and returns the one that matches the argument signature or is the closest match.
Closest match is defined as the one that requires the least number of arguments to be converted.
In case more than one matches are found, the method throws an ambiguous method exception.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultUDAFEvaluatorResolver
public DefaultUDAFEvaluatorResolver(Class<? extends UDAF> udafClass)
- Constructor.
This constructor sets the resolver to be used for comparison operators.
See
UDAFEvaluatorResolver
getEvaluatorClass
public Class<? extends UDAFEvaluator> getEvaluatorClass(List<Class<?>> argClasses)
throws AmbiguousMethodException
- Gets the evaluator class for the UDAF given the parameter types.
- Specified by:
getEvaluatorClass
in interface UDAFEvaluatorResolver
- Parameters:
argClasses
- The list of the parameter types.
- Throws:
AmbiguousMethodException
Copyright © 2009 The Apache Software Foundation