record method

void record(
  1. double value
)

Implementation

void record(double value) {
  longAvg = longAvg * (1 - _LONG_FRACTION) + value * _LONG_FRACTION;
  shortAvg = shortAvg * (1 - _SHORT_FRACTION) + value * _SHORT_FRACTION;
  min = Math.min(value, min);
  max = Math.max(value, max);
}