public final class JmxAttributeMeter extends AbstractMeter
Constructor and Description |
---|
JmxAttributeMeter(java.lang.String name,
java.lang.String objectName,
java.lang.String attribute,
boolean isOptional) |
Modifier and Type | Method and Description |
---|---|
double |
calculate()
Calculate the current value based on the previous sample().
|
boolean |
isOptional() |
double |
peek()
Returns the current value.
|
void |
sample()
Polls the statistics attribute.
|
void |
setOptional(boolean optional) |
getName, toString
public JmxAttributeMeter(java.lang.String name, java.lang.String objectName, java.lang.String attribute, boolean isOptional)
public void sample()
sample
in interface Meter
sample
in class AbstractMeter
public double calculate()
AbstractMeter
calculate
in interface Meter
calculate
in class AbstractMeter
public double peek()
AbstractMeter
peek
in interface Meter
peek
in class AbstractMeter
public boolean isOptional()
public void setOptional(boolean optional)