org.apache.hadoop.hive.ql.exec
Class ComparisonOpMethodResolver
java.lang.Object
org.apache.hadoop.hive.ql.exec.ComparisonOpMethodResolver
- All Implemented Interfaces:
- UDFMethodResolver
public class ComparisonOpMethodResolver
- extends Object
- implements UDFMethodResolver
The class implements the method resolution for overloaded comparison operators. The
resolution logic is as follows:
1. The resolver first tries to find an exact parameter match.
2. If 1 fails and any of the parameters is a date, it converts the other to the date.
3. If 1 and 3 fail then it returns the evaluate(Double, Double) method.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ComparisonOpMethodResolver
public ComparisonOpMethodResolver(Class<? extends UDF> udfClass)
- Constuctor.
getEvalMethod
public Method getEvalMethod(List<Class<?>> argClasses)
throws AmbiguousMethodException
- Description copied from interface:
UDFMethodResolver
- Gets the evaluate method for the UDF given the parameter types.
- Specified by:
getEvalMethod
in interface UDFMethodResolver
- Parameters:
argClasses
- The list of the argument types that need to matched with the evaluate
function signature.
- Throws:
AmbiguousMethodException
Copyright © 2009 The Apache Software Foundation