Class DecimalAverageAggregation
- java.lang.Object
-
- io.prestosql.metadata.SqlAggregationFunction
-
- io.prestosql.operator.aggregation.DecimalAverageAggregation
-
- All Implemented Interfaces:
SqlFunction
public class DecimalAverageAggregation extends SqlAggregationFunction
-
-
Field Summary
Fields Modifier and Type Field Description static DecimalAverageAggregation
DECIMAL_AVERAGE_AGGREGATION
-
Constructor Summary
Constructors Constructor Description DecimalAverageAggregation()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static BigDecimal
average(LongDecimalWithOverflowAndLongState state, DecimalType type)
static void
combine(LongDecimalWithOverflowAndLongState state, LongDecimalWithOverflowAndLongState otherState)
List<TypeSignature>
getIntermediateTypes(FunctionBinding functionBinding)
static void
inputLongDecimal(Type type, LongDecimalWithOverflowAndLongState state, Block block, int position)
static void
inputShortDecimal(Type type, LongDecimalWithOverflowAndLongState state, Block block, int position)
static void
outputLongDecimal(DecimalType type, LongDecimalWithOverflowAndLongState state, BlockBuilder out)
static void
outputShortDecimal(DecimalType type, LongDecimalWithOverflowAndLongState state, BlockBuilder out)
InternalAggregationFunction
specialize(FunctionBinding functionBinding)
-
Methods inherited from class io.prestosql.metadata.SqlAggregationFunction
createFunctionByAnnotations, createFunctionsByAnnotations, getAggregationMetadata, getFunctionMetadata, specialize
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.prestosql.metadata.SqlFunction
getFunctionDependencies, getFunctionDependencies
-
-
-
-
Field Detail
-
DECIMAL_AVERAGE_AGGREGATION
public static final DecimalAverageAggregation DECIMAL_AVERAGE_AGGREGATION
-
-
Method Detail
-
getIntermediateTypes
public List<TypeSignature> getIntermediateTypes(FunctionBinding functionBinding)
- Overrides:
getIntermediateTypes
in classSqlAggregationFunction
-
specialize
public InternalAggregationFunction specialize(FunctionBinding functionBinding)
- Overrides:
specialize
in classSqlAggregationFunction
-
inputShortDecimal
public static void inputShortDecimal(Type type, LongDecimalWithOverflowAndLongState state, Block block, int position)
-
inputLongDecimal
public static void inputLongDecimal(Type type, LongDecimalWithOverflowAndLongState state, Block block, int position)
-
combine
public static void combine(LongDecimalWithOverflowAndLongState state, LongDecimalWithOverflowAndLongState otherState)
-
outputShortDecimal
public static void outputShortDecimal(DecimalType type, LongDecimalWithOverflowAndLongState state, BlockBuilder out)
-
outputLongDecimal
public static void outputLongDecimal(DecimalType type, LongDecimalWithOverflowAndLongState state, BlockBuilder out)
-
average
public static BigDecimal average(LongDecimalWithOverflowAndLongState state, DecimalType type)
-
-