Adds a new Windows performance counter to the set being monitored automatically by the Listener. Manually added counters may be removed using the removeCounter method.
For more information about working with counters, see Supporting Windows Performance Counters.
void addCounter(String counterPath);
Listener listener = new Listener("sampleApp", "4.0");
listener.addCounter("\\TCP\\Segments Sent/sec");
...