![]() |
![]() |
![]() |
Alarmd Reference Manual | ![]() |
---|---|---|---|---|
enum AlarmdActionAckType; AlarmdAction; AlarmdAction* alarmd_action_new (void);void alarmd_action_run (AlarmdAction *action,gboolean delayed);void alarmd_action_acknowledge (AlarmdAction *action, AlarmdActionAckType ack_type);gboolean alarmd_action_need_power_up (AlarmdAction *action);
"acknowledge"void user_function (AlarmdAction *action,guint ack_type,gpointer user_data) : Run last / No recursion / Action / No hooks "run"void user_function (AlarmdAction *action,gboolean delayed,gpointer user_data) : Run last / No recursion / Action / No hooks
AlarmdAction is a base class for objects that define the action run when event is due. It itself does nothing, and should not be used as-is.
typedef enum { ACK_NORMAL, ACK_SNOOZE } AlarmdActionAckType;
Defines the ways a action can be acknowledged.
AlarmdAction* alarmd_action_new (void);
Creates new alarmd action.
Returns : | Newly created AlarmdAction. |
void alarmd_action_run (AlarmdAction *action,gboolean delayed);
Emits "run" signal on the given AlarmdAction. The interpretion of the
delayed
flag depends on the action type.
action : |
A AlarmdAction that should be run. |
delayed : |
Whether the AlarmdAction is run on time or after it. |
void alarmd_action_acknowledge (AlarmdAction *action, AlarmdActionAckType ack_type);
Emits "acknowledge" -signal on the given AlarmdAction.
action : |
AlarmdAction that is acknowledged. |
ack_type : |
ACK_NORMAL if the action was normally acknowledged or
ACK_SNOOZE if it was snoozed.
|
gboolean alarmd_action_need_power_up (AlarmdAction *action);
Queries the given AlarmdAction, if it needs power up functionality.
action : |
AlarmdAction that is being queried. |
Returns : | TRUE if the AlarmdAction needs power up, FALSE otherwise. |
void user_function (AlarmdAction *action,guint ack_type,gpointer user_data) : Run last / No recursion / Action / No hooks
When an AlarmdAction is acknowledged, it should emit the acknowledge signal.
action : |
The action that is acknowledged. |
ack_type : |
How was the action acknowledged, as defined by
AlarmdActionAckType.
|
user_data : |
user data set when the signal handler was connected. |
void user_function (AlarmdAction *action,gboolean delayed,gpointer user_data) : Run last / No recursion / Action / No hooks
When an AlarmdAction should be run, this signal should be emitted.
action : |
The action that is run. |
delayed : |
Specifies if the execution of action is delayed.
|
user_data : |
user data set when the signal handler was connected. |