Package org.quartz.utils.counter.sampled
Interface SampledCounter
-
- All Superinterfaces:
Counter
- All Known Subinterfaces:
SampledRateCounter
- All Known Implementing Classes:
SampledCounterImpl
,SampledRateCounterImpl
public interface SampledCounter extends Counter
Interface of a sampled counter -- a counter that keeps sampled values- Since:
- 1.8
- Author:
- Abhishek Sanoujam
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TimeStampedCounterValue[]
getAllSampleValues()
Returns all samples in historylong
getAndReset()
Returns the current value of the counter and resets it to 0TimeStampedCounterValue
getMostRecentSample()
Returns the most recent sampled valuevoid
shutdown()
Shutdown this counter
-
-
-
Method Detail
-
shutdown
void shutdown()
Shutdown this counter
-
getMostRecentSample
TimeStampedCounterValue getMostRecentSample()
Returns the most recent sampled value- Returns:
- Value of the most recent sampled value
-
getAllSampleValues
TimeStampedCounterValue[] getAllSampleValues()
Returns all samples in history- Returns:
- An array containing the TimeStampedCounterValue's
-
getAndReset
long getAndReset()
Returns the current value of the counter and resets it to 0- Returns:
- current value of the counter
-
-