Module datarush.commons
Class RuntimeStatistic<T extends StatisticSupplier>
- java.lang.Object
-
- com.pervasive.datarush.monitoring.RuntimeStatistic<T>
-
- Type Parameters:
T
- the type of statistic supplier
- All Implemented Interfaces:
Serializable
public final class RuntimeStatistic<T extends StatisticSupplier> extends Object implements Serializable
Pairing of aStatisticDefinition
and itsStatisticSupplier
.- See Also:
StatisticDefinition
,StatisticSupplier
, Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RuntimeStatistic(StatisticDefinition<T> definition, T supplier)
Create a new statistic
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StatisticDefinition<T>
definition()
Return the definition of this statisticRuntimeStatistic<T>
finalSnapshot()
Creates a final snapshot of this statisticRuntimeStatistic<T>
snapshot()
Creates a snapshot of this statisticT
supplier()
Returns the supplier of this statistic
-
-
-
Constructor Detail
-
RuntimeStatistic
public RuntimeStatistic(StatisticDefinition<T> definition, T supplier)
Create a new statistic- Parameters:
definition
- the definitionsupplier
- the supplier
-
-
Method Detail
-
definition
public StatisticDefinition<T> definition()
Return the definition of this statistic- Returns:
- the definition
-
supplier
public T supplier()
Returns the supplier of this statistic- Returns:
- the supplier
-
snapshot
public RuntimeStatistic<T> snapshot()
Creates a snapshot of this statistic- Returns:
- a snapshot
-
finalSnapshot
public RuntimeStatistic<T> finalSnapshot()
Creates a final snapshot of this statistic- Returns:
- a snapshot
-
-