Class UsageFunction
java.lang.Object
com.illumon.iris.db.tables.remotequery.UsageFunction
-
Constructor Summary
ConstructorsConstructorDescriptionUsageFunction
(String name, long intervalMS) Constructs a UsageFunction that uses intervalMS as the decay interval in its EMA function, with initial value 0. -
Method Summary
-
Constructor Details
-
UsageFunction
Constructs a UsageFunction that uses intervalMS as the decay interval in its EMA function, with initial value 0.- Parameters:
name
-intervalMS
-
-
-
Method Details
-
getValue
public double getValue()- Returns:
- The last calculated value for this UsageFunction
-
isInitialized
public boolean isInitialized()- Returns:
- The state of this UsageFunction
-
update
public void update(double observation, long observationDurationMS) Updates the value of this function according to an Exponential Moving Average (EMA).- Parameters:
observation
-observationDurationMS
-
-