Exemplo n.º 1
0
 private static void AddEventTypeItem(XIMMessage message)
 {
     if (message is XIMInboundMessage)
     {
         if (message == null)
         {
             return;
         }
         XIMMappingItem item = new XIMMappingItem();
         item.GWDataDBField          = GWDataDBField.i_EventType.Clone();
         item.Translating.ConstValue = message.GWEventType.Code;
         item.Translating.Type       = TranslatingType.FixValue;
         GenerateSourceFieldName(item);
         message.MappingList.Add(item);
     }
     else if (message is XIMOutboundMessage)
     {
         if (message == null)
         {
             return;
         }
         QueryCriteriaItem item = new QueryCriteriaItem();
         item.GWDataDBField          = GWDataDBField.i_EventType.Clone();
         item.Translating.ConstValue = message.GWEventType.Code;
         item.Translating.Type       = TranslatingType.FixValue;
         item.Type = QueryCriteriaType.And;
         GenerateTargetFieldName(item);
         ((XIMOutboundMessage)message).Rule.QueryCriteria.MappingList.Add(item);
     }
 }
Exemplo n.º 2
0
        public XIMOutboundMessage Clone()
        {
            XIMOutboundMessage msg = new XIMOutboundMessage();

            msg.HL7EventType = HL7EventType.Clone();
            msg.GWEventType  = GWEventType.Clone();
            msg.XSLFileName  = XSLFileName;

            //msg.Rule.RuleID = Rule.RuleID;    // do not copy RuleID
            msg.Rule.RuleName              = Rule.RuleName;
            msg.Rule.MaxRecordCount        = Rule.MaxRecordCount;
            msg.Rule.CheckProcessFlag      = Rule.CheckProcessFlag;
            msg.Rule.AutoUpdateProcessFlag = Rule.AutoUpdateProcessFlag;
            foreach (XIMMappingItem item in Rule.QueryResult.MappingList)
            {
                XIMMappingItem i = item.Clone() as XIMMappingItem;
                msg.Rule.QueryResult.MappingList.Add(i);
            }
            foreach (QueryCriteriaItem item in Rule.QueryCriteria.MappingList)
            {
                QueryCriteriaItem i = new QueryCriteriaItem();
                i.Type           = item.Type;
                i.Translating    = item.Translating.Clone();
                i.TargetField    = item.TargetField;
                i.SourceField    = item.SourceField;
                i.Singal         = item.Singal;
                i.RedundancyFlag = item.RedundancyFlag;
                i.Operator       = item.Operator;
                i.GWDataDBField  = item.GWDataDBField.Clone();
                msg.Rule.QueryCriteria.MappingList.Add(i);
            }

            return(msg);
        }
Exemplo n.º 3
0
        public IXmlElementItem Clone()
        {
            XIMMappingItem item = new XIMMappingItem();

            item.GWDataDBField  = GWDataDBField.Clone();
            item.Translating    = Translating.Clone();
            item.RedundancyFlag = RedundancyFlag;
            item.SourceField    = SourceField;
            item.TargetField    = TargetField;
            item.Element        = Element.Clone();
            item.Enable         = Enable;
            return(item);
        }
Exemplo n.º 4
0
        public XIMInboundMessage Clone()
        {
            XIMInboundMessage msg = new XIMInboundMessage();

            msg.HL7EventType = HL7EventType.Clone();
            msg.GWEventType  = GWEventType.Clone();
            msg.XSLFileName  = XSLFileName;

            //msg.Rule.RuleID = Rule.RuleID;        // do not copy RuleID
            msg.Rule.RuleName              = Rule.RuleName;
            msg.Rule.CheckProcessFlag      = Rule.CheckProcessFlag;
            msg.Rule.AutoUpdateProcessFlag = Rule.AutoUpdateProcessFlag;
            foreach (XIMMappingItem item in Rule.QueryResult.MappingList)
            {
                XIMMappingItem i = item.Clone() as XIMMappingItem;
                msg.Rule.QueryResult.MappingList.Add(i);
            }

            return(msg);
        }