public abstract class AbstractMeter extends java.lang.Object implements Meter
Modifier | Constructor and Description |
---|---|
protected |
AbstractMeter(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
abstract double |
calculate()
Calculate the current value based on the previous sample().
|
java.lang.String |
getName()
Returns the meter's name.
|
double |
peek()
Returns the current value.
|
abstract void |
sample()
Sample the meter, resetting any counters for the next sample.
|
java.lang.String |
toString() |
public final java.lang.String getName()
public abstract void sample()
public abstract double calculate()
public java.lang.String toString()
toString
in class java.lang.Object