public class InvocationStatisticsCalculator extends java.lang.Object implements InvocationStatistics
| Modifier and Type | Field and Description | 
|---|---|
| private long | callCount | 
| private long | errorCount | 
| private int | index | 
| private java.lang.String | name | 
| private long[] | times | 
| private long | totalTime | 
| Constructor and Description | 
|---|
| InvocationStatisticsCalculator(java.lang.String name,
                              int historySize) | 
| Modifier and Type | Method and Description | 
|---|---|
| long | getAverageTime() | 
| long | getCallCount() | 
| long | getErrorCount() | 
| java.lang.String | getName() | 
| long | getTotalTime() | 
| (package private) void | increment(long time,
         boolean success) | 
| void | reset() | 
| java.lang.String | toString() | 
private java.lang.String name
private long[] times
private int index
private long callCount
private long errorCount
private long totalTime
public InvocationStatisticsCalculator(java.lang.String name,
                              int historySize)
name - the name of this API methodhistorySize - the number of calls to track (for invocation time averaging)void increment(long time,
             boolean success)
public java.lang.String getName()
getName in interface InvocationStatisticspublic long getCallCount()
getCallCount in interface InvocationStatisticspublic long getErrorCount()
getErrorCount in interface InvocationStatisticspublic long getTotalTime()
getTotalTime in interface InvocationStatisticspublic long getAverageTime()
getAverageTime in interface InvocationStatisticspublic void reset()
reset in interface InvocationStatisticspublic java.lang.String toString()
toString in class java.lang.Object