Skip to main content

handle

Short summary

This methods adds a given event to the list of active events.

Parameters

NameTypeCommentKind
messageCNM_MessageInterfaces.IMessage-input

Code

Declaration

METHOD handle
VAR_INPUT
message : CNM_MessageInterfaces.IMessage;
END_VAR
VAR
alarm :CNM_MessageInterfaces.IAlarm;
dialog :CNM_MessageInterfaces.IDialog;
END_VAR

Implementation

IF(__QUERYINTERFACE(message, alarm) AND_THEN NOT THIS^.activeAlarmList.containsEqualObject(alarm))THEN
THIS^.activeAlarmList.append(alarm);
THIS^.activeAlarm := TRUE;
END_IF
IF(__QUERYINTERFACE(message, dialog) AND_THEN THIS^.isObjectValid(THIS^.dialogManager))THEN
THIS^.dialogManager.queue(dialog);
END_IF