Class TimePeriodAveragingCollater
java.lang.Object
com.atlassian.bamboo.charts.timeperiod.AbstractTimePeriodCollater
com.atlassian.bamboo.clover.charts.collater.TimePeriodAveragingCollater
- All Implemented Interfaces:
TimePeriodCollater
- Direct Known Subclasses:
TimePeriodCoverageCollater
,TimePeriodLOCCollater
,TimePeriodNCLOCCollater
public abstract class TimePeriodAveragingCollater
extends AbstractTimePeriodCollater
implements TimePeriodCollater
Base class which collects values from build results from a specified metadata key, by summing them and
next dividing by count. An averaging collater is being used here, because in case there is more than one build
result in the specified time period, an average value is be returned.
-
Field Summary
Fields inherited from class com.atlassian.bamboo.charts.timeperiod.AbstractTimePeriodCollater
period, seriesName
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addResult
(ResultStatisticsProvider result) abstract boolean
Whether results from successful or all builds should be considered.abstract String
A meta data key to be summed up.double
getValue()
Methods inherited from class com.atlassian.bamboo.charts.timeperiod.AbstractTimePeriodCollater
getPeriod, getSeriesName, setPeriod, setSeriesName
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.atlassian.bamboo.charts.collater.TimePeriodCollater
getPeriod, getSeriesName, setPeriod, setSeriesName
-
Constructor Details
-
TimePeriodAveragingCollater
public TimePeriodAveragingCollater()
-
-
Method Details
-
getMetaDataKey
A meta data key to be summed up.- Returns:
- String key name
-
countSuccessfulBuildsOnly
public abstract boolean countSuccessfulBuildsOnly()Whether results from successful or all builds should be considered.- Returns:
- boolean true for successful only, false for all builds
-
addResult
- Specified by:
addResult
in interfaceTimePeriodCollater
-
getValue
public double getValue()- Specified by:
getValue
in interfaceTimePeriodCollater
-