Package elki.logging.statistics
Class LongStatistic
- java.lang.Object
-
- elki.logging.statistics.AbstractStatistic
-
- elki.logging.statistics.LongStatistic
-
- All Implemented Interfaces:
Statistic
public class LongStatistic extends AbstractStatistic
Trivial long-valued statistic.- Since:
- 0.6.0
- Author:
- Erich Schubert
-
-
Field Summary
Fields Modifier and Type Field Description (package private) long
value
Statistic value.-
Fields inherited from class elki.logging.statistics.AbstractStatistic
key
-
-
Constructor Summary
Constructors Constructor Description LongStatistic(java.lang.String key)
Constructor.LongStatistic(java.lang.String key, long value)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
formatValue()
Get a formatted version of the value, for output.LongStatistic
increment(long inc)
Increment counter.LongStatistic
setLong(long value)
Set the statistics.-
Methods inherited from class elki.logging.statistics.AbstractStatistic
getKey, toString
-
-
-
-
Method Detail
-
setLong
public LongStatistic setLong(long value)
Set the statistics.- Parameters:
value
- New value- Returns:
this
for chaining
-
increment
public LongStatistic increment(long inc)
Increment counter.- Parameters:
inc
- Increment- Returns:
this
for chaining
-
formatValue
public java.lang.String formatValue()
Description copied from interface:Statistic
Get a formatted version of the value, for output.- Returns:
- Value
-
-