public class Avg extends Sum
AggregateSymbol - the type will not be an
integral type but will always be some kind of decimal type.accumulatorType, BIG_DECIMAL, BIG_INTEGER, DOUBLE, LONGargIndexes| Constructor and Description |
|---|
Avg() |
| Modifier and Type | Method and Description |
|---|---|
void |
addInputDirect(Object input,
List<?> tuple,
CommandContext commandContext) |
Object |
getResult(CommandContext commandContext)
Called after all values have been processed to get the result.
|
void |
getState(List<Object> state) |
List<? extends Class<?>> |
getStateTypes() |
void |
initialize(Class<?> dataType,
Class<?> inputType) |
void |
reset()
Called to reset the state of the function.
|
int |
setState(List<?> state,
int index) |
getAccumulatorTypeaddInputDirect, initializeaddInput, filter, getArgIndexes, getOutputType, respectsNull, setArgIndexes, setConditionIndexpublic void initialize(Class<?> dataType, Class<?> inputType)
initialize in class Sumpublic void reset()
AggregateFunctionpublic void addInputDirect(Object input, List<?> tuple, CommandContext commandContext) throws FunctionExecutionException, ExpressionEvaluationException, TeiidComponentException
addInputDirect in class SumFunctionExecutionExceptionExpressionEvaluationExceptionTeiidComponentExceptionpublic Object getResult(CommandContext commandContext) throws FunctionExecutionException, ExpressionEvaluationException, TeiidComponentException
AggregateFunctiongetResult in class SumFunctionExecutionExceptionExpressionEvaluationExceptionTeiidComponentExceptionAggregateFunction.getResult(CommandContext)public List<? extends Class<?>> getStateTypes()
getStateTypes in class SumCopyright © 2019. All rights reserved.