@InterfaceAudience.Private public class SimpleMovingAverage extends MovingAverage
Modifier and Type | Field and Description |
---|---|
protected long |
count |
label
Constructor and Description |
---|
SimpleMovingAverage(String label) |
Modifier and Type | Method and Description |
---|---|
double |
getAverageTime()
Get average execution time of the measured method.
|
void |
updateMostRecentTime(long elapsed)
Update the most recent data.
|
measure, start, stop
public SimpleMovingAverage(String label)
public void updateMostRecentTime(long elapsed)
MovingAverage
updateMostRecentTime
in class MovingAverage
elapsed
- elapsed time of the most recent measurementpublic double getAverageTime()
MovingAverage
getAverageTime
in class MovingAverage
Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.