lookupMeter Method
Creates a Meter object for a Container object or Event object of the Listener. This method will create a Meter object only when that object does not already exist. If the object already exists, the existing object is returned.
Syntax
Meter lookupMeter(String
meterName);
Parameters
- meterName
- [in] Required String, which provides the name of the Meter object. The string may be passed as Unicode that contains any printable characters, excluding the newline character.
Example
Listener listener = new Listener("sampleApp", "4.0");
Meter cacheSize = listener.lookupMeter("cache size");
- or -
Container store = listener.lookupContainer("storeName");
Meter cacheSize = store.lookupMeter("cache size");
- or -
Event creations = listener.lookupEvent(PCHeventClass.USER, "document creations", true);
Meter creationSize = creations.lookupMeter("creation size");
...