Interface ResourceStatsComputer<T extends ResourceStats>
- Type Parameters:
T- the class in which resource utilization will be computed and stored
- All Known Implementing Classes:
HostAbstract,HostSimple,NetworkHost,NetworkVm,VmAbstract,VmGroup,VmSimple
public interface ResourceStatsComputer<T extends ResourceStats>
An interface that enables machines (
Vms or Hosts)
to enable the calculation of statistics for its resource utilization.
Since that may be computationally complex and increase memory consumption,
you have to explicitly enable that by calling enableUtilizationStats().- Since:
- CloudSim Plus 6.1.0
- Author:
- Manoel Camops da Silva Filho
-
Method Summary
Modifier and TypeMethodDescriptionvoidEnables the data collection and computation of utilization statistics.Gets machine's CPU utilization percentage statistics (between [0 and 1]).
-
Method Details
-
getCpuUtilizationStats
T getCpuUtilizationStats()Gets machine's CPU utilization percentage statistics (between [0 and 1]).WARNING: You need to enable the data collection and computation of statistics by calling
enableUtilizationStats().The time interval in which utilization is collected is defined by the
Datacenter.getSchedulingInterval().- Returns:
- an object containing the statistics
-
enableUtilizationStats
void enableUtilizationStats()Enables the data collection and computation of utilization statistics.- See Also:
-