Esempio n. 1
0
        private void Do_Notify_AlarmOrEvent(AdapterAlarmOrEvent eventInfo, Calculation adapter)
        {
            var ae = new AlarmOrEventInfo()
            {
                Time            = eventInfo.Time,
                Severity        = eventInfo.Severity,
                Type            = eventInfo.Type,
                ReturnToNormal  = eventInfo.ReturnToNormal,
                Message         = adapter.Name + ": " + eventInfo.Message,
                Details         = eventInfo.Details,
                AffectedObjects = eventInfo.AffectedObjects.Select(obj => ObjectRef.Make(moduleID, obj)).ToArray(),
                Initiator       = null
            };

            notifier !.Notify_AlarmOrEvent(ae);
        }
Esempio n. 2
0
 public void Notify_AlarmOrEvent(AdapterAlarmOrEvent eventInfo)
 {
     m.Notify_AlarmOrEvent(eventInfo, a);
 }
Esempio n. 3
0
 // This will be called from a different Thread, therefore post it to the main thread!
 public void Notify_AlarmOrEvent(AdapterAlarmOrEvent eventInfo, Calculation adapter)
 {
     moduleThread?.Post(Do_Notify_AlarmOrEvent, eventInfo, adapter);
 }
Esempio n. 4
0
 public void Notify_AlarmOrEvent(AdapterAlarmOrEvent eventInfo)
 {
     connector.SendEvent(AdapterMsg.ID_Event_AlarmOrEvent, s => StdJson.ObjectToStream(eventInfo, s));
 }