public class AggregateConsumer extends AbstractSampleConsumer
Constructor and Description |
---|
AggregateConsumer(Aggregator aggregator,
SampleSelector<java.lang.Double> selector)
Instantiates a new abstract aggregate consumer.
|
Modifier and Type | Method and Description |
---|---|
void |
consume(Sample sample,
int channel)
Consumes the specified sample ton the specified channel.
|
Aggregator |
getAggregator()
Gets the aggregator.
|
SampleSelector<java.lang.Double> |
getSelector()
Gets the selector.
|
void |
startConsuming()
Start the sample consuming.
|
void |
stopConsuming()
Stops the consuming process.
|
addSampleConsumer, getConsumedChannelCount, getConsumedMetadata, getConsumer, getDataFromContext, getName, getWorkingDirectory, produce, removeSampleConsumer, setChannelAttribute, setConsumedMetadata, setDataToContext, setName, setProducedMetadata, setSampleConsumer, setSampleConsumers, setSampleContext, startProducing, stopProducing
getChannelAttribute, getSampleContext
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getChannelAttribute, getSampleContext
public AggregateConsumer(Aggregator aggregator, SampleSelector<java.lang.Double> selector)
aggregator
- the aggregator (must not be null
)selector
- the selector (must not be null
)public final Aggregator getAggregator()
public final SampleSelector<java.lang.Double> getSelector()
public void startConsuming()
SampleConsumer
public void consume(Sample sample, int channel)
SampleConsumer
sample
- The sample to be consumedchannel
- The channel on which the sample is consumedpublic void stopConsuming()
SampleConsumer
Copyright © 1998-2019 Apache Software Foundation. All Rights Reserved.