Inheritance diagram for lm::LoadMonitor::SystemEnumCache:
Public Member Functions | |
SystemEnumCache (void) | |
Create new cache object. | |
virtual | ~SystemEnumCache (void) |
Free used resources. | |
virtual bool | AddToRefresher (IWbemConfigureRefresher *configure, IWbemServices *services) |
Add object to the refresher. | |
virtual void | Release (void) |
Free resources. | |
virtual bool | QueryData (LoadSample &target) |
Query data. | |
Protected Member Functions | |
virtual bool | CacheImpl (IWbemObjectAccess *access_object) |
Cache property handles. | |
Private Attributes | |
IWbemHiPerfEnum * | enum_system |
Enumerator for Win32_PerfRawData_PerfOS_System or Win32_PerfFormattedData_PerfOS_System. | |
long | enum_system_id |
ID of the system enumerator. | |
long | id_processes |
ID of the "Processes" property. | |
long | id_processor_queue |
ID of the "ProcessorQueueLength" property. |
lm::LoadMonitor::SystemEnumCache::SystemEnumCache | ( | void | ) |
Create new cache object.
lm::LoadMonitor::SystemEnumCache::~SystemEnumCache | ( | void | ) | [virtual] |
Free used resources.
bool lm::LoadMonitor::SystemEnumCache::AddToRefresher | ( | IWbemConfigureRefresher * | configure, | |
IWbemServices * | services | |||
) | [virtual] |
Add object to the refresher.
configure | Configure refresher which will be used to add required objects to the refresher. | |
services | WMI service provider. |
Implements lm::LoadMonitor::PerformanceCounterEnumCache.
bool lm::LoadMonitor::SystemEnumCache::CacheImpl | ( | IWbemObjectAccess * | access_object | ) | [protected, virtual] |
Cache property handles.
access_object | Object which contains all properties that need to be cached. |
Implements lm::LoadMonitor::PerformanceCounterEnumCache.
bool lm::LoadMonitor::SystemEnumCache::QueryData | ( | LoadSample & | target | ) | [virtual] |
Query data.
Query data after it has been refreshed. This will collect all data from enumerators previously registered with refresher via AddToRefresher method and store resulting data in provided load sample. If data are stored in array (e.g. CPU usage on multi-processor machines), arrays will be automatically allocated. If query fails, sample will remain unmodified.
target | Reference to the load sample which will receive data. |
Implements lm::LoadMonitor::PerformanceCounterEnumCache.
void lm::LoadMonitor::SystemEnumCache::Release | ( | void | ) | [virtual] |
IWbemHiPerfEnum* lm::LoadMonitor::SystemEnumCache::enum_system [private] |
Enumerator for Win32_PerfRawData_PerfOS_System or Win32_PerfFormattedData_PerfOS_System.
long lm::LoadMonitor::SystemEnumCache::enum_system_id [private] |
ID of the system enumerator.
long lm::LoadMonitor::SystemEnumCache::id_processes [private] |
ID of the "Processes" property.
long lm::LoadMonitor::SystemEnumCache::id_processor_queue [private] |
ID of the "ProcessorQueueLength" property.