|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cppncss.measure.Average
public final class Average
Computes the average of a series of values.
Constructor Summary | |
---|---|
Average(java.lang.String label,
int value)
Create an average. |
Method Summary | |
---|---|
void |
accept(AverageObserver observer)
Accept a visitor. |
boolean |
update(java.lang.String label,
int value)
Add a value to the average and recompute it. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Average(java.lang.String label, int value)
label
- the label of the measurementvalue
- the first value of the measurementMethod Detail |
---|
public boolean update(java.lang.String label, int value)
If the label does not match the label given at creation the measurement is ignored.
label
- the label of the measurementvalue
- the value of the measurement
public void accept(AverageObserver observer)
observer
- an average observer
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |