protected void AddHl7Client(ActorNameEnum actorName, ActorConfig actorConfig) { int index = Hl7ConfigPresent(actorName, actorConfig); if (index != -1) { Hl7Client hl7Client = new Hl7Client(this, actorName, (Hl7Config)actorConfig[index]); _hl7Clients.Add(actorName, hl7Client); } }
public void TriggerActor(ActorNameEnum actorName, BaseTrigger trigger) { // can only trigger an actor that is started if (_actorState == ActorStateEnum.ActorStarted) { if (trigger is Hl7Trigger) { Hl7Client hl7Client = GetHl7Client(actorName); if (hl7Client != null) { hl7Client.TriggerClient(actorName, trigger); } } else { DicomClient dicomClient = GetDicomClient(actorName); if (dicomClient != null) { dicomClient.TriggerClient(actorName, trigger); } } } }