public abstract class MaxAggregate<T> extends Object implements Aggregate<T>
Constructor and Description |
---|
MaxAggregate(scala.math.Ordering<T> ord) |
Modifier and Type | Method and Description |
---|---|
T |
evaluate(Row buffer)
Return the final aggregated result based on aggregate buffer.
|
void |
initiate(Row intermediate)
Initiate the intermediate aggregate value in Row.
|
protected int |
maxIndex() |
void |
merge(Row intermediate,
Row buffer)
Accessed in CombineFunction and GroupReduceFunction, merge partial
aggregate result into aggregate buffer.
|
void |
prepare(Object value,
Row intermediate)
Accessed in MapFunction, prepare the input of partial aggregate.
|
void |
setAggOffsetInRow(int aggOffset)
Set the aggregate data offset in Row.
|
boolean |
supportPartial()
Whether aggregate function support partial aggregate.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
intermediateDataType
public MaxAggregate(scala.math.Ordering<T> ord)
protected int maxIndex()
public void initiate(Row intermediate)
public void prepare(Object value, Row intermediate)
public void merge(Row intermediate, Row buffer)
public T evaluate(Row buffer)
public boolean supportPartial()
Aggregate
supportPartial
in interface Aggregate<T>
public void setAggOffsetInRow(int aggOffset)
Aggregate
setAggOffsetInRow
in interface Aggregate<T>
aggOffset
- The offset of this aggregate in the intermediate aggregate rows.Copyright © 2014–2017 The Apache Software Foundation. All rights reserved.