When running on Microsoft® Windows®, the System Manager monitors performance counters, such as CPU usage, Network packets sent and received, and so on. This is accomplished through the use of the Microsoft Windows Performance Data Handler library (PDH.dll).
The System Manager Listener Java™ API enables the application to specify additional counters to the set being monitored automatically by the Listener. Manually added counters are reported as Events in the CPU Event class. Note that these application-supplied counter names will be ignored when running on any other operating system.
To add a new counter, use the addCounter method of the Listener object, as follows:
listener.addCounter("counterPath");
To remove a counter from the set, use the removeCounter method, as follows:
listener.removeCounter("counterPath");
The counterPath is a string which specifies a valid counter path.