示例#1
0
 public override void Refresh()
 {
     base.Refresh();
     if (!UINotified)
     {
         SegmentCranes.ForEach(prop => prop.DirectVMNotify());
         DirectVMNotify();
         UINotified = true;
     }
 }
示例#2
0
 public override void OnlineTrigger()
 {
     if (Communicator.Online() && !_oldOnline)
     {
         Startup();
         DirectVMNotify();
         SegmentCranes.ForEach(prop => prop.DirectVMNotify());
     }
     if (!Communicator.Online() && _oldOnline)
     {
         DirectVMNotify();
         SegmentCranes.ForEach(prop => prop.DirectVMNotify());
     }
     _oldOnline = Communicator.Online();
 }
示例#3
0
 public void OnTelegramCraneStatus(Telegram t)
 {
     try
     {
         SegmentCranes.ForEach(prop => prop.OnTelegramCraneStatus(t));
         if (t != null)
         {
             PLC_Status = t;
         }
         DirectVMNotify();
     }
     catch (Exception ex)
     {
         Warehouse.AddEvent(Event.EnumSeverity.Error, Event.EnumType.Exception, ex.Message);
         throw new SegmentException(String.Format("{0} SegmentCrane.OnTelegramCraneStatus failed.", Name));
     }
 }