%Monitor.Adaptor
Class %Monitor.Adaptor Extends %RegisteredObject [ Abstract, Not ProcedureBlock, System = 3 ]
Monitor enabling class. Users inherit from this class to register as a Monitor class.
Parameters
APPLICATION;
Parameter APPLICATION;
User name for application. Default = Package name
GROUPNAME;
Parameter GROUPNAME;
User name for this group of metrics. Default = classname
INDEX;
Parameter INDEX;
Comma separated list of properties to act as primary key for instances. Default = ""
SECURITYRESOURCE;
Parameter SECURITYRESOURCE;
Comma separated list of Resources required to view the CSP page. Default = ""
Methods
Startup
Method Startup() As %Status
The Projection creates metadata and the sample persistent class USER MAY IMPLEMENT THIS METHOD
This method is called once when the control object is created at the beginning of sampling. The user may initialize the control class.
Shutdown
Method Shutdown() As %Status
USER MAY IMPLEMENT THIS METHOD
This method is called once when the control object is closed at the end of sampling. The user may cleanup the control class.
Initialize
Method Initialize() As %Status
USER MAY IMPLEMENT THIS METHOD
This method is called to initialize the control for the first sample of a set of sample instances.
A return code of $$$OK indicates there is a new sample instance.
A return code of 0 indicates there is no sample instance.
GetSample
Method GetSample() As %Status [ Abstract ]
USER MUST IMPLEMENT THIS METHOD
This method is called to initialize and populate properties for successive sample instances.
A return code of $$$OK indicates there is a new sample instance.
A return code of 0 indicates there is no sample instance.
NOTE: If an INDEX is specified, i.e. we expect to collect multiple samples for each sampling period, then the System Monitor will loop calling GetSample() until "0" is returned. Users code MUST return "0" when all indexed sample have been collected for a period, in order to terminate the loop.
%OnNew
Method %OnNew() As %Status [ Private ]
Initialize the collection.