public class GenericUDFOPDTIPlus extends GenericUDFBaseDTI
GenericUDF.DeferredJavaObject, GenericUDF.DeferredObject| Modifier and Type | Field and Description |
|---|---|
protected DateWritableV2 |
dateResult |
protected int |
dtArgIdx |
protected ObjectInspectorConverters.Converter |
dtConverter |
protected DateTimeMath |
dtm |
protected int |
intervalArg1Idx |
protected int |
intervalArg2Idx |
protected HiveIntervalDayTimeWritable |
intervalDayTimeResult |
protected HiveIntervalYearMonthWritable |
intervalYearMonthResult |
protected org.apache.hadoop.hive.ql.udf.generic.GenericUDFOPDTIPlus.OperationType |
plusOpType |
protected TimestampWritableV2 |
timestampResult |
inputOIsopDisplayName, opName| Constructor and Description |
|---|
GenericUDFOPDTIPlus() |
| Modifier and Type | Method and Description |
|---|---|
Object |
evaluate(GenericUDF.DeferredObject[] arguments)
Evaluate the GenericUDF with the arguments.
|
protected DateWritableV2 |
handleDateResult(Date result) |
protected HiveIntervalDayTimeWritable |
handleIntervalDayTimeResult(org.apache.hadoop.hive.common.type.HiveIntervalDayTime result) |
protected HiveIntervalYearMonthWritable |
handleIntervalYearMonthResult(HiveIntervalYearMonth result) |
protected TimestampWritableV2 |
handleTimestampResult(Timestamp result) |
ObjectInspector |
initialize(ObjectInspector[] arguments)
Initialize this GenericUDF.
|
checkArgsgetDisplayStringcheckArgGroups, checkArgPrimitive, checkArgsSize, close, configure, copyToNewInstance, flip, getArgOrder, getConstantBooleanValue, getConstantIntValue, getConstantStringValue, getDateValue, getDoubleValue, getFuncName, getIntervalDayTimeValue, getIntervalYearMonthValue, getIntValue, getLongValue, getRequiredFiles, getRequiredJars, getStandardDisplayString, getStandardDisplayString, getStringValue, getTimestampValue, getUdfName, initializeAndFoldConstants, negative, obtainDateConverter, obtainDoubleConverter, obtainIntConverter, obtainLongConverter, obtainStringConverter, obtainTimestampConverterprotected transient DateTimeMath dtm
protected transient org.apache.hadoop.hive.ql.udf.generic.GenericUDFOPDTIPlus.OperationType plusOpType
protected transient int intervalArg1Idx
protected transient int intervalArg2Idx
protected transient int dtArgIdx
protected transient ObjectInspectorConverters.Converter dtConverter
protected transient TimestampWritableV2 timestampResult
protected transient DateWritableV2 dateResult
protected transient HiveIntervalDayTimeWritable intervalDayTimeResult
protected transient HiveIntervalYearMonthWritable intervalYearMonthResult
public ObjectInspector initialize(ObjectInspector[] arguments) throws UDFArgumentException
GenericUDFinitialize in class GenericUDFarguments - The ObjectInspector for the argumentsUDFArgumentException - Thrown when arguments have wrong types, wrong length, etc.public Object evaluate(GenericUDF.DeferredObject[] arguments) throws HiveException
GenericUDFevaluate in class GenericUDFarguments - The arguments as DeferedObject, use DeferedObject.get() to get the
actual argument Object. The Objects can be inspected by the
ObjectInspectors passed in the initialize call.HiveExceptionprotected DateWritableV2 handleDateResult(Date result)
protected TimestampWritableV2 handleTimestampResult(Timestamp result)
protected HiveIntervalYearMonthWritable handleIntervalYearMonthResult(HiveIntervalYearMonth result)
protected HiveIntervalDayTimeWritable handleIntervalDayTimeResult(org.apache.hadoop.hive.common.type.HiveIntervalDayTime result)
Copyright © 2019 The Apache Software Foundation. All Rights Reserved.