Dataflow Runtime API
4.0.1.0
|
Activates the given alarms if the flag is set and deactivates it when the flag is cleared. More...
#include <Imt.Base.Lib.Alarms/FlagAlarm.h>
Public Member Functions | |
FlagAlarm (AlarmSenderIfc &alarmSender, AlarmIdentifier const alarmId) | |
Constructor. More... | |
void | setFlag () |
Sets the flag and activates the alarm. More... | |
void | clearFlag () |
Clears the flag and disables the alarm. More... | |
bool | isAlarmActive () const |
Returns if any alarm is currently activated. More... | |
void | reset () |
Resets the flag without sending a disable alarm message. More... | |
void | updateValue (bool const flag) |
Updates the flag. More... | |
FlagAlarm ()=delete | |
FlagAlarm (FlagAlarm const &other)=delete | |
FlagAlarm (FlagAlarm &&other)=default | |
FlagAlarm & | operator= (FlagAlarm const &other)=delete |
~FlagAlarm ()=default | |
Activates the given alarms if the flag is set and deactivates it when the flag is cleared.
Does send the activation/deactivation message only when the condition changes. Initially the alarm is deactivated.
|
explicit |
Constructor.
alarmSender | The interface to the actual alarm sender. |
alarmId | The ID of the alarm that shall be sent. |
|
delete |
|
delete |
|
default |
|
default |
void imt::base::lib::alarms::FlagAlarm::clearFlag | ( | ) |
Clears the flag and disables the alarm.
bool imt::base::lib::alarms::FlagAlarm::isAlarmActive | ( | ) | const |
Returns if any alarm is currently activated.
void imt::base::lib::alarms::FlagAlarm::reset | ( | ) |
Resets the flag without sending a disable alarm message.
void imt::base::lib::alarms::FlagAlarm::setFlag | ( | ) |
Sets the flag and activates the alarm.
void imt::base::lib::alarms::FlagAlarm::updateValue | ( | bool const | flag | ) |
Updates the flag.
flag | The new value for the flag. |