Class MutableAggregation
java.lang.Object
io.opencensus.implcore.stats.MutableAggregation
- Direct Known Subclasses:
MutableAggregation.MutableCount, MutableAggregation.MutableDistribution, MutableAggregation.MutableLastValueDouble, MutableAggregation.MutableMean, MutableAggregation.MutableSumDouble
Mutable version of
Aggregation that supports adding values.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static final classCalculate count on aggregatedMeasureValues.(package private) static final classCalculate distribution stats on aggregatedMeasureValues.(package private) static classCalculate double last value on aggregatedMeasureValues.(package private) static final classCalculate last long value on aggregatedMeasureValues.(package private) static final classCalculate mean on aggregatedMeasureValues.(package private) static classCalculate sum of doubles on aggregatedMeasureValues.(package private) static final classCalculate sum of longs on aggregatedMeasureValues. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) abstract voidadd(double value, Map<String, AttachmentValue> attachments, Timestamp timestamp) Put a new value into the MutableAggregation.(package private) abstract voidcombine(MutableAggregation other, double fraction) Combine the internal values of this MutableAggregation and value of the given MutableAggregation, with the given fraction.(package private) abstract AggregationData(package private) abstract Point
-
Field Details
-
TOLERANCE
private static final double TOLERANCE- See Also:
-
-
Constructor Details
-
MutableAggregation
private MutableAggregation()
-
-
Method Details
-
add
Put a new value into the MutableAggregation.- Parameters:
value- new value to be added to populationattachments- the contextual information on anExemplartimestamp- the timestamp when the value is recorded
-
combine
Combine the internal values of this MutableAggregation and value of the given MutableAggregation, with the given fraction. Then set the internal value of this MutableAggregation to the combined value.- Parameters:
other- the otherMutableAggregation. The type of this and otherMutableAggregationmust match.fraction- the fraction that the value in otherMutableAggregationshould contribute. Must be within [0.0, 1.0].
-
toAggregationData
-
toPoint
-