Class DecimalReturnTypeInference.DecimalZeroScaleReturnTypeInference
java.lang.Object
org.apache.drill.exec.expr.fn.output.DecimalReturnTypeInference.DecimalZeroScaleReturnTypeInference
- All Implemented Interfaces:
ReturnTypeInference
- Enclosing class:
- DecimalReturnTypeInference
public static class DecimalReturnTypeInference.DecimalZeroScaleReturnTypeInference
extends Object
implements ReturnTypeInference
Return type calculation implementation for functions with return type set as
FunctionTemplate.ReturnType.DECIMAL_ZERO_SCALE
.-
Field Summary
Modifier and TypeFieldDescription -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiongetType
(List<LogicalExpression> logicalExpressions, FunctionAttributes attributes) Return type is used for functions where we need to remove the scale part.
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
DecimalZeroScaleReturnTypeInference
public DecimalZeroScaleReturnTypeInference()
-
-
Method Details
-
getType
public TypeProtos.MajorType getType(List<LogicalExpression> logicalExpressions, FunctionAttributes attributes) Return type is used for functions where we need to remove the scale part. For example, truncate and round functions.- Specified by:
getType
in interfaceReturnTypeInference
- Parameters:
logicalExpressions
- logical expressionsattributes
- function attributes- Returns:
- return type
-