Class UtilizationCalculator
- java.lang.Object
-
- edu.kit.ipd.sdq.eventsim.resources.rjobs.window.UtilizationCalculator
-
- All Implemented Interfaces:
WindowCalculator
public class UtilizationCalculator extends Object implements WindowCalculator
-
-
Constructor Summary
Constructors Constructor Description UtilizationCalculator(double windowSize)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description double
processValue(double queueLength, double consumedDuration)
Calculates how the current window's value has to change when integrating the given observation:
-
-
-
Method Detail
-
processValue
public double processValue(double queueLength, double consumedDuration)
Description copied from interface:WindowCalculator
Calculates how the current window's value has to change when integrating the given observation:currentWindow = currentWindow + processValue(observation, duration)
This method will be called at least once per window. The common case is, however, that this method is called multiple times for each window in order to incrementally fill the window.- Specified by:
processValue
in interfaceWindowCalculator
- Parameters:
queueLength
- the observation to be integratedconsumedDuration
- the time span the observation is valid- Returns:
- the summand that needs to be added (mathematically) to the current window's value so that the observations subsumed by the window include the passed observation.
-
-