private static class Aggregators.SumConsumer extends Aggregators.QuantityConsumer<Aggregators.SumConsumer>
Modifier and Type | Field and Description |
---|---|
(package private) double |
sum |
(package private) IUnit |
unit |
accessor
Constructor and Description |
---|
SumConsumer(IMemberAccessor<? extends IQuantity,IItem> accessor) |
Modifier and Type | Method and Description |
---|---|
void |
consume(IItem item)
Consumes another item.
|
Aggregators.SumConsumer |
merge(Aggregators.SumConsumer other)
Merges this object with the supplied object.
|
double sum
IUnit unit
SumConsumer(IMemberAccessor<? extends IQuantity,IItem> accessor)
public void consume(IItem item)
IItemConsumer
public Aggregators.SumConsumer merge(Aggregators.SumConsumer other)
IItemConsumer
other
- another instance to merge with