/// <summary> /// Class Constructor. /// </summary> /// <param name="hl7Client">HL7 Client.</param> public Hl7ThreadForHl7Client(Hl7Client hl7Client) { _hl7Client = hl7Client; }
private void SubscribeEvent(Hl7Client hl7Client) { hl7Client.OnTransactionAvailable += new Hl7Client.TransactionAvailableHandler(TransactionIsAvailable); hl7Client.OnMessageAvailable += new Hl7Client.MessageAvailableHandler(MessageIsAvailable); }
/// <summary> /// Create an Hl7 Client of the given type. /// </summary> /// <param name="hl7ClientType">Hl7 Client Type - enum.</param> /// <param name="fromActor">From Actor instance.</param> /// <param name="toActorName">To Actor Name.</param> /// <param name="commonConfig">Common Configuration.</param> /// <param name="config">HL7 Configuration.</param> /// <returns>Hl7 Client.</returns> public static Hl7Client CreateHl7Client(Hl7ClientTypeEnum hl7ClientType, BaseActor fromActor, ActorName toActorName, CommonConfig commonConfig, Hl7PeerToPeerConfig config) { Hl7Client hl7Client = null; switch (hl7ClientType) { case Hl7ClientTypeEnum.Hl7Client: hl7Client = new Hl7Client(fromActor, toActorName, commonConfig, config); break; case Hl7ClientTypeEnum.Unknown: default: break; } return hl7Client; }