public abstract class IntegralAvgAggregate<T> extends AvgAggregate<T>
Constructor and Description |
---|
IntegralAvgAggregate() |
Modifier and Type | Method and Description |
---|---|
abstract Object |
doEvaluate(Row buffer) |
abstract void |
doPrepare(Object value,
Row partial) |
T |
evaluate(Row buffer)
Calculate the final aggregated result based on aggregate buffer.
|
void |
initiate(Row partial)
Initiate the intermediate aggregate value in Row.
|
TypeInformation<?>[] |
intermediateDataType()
Intermediate aggregate value types.
|
void |
merge(Row partial,
Row buffer)
Merge intermediate aggregate data into aggregate buffer.
|
void |
prepare(Object value,
Row partial)
Transform the aggregate field value into intermediate aggregate data.
|
partialCountIndex, partialSumIndex, setAggOffsetInRow, supportPartial
public void initiate(Row partial)
Aggregate
partial
- The intermediate aggregate row to initiate.public void prepare(Object value, Row partial)
Aggregate
value
- The value to insert into the intermediate aggregate row.partial
- The intermediate aggregate row into which the value is inserted.public void merge(Row partial, Row buffer)
Aggregate
partial
- The intermediate aggregate row to merge.buffer
- The aggregate buffer into which the intermedidate is merged.public T evaluate(Row buffer)
Aggregate
buffer
- The aggregate buffer from which the final aggregate is computed.public TypeInformation<?>[] intermediateDataType()
Aggregate
Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.