#include <devicecpu.h>
void DeviceCpu::stress |
( |
| ) |
|
757 for (
int i = 0;
i< 40000;
i++) {
758 double temp = sqrt(
i)*
i/log(
i);
int i
Definition: rw_test.cpp:37
double DeviceCpu::getLoad |
( |
| ) |
|
41 #if defined(COSMOS_LINUX_OS) 42 load = cpuLinux.getLoad1minAverage();
45 #if defined(COSMOS_MAC_OS) 46 load = cpuMac.getLoad1minAverage();
49 #if defined(COSMOS_WIN_OS) int numProcessors
Definition: devicecpu.h:245
double load
Definition: devicecpu.h:255
uint16_t DeviceCpu::getCpuCount |
( |
| ) |
|
59 #if defined(COSMOS_LINUX_OS) 60 count = cpuLinux.getCpuCount();
int count
Definition: rw_test.cpp:36
uint32_t DeviceCpu::getUptime |
( |
| ) |
|
77 #if defined(COSMOS_LINUX_OS) 78 count = cpuLinux.getUptime();
int count
Definition: rw_test.cpp:36
uint16_t DeviceCpu::getBootCount |
( |
| ) |
|
68 #if defined(COSMOS_LINUX_OS) 69 count = cpuLinux.getBootCount();
int count
Definition: rw_test.cpp:36
double DeviceCpu::getVirtualMemoryTotal |
( |
| ) |
|
170 #if defined(COSMOS_LINUX_OS) 174 #if defined(COSMOS_WIN_OS) double virtualMemoryTotal
Definition: devicecpu.h:253
double DeviceCpu::getVirtualMemoryUsed |
( |
| ) |
|
112 #if defined(COSMOS_LINUX_OS) 116 #if defined(COSMOS_WIN_OS) double virtualMemoryUsed
Definition: devicecpu.h:252
double DeviceCpu::getVirtualMemoryFree |
( |
| ) |
|
double DeviceCpu::getVirtualMemoryUsedPercent |
( |
| ) |
|
187 return virtualMemoryUsedPercent;
double getVirtualMemoryTotal()
Definition: devicecpu.cpp:168
double getVirtualMemoryUsed()
Definition: devicecpu.cpp:110
double DeviceCpu::getPercentUseForCurrentProcess |
( |
| ) |
|
193 #if defined(COSMOS_LINUX_OS) 197 #if defined(COSMOS_WIN_OS) double percentUseForCurrentProcess
Definition: devicecpu.h:244
string DeviceCpu::getHostName |
( |
| ) |
|
207 #if defined(COSMOS_LINUX_OS) 211 #if defined(COSMOS_MAC_OS) 215 #if defined(COSMOS_WIN_OS) string hostName
Definition: devicecpu.h:247
double DeviceCpu::BytesToKiB |
( |
double |
bytes | ) |
|
double DeviceCpu::BytesToMiB |
( |
double |
bytes | ) |
|
279 return bytes/1024./1024.;
double DeviceCpu::BytesToMB |
( |
double |
bytes | ) |
|
284 return bytes/1000./1000.;
double DeviceCpu::getVirtualMemoryUsedKiB |
( |
| ) |
|
double BytesToKiB(double bytes)
Definition: devicecpu.cpp:272
double getVirtualMemoryUsed()
Definition: devicecpu.cpp:110
double DeviceCpu::getVirtualMemoryUsedMiB |
( |
| ) |
|
double BytesToMiB(double bytes)
Definition: devicecpu.cpp:277
double getVirtualMemoryUsed()
Definition: devicecpu.cpp:110
double DeviceCpu::getVirtualMemoryUsedMB |
( |
| ) |
|
double BytesToMB(double bytes)
Definition: devicecpu.cpp:282
double getVirtualMemoryUsed()
Definition: devicecpu.cpp:110
double DeviceCpu::getMemoryUsed |
( |
| ) |
|
99 #if defined(COSMOS_LINUX_OS) 103 #if defined(COSMOS_WIN_OS) double memoryUsed
Definition: devicecpu.h:248
double DeviceCpu::getMemoryTotal |
( |
| ) |
|
86 #if defined(COSMOS_LINUX_OS) 90 #if defined(COSMOS_WIN_OS) double memoryTotal
Definition: devicecpu.h:249
double DeviceCpu::getMemoryUsedKiB |
( |
| ) |
|
double BytesToKiB(double bytes)
Definition: devicecpu.cpp:272
double getMemoryUsed()
Definition: devicecpu.cpp:97
double DeviceCpu::getMemoryUsedMiB |
( |
| ) |
|
double getMemoryUsed()
Definition: devicecpu.cpp:97
double BytesToMiB(double bytes)
Definition: devicecpu.cpp:277
double DeviceCpu::getMemoryTotalKiB |
( |
| ) |
|
double BytesToKiB(double bytes)
Definition: devicecpu.cpp:272
double getMemoryTotal()
Definition: devicecpu.cpp:84
double DeviceCpu::getMemoryTotalMiB |
( |
| ) |
|
double getMemoryTotal()
Definition: devicecpu.cpp:84
double BytesToMiB(double bytes)
Definition: devicecpu.cpp:277
double DeviceCpu::getMemoryUsedMB |
( |
| ) |
|
double getMemoryUsed()
Definition: devicecpu.cpp:97
double BytesToMB(double bytes)
Definition: devicecpu.cpp:282
double DeviceCpu::getMemoryTotalMB |
( |
| ) |
|
double BytesToMB(double bytes)
Definition: devicecpu.cpp:282
double getMemoryTotal()
Definition: devicecpu.cpp:84
pid_t DeviceCpu::getPidOf |
( |
string |
processName | ) |
|
224 #if defined(COSMOS_LINUX_OS) 228 #if defined(COSMOS_WIN_OS) string processName
Definition: devicecpu.h:246
pid_t DeviceCpu::getMemoryUsedOf |
( |
string |
processName | ) |
|
236 #if defined(COSMOS_LINUX_OS) 240 #if defined(COSMOS_WIN_OS) string processName
Definition: devicecpu.h:246
float DeviceCpu::getPercentCpuOf |
( |
string |
processName | ) |
|
249 #if defined(COSMOS_LINUX_OS) 253 #if defined(COSMOS_WIN_OS) string processName
Definition: devicecpu.h:246
float DeviceCpu::getPercentMemoryOf |
( |
string |
processName | ) |
|
261 #if defined(COSMOS_LINUX_OS) 265 #if defined(COSMOS_WIN_OS) string processName
Definition: devicecpu.h:246
double DeviceCpu::percentUseForCurrentProcess |
int DeviceCpu::numProcessors |
string DeviceCpu::processName |
string DeviceCpu::hostName |
double DeviceCpu::memoryUsed |
double DeviceCpu::memoryTotal |
double DeviceCpu::memoryFree |
double DeviceCpu::memoryBuffers |
double DeviceCpu::virtualMemoryUsed |
double DeviceCpu::virtualMemoryTotal |
double DeviceCpu::virtualMemoryFree |
The documentation for this class was generated from the following files: