Class SingleTypedHistogram
- java.lang.Object
-
- io.trino.operator.aggregation.histogram.SingleTypedHistogram
-
- All Implemented Interfaces:
TypedHistogram
public class SingleTypedHistogram extends Object implements TypedHistogram
-
-
Constructor Summary
Constructors Constructor Description SingleTypedHistogram(Block block, Type type, BlockTypeOperators.BlockPositionEqual equalOperator, BlockTypeOperators.BlockPositionHashCode hashCodeOperator, int expectedSize)SingleTypedHistogram(Type type, BlockTypeOperators.BlockPositionEqual equalOperator, BlockTypeOperators.BlockPositionHashCode hashCodeOperator, int expectedSize)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidadd(int position, Block block, long count)voidaddAll(TypedHistogram other)longgetEstimatedSize()intgetExpectedSize()TypegetType()booleanisEmpty()voidreadAllValues(HistogramValueReader reader)voidserialize(BlockBuilder out)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.trino.operator.aggregation.histogram.TypedHistogram
ensureCapacity, setGroupId
-
-
-
-
Constructor Detail
-
SingleTypedHistogram
public SingleTypedHistogram(Type type, BlockTypeOperators.BlockPositionEqual equalOperator, BlockTypeOperators.BlockPositionHashCode hashCodeOperator, int expectedSize)
-
SingleTypedHistogram
public SingleTypedHistogram(Block block, Type type, BlockTypeOperators.BlockPositionEqual equalOperator, BlockTypeOperators.BlockPositionHashCode hashCodeOperator, int expectedSize)
-
-
Method Detail
-
getEstimatedSize
public long getEstimatedSize()
- Specified by:
getEstimatedSizein interfaceTypedHistogram
-
serialize
public void serialize(BlockBuilder out)
- Specified by:
serializein interfaceTypedHistogram
-
addAll
public void addAll(TypedHistogram other)
- Specified by:
addAllin interfaceTypedHistogram
-
readAllValues
public void readAllValues(HistogramValueReader reader)
- Specified by:
readAllValuesin interfaceTypedHistogram
-
add
public void add(int position, Block block, long count)- Specified by:
addin interfaceTypedHistogram
-
getType
public Type getType()
- Specified by:
getTypein interfaceTypedHistogram
-
getExpectedSize
public int getExpectedSize()
- Specified by:
getExpectedSizein interfaceTypedHistogram
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmptyin interfaceTypedHistogram
-
-