public void Display(MobilizationCancelled m) { logger.Info("Display message: " + m); Messages.Push(m); if (MobilizationCancelled != null) { MobilizationCancelled(this, EventArgs.Empty); } }
void Start() { foreach (var i in allocationsToProcess.GetConsumingEnumerable()) { var ambulance = ambulanceRepository.Get(i.AmbulanceId); var m = new MobilizationCancelled(i.AllocationId); sender.Send(m, ambulance.Port); } }