Package com.helger.commons.statistics
Class StatisticsHandlerCounter
java.lang.Object
com.helger.commons.statistics.StatisticsHandlerCounter
- All Implemented Interfaces:
IMutableStatisticsHandlerCounter,IStatisticsHandler,IStatisticsHandlerCounter
@ThreadSafe
public class StatisticsHandlerCounter
extends Object
implements IMutableStatisticsHandlerCounter
Default implementation of
IMutableStatisticsHandlerCounter- Author:
- Philip Helger
-
Constructor Details
-
StatisticsHandlerCounter
public StatisticsHandlerCounter()
-
-
Method Details
-
getInvocationCount
- Specified by:
getInvocationCountin interfaceIStatisticsHandler- Returns:
- The number of times this statistics hander was invoked.
-
getCount
- Specified by:
getCountin interfaceIStatisticsHandlerCounter- Returns:
- The total count. May be negative if negative values were added.
-
increment
public void increment(long nByHowMany) Description copied from interface:IMutableStatisticsHandlerCounterIncrement the counter by an arbitrary number- Specified by:
incrementin interfaceIMutableStatisticsHandlerCounter- Parameters:
nByHowMany- The number to be added. May be negative as well.
-