public abstract class AbstractStats extends java.lang.Object implements CountStats
| Modifier and Type | Field and Description |
|---|---|
protected int |
count |
static StatsBase |
EMPTY_STATS
Used when we want to send up a metric with a zero call count.
|
| Constructor and Description |
|---|
AbstractStats() |
AbstractStats(int count) |
| Modifier and Type | Method and Description |
|---|---|
abstract java.lang.Object |
clone()
Every stats base should be cloneable.
|
int |
getCallCount()
Returns the invocation count.
|
void |
incrementCallCount()
Increment the call count by one.
|
void |
incrementCallCount(int value)
Increment the call count by the given value.
|
void |
setCallCount(int count)
Sets the invocation count.
|
void |
writeJSONString(java.io.Writer writer) |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetMaxCallTime, getMinCallTime, getSumOfSquares, getTotal, getTotalExclusiveTimeprotected int count
public static final StatsBase EMPTY_STATS
public AbstractStats()
public AbstractStats(int count)
public void incrementCallCount(int value)
CountStatsincrementCallCount in interface CountStatspublic void incrementCallCount()
CountStatsincrementCallCount in interface CountStatspublic int getCallCount()
CountStatsgetCallCount in interface CountStatspublic void setCallCount(int count)
CountStatssetCallCount in interface CountStatspublic final void writeJSONString(java.io.Writer writer)
throws java.io.IOException,
InvalidStatsException
writeJSONString in interface org.json.simple.JSONStreamAwarejava.io.IOExceptionInvalidStatsExceptionpublic abstract java.lang.Object clone()
throws java.lang.CloneNotSupportedException
StatsBase