Package com.helger.commons.statistics
Class StatisticsHandlerCache
- java.lang.Object
-
- com.helger.commons.statistics.StatisticsHandlerCache
-
- All Implemented Interfaces:
IMutableStatisticsHandlerCache,IStatisticsHandler,IStatisticsHandlerCache
@ThreadSafe public class StatisticsHandlerCache extends Object implements IMutableStatisticsHandlerCache
Default implementation ofIMutableStatisticsHandlerCache- Author:
- Philip Helger
-
-
Constructor Summary
Constructors Constructor Description StatisticsHandlerCache()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcacheHit()Called when a cache hit occurred.voidcacheMiss()Called when a cache miss occurred.intgetHits()intgetInvocationCount()intgetMisses()
-
-
-
Method Detail
-
getInvocationCount
@Nonnegative public int getInvocationCount()
- Specified by:
getInvocationCountin interfaceIStatisticsHandler- Returns:
- The number of times this statistics hander was invoked.
-
cacheHit
public void cacheHit()
Description copied from interface:IMutableStatisticsHandlerCacheCalled when a cache hit occurred.- Specified by:
cacheHitin interfaceIMutableStatisticsHandlerCache
-
cacheMiss
public void cacheMiss()
Description copied from interface:IMutableStatisticsHandlerCacheCalled when a cache miss occurred.- Specified by:
cacheMissin interfaceIMutableStatisticsHandlerCache
-
getHits
@Nonnegative public int getHits()
- Specified by:
getHitsin interfaceIStatisticsHandlerCache
-
getMisses
@Nonnegative public int getMisses()
- Specified by:
getMissesin interfaceIStatisticsHandlerCache
-
-