public abstract class SketchAggregatorFactory extends Object implements AggregatorFactory
| Modifier and Type | Field and Description |
|---|---|
static Comparator<com.yahoo.sketches.theta.Sketch> |
COMPARATOR |
static int |
DEFAULT_MAX_SKETCH_SIZE |
protected String |
fieldName |
protected String |
name |
protected int |
size |
| Constructor and Description |
|---|
SketchAggregatorFactory(String name,
String fieldName,
Integer size,
byte cacheId) |
| Modifier and Type | Method and Description |
|---|---|
Object |
combine(Object lhs,
Object rhs)
A method that knows how to combine the outputs of the getIntermediate() method from the Aggregators
produced via factorize().
|
Object |
deserialize(Object object)
A method that knows how to "deserialize" the object from whatever form it might have been put into
in order to transfer via JSON.
|
boolean |
equals(Object o) |
Aggregator |
factorize(ColumnSelectorFactory metricFactory) |
BufferAggregator |
factorizeBuffered(ColumnSelectorFactory metricFactory) |
Object |
getAggregatorStartValue()
Returns the starting value for a corresponding aggregator.
|
byte[] |
getCacheKey() |
Comparator<com.yahoo.sketches.theta.Sketch> |
getComparator() |
String |
getFieldName() |
int |
getMaxIntermediateSize()
Returns the maximum size that this aggregator will require in bytes for intermediate storage of results.
|
String |
getName() |
int |
getSize() |
int |
hashCode() |
List<String> |
requiredFields() |
String |
toString() |
clone, finalize, getClass, notify, notifyAll, wait, wait, waitfinalizeComputation, getCombiningFactory, getRequiredColumns, getTypeNamepublic static final int DEFAULT_MAX_SKETCH_SIZE
protected final String name
protected final String fieldName
protected final int size
public static final Comparator<com.yahoo.sketches.theta.Sketch> COMPARATOR
public Aggregator factorize(ColumnSelectorFactory metricFactory)
factorize in interface AggregatorFactorypublic BufferAggregator factorizeBuffered(ColumnSelectorFactory metricFactory)
factorizeBuffered in interface AggregatorFactorypublic Object deserialize(Object object)
AggregatorFactorydeserialize in interface AggregatorFactoryobject - the object to deserializepublic Comparator<com.yahoo.sketches.theta.Sketch> getComparator()
getComparator in interface AggregatorFactorypublic Object combine(Object lhs, Object rhs)
AggregatorFactorycombine in interface AggregatorFactorylhs - The left hand side of the combinerhs - The right hand side of the combinepublic String getName()
getName in interface AggregatorFactorypublic String getFieldName()
public int getSize()
public int getMaxIntermediateSize()
AggregatorFactorygetMaxIntermediateSize in interface AggregatorFactorypublic Object getAggregatorStartValue()
AggregatorFactorygetAggregatorStartValue in interface AggregatorFactorypublic List<String> requiredFields()
requiredFields in interface AggregatorFactorypublic byte[] getCacheKey()
getCacheKey in interface AggregatorFactoryCopyright © 2011–2016. All rights reserved.