public StopLossPayoff(XmlNode xmlNode)
            : base(xmlNode)
        {
            XmlNode eventTriggerListNode = xmlNode.SelectSingleNode("eventTriggerList");

            if (eventTriggerListNode != null)
            {
                if (eventTriggerListNode.Attributes["href"] != null || eventTriggerListNode.Attributes["id"] != null)
                {
                    if (eventTriggerListNode.Attributes["id"] != null)
                    {
                        eventTriggerListIDRef_ = eventTriggerListNode.Attributes["id"].Value;
                        EventTriggerList ob = new EventTriggerList(eventTriggerListNode);
                        IDManager.SetID(eventTriggerListIDRef_, ob);
                    }
                    else if (eventTriggerListNode.Attributes["href"] != null)
                    {
                        eventTriggerListIDRef_ = eventTriggerListNode.Attributes["href"].Value;
                    }
                    else
                    {
                        eventTriggerList_ = new EventTriggerList(eventTriggerListNode);
                    }
                }
                else
                {
                    eventTriggerList_ = new EventTriggerList(eventTriggerListNode);
                }
            }


            XmlNode barrierInfoNode = xmlNode.SelectSingleNode("barrierInfo");

            if (barrierInfoNode != null)
            {
                if (barrierInfoNode.Attributes["href"] != null || barrierInfoNode.Attributes["id"] != null)
                {
                    if (barrierInfoNode.Attributes["id"] != null)
                    {
                        barrierInfoIDRef_ = barrierInfoNode.Attributes["id"].Value;
                        BarrierInfo ob = new BarrierInfo(barrierInfoNode);
                        IDManager.SetID(barrierInfoIDRef_, ob);
                    }
                    else if (barrierInfoNode.Attributes["href"] != null)
                    {
                        barrierInfoIDRef_ = barrierInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        barrierInfo_ = new BarrierInfo(barrierInfoNode);
                    }
                }
                else
                {
                    barrierInfo_ = new BarrierInfo(barrierInfoNode);
                }
            }


            XmlNode returnCalculationNode = xmlNode.SelectSingleNode("returnCalculation");

            if (returnCalculationNode != null)
            {
                if (returnCalculationNode.Attributes["href"] != null || returnCalculationNode.Attributes["id"] != null)
                {
                    if (returnCalculationNode.Attributes["id"] != null)
                    {
                        returnCalculationIDRef_ = returnCalculationNode.Attributes["id"].Value;
                        ReturnCalculation ob = new ReturnCalculation(returnCalculationNode);
                        IDManager.SetID(returnCalculationIDRef_, ob);
                    }
                    else if (returnCalculationNode.Attributes["href"] != null)
                    {
                        returnCalculationIDRef_ = returnCalculationNode.Attributes["href"].Value;
                    }
                    else
                    {
                        returnCalculation_ = new ReturnCalculation(returnCalculationNode);
                    }
                }
                else
                {
                    returnCalculation_ = new ReturnCalculation(returnCalculationNode);
                }
            }


            XmlNode payoffDateInfoNode = xmlNode.SelectSingleNode("payoffDateInfo");

            if (payoffDateInfoNode != null)
            {
                if (payoffDateInfoNode.Attributes["href"] != null || payoffDateInfoNode.Attributes["id"] != null)
                {
                    if (payoffDateInfoNode.Attributes["id"] != null)
                    {
                        payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["id"].Value;
                        PayoffDateInfo ob = new PayoffDateInfo(payoffDateInfoNode);
                        IDManager.SetID(payoffDateInfoIDRef_, ob);
                    }
                    else if (payoffDateInfoNode.Attributes["href"] != null)
                    {
                        payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
                    }
                }
                else
                {
                    payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
                }
            }
        }
 public BarrierWithConstRebateCallOption(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNode payoffDateInfoNode = xmlNode.SelectSingleNode("payoffDateInfo");
     
     if (payoffDateInfoNode != null)
     {
         if (payoffDateInfoNode.Attributes["href"] != null || payoffDateInfoNode.Attributes["id"] != null) 
         {
             if (payoffDateInfoNode.Attributes["id"] != null) 
             {
                 payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["id"].Value;
                 PayoffDateInfo ob = new PayoffDateInfo(payoffDateInfoNode);
                 IDManager.SetID(payoffDateInfoIDRef_, ob);
             }
             else if (payoffDateInfoNode.Attributes["href"] != null)
             {
                 payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["href"].Value;
             }
             else
             {
                 payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
             }
         }
         else
         {
             payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
         }
     }
     
 
     XmlNode participateRateNode = xmlNode.SelectSingleNode("participateRate");
     
     if (participateRateNode != null)
     {
         if (participateRateNode.Attributes["href"] != null || participateRateNode.Attributes["id"] != null) 
         {
             if (participateRateNode.Attributes["id"] != null) 
             {
                 participateRateIDRef_ = participateRateNode.Attributes["id"].Value;
                 XsdTypeDouble ob = new XsdTypeDouble(participateRateNode);
                 IDManager.SetID(participateRateIDRef_, ob);
             }
             else if (participateRateNode.Attributes["href"] != null)
             {
                 participateRateIDRef_ = participateRateNode.Attributes["href"].Value;
             }
             else
             {
                 participateRate_ = new XsdTypeDouble(participateRateNode);
             }
         }
         else
         {
             participateRate_ = new XsdTypeDouble(participateRateNode);
         }
     }
     
 
     XmlNode referenceCalculationInfoNode = xmlNode.SelectSingleNode("referenceCalculationInfo");
     
     if (referenceCalculationInfoNode != null)
     {
         if (referenceCalculationInfoNode.Attributes["href"] != null || referenceCalculationInfoNode.Attributes["id"] != null) 
         {
             if (referenceCalculationInfoNode.Attributes["id"] != null) 
             {
                 referenceCalculationInfoIDRef_ = referenceCalculationInfoNode.Attributes["id"].Value;
                 ReferenceCalculationInfo ob = new ReferenceCalculationInfo(referenceCalculationInfoNode);
                 IDManager.SetID(referenceCalculationInfoIDRef_, ob);
             }
             else if (referenceCalculationInfoNode.Attributes["href"] != null)
             {
                 referenceCalculationInfoIDRef_ = referenceCalculationInfoNode.Attributes["href"].Value;
             }
             else
             {
                 referenceCalculationInfo_ = new ReferenceCalculationInfo(referenceCalculationInfoNode);
             }
         }
         else
         {
             referenceCalculationInfo_ = new ReferenceCalculationInfo(referenceCalculationInfoNode);
         }
     }
     
 
     XmlNode barrierInfoNode = xmlNode.SelectSingleNode("barrierInfo");
     
     if (barrierInfoNode != null)
     {
         if (barrierInfoNode.Attributes["href"] != null || barrierInfoNode.Attributes["id"] != null) 
         {
             if (barrierInfoNode.Attributes["id"] != null) 
             {
                 barrierInfoIDRef_ = barrierInfoNode.Attributes["id"].Value;
                 BarrierInfo ob = new BarrierInfo(barrierInfoNode);
                 IDManager.SetID(barrierInfoIDRef_, ob);
             }
             else if (barrierInfoNode.Attributes["href"] != null)
             {
                 barrierInfoIDRef_ = barrierInfoNode.Attributes["href"].Value;
             }
             else
             {
                 barrierInfo_ = new BarrierInfo(barrierInfoNode);
             }
         }
         else
         {
             barrierInfo_ = new BarrierInfo(barrierInfoNode);
         }
     }
     
 
     XmlNode strikeNode = xmlNode.SelectSingleNode("strike");
     
     if (strikeNode != null)
     {
         if (strikeNode.Attributes["href"] != null || strikeNode.Attributes["id"] != null) 
         {
             if (strikeNode.Attributes["id"] != null) 
             {
                 strikeIDRef_ = strikeNode.Attributes["id"].Value;
                 XsdTypeDouble ob = new XsdTypeDouble(strikeNode);
                 IDManager.SetID(strikeIDRef_, ob);
             }
             else if (strikeNode.Attributes["href"] != null)
             {
                 strikeIDRef_ = strikeNode.Attributes["href"].Value;
             }
             else
             {
                 strike_ = new XsdTypeDouble(strikeNode);
             }
         }
         else
         {
             strike_ = new XsdTypeDouble(strikeNode);
         }
     }
     
 
     XmlNode lowerBoundNode = xmlNode.SelectSingleNode("lowerBound");
     
     if (lowerBoundNode != null)
     {
         if (lowerBoundNode.Attributes["href"] != null || lowerBoundNode.Attributes["id"] != null) 
         {
             if (lowerBoundNode.Attributes["id"] != null) 
             {
                 lowerBoundIDRef_ = lowerBoundNode.Attributes["id"].Value;
                 XsdTypeDouble ob = new XsdTypeDouble(lowerBoundNode);
                 IDManager.SetID(lowerBoundIDRef_, ob);
             }
             else if (lowerBoundNode.Attributes["href"] != null)
             {
                 lowerBoundIDRef_ = lowerBoundNode.Attributes["href"].Value;
             }
             else
             {
                 lowerBound_ = new XsdTypeDouble(lowerBoundNode);
             }
         }
         else
         {
             lowerBound_ = new XsdTypeDouble(lowerBoundNode);
         }
     }
     
 
     XmlNode rebateRateNode = xmlNode.SelectSingleNode("rebateRate");
     
     if (rebateRateNode != null)
     {
         if (rebateRateNode.Attributes["href"] != null || rebateRateNode.Attributes["id"] != null) 
         {
             if (rebateRateNode.Attributes["id"] != null) 
             {
                 rebateRateIDRef_ = rebateRateNode.Attributes["id"].Value;
                 XsdTypeDouble ob = new XsdTypeDouble(rebateRateNode);
                 IDManager.SetID(rebateRateIDRef_, ob);
             }
             else if (rebateRateNode.Attributes["href"] != null)
             {
                 rebateRateIDRef_ = rebateRateNode.Attributes["href"].Value;
             }
             else
             {
                 rebateRate_ = new XsdTypeDouble(rebateRateNode);
             }
         }
         else
         {
             rebateRate_ = new XsdTypeDouble(rebateRateNode);
         }
     }
     
 
 }
 public SingleBarrier(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNode payoffDateInfoNode = xmlNode.SelectSingleNode("payoffDateInfo");
     
     if (payoffDateInfoNode != null)
     {
         if (payoffDateInfoNode.Attributes["href"] != null || payoffDateInfoNode.Attributes["id"] != null) 
         {
             if (payoffDateInfoNode.Attributes["id"] != null) 
             {
                 payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["id"].Value;
                 PayoffDateInfo ob = new PayoffDateInfo(payoffDateInfoNode);
                 IDManager.SetID(payoffDateInfoIDRef_, ob);
             }
             else if (payoffDateInfoNode.Attributes["href"] != null)
             {
                 payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["href"].Value;
             }
             else
             {
                 payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
             }
         }
         else
         {
             payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
         }
     }
     
 
     XmlNode participateRateNode = xmlNode.SelectSingleNode("participateRate");
     
     if (participateRateNode != null)
     {
         if (participateRateNode.Attributes["href"] != null || participateRateNode.Attributes["id"] != null) 
         {
             if (participateRateNode.Attributes["id"] != null) 
             {
                 participateRateIDRef_ = participateRateNode.Attributes["id"].Value;
                 XsdTypeDouble ob = new XsdTypeDouble(participateRateNode);
                 IDManager.SetID(participateRateIDRef_, ob);
             }
             else if (participateRateNode.Attributes["href"] != null)
             {
                 participateRateIDRef_ = participateRateNode.Attributes["href"].Value;
             }
             else
             {
                 participateRate_ = new XsdTypeDouble(participateRateNode);
             }
         }
         else
         {
             participateRate_ = new XsdTypeDouble(participateRateNode);
         }
     }
     
 
     XmlNode barrierInfoNode = xmlNode.SelectSingleNode("barrierInfo");
     
     if (barrierInfoNode != null)
     {
         if (barrierInfoNode.Attributes["href"] != null || barrierInfoNode.Attributes["id"] != null) 
         {
             if (barrierInfoNode.Attributes["id"] != null) 
             {
                 barrierInfoIDRef_ = barrierInfoNode.Attributes["id"].Value;
                 BarrierInfo ob = new BarrierInfo(barrierInfoNode);
                 IDManager.SetID(barrierInfoIDRef_, ob);
             }
             else if (barrierInfoNode.Attributes["href"] != null)
             {
                 barrierInfoIDRef_ = barrierInfoNode.Attributes["href"].Value;
             }
             else
             {
                 barrierInfo_ = new BarrierInfo(barrierInfoNode);
             }
         }
         else
         {
             barrierInfo_ = new BarrierInfo(barrierInfoNode);
         }
     }
     
 
     XmlNode rebateNode = xmlNode.SelectSingleNode("rebate");
     
     if (rebateNode != null)
     {
         if (rebateNode.Attributes["href"] != null || rebateNode.Attributes["id"] != null) 
         {
             if (rebateNode.Attributes["id"] != null) 
             {
                 rebateIDRef_ = rebateNode.Attributes["id"].Value;
                 XsdTypeDouble ob = new XsdTypeDouble(rebateNode);
                 IDManager.SetID(rebateIDRef_, ob);
             }
             else if (rebateNode.Attributes["href"] != null)
             {
                 rebateIDRef_ = rebateNode.Attributes["href"].Value;
             }
             else
             {
                 rebate_ = new XsdTypeDouble(rebateNode);
             }
         }
         else
         {
             rebate_ = new XsdTypeDouble(rebateNode);
         }
     }
     
 
 }
Exemple #4
0
        public BarrierWithConstRebateCallOption(XmlNode xmlNode)
            : base(xmlNode)
        {
            XmlNode payoffDateInfoNode = xmlNode.SelectSingleNode("payoffDateInfo");

            if (payoffDateInfoNode != null)
            {
                if (payoffDateInfoNode.Attributes["href"] != null || payoffDateInfoNode.Attributes["id"] != null)
                {
                    if (payoffDateInfoNode.Attributes["id"] != null)
                    {
                        payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["id"].Value;
                        PayoffDateInfo ob = new PayoffDateInfo(payoffDateInfoNode);
                        IDManager.SetID(payoffDateInfoIDRef_, ob);
                    }
                    else if (payoffDateInfoNode.Attributes["href"] != null)
                    {
                        payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
                    }
                }
                else
                {
                    payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
                }
            }


            XmlNode participateRateNode = xmlNode.SelectSingleNode("participateRate");

            if (participateRateNode != null)
            {
                if (participateRateNode.Attributes["href"] != null || participateRateNode.Attributes["id"] != null)
                {
                    if (participateRateNode.Attributes["id"] != null)
                    {
                        participateRateIDRef_ = participateRateNode.Attributes["id"].Value;
                        XsdTypeDouble ob = new XsdTypeDouble(participateRateNode);
                        IDManager.SetID(participateRateIDRef_, ob);
                    }
                    else if (participateRateNode.Attributes["href"] != null)
                    {
                        participateRateIDRef_ = participateRateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        participateRate_ = new XsdTypeDouble(participateRateNode);
                    }
                }
                else
                {
                    participateRate_ = new XsdTypeDouble(participateRateNode);
                }
            }


            XmlNode referenceCalculationInfoNode = xmlNode.SelectSingleNode("referenceCalculationInfo");

            if (referenceCalculationInfoNode != null)
            {
                if (referenceCalculationInfoNode.Attributes["href"] != null || referenceCalculationInfoNode.Attributes["id"] != null)
                {
                    if (referenceCalculationInfoNode.Attributes["id"] != null)
                    {
                        referenceCalculationInfoIDRef_ = referenceCalculationInfoNode.Attributes["id"].Value;
                        ReferenceCalculationInfo ob = new ReferenceCalculationInfo(referenceCalculationInfoNode);
                        IDManager.SetID(referenceCalculationInfoIDRef_, ob);
                    }
                    else if (referenceCalculationInfoNode.Attributes["href"] != null)
                    {
                        referenceCalculationInfoIDRef_ = referenceCalculationInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        referenceCalculationInfo_ = new ReferenceCalculationInfo(referenceCalculationInfoNode);
                    }
                }
                else
                {
                    referenceCalculationInfo_ = new ReferenceCalculationInfo(referenceCalculationInfoNode);
                }
            }


            XmlNode barrierInfoNode = xmlNode.SelectSingleNode("barrierInfo");

            if (barrierInfoNode != null)
            {
                if (barrierInfoNode.Attributes["href"] != null || barrierInfoNode.Attributes["id"] != null)
                {
                    if (barrierInfoNode.Attributes["id"] != null)
                    {
                        barrierInfoIDRef_ = barrierInfoNode.Attributes["id"].Value;
                        BarrierInfo ob = new BarrierInfo(barrierInfoNode);
                        IDManager.SetID(barrierInfoIDRef_, ob);
                    }
                    else if (barrierInfoNode.Attributes["href"] != null)
                    {
                        barrierInfoIDRef_ = barrierInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        barrierInfo_ = new BarrierInfo(barrierInfoNode);
                    }
                }
                else
                {
                    barrierInfo_ = new BarrierInfo(barrierInfoNode);
                }
            }


            XmlNode strikeNode = xmlNode.SelectSingleNode("strike");

            if (strikeNode != null)
            {
                if (strikeNode.Attributes["href"] != null || strikeNode.Attributes["id"] != null)
                {
                    if (strikeNode.Attributes["id"] != null)
                    {
                        strikeIDRef_ = strikeNode.Attributes["id"].Value;
                        XsdTypeDouble ob = new XsdTypeDouble(strikeNode);
                        IDManager.SetID(strikeIDRef_, ob);
                    }
                    else if (strikeNode.Attributes["href"] != null)
                    {
                        strikeIDRef_ = strikeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        strike_ = new XsdTypeDouble(strikeNode);
                    }
                }
                else
                {
                    strike_ = new XsdTypeDouble(strikeNode);
                }
            }


            XmlNode lowerBoundNode = xmlNode.SelectSingleNode("lowerBound");

            if (lowerBoundNode != null)
            {
                if (lowerBoundNode.Attributes["href"] != null || lowerBoundNode.Attributes["id"] != null)
                {
                    if (lowerBoundNode.Attributes["id"] != null)
                    {
                        lowerBoundIDRef_ = lowerBoundNode.Attributes["id"].Value;
                        XsdTypeDouble ob = new XsdTypeDouble(lowerBoundNode);
                        IDManager.SetID(lowerBoundIDRef_, ob);
                    }
                    else if (lowerBoundNode.Attributes["href"] != null)
                    {
                        lowerBoundIDRef_ = lowerBoundNode.Attributes["href"].Value;
                    }
                    else
                    {
                        lowerBound_ = new XsdTypeDouble(lowerBoundNode);
                    }
                }
                else
                {
                    lowerBound_ = new XsdTypeDouble(lowerBoundNode);
                }
            }


            XmlNode rebateRateNode = xmlNode.SelectSingleNode("rebateRate");

            if (rebateRateNode != null)
            {
                if (rebateRateNode.Attributes["href"] != null || rebateRateNode.Attributes["id"] != null)
                {
                    if (rebateRateNode.Attributes["id"] != null)
                    {
                        rebateRateIDRef_ = rebateRateNode.Attributes["id"].Value;
                        XsdTypeDouble ob = new XsdTypeDouble(rebateRateNode);
                        IDManager.SetID(rebateRateIDRef_, ob);
                    }
                    else if (rebateRateNode.Attributes["href"] != null)
                    {
                        rebateRateIDRef_ = rebateRateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        rebateRate_ = new XsdTypeDouble(rebateRateNode);
                    }
                }
                else
                {
                    rebateRate_ = new XsdTypeDouble(rebateRateNode);
                }
            }
        }
 public StopLossPayoff(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNode eventTriggerListNode = xmlNode.SelectSingleNode("eventTriggerList");
     
     if (eventTriggerListNode != null)
     {
         if (eventTriggerListNode.Attributes["href"] != null || eventTriggerListNode.Attributes["id"] != null) 
         {
             if (eventTriggerListNode.Attributes["id"] != null) 
             {
                 eventTriggerListIDRef_ = eventTriggerListNode.Attributes["id"].Value;
                 EventTriggerList ob = new EventTriggerList(eventTriggerListNode);
                 IDManager.SetID(eventTriggerListIDRef_, ob);
             }
             else if (eventTriggerListNode.Attributes["href"] != null)
             {
                 eventTriggerListIDRef_ = eventTriggerListNode.Attributes["href"].Value;
             }
             else
             {
                 eventTriggerList_ = new EventTriggerList(eventTriggerListNode);
             }
         }
         else
         {
             eventTriggerList_ = new EventTriggerList(eventTriggerListNode);
         }
     }
     
 
     XmlNode barrierInfoNode = xmlNode.SelectSingleNode("barrierInfo");
     
     if (barrierInfoNode != null)
     {
         if (barrierInfoNode.Attributes["href"] != null || barrierInfoNode.Attributes["id"] != null) 
         {
             if (barrierInfoNode.Attributes["id"] != null) 
             {
                 barrierInfoIDRef_ = barrierInfoNode.Attributes["id"].Value;
                 BarrierInfo ob = new BarrierInfo(barrierInfoNode);
                 IDManager.SetID(barrierInfoIDRef_, ob);
             }
             else if (barrierInfoNode.Attributes["href"] != null)
             {
                 barrierInfoIDRef_ = barrierInfoNode.Attributes["href"].Value;
             }
             else
             {
                 barrierInfo_ = new BarrierInfo(barrierInfoNode);
             }
         }
         else
         {
             barrierInfo_ = new BarrierInfo(barrierInfoNode);
         }
     }
     
 
     XmlNode returnCalculationNode = xmlNode.SelectSingleNode("returnCalculation");
     
     if (returnCalculationNode != null)
     {
         if (returnCalculationNode.Attributes["href"] != null || returnCalculationNode.Attributes["id"] != null) 
         {
             if (returnCalculationNode.Attributes["id"] != null) 
             {
                 returnCalculationIDRef_ = returnCalculationNode.Attributes["id"].Value;
                 ReturnCalculation ob = new ReturnCalculation(returnCalculationNode);
                 IDManager.SetID(returnCalculationIDRef_, ob);
             }
             else if (returnCalculationNode.Attributes["href"] != null)
             {
                 returnCalculationIDRef_ = returnCalculationNode.Attributes["href"].Value;
             }
             else
             {
                 returnCalculation_ = new ReturnCalculation(returnCalculationNode);
             }
         }
         else
         {
             returnCalculation_ = new ReturnCalculation(returnCalculationNode);
         }
     }
     
 
     XmlNode payoffDateInfoNode = xmlNode.SelectSingleNode("payoffDateInfo");
     
     if (payoffDateInfoNode != null)
     {
         if (payoffDateInfoNode.Attributes["href"] != null || payoffDateInfoNode.Attributes["id"] != null) 
         {
             if (payoffDateInfoNode.Attributes["id"] != null) 
             {
                 payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["id"].Value;
                 PayoffDateInfo ob = new PayoffDateInfo(payoffDateInfoNode);
                 IDManager.SetID(payoffDateInfoIDRef_, ob);
             }
             else if (payoffDateInfoNode.Attributes["href"] != null)
             {
                 payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["href"].Value;
             }
             else
             {
                 payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
             }
         }
         else
         {
             payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
         }
     }
     
 
 }
        public SingleBarrier(XmlNode xmlNode)
            : base(xmlNode)
        {
            XmlNode payoffDateInfoNode = xmlNode.SelectSingleNode("payoffDateInfo");

            if (payoffDateInfoNode != null)
            {
                if (payoffDateInfoNode.Attributes["href"] != null || payoffDateInfoNode.Attributes["id"] != null)
                {
                    if (payoffDateInfoNode.Attributes["id"] != null)
                    {
                        payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["id"].Value;
                        PayoffDateInfo ob = new PayoffDateInfo(payoffDateInfoNode);
                        IDManager.SetID(payoffDateInfoIDRef_, ob);
                    }
                    else if (payoffDateInfoNode.Attributes["href"] != null)
                    {
                        payoffDateInfoIDRef_ = payoffDateInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
                    }
                }
                else
                {
                    payoffDateInfo_ = new PayoffDateInfo(payoffDateInfoNode);
                }
            }


            XmlNode participateRateNode = xmlNode.SelectSingleNode("participateRate");

            if (participateRateNode != null)
            {
                if (participateRateNode.Attributes["href"] != null || participateRateNode.Attributes["id"] != null)
                {
                    if (participateRateNode.Attributes["id"] != null)
                    {
                        participateRateIDRef_ = participateRateNode.Attributes["id"].Value;
                        XsdTypeDouble ob = new XsdTypeDouble(participateRateNode);
                        IDManager.SetID(participateRateIDRef_, ob);
                    }
                    else if (participateRateNode.Attributes["href"] != null)
                    {
                        participateRateIDRef_ = participateRateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        participateRate_ = new XsdTypeDouble(participateRateNode);
                    }
                }
                else
                {
                    participateRate_ = new XsdTypeDouble(participateRateNode);
                }
            }


            XmlNode barrierInfoNode = xmlNode.SelectSingleNode("barrierInfo");

            if (barrierInfoNode != null)
            {
                if (barrierInfoNode.Attributes["href"] != null || barrierInfoNode.Attributes["id"] != null)
                {
                    if (barrierInfoNode.Attributes["id"] != null)
                    {
                        barrierInfoIDRef_ = barrierInfoNode.Attributes["id"].Value;
                        BarrierInfo ob = new BarrierInfo(barrierInfoNode);
                        IDManager.SetID(barrierInfoIDRef_, ob);
                    }
                    else if (barrierInfoNode.Attributes["href"] != null)
                    {
                        barrierInfoIDRef_ = barrierInfoNode.Attributes["href"].Value;
                    }
                    else
                    {
                        barrierInfo_ = new BarrierInfo(barrierInfoNode);
                    }
                }
                else
                {
                    barrierInfo_ = new BarrierInfo(barrierInfoNode);
                }
            }


            XmlNode rebateNode = xmlNode.SelectSingleNode("rebate");

            if (rebateNode != null)
            {
                if (rebateNode.Attributes["href"] != null || rebateNode.Attributes["id"] != null)
                {
                    if (rebateNode.Attributes["id"] != null)
                    {
                        rebateIDRef_ = rebateNode.Attributes["id"].Value;
                        XsdTypeDouble ob = new XsdTypeDouble(rebateNode);
                        IDManager.SetID(rebateIDRef_, ob);
                    }
                    else if (rebateNode.Attributes["href"] != null)
                    {
                        rebateIDRef_ = rebateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        rebate_ = new XsdTypeDouble(rebateNode);
                    }
                }
                else
                {
                    rebate_ = new XsdTypeDouble(rebateNode);
                }
            }
        }