![JAR search and dependency download from the Maven repository](/logo.png)
com.fillumina.performance.util.RunningStatistics Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of performance-tools Show documentation
Show all versions of performance-tools Show documentation
Configurable tool to easily compare performances of different code
snippets and to take performance telemetry of a running application.
The newest version!
package com.fillumina.performance.util;
import java.util.Collection;
/**
* Calculates live statistics over a set of data.
* The values are not retained and all statistics
* are calculated on the run so its memory footprint is fixed whatever amount
* of data is collected.
*
* @author Francesco Illuminati
*/
public class RunningStatistics extends Statistics {
private static final long serialVersionUID = 1L;
public static RunningStatistics[] createArray(final int size) {
final RunningStatistics[] array = new RunningStatistics[size];
for (int i=0; i collection) {
addAll(collection);
}
@Override
public final void addAll(final double... values) {
super.addAll(values);
}
@Override
public final void addAll(final Collection extends Number> collection) {
super.addAll(collection);
}
@Override
public final void add(final double value) {
super.add(value);
}
@Override
public final void clear() {
super.clear();
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy