public final class ActiveTimeMeter extends AbstractMeter implements ActiveTimeSensor
Constructor and Description |
---|
ActiveTimeMeter(java.lang.String name) |
Modifier and Type | Method and Description |
---|---|
double |
calculate()
Calculate the current value based on the previous sample().
|
AbstractMeter |
createActiveCount(java.lang.String name) |
AbstractMeter |
createActiveCountMax(java.lang.String name) |
AbstractMeter |
createMax(java.lang.String name) |
AbstractMeter |
createSigma(java.lang.String name,
int n) |
AbstractMeter |
createTotalCount(java.lang.String name) |
long |
end(long startTime)
End the active time.
|
void |
sample()
Return the probe's next average.
|
double |
sampleActiveCount()
Sample the active count
|
double |
sampleActiveCountMax()
Sample the active count
|
double |
sampleMax()
Return the probe's next sample.
|
double |
sampleSigma(int n)
Return the probe's next 2-sigma
|
double |
sampleTotalCount()
Sample the total count
|
long |
start()
Start the active time.
|
getName, peek, toString
public final long start()
ActiveTimeSensor
start
in interface ActiveTimeSensor
public final long end(long startTime)
ActiveTimeSensor
end
in interface ActiveTimeSensor
public AbstractMeter createActiveCount(java.lang.String name)
public AbstractMeter createActiveCountMax(java.lang.String name)
public AbstractMeter createTotalCount(java.lang.String name)
public AbstractMeter createMax(java.lang.String name)
public AbstractMeter createSigma(java.lang.String name, int n)
public final void sample()
sample
in interface Meter
sample
in class AbstractMeter
public final double calculate()
AbstractMeter
calculate
in interface Meter
calculate
in class AbstractMeter
public final double sampleActiveCount()
public final double sampleActiveCountMax()
public final double sampleTotalCount()
public final double sampleSigma(int n)
public final double sampleMax()