Skip to content

Commit 991916f

Browse files
committed
feat: provide access to underlying data
1 parent 0720704 commit 991916f

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

analysis/src/main/java/net/laprun/sustainability/power/analysis/DescriptiveStatisticsComponentProcessor.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ public DescriptiveStatisticsComponentProcessor() {
1010
statistics = new DescriptiveStatistics();
1111
}
1212

13+
public DescriptiveStatistics statistics() {
14+
return statistics;
15+
}
16+
1317
@Override
1418
public void recordComponentValue(double value, long timestamp) {
1519
statistics.addValue(value);

analysis/src/main/java/net/laprun/sustainability/power/analysis/HdrHistogramComponentProcessor.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ public HdrHistogramComponentProcessor() {
1313
histogram = new IntCountsHistogram(HIGHEST_TRACKABLE_VALUE, NUMBER_OF_SIGNIFICANT_VALUE_DIGITS);
1414
}
1515

16+
public IntCountsHistogram histogram() {
17+
return histogram;
18+
}
19+
1620
@Override
1721
public void recordComponentValue(double value, long timestamp) {
1822
histogram.recordValue((long) (CONVERSION_FACTOR * value));

0 commit comments

Comments
 (0)