In file AlarmClient/AlarmClient.hh:

class AlarmClient ifndef DMTOFFLINE : private lmsg AppClient endif

Alarm Client API The alarm client API provides an interface to the alarm manager. Refer to xxxx for a full description of the Alarm Manager functionality. The AlarmClient API allows the client process to:

Inheritance:


Public Methods

AlarmClient (const char* name=0)
Construct an alarm client interface.
virtual ~AlarmClient (void)
Alarm client destructor
lmsg::error_type cancelAlarm (const AlarmHandle& handle)
Cancel an alarm.
lmsg::error_type defineAlarm (const std::string& ID, Interval timeout=0.0, int severe=0, const std::string& desc="", const std::string& params="")
define an alarm type
lmsg::error_type defineAlarm (const AlarmData& x)
define an alarm type
lmsg::error_type getActive (const AlarmID& x, std::vector<AlarmHandle>& reply)
Get active alarm handles.
lmsg::error_type getDefined (const AlarmID& x, std::string& reply)
Get defined alarm type
lmsg::error_type getTemplate (const AlarmID& aid, AlarmData& reply)
Get defined alarm template.
lmsg::error_type prolongAlarm (const AlarmHandle& handle, Interval dt)
Prolong an alarm.
lmsg::error_type remove (const AlarmID& aid)
Remove an alarm type.
lmsg::error_type setAlarm (const AlarmData& alarm, AlarmHandle& reply)
Issue an alarm.
void setDebug (int level)
Set the debug level.
lmsg::error_type setDisable (const AlarmID& aid, bool flag=true)
Disable an alarm type.
void setName (const std::string& name)
set the monitor name.
lmsg::error_type testAlarm (const AlarmHandle& x, AlarmData& reply)
Get alarm status.

Inherited from AppClient:

Public Methods

error_type request(const MsgAddr& to, const Message& req, MsgHeader& hdr, char* data, index_type length)
error_type request(const MsgHeader& ReqHdr, const void* ReqData, MsgHeader& hdr, char* data, index_type length)
error_type request(const MsgAddr& to, const Message& Req, Message& Reply)
error_type request(const MsgAddr& to, const Message& Req, MsgHeader& RepHdr, Message& Reply)
error_type getDebug(void) const
error_type getRetry(void) const
wtime_type getTimeOut(void) const
bool isOpen(void) const
void setBufferPool(BufferPool* pool)
void setRetry(index_type n)
void setTimeOut(wtime_type time)
void setSocketPool(SocketPool* pool)

Documentation

Alarm Client API The alarm client API provides an interface to the alarm manager. Refer to xxxx for a full description of the Alarm Manager functionality. The AlarmClient API allows the client process to:
AlarmClient(const char* name=0)
Construct an alarm client interface. The optional name argument specifies the monitor name to be used in all Alarm requests. The monitor name must be specified if the interface is to be used to define or set alarms.
Parameters:
name - Monitor name to be used in defining and setting alarms.

virtual ~AlarmClient(void)
Destroy the alarm client.

lmsg::error_type cancelAlarm(const AlarmHandle& handle)
Cancel the alarm specified by the alarm handle. The Alarm manager is instructed to cancel the alarm. No action is taken if the alarm has already expired.
Returns:
Code indicating success or failure of the cancel request.
Parameters:
handle - Identifier of alarm to be canceled.

lmsg::error_type defineAlarm(const std::string& ID, Interval timeout=0.0, int severe=0, const std::string& desc="", const std::string& params="")
Define an alarm type and specify the default parameter values. The Alarm manager is instructed to add the alarm type to its database.
Returns:
Code indicating success or failure of the cancel request.
Parameters:
ID - Alarm name.
timeout - Default time before alarm expiry.
severe - Default alarm severity.
desc - Alarm description string file or URL.
params - Parameter substitution string.

lmsg::error_type defineAlarm(const AlarmData& x)
Define an alarm type and specify the default parameter values. The Alarm manager is instructed to add the alarm type to its database.
Returns:
Code indicating success or failure of the define request.
Parameters:
x - AlarmData object containing the alarm default values.

lmsg::error_type getActive(const AlarmID& x, std::vector<AlarmHandle>& reply)
Get a list of active alarms known by the alarm manager.
Returns:
Code indicating success or failure of the request.
Parameters:
x - AlarmID object specifying a pattern for alarms.
reply - Vector of alarm handles.

lmsg::error_type getDefined(const AlarmID& x, std::string& reply)
Get a list of alarm types known by the alarm manager.
Returns:
Code indicating success or failure of the request.
Parameters:
x - AlarmID object specifying a pattern for alarms.
reply - string of alarm IDs.

lmsg::error_type getTemplate(const AlarmID& aid, AlarmData& reply)
Get the template alarm data of an alarm type known by the alarm manager.
Returns:
Code indicating success or failure of the request.
Parameters:
x - AlarmID object specifying an alarm type.
reply - Template infomation kept by the manager.

lmsg::error_type prolongAlarm(const AlarmHandle& handle, Interval dt)
Prolong the alarm specified by the alarm handle. The Alarm manager is instructed to increase the expiry time of the existing alarm by the specified time duration. No action is taken if the alarm has already expired, although an Invalid code is returned.
Returns:
Code indicating success or failure of the prolongation request.
Parameters:
handle - Identifier of alarm to be prolonged.
dt - Duration increment.

lmsg::error_type remove(const AlarmID& aid)
The alarm manager is requested to remove the specified alarm type definition from its table.
Returns:
Code indicating success or failure of the removal request.
Parameters:
aid - Identifier of alarm to be removed.

lmsg::error_type setAlarm(const AlarmData& alarm, AlarmHandle& reply)
The alarm manager is instructed to activate an alarm. The alarm remains active until it expires or is explicitly cancelled. Any parameters not specified in the alarm must have default values specified.
Returns:
Code indicating success or failure of the set request.
Parameters:
alarm - AlarmData specifying the alarm to be issued.
reply - Handle to the alarm is successfully issued.

void setDebug(int level)
Set the level of debugging output to print.
Parameters:
name - Debug level.

lmsg::error_type setDisable(const AlarmID& aid, bool flag=true)
The alarm manager is instructed to enable or disable an alarm type. Any attempts to set an alarm that has been disabled will be ignored. The alarm type may be reenabled with the same
Returns:
Code indicating success or failure.
Parameters:
aid - AlarmID specifying the alarm type to be disabled.
flag - If true the alarm is diabled, if false it is enabled.

void setName(const std::string& name)
Set the monitor name to be used any time an alarm is defined or set.
Parameters:
name - Monitor name.

lmsg::error_type testAlarm(const AlarmHandle& x, AlarmData& reply)
Get the current status of the alarm specified by the handle.
Returns:
Code indicating success or failure of the request.
Parameters:
handle - Handle of alarm to be interrogated.
reply - Status of alaram (returned).


This class has no child classes.
Author:
J. Zweizig
Version:
; Last Modified

alphabetic index hierarchy of classes


Please send questions and comments to zweizig_j@ligo.caltech.edu


generated by doc++