public BusinessCenterTime(XmlNode xmlNode)
 {
     XmlNode hourMinuteTimeNode = xmlNode.SelectSingleNode("hourMinuteTime");
     
     if (hourMinuteTimeNode != null)
     {
         if (hourMinuteTimeNode.Attributes["href"] != null || hourMinuteTimeNode.Attributes["id"] != null) 
         {
             if (hourMinuteTimeNode.Attributes["id"] != null) 
             {
                 hourMinuteTimeIDRef_ = hourMinuteTimeNode.Attributes["id"].Value;
                 HourMinuteTime ob = new HourMinuteTime(hourMinuteTimeNode);
                 IDManager.SetID(hourMinuteTimeIDRef_, ob);
             }
             else if (hourMinuteTimeNode.Attributes["href"] != null)
             {
                 hourMinuteTimeIDRef_ = hourMinuteTimeNode.Attributes["href"].Value;
             }
             else
             {
                 hourMinuteTime_ = new HourMinuteTime(hourMinuteTimeNode);
             }
         }
         else
         {
             hourMinuteTime_ = new HourMinuteTime(hourMinuteTimeNode);
         }
     }
     
 
     XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");
     
     if (businessCenterNode != null)
     {
         if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null) 
         {
             if (businessCenterNode.Attributes["id"] != null) 
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(businessCenterNode);
                 IDManager.SetID(businessCenterIDRef_, ob);
             }
             else if (businessCenterNode.Attributes["href"] != null)
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
             }
             else
             {
                 businessCenter_ = new BusinessCenter(businessCenterNode);
             }
         }
         else
         {
             businessCenter_ = new BusinessCenter(businessCenterNode);
         }
     }
     
 
 }
示例#2
0
        public BusinessCenterTime(XmlNode xmlNode)
        {
            XmlNodeList hourMinuteTimeNodeList = xmlNode.SelectNodes("hourMinuteTime");

            if (hourMinuteTimeNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in hourMinuteTimeNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        hourMinuteTimeIDRef = item.Attributes["id"].Name;
                        HourMinuteTime ob = HourMinuteTime();
                        IDManager.SetID(hourMinuteTimeIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        hourMinuteTimeIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        hourMinuteTime = new HourMinuteTime(item);
                    }
                }
            }


            XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");

            if (businessCenterNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in businessCenterNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        businessCenterIDRef = item.Attributes["id"].Name;
                        BusinessCenter ob = BusinessCenter();
                        IDManager.SetID(businessCenterIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        businessCenterIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        businessCenter = new BusinessCenter(item);
                    }
                }
            }
        }
 public BusinessCenterTime(XmlNode xmlNode)
 {
     XmlNodeList hourMinuteTimeNodeList = xmlNode.SelectNodes("hourMinuteTime");
     if (hourMinuteTimeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in hourMinuteTimeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 hourMinuteTimeIDRef = item.Attributes["id"].Name;
                 HourMinuteTime ob = HourMinuteTime();
                 IDManager.SetID(hourMinuteTimeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 hourMinuteTimeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 hourMinuteTime = new HourMinuteTime(item);
             }
         }
     }
     
 
     XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");
     if (businessCenterNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in businessCenterNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 businessCenterIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(businessCenterIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 businessCenterIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 businessCenter = new BusinessCenter(item);
             }
         }
     }
     
 
 }
示例#4
0
        public BusinessCenterTime(XmlNode xmlNode)
        {
            XmlNode hourMinuteTimeNode = xmlNode.SelectSingleNode("hourMinuteTime");

            if (hourMinuteTimeNode != null)
            {
                if (hourMinuteTimeNode.Attributes["href"] != null || hourMinuteTimeNode.Attributes["id"] != null)
                {
                    if (hourMinuteTimeNode.Attributes["id"] != null)
                    {
                        hourMinuteTimeIDRef_ = hourMinuteTimeNode.Attributes["id"].Value;
                        HourMinuteTime ob = new HourMinuteTime(hourMinuteTimeNode);
                        IDManager.SetID(hourMinuteTimeIDRef_, ob);
                    }
                    else if (hourMinuteTimeNode.Attributes["href"] != null)
                    {
                        hourMinuteTimeIDRef_ = hourMinuteTimeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        hourMinuteTime_ = new HourMinuteTime(hourMinuteTimeNode);
                    }
                }
                else
                {
                    hourMinuteTime_ = new HourMinuteTime(hourMinuteTimeNode);
                }
            }


            XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");

            if (businessCenterNode != null)
            {
                if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null)
                {
                    if (businessCenterNode.Attributes["id"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                        BusinessCenter ob = new BusinessCenter(businessCenterNode);
                        IDManager.SetID(businessCenterIDRef_, ob);
                    }
                    else if (businessCenterNode.Attributes["href"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
                    }
                    else
                    {
                        businessCenter_ = new BusinessCenter(businessCenterNode);
                    }
                }
                else
                {
                    businessCenter_ = new BusinessCenter(businessCenterNode);
                }
            }
        }
        public QuotationCharacteristics(XmlNode xmlNode)
        {
            XmlNodeList measureTypeNodeList = xmlNode.SelectNodes("measureType");

            if (measureTypeNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in measureTypeNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        measureTypeIDRef = item.Attributes["id"].Name;
                        AssetMeasureType ob = AssetMeasureType();
                        IDManager.SetID(measureTypeIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        measureTypeIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        measureType = new AssetMeasureType(item);
                    }
                }
            }


            XmlNodeList quoteUnitsNodeList = xmlNode.SelectNodes("quoteUnits");

            if (quoteUnitsNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in quoteUnitsNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        quoteUnitsIDRef = item.Attributes["id"].Name;
                        PriceQuoteUnits ob = PriceQuoteUnits();
                        IDManager.SetID(quoteUnitsIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        quoteUnitsIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        quoteUnits = new PriceQuoteUnits(item);
                    }
                }
            }


            XmlNodeList sideNodeList = xmlNode.SelectNodes("side");

            if (sideNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in sideNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        sideIDRef = item.Attributes["id"].Name;
                        QuotationSideEnum ob = QuotationSideEnum();
                        IDManager.SetID(sideIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        sideIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        side = new QuotationSideEnum(item);
                    }
                }
            }


            XmlNodeList currencyNodeList = xmlNode.SelectNodes("currency");

            if (currencyNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in currencyNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        currencyIDRef = item.Attributes["id"].Name;
                        Currency ob = Currency();
                        IDManager.SetID(currencyIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        currencyIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        currency = new Currency(item);
                    }
                }
            }


            XmlNodeList currencyTypeNodeList = xmlNode.SelectNodes("currencyType");

            if (currencyTypeNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in currencyTypeNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        currencyTypeIDRef = item.Attributes["id"].Name;
                        ReportingCurrencyType ob = ReportingCurrencyType();
                        IDManager.SetID(currencyTypeIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        currencyTypeIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        currencyType = new ReportingCurrencyType(item);
                    }
                }
            }


            XmlNodeList timingNodeList = xmlNode.SelectNodes("timing");

            if (timingNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in timingNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        timingIDRef = item.Attributes["id"].Name;
                        QuoteTiming ob = QuoteTiming();
                        IDManager.SetID(timingIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        timingIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        timing = new QuoteTiming(item);
                    }
                }
            }


            XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");

            if (businessCenterNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in businessCenterNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        businessCenterIDRef = item.Attributes["id"].Name;
                        BusinessCenter ob = BusinessCenter();
                        IDManager.SetID(businessCenterIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        businessCenterIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        businessCenter = new BusinessCenter(item);
                    }
                }
            }


            XmlNodeList exchangeIdNodeList = xmlNode.SelectNodes("exchangeId");

            if (exchangeIdNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in exchangeIdNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        exchangeIdIDRef = item.Attributes["id"].Name;
                        ExchangeId ob = ExchangeId();
                        IDManager.SetID(exchangeIdIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        exchangeIdIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        exchangeId = new ExchangeId(item);
                    }
                }
            }


            XmlNodeList informationSourceNodeList = xmlNode.SelectNodes("informationSource");

            foreach (XmlNode item in informationSourceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        informationSourceIDRef = item.Attributes["id"].Name;
                        List <InformationSource> ob = new List <InformationSource>();
                        ob.Add(new InformationSource(item));
                        IDManager.SetID(informationSourceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        informationSourceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        informationSource.Add(new InformationSource(item));
                    }
                }
            }


            XmlNodeList pricingModelNodeList = xmlNode.SelectNodes("pricingModel");

            if (pricingModelNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in pricingModelNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        pricingModelIDRef = item.Attributes["id"].Name;
                        PricingModel ob = PricingModel();
                        IDManager.SetID(pricingModelIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        pricingModelIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        pricingModel = new PricingModel(item);
                    }
                }
            }


            XmlNodeList timeNodeList = xmlNode.SelectNodes("time");

            if (timeNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in timeNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        timeIDRef = item.Attributes["id"].Name;
                        XsdTypeDateTime ob = XsdTypeDateTime();
                        IDManager.SetID(timeIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        timeIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        time = new XsdTypeDateTime(item);
                    }
                }
            }


            XmlNodeList valuationDateNodeList = xmlNode.SelectNodes("valuationDate");

            if (valuationDateNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in valuationDateNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        valuationDateIDRef = item.Attributes["id"].Name;
                        XsdTypeDate ob = XsdTypeDate();
                        IDManager.SetID(valuationDateIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        valuationDateIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        valuationDate = new XsdTypeDate(item);
                    }
                }
            }


            XmlNodeList expiryTimeNodeList = xmlNode.SelectNodes("expiryTime");

            if (expiryTimeNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in expiryTimeNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        expiryTimeIDRef = item.Attributes["id"].Name;
                        XsdTypeDateTime ob = XsdTypeDateTime();
                        IDManager.SetID(expiryTimeIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        expiryTimeIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        expiryTime = new XsdTypeDateTime(item);
                    }
                }
            }


            XmlNodeList cashflowTypeNodeList = xmlNode.SelectNodes("cashflowType");

            if (cashflowTypeNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in cashflowTypeNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        cashflowTypeIDRef = item.Attributes["id"].Name;
                        CashflowType ob = CashflowType();
                        IDManager.SetID(cashflowTypeIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        cashflowTypeIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        cashflowType = new CashflowType(item);
                    }
                }
            }
        }
        public WeatherLegCalculation(XmlNode xmlNode)
        {
            XmlNodeList settlementLevelNodeList = xmlNode.SelectNodes("settlementLevel");

            if (settlementLevelNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in settlementLevelNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        settlementLevelIDRef = item.Attributes["id"].Name;
                        WeatherSettlementLevelEnum ob = WeatherSettlementLevelEnum();
                        IDManager.SetID(settlementLevelIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        settlementLevelIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        settlementLevel = new WeatherSettlementLevelEnum(item);
                    }
                }
            }


            XmlNodeList referenceLevelEqualsZeroNodeList = xmlNode.SelectNodes("referenceLevelEqualsZero");

            if (referenceLevelEqualsZeroNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in referenceLevelEqualsZeroNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        referenceLevelEqualsZeroIDRef = item.Attributes["id"].Name;
                        XsdTypeBoolean ob = XsdTypeBoolean();
                        IDManager.SetID(referenceLevelEqualsZeroIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        referenceLevelEqualsZeroIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        referenceLevelEqualsZero = new XsdTypeBoolean(item);
                    }
                }
            }


            XmlNodeList calculationDateNodeList = xmlNode.SelectNodes("calculationDate");

            if (calculationDateNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in calculationDateNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        calculationDateIDRef = item.Attributes["id"].Name;
                        Period ob = Period();
                        IDManager.SetID(calculationDateIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        calculationDateIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        calculationDate = new Period(item);
                    }
                }
            }


            XmlNodeList businessDaysNodeList = xmlNode.SelectNodes("businessDays");

            if (businessDaysNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in businessDaysNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        businessDaysIDRef = item.Attributes["id"].Name;
                        BusinessCenter ob = BusinessCenter();
                        IDManager.SetID(businessDaysIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        businessDaysIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        businessDays = new BusinessCenter(item);
                    }
                }
            }


            XmlNodeList dataCorrectionNodeList = xmlNode.SelectNodes("dataCorrection");

            if (dataCorrectionNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in dataCorrectionNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        dataCorrectionIDRef = item.Attributes["id"].Name;
                        XsdTypeBoolean ob = XsdTypeBoolean();
                        IDManager.SetID(dataCorrectionIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        dataCorrectionIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        dataCorrection = new XsdTypeBoolean(item);
                    }
                }
            }


            XmlNodeList correctionPeriodNodeList = xmlNode.SelectNodes("correctionPeriod");

            if (correctionPeriodNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in correctionPeriodNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        correctionPeriodIDRef = item.Attributes["id"].Name;
                        Period ob = Period();
                        IDManager.SetID(correctionPeriodIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        correctionPeriodIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        correctionPeriod = new Period(item);
                    }
                }
            }


            XmlNodeList maximumPaymentAmountNodeList = xmlNode.SelectNodes("maximumPaymentAmount");

            if (maximumPaymentAmountNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in maximumPaymentAmountNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        maximumPaymentAmountIDRef = item.Attributes["id"].Name;
                        NonNegativeMoney ob = NonNegativeMoney();
                        IDManager.SetID(maximumPaymentAmountIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        maximumPaymentAmountIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        maximumPaymentAmount = new NonNegativeMoney(item);
                    }
                }
            }


            XmlNodeList maximumTransactionPaymentAmountNodeList = xmlNode.SelectNodes("maximumTransactionPaymentAmount");

            if (maximumTransactionPaymentAmountNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in maximumTransactionPaymentAmountNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        maximumTransactionPaymentAmountIDRef = item.Attributes["id"].Name;
                        NonNegativeMoney ob = NonNegativeMoney();
                        IDManager.SetID(maximumTransactionPaymentAmountIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        maximumTransactionPaymentAmountIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        maximumTransactionPaymentAmount = new NonNegativeMoney(item);
                    }
                }
            }


            XmlNodeList roundingNodeList = xmlNode.SelectNodes("rounding");

            if (roundingNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in roundingNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        roundingIDRef = item.Attributes["id"].Name;
                        Rounding ob = Rounding();
                        IDManager.SetID(roundingIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        roundingIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        rounding = new Rounding(item);
                    }
                }
            }
        }
 public Trade(XmlNode xmlNode)
 {
     XmlNode tradeHeaderNode = xmlNode.SelectSingleNode("tradeHeader");
     
     if (tradeHeaderNode != null)
     {
         if (tradeHeaderNode.Attributes["href"] != null || tradeHeaderNode.Attributes["id"] != null) 
         {
             if (tradeHeaderNode.Attributes["id"] != null) 
             {
                 tradeHeaderIDRef_ = tradeHeaderNode.Attributes["id"].Value;
                 TradeHeader ob = new TradeHeader(tradeHeaderNode);
                 IDManager.SetID(tradeHeaderIDRef_, ob);
             }
             else if (tradeHeaderNode.Attributes["href"] != null)
             {
                 tradeHeaderIDRef_ = tradeHeaderNode.Attributes["href"].Value;
             }
             else
             {
                 tradeHeader_ = new TradeHeader(tradeHeaderNode);
             }
         }
         else
         {
             tradeHeader_ = new TradeHeader(tradeHeaderNode);
         }
     }
     
 
     XmlNode productNode = xmlNode.SelectSingleNode("product");
     
     if (productNode != null)
     {
         if (productNode.Attributes["href"] != null || productNode.Attributes["id"] != null) 
         {
             if (productNode.Attributes["id"] != null) 
             {
                 productIDRef_ = productNode.Attributes["id"].Value;
                 Product ob = new Product(productNode);
                 IDManager.SetID(productIDRef_, ob);
             }
             else if (productNode.Attributes["href"] != null)
             {
                 productIDRef_ = productNode.Attributes["href"].Value;
             }
             else
             {
                 product_ = new Product(productNode);
             }
         }
         else
         {
             product_ = new Product(productNode);
         }
     }
     
 
     XmlNode forwardNode = xmlNode.SelectSingleNode("forward");
     
     if (forwardNode != null)
     {
         if (forwardNode.Attributes["href"] != null || forwardNode.Attributes["id"] != null) 
         {
             if (forwardNode.Attributes["id"] != null) 
             {
                 forwardIDRef_ = forwardNode.Attributes["id"].Value;
                 ForwardSale ob = new ForwardSale(forwardNode);
                 IDManager.SetID(forwardIDRef_, ob);
             }
             else if (forwardNode.Attributes["href"] != null)
             {
                 forwardIDRef_ = forwardNode.Attributes["href"].Value;
             }
             else
             {
                 forward_ = new ForwardSale(forwardNode);
             }
         }
         else
         {
             forward_ = new ForwardSale(forwardNode);
         }
     }
     
 
     XmlNode bondOptionNode = xmlNode.SelectSingleNode("bondOption");
     
     if (bondOptionNode != null)
     {
         if (bondOptionNode.Attributes["href"] != null || bondOptionNode.Attributes["id"] != null) 
         {
             if (bondOptionNode.Attributes["id"] != null) 
             {
                 bondOptionIDRef_ = bondOptionNode.Attributes["id"].Value;
                 BondOption ob = new BondOption(bondOptionNode);
                 IDManager.SetID(bondOptionIDRef_, ob);
             }
             else if (bondOptionNode.Attributes["href"] != null)
             {
                 bondOptionIDRef_ = bondOptionNode.Attributes["href"].Value;
             }
             else
             {
                 bondOption_ = new BondOption(bondOptionNode);
             }
         }
         else
         {
             bondOption_ = new BondOption(bondOptionNode);
         }
     }
     
 
     XmlNode creditDefaultSwapNode = xmlNode.SelectSingleNode("creditDefaultSwap");
     
     if (creditDefaultSwapNode != null)
     {
         if (creditDefaultSwapNode.Attributes["href"] != null || creditDefaultSwapNode.Attributes["id"] != null) 
         {
             if (creditDefaultSwapNode.Attributes["id"] != null) 
             {
                 creditDefaultSwapIDRef_ = creditDefaultSwapNode.Attributes["id"].Value;
                 CreditDefaultSwap ob = new CreditDefaultSwap(creditDefaultSwapNode);
                 IDManager.SetID(creditDefaultSwapIDRef_, ob);
             }
             else if (creditDefaultSwapNode.Attributes["href"] != null)
             {
                 creditDefaultSwapIDRef_ = creditDefaultSwapNode.Attributes["href"].Value;
             }
             else
             {
                 creditDefaultSwap_ = new CreditDefaultSwap(creditDefaultSwapNode);
             }
         }
         else
         {
             creditDefaultSwap_ = new CreditDefaultSwap(creditDefaultSwapNode);
         }
     }
     
 
     XmlNode creditDefaultSwapOptionNode = xmlNode.SelectSingleNode("creditDefaultSwapOption");
     
     if (creditDefaultSwapOptionNode != null)
     {
         if (creditDefaultSwapOptionNode.Attributes["href"] != null || creditDefaultSwapOptionNode.Attributes["id"] != null) 
         {
             if (creditDefaultSwapOptionNode.Attributes["id"] != null) 
             {
                 creditDefaultSwapOptionIDRef_ = creditDefaultSwapOptionNode.Attributes["id"].Value;
                 CreditDefaultSwapOption ob = new CreditDefaultSwapOption(creditDefaultSwapOptionNode);
                 IDManager.SetID(creditDefaultSwapOptionIDRef_, ob);
             }
             else if (creditDefaultSwapOptionNode.Attributes["href"] != null)
             {
                 creditDefaultSwapOptionIDRef_ = creditDefaultSwapOptionNode.Attributes["href"].Value;
             }
             else
             {
                 creditDefaultSwapOption_ = new CreditDefaultSwapOption(creditDefaultSwapOptionNode);
             }
         }
         else
         {
             creditDefaultSwapOption_ = new CreditDefaultSwapOption(creditDefaultSwapOptionNode);
         }
     }
     
 
     XmlNode commodityForwardNode = xmlNode.SelectSingleNode("commodityForward");
     
     if (commodityForwardNode != null)
     {
         if (commodityForwardNode.Attributes["href"] != null || commodityForwardNode.Attributes["id"] != null) 
         {
             if (commodityForwardNode.Attributes["id"] != null) 
             {
                 commodityForwardIDRef_ = commodityForwardNode.Attributes["id"].Value;
                 CommodityForward ob = new CommodityForward(commodityForwardNode);
                 IDManager.SetID(commodityForwardIDRef_, ob);
             }
             else if (commodityForwardNode.Attributes["href"] != null)
             {
                 commodityForwardIDRef_ = commodityForwardNode.Attributes["href"].Value;
             }
             else
             {
                 commodityForward_ = new CommodityForward(commodityForwardNode);
             }
         }
         else
         {
             commodityForward_ = new CommodityForward(commodityForwardNode);
         }
     }
     
 
     XmlNode commodityOptionNode = xmlNode.SelectSingleNode("commodityOption");
     
     if (commodityOptionNode != null)
     {
         if (commodityOptionNode.Attributes["href"] != null || commodityOptionNode.Attributes["id"] != null) 
         {
             if (commodityOptionNode.Attributes["id"] != null) 
             {
                 commodityOptionIDRef_ = commodityOptionNode.Attributes["id"].Value;
                 CommodityOption ob = new CommodityOption(commodityOptionNode);
                 IDManager.SetID(commodityOptionIDRef_, ob);
             }
             else if (commodityOptionNode.Attributes["href"] != null)
             {
                 commodityOptionIDRef_ = commodityOptionNode.Attributes["href"].Value;
             }
             else
             {
                 commodityOption_ = new CommodityOption(commodityOptionNode);
             }
         }
         else
         {
             commodityOption_ = new CommodityOption(commodityOptionNode);
         }
     }
     
 
     XmlNode commoditySwapNode = xmlNode.SelectSingleNode("commoditySwap");
     
     if (commoditySwapNode != null)
     {
         if (commoditySwapNode.Attributes["href"] != null || commoditySwapNode.Attributes["id"] != null) 
         {
             if (commoditySwapNode.Attributes["id"] != null) 
             {
                 commoditySwapIDRef_ = commoditySwapNode.Attributes["id"].Value;
                 CommoditySwap ob = new CommoditySwap(commoditySwapNode);
                 IDManager.SetID(commoditySwapIDRef_, ob);
             }
             else if (commoditySwapNode.Attributes["href"] != null)
             {
                 commoditySwapIDRef_ = commoditySwapNode.Attributes["href"].Value;
             }
             else
             {
                 commoditySwap_ = new CommoditySwap(commoditySwapNode);
             }
         }
         else
         {
             commoditySwap_ = new CommoditySwap(commoditySwapNode);
         }
     }
     
 
     XmlNode commoditySwaptionNode = xmlNode.SelectSingleNode("commoditySwaption");
     
     if (commoditySwaptionNode != null)
     {
         if (commoditySwaptionNode.Attributes["href"] != null || commoditySwaptionNode.Attributes["id"] != null) 
         {
             if (commoditySwaptionNode.Attributes["id"] != null) 
             {
                 commoditySwaptionIDRef_ = commoditySwaptionNode.Attributes["id"].Value;
                 CommoditySwaption ob = new CommoditySwaption(commoditySwaptionNode);
                 IDManager.SetID(commoditySwaptionIDRef_, ob);
             }
             else if (commoditySwaptionNode.Attributes["href"] != null)
             {
                 commoditySwaptionIDRef_ = commoditySwaptionNode.Attributes["href"].Value;
             }
             else
             {
                 commoditySwaption_ = new CommoditySwaption(commoditySwaptionNode);
             }
         }
         else
         {
             commoditySwaption_ = new CommoditySwaption(commoditySwaptionNode);
         }
     }
     
 
     XmlNode correlationSwapNode = xmlNode.SelectSingleNode("correlationSwap");
     
     if (correlationSwapNode != null)
     {
         if (correlationSwapNode.Attributes["href"] != null || correlationSwapNode.Attributes["id"] != null) 
         {
             if (correlationSwapNode.Attributes["id"] != null) 
             {
                 correlationSwapIDRef_ = correlationSwapNode.Attributes["id"].Value;
                 CorrelationSwap ob = new CorrelationSwap(correlationSwapNode);
                 IDManager.SetID(correlationSwapIDRef_, ob);
             }
             else if (correlationSwapNode.Attributes["href"] != null)
             {
                 correlationSwapIDRef_ = correlationSwapNode.Attributes["href"].Value;
             }
             else
             {
                 correlationSwap_ = new CorrelationSwap(correlationSwapNode);
             }
         }
         else
         {
             correlationSwap_ = new CorrelationSwap(correlationSwapNode);
         }
     }
     
 
     XmlNode dividendSwapOptionTransactionSupplementNode = xmlNode.SelectSingleNode("dividendSwapOptionTransactionSupplement");
     
     if (dividendSwapOptionTransactionSupplementNode != null)
     {
         if (dividendSwapOptionTransactionSupplementNode.Attributes["href"] != null || dividendSwapOptionTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (dividendSwapOptionTransactionSupplementNode.Attributes["id"] != null) 
             {
                 dividendSwapOptionTransactionSupplementIDRef_ = dividendSwapOptionTransactionSupplementNode.Attributes["id"].Value;
                 DividendSwapOptionTransactionSupplement ob = new DividendSwapOptionTransactionSupplement(dividendSwapOptionTransactionSupplementNode);
                 IDManager.SetID(dividendSwapOptionTransactionSupplementIDRef_, ob);
             }
             else if (dividendSwapOptionTransactionSupplementNode.Attributes["href"] != null)
             {
                 dividendSwapOptionTransactionSupplementIDRef_ = dividendSwapOptionTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 dividendSwapOptionTransactionSupplement_ = new DividendSwapOptionTransactionSupplement(dividendSwapOptionTransactionSupplementNode);
             }
         }
         else
         {
             dividendSwapOptionTransactionSupplement_ = new DividendSwapOptionTransactionSupplement(dividendSwapOptionTransactionSupplementNode);
         }
     }
     
 
     XmlNode dividendSwapTransactionSupplementNode = xmlNode.SelectSingleNode("dividendSwapTransactionSupplement");
     
     if (dividendSwapTransactionSupplementNode != null)
     {
         if (dividendSwapTransactionSupplementNode.Attributes["href"] != null || dividendSwapTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (dividendSwapTransactionSupplementNode.Attributes["id"] != null) 
             {
                 dividendSwapTransactionSupplementIDRef_ = dividendSwapTransactionSupplementNode.Attributes["id"].Value;
                 DividendSwapTransactionSupplement ob = new DividendSwapTransactionSupplement(dividendSwapTransactionSupplementNode);
                 IDManager.SetID(dividendSwapTransactionSupplementIDRef_, ob);
             }
             else if (dividendSwapTransactionSupplementNode.Attributes["href"] != null)
             {
                 dividendSwapTransactionSupplementIDRef_ = dividendSwapTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 dividendSwapTransactionSupplement_ = new DividendSwapTransactionSupplement(dividendSwapTransactionSupplementNode);
             }
         }
         else
         {
             dividendSwapTransactionSupplement_ = new DividendSwapTransactionSupplement(dividendSwapTransactionSupplementNode);
         }
     }
     
 
     XmlNode instrumentTradeDetailsNode = xmlNode.SelectSingleNode("instrumentTradeDetails");
     
     if (instrumentTradeDetailsNode != null)
     {
         if (instrumentTradeDetailsNode.Attributes["href"] != null || instrumentTradeDetailsNode.Attributes["id"] != null) 
         {
             if (instrumentTradeDetailsNode.Attributes["id"] != null) 
             {
                 instrumentTradeDetailsIDRef_ = instrumentTradeDetailsNode.Attributes["id"].Value;
                 InstrumentTradeDetails ob = new InstrumentTradeDetails(instrumentTradeDetailsNode);
                 IDManager.SetID(instrumentTradeDetailsIDRef_, ob);
             }
             else if (instrumentTradeDetailsNode.Attributes["href"] != null)
             {
                 instrumentTradeDetailsIDRef_ = instrumentTradeDetailsNode.Attributes["href"].Value;
             }
             else
             {
                 instrumentTradeDetails_ = new InstrumentTradeDetails(instrumentTradeDetailsNode);
             }
         }
         else
         {
             instrumentTradeDetails_ = new InstrumentTradeDetails(instrumentTradeDetailsNode);
         }
     }
     
 
     XmlNode strategyNode = xmlNode.SelectSingleNode("strategy");
     
     if (strategyNode != null)
     {
         if (strategyNode.Attributes["href"] != null || strategyNode.Attributes["id"] != null) 
         {
             if (strategyNode.Attributes["id"] != null) 
             {
                 strategyIDRef_ = strategyNode.Attributes["id"].Value;
                 Strategy ob = new Strategy(strategyNode);
                 IDManager.SetID(strategyIDRef_, ob);
             }
             else if (strategyNode.Attributes["href"] != null)
             {
                 strategyIDRef_ = strategyNode.Attributes["href"].Value;
             }
             else
             {
                 strategy_ = new Strategy(strategyNode);
             }
         }
         else
         {
             strategy_ = new Strategy(strategyNode);
         }
     }
     
 
     XmlNode returnSwapNode = xmlNode.SelectSingleNode("returnSwap");
     
     if (returnSwapNode != null)
     {
         if (returnSwapNode.Attributes["href"] != null || returnSwapNode.Attributes["id"] != null) 
         {
             if (returnSwapNode.Attributes["id"] != null) 
             {
                 returnSwapIDRef_ = returnSwapNode.Attributes["id"].Value;
                 ReturnSwap ob = new ReturnSwap(returnSwapNode);
                 IDManager.SetID(returnSwapIDRef_, ob);
             }
             else if (returnSwapNode.Attributes["href"] != null)
             {
                 returnSwapIDRef_ = returnSwapNode.Attributes["href"].Value;
             }
             else
             {
                 returnSwap_ = new ReturnSwap(returnSwapNode);
             }
         }
         else
         {
             returnSwap_ = new ReturnSwap(returnSwapNode);
         }
     }
     
 
     XmlNode brokerEquityOptionNode = xmlNode.SelectSingleNode("brokerEquityOption");
     
     if (brokerEquityOptionNode != null)
     {
         if (brokerEquityOptionNode.Attributes["href"] != null || brokerEquityOptionNode.Attributes["id"] != null) 
         {
             if (brokerEquityOptionNode.Attributes["id"] != null) 
             {
                 brokerEquityOptionIDRef_ = brokerEquityOptionNode.Attributes["id"].Value;
                 BrokerEquityOption ob = new BrokerEquityOption(brokerEquityOptionNode);
                 IDManager.SetID(brokerEquityOptionIDRef_, ob);
             }
             else if (brokerEquityOptionNode.Attributes["href"] != null)
             {
                 brokerEquityOptionIDRef_ = brokerEquityOptionNode.Attributes["href"].Value;
             }
             else
             {
                 brokerEquityOption_ = new BrokerEquityOption(brokerEquityOptionNode);
             }
         }
         else
         {
             brokerEquityOption_ = new BrokerEquityOption(brokerEquityOptionNode);
         }
     }
     
 
     XmlNode equityForwardNode = xmlNode.SelectSingleNode("equityForward");
     
     if (equityForwardNode != null)
     {
         if (equityForwardNode.Attributes["href"] != null || equityForwardNode.Attributes["id"] != null) 
         {
             if (equityForwardNode.Attributes["id"] != null) 
             {
                 equityForwardIDRef_ = equityForwardNode.Attributes["id"].Value;
                 EquityForward ob = new EquityForward(equityForwardNode);
                 IDManager.SetID(equityForwardIDRef_, ob);
             }
             else if (equityForwardNode.Attributes["href"] != null)
             {
                 equityForwardIDRef_ = equityForwardNode.Attributes["href"].Value;
             }
             else
             {
                 equityForward_ = new EquityForward(equityForwardNode);
             }
         }
         else
         {
             equityForward_ = new EquityForward(equityForwardNode);
         }
     }
     
 
     XmlNode equityOptionNode = xmlNode.SelectSingleNode("equityOption");
     
     if (equityOptionNode != null)
     {
         if (equityOptionNode.Attributes["href"] != null || equityOptionNode.Attributes["id"] != null) 
         {
             if (equityOptionNode.Attributes["id"] != null) 
             {
                 equityOptionIDRef_ = equityOptionNode.Attributes["id"].Value;
                 EquityOption ob = new EquityOption(equityOptionNode);
                 IDManager.SetID(equityOptionIDRef_, ob);
             }
             else if (equityOptionNode.Attributes["href"] != null)
             {
                 equityOptionIDRef_ = equityOptionNode.Attributes["href"].Value;
             }
             else
             {
                 equityOption_ = new EquityOption(equityOptionNode);
             }
         }
         else
         {
             equityOption_ = new EquityOption(equityOptionNode);
         }
     }
     
 
     XmlNode equityOptionTransactionSupplementNode = xmlNode.SelectSingleNode("equityOptionTransactionSupplement");
     
     if (equityOptionTransactionSupplementNode != null)
     {
         if (equityOptionTransactionSupplementNode.Attributes["href"] != null || equityOptionTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (equityOptionTransactionSupplementNode.Attributes["id"] != null) 
             {
                 equityOptionTransactionSupplementIDRef_ = equityOptionTransactionSupplementNode.Attributes["id"].Value;
                 EquityOptionTransactionSupplement ob = new EquityOptionTransactionSupplement(equityOptionTransactionSupplementNode);
                 IDManager.SetID(equityOptionTransactionSupplementIDRef_, ob);
             }
             else if (equityOptionTransactionSupplementNode.Attributes["href"] != null)
             {
                 equityOptionTransactionSupplementIDRef_ = equityOptionTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 equityOptionTransactionSupplement_ = new EquityOptionTransactionSupplement(equityOptionTransactionSupplementNode);
             }
         }
         else
         {
             equityOptionTransactionSupplement_ = new EquityOptionTransactionSupplement(equityOptionTransactionSupplementNode);
         }
     }
     
 
     XmlNode fxSingleLegNode = xmlNode.SelectSingleNode("fxSingleLeg");
     
     if (fxSingleLegNode != null)
     {
         if (fxSingleLegNode.Attributes["href"] != null || fxSingleLegNode.Attributes["id"] != null) 
         {
             if (fxSingleLegNode.Attributes["id"] != null) 
             {
                 fxSingleLegIDRef_ = fxSingleLegNode.Attributes["id"].Value;
                 FxSingleLeg ob = new FxSingleLeg(fxSingleLegNode);
                 IDManager.SetID(fxSingleLegIDRef_, ob);
             }
             else if (fxSingleLegNode.Attributes["href"] != null)
             {
                 fxSingleLegIDRef_ = fxSingleLegNode.Attributes["href"].Value;
             }
             else
             {
                 fxSingleLeg_ = new FxSingleLeg(fxSingleLegNode);
             }
         }
         else
         {
             fxSingleLeg_ = new FxSingleLeg(fxSingleLegNode);
         }
     }
     
 
     XmlNode fxSwapNode = xmlNode.SelectSingleNode("fxSwap");
     
     if (fxSwapNode != null)
     {
         if (fxSwapNode.Attributes["href"] != null || fxSwapNode.Attributes["id"] != null) 
         {
             if (fxSwapNode.Attributes["id"] != null) 
             {
                 fxSwapIDRef_ = fxSwapNode.Attributes["id"].Value;
                 FxSwap ob = new FxSwap(fxSwapNode);
                 IDManager.SetID(fxSwapIDRef_, ob);
             }
             else if (fxSwapNode.Attributes["href"] != null)
             {
                 fxSwapIDRef_ = fxSwapNode.Attributes["href"].Value;
             }
             else
             {
                 fxSwap_ = new FxSwap(fxSwapNode);
             }
         }
         else
         {
             fxSwap_ = new FxSwap(fxSwapNode);
         }
     }
     
 
     XmlNode fxOptionNode = xmlNode.SelectSingleNode("fxOption");
     
     if (fxOptionNode != null)
     {
         if (fxOptionNode.Attributes["href"] != null || fxOptionNode.Attributes["id"] != null) 
         {
             if (fxOptionNode.Attributes["id"] != null) 
             {
                 fxOptionIDRef_ = fxOptionNode.Attributes["id"].Value;
                 FxOption ob = new FxOption(fxOptionNode);
                 IDManager.SetID(fxOptionIDRef_, ob);
             }
             else if (fxOptionNode.Attributes["href"] != null)
             {
                 fxOptionIDRef_ = fxOptionNode.Attributes["href"].Value;
             }
             else
             {
                 fxOption_ = new FxOption(fxOptionNode);
             }
         }
         else
         {
             fxOption_ = new FxOption(fxOptionNode);
         }
     }
     
 
     XmlNode fxDigitalOptionNode = xmlNode.SelectSingleNode("fxDigitalOption");
     
     if (fxDigitalOptionNode != null)
     {
         if (fxDigitalOptionNode.Attributes["href"] != null || fxDigitalOptionNode.Attributes["id"] != null) 
         {
             if (fxDigitalOptionNode.Attributes["id"] != null) 
             {
                 fxDigitalOptionIDRef_ = fxDigitalOptionNode.Attributes["id"].Value;
                 FxDigitalOption ob = new FxDigitalOption(fxDigitalOptionNode);
                 IDManager.SetID(fxDigitalOptionIDRef_, ob);
             }
             else if (fxDigitalOptionNode.Attributes["href"] != null)
             {
                 fxDigitalOptionIDRef_ = fxDigitalOptionNode.Attributes["href"].Value;
             }
             else
             {
                 fxDigitalOption_ = new FxDigitalOption(fxDigitalOptionNode);
             }
         }
         else
         {
             fxDigitalOption_ = new FxDigitalOption(fxDigitalOptionNode);
         }
     }
     
 
     XmlNode termDepositNode = xmlNode.SelectSingleNode("termDeposit");
     
     if (termDepositNode != null)
     {
         if (termDepositNode.Attributes["href"] != null || termDepositNode.Attributes["id"] != null) 
         {
             if (termDepositNode.Attributes["id"] != null) 
             {
                 termDepositIDRef_ = termDepositNode.Attributes["id"].Value;
                 TermDeposit ob = new TermDeposit(termDepositNode);
                 IDManager.SetID(termDepositIDRef_, ob);
             }
             else if (termDepositNode.Attributes["href"] != null)
             {
                 termDepositIDRef_ = termDepositNode.Attributes["href"].Value;
             }
             else
             {
                 termDeposit_ = new TermDeposit(termDepositNode);
             }
         }
         else
         {
             termDeposit_ = new TermDeposit(termDepositNode);
         }
     }
     
 
     XmlNode genericProductNode = xmlNode.SelectSingleNode("genericProduct");
     
     if (genericProductNode != null)
     {
         if (genericProductNode.Attributes["href"] != null || genericProductNode.Attributes["id"] != null) 
         {
             if (genericProductNode.Attributes["id"] != null) 
             {
                 genericProductIDRef_ = genericProductNode.Attributes["id"].Value;
                 GenericProduct ob = new GenericProduct(genericProductNode);
                 IDManager.SetID(genericProductIDRef_, ob);
             }
             else if (genericProductNode.Attributes["href"] != null)
             {
                 genericProductIDRef_ = genericProductNode.Attributes["href"].Value;
             }
             else
             {
                 genericProduct_ = new GenericProduct(genericProductNode);
             }
         }
         else
         {
             genericProduct_ = new GenericProduct(genericProductNode);
         }
     }
     
 
     XmlNode nonSchemaProductNode = xmlNode.SelectSingleNode("nonSchemaProduct");
     
     if (nonSchemaProductNode != null)
     {
         if (nonSchemaProductNode.Attributes["href"] != null || nonSchemaProductNode.Attributes["id"] != null) 
         {
             if (nonSchemaProductNode.Attributes["id"] != null) 
             {
                 nonSchemaProductIDRef_ = nonSchemaProductNode.Attributes["id"].Value;
                 GenericProduct ob = new GenericProduct(nonSchemaProductNode);
                 IDManager.SetID(nonSchemaProductIDRef_, ob);
             }
             else if (nonSchemaProductNode.Attributes["href"] != null)
             {
                 nonSchemaProductIDRef_ = nonSchemaProductNode.Attributes["href"].Value;
             }
             else
             {
                 nonSchemaProduct_ = new GenericProduct(nonSchemaProductNode);
             }
         }
         else
         {
             nonSchemaProduct_ = new GenericProduct(nonSchemaProductNode);
         }
     }
     
 
     XmlNode bulletPaymentNode = xmlNode.SelectSingleNode("bulletPayment");
     
     if (bulletPaymentNode != null)
     {
         if (bulletPaymentNode.Attributes["href"] != null || bulletPaymentNode.Attributes["id"] != null) 
         {
             if (bulletPaymentNode.Attributes["id"] != null) 
             {
                 bulletPaymentIDRef_ = bulletPaymentNode.Attributes["id"].Value;
                 BulletPayment ob = new BulletPayment(bulletPaymentNode);
                 IDManager.SetID(bulletPaymentIDRef_, ob);
             }
             else if (bulletPaymentNode.Attributes["href"] != null)
             {
                 bulletPaymentIDRef_ = bulletPaymentNode.Attributes["href"].Value;
             }
             else
             {
                 bulletPayment_ = new BulletPayment(bulletPaymentNode);
             }
         }
         else
         {
             bulletPayment_ = new BulletPayment(bulletPaymentNode);
         }
     }
     
 
     XmlNode capFloorNode = xmlNode.SelectSingleNode("capFloor");
     
     if (capFloorNode != null)
     {
         if (capFloorNode.Attributes["href"] != null || capFloorNode.Attributes["id"] != null) 
         {
             if (capFloorNode.Attributes["id"] != null) 
             {
                 capFloorIDRef_ = capFloorNode.Attributes["id"].Value;
                 CapFloor ob = new CapFloor(capFloorNode);
                 IDManager.SetID(capFloorIDRef_, ob);
             }
             else if (capFloorNode.Attributes["href"] != null)
             {
                 capFloorIDRef_ = capFloorNode.Attributes["href"].Value;
             }
             else
             {
                 capFloor_ = new CapFloor(capFloorNode);
             }
         }
         else
         {
             capFloor_ = new CapFloor(capFloorNode);
         }
     }
     
 
     XmlNode fraNode = xmlNode.SelectSingleNode("fra");
     
     if (fraNode != null)
     {
         if (fraNode.Attributes["href"] != null || fraNode.Attributes["id"] != null) 
         {
             if (fraNode.Attributes["id"] != null) 
             {
                 fraIDRef_ = fraNode.Attributes["id"].Value;
                 Fra ob = new Fra(fraNode);
                 IDManager.SetID(fraIDRef_, ob);
             }
             else if (fraNode.Attributes["href"] != null)
             {
                 fraIDRef_ = fraNode.Attributes["href"].Value;
             }
             else
             {
                 fra_ = new Fra(fraNode);
             }
         }
         else
         {
             fra_ = new Fra(fraNode);
         }
     }
     
 
     XmlNode swapNode = xmlNode.SelectSingleNode("swap");
     
     if (swapNode != null)
     {
         if (swapNode.Attributes["href"] != null || swapNode.Attributes["id"] != null) 
         {
             if (swapNode.Attributes["id"] != null) 
             {
                 swapIDRef_ = swapNode.Attributes["id"].Value;
                 Swap ob = new Swap(swapNode);
                 IDManager.SetID(swapIDRef_, ob);
             }
             else if (swapNode.Attributes["href"] != null)
             {
                 swapIDRef_ = swapNode.Attributes["href"].Value;
             }
             else
             {
                 swap_ = new Swap(swapNode);
             }
         }
         else
         {
             swap_ = new Swap(swapNode);
         }
     }
     
 
     XmlNode swaptionNode = xmlNode.SelectSingleNode("swaption");
     
     if (swaptionNode != null)
     {
         if (swaptionNode.Attributes["href"] != null || swaptionNode.Attributes["id"] != null) 
         {
             if (swaptionNode.Attributes["id"] != null) 
             {
                 swaptionIDRef_ = swaptionNode.Attributes["id"].Value;
                 Swaption ob = new Swaption(swaptionNode);
                 IDManager.SetID(swaptionIDRef_, ob);
             }
             else if (swaptionNode.Attributes["href"] != null)
             {
                 swaptionIDRef_ = swaptionNode.Attributes["href"].Value;
             }
             else
             {
                 swaption_ = new Swaption(swaptionNode);
             }
         }
         else
         {
             swaption_ = new Swaption(swaptionNode);
         }
     }
     
 
     XmlNode equitySwapTransactionSupplementNode = xmlNode.SelectSingleNode("equitySwapTransactionSupplement");
     
     if (equitySwapTransactionSupplementNode != null)
     {
         if (equitySwapTransactionSupplementNode.Attributes["href"] != null || equitySwapTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (equitySwapTransactionSupplementNode.Attributes["id"] != null) 
             {
                 equitySwapTransactionSupplementIDRef_ = equitySwapTransactionSupplementNode.Attributes["id"].Value;
                 EquitySwapTransactionSupplement ob = new EquitySwapTransactionSupplement(equitySwapTransactionSupplementNode);
                 IDManager.SetID(equitySwapTransactionSupplementIDRef_, ob);
             }
             else if (equitySwapTransactionSupplementNode.Attributes["href"] != null)
             {
                 equitySwapTransactionSupplementIDRef_ = equitySwapTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 equitySwapTransactionSupplement_ = new EquitySwapTransactionSupplement(equitySwapTransactionSupplementNode);
             }
         }
         else
         {
             equitySwapTransactionSupplement_ = new EquitySwapTransactionSupplement(equitySwapTransactionSupplementNode);
         }
     }
     
 
     XmlNode standardProductNode = xmlNode.SelectSingleNode("standardProduct");
     
     if (standardProductNode != null)
     {
         if (standardProductNode.Attributes["href"] != null || standardProductNode.Attributes["id"] != null) 
         {
             if (standardProductNode.Attributes["id"] != null) 
             {
                 standardProductIDRef_ = standardProductNode.Attributes["id"].Value;
                 StandardProduct ob = new StandardProduct(standardProductNode);
                 IDManager.SetID(standardProductIDRef_, ob);
             }
             else if (standardProductNode.Attributes["href"] != null)
             {
                 standardProductIDRef_ = standardProductNode.Attributes["href"].Value;
             }
             else
             {
                 standardProduct_ = new StandardProduct(standardProductNode);
             }
         }
         else
         {
             standardProduct_ = new StandardProduct(standardProductNode);
         }
     }
     
 
     XmlNode varianceOptionTransactionSupplementNode = xmlNode.SelectSingleNode("varianceOptionTransactionSupplement");
     
     if (varianceOptionTransactionSupplementNode != null)
     {
         if (varianceOptionTransactionSupplementNode.Attributes["href"] != null || varianceOptionTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (varianceOptionTransactionSupplementNode.Attributes["id"] != null) 
             {
                 varianceOptionTransactionSupplementIDRef_ = varianceOptionTransactionSupplementNode.Attributes["id"].Value;
                 VarianceOptionTransactionSupplement ob = new VarianceOptionTransactionSupplement(varianceOptionTransactionSupplementNode);
                 IDManager.SetID(varianceOptionTransactionSupplementIDRef_, ob);
             }
             else if (varianceOptionTransactionSupplementNode.Attributes["href"] != null)
             {
                 varianceOptionTransactionSupplementIDRef_ = varianceOptionTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 varianceOptionTransactionSupplement_ = new VarianceOptionTransactionSupplement(varianceOptionTransactionSupplementNode);
             }
         }
         else
         {
             varianceOptionTransactionSupplement_ = new VarianceOptionTransactionSupplement(varianceOptionTransactionSupplementNode);
         }
     }
     
 
     XmlNode varianceSwapNode = xmlNode.SelectSingleNode("varianceSwap");
     
     if (varianceSwapNode != null)
     {
         if (varianceSwapNode.Attributes["href"] != null || varianceSwapNode.Attributes["id"] != null) 
         {
             if (varianceSwapNode.Attributes["id"] != null) 
             {
                 varianceSwapIDRef_ = varianceSwapNode.Attributes["id"].Value;
                 VarianceSwap ob = new VarianceSwap(varianceSwapNode);
                 IDManager.SetID(varianceSwapIDRef_, ob);
             }
             else if (varianceSwapNode.Attributes["href"] != null)
             {
                 varianceSwapIDRef_ = varianceSwapNode.Attributes["href"].Value;
             }
             else
             {
                 varianceSwap_ = new VarianceSwap(varianceSwapNode);
             }
         }
         else
         {
             varianceSwap_ = new VarianceSwap(varianceSwapNode);
         }
     }
     
 
     XmlNode varianceSwapTransactionSupplementNode = xmlNode.SelectSingleNode("varianceSwapTransactionSupplement");
     
     if (varianceSwapTransactionSupplementNode != null)
     {
         if (varianceSwapTransactionSupplementNode.Attributes["href"] != null || varianceSwapTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (varianceSwapTransactionSupplementNode.Attributes["id"] != null) 
             {
                 varianceSwapTransactionSupplementIDRef_ = varianceSwapTransactionSupplementNode.Attributes["id"].Value;
                 VarianceSwapTransactionSupplement ob = new VarianceSwapTransactionSupplement(varianceSwapTransactionSupplementNode);
                 IDManager.SetID(varianceSwapTransactionSupplementIDRef_, ob);
             }
             else if (varianceSwapTransactionSupplementNode.Attributes["href"] != null)
             {
                 varianceSwapTransactionSupplementIDRef_ = varianceSwapTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 varianceSwapTransactionSupplement_ = new VarianceSwapTransactionSupplement(varianceSwapTransactionSupplementNode);
             }
         }
         else
         {
             varianceSwapTransactionSupplement_ = new VarianceSwapTransactionSupplement(varianceSwapTransactionSupplementNode);
         }
     }
     
 
     XmlNodeList otherPartyPaymentNodeList = xmlNode.SelectNodes("otherPartyPayment");
     
     if (otherPartyPaymentNodeList != null)
     {
         this.otherPartyPayment_ = new List<Payment>();
         foreach (XmlNode item in otherPartyPaymentNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     otherPartyPaymentIDRef_ = item.Attributes["id"].Value;
                     otherPartyPayment_.Add(new Payment(item));
                     IDManager.SetID(otherPartyPaymentIDRef_, otherPartyPayment_[otherPartyPayment_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     otherPartyPaymentIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 otherPartyPayment_.Add(new Payment(item));
                 }
             }
             else
             {
                 otherPartyPayment_.Add(new Payment(item));
             }
         }
     }
     
 
     XmlNodeList brokerPartyReferenceNodeList = xmlNode.SelectNodes("brokerPartyReference");
     
     if (brokerPartyReferenceNodeList != null)
     {
         this.brokerPartyReference_ = new List<PartyReference>();
         foreach (XmlNode item in brokerPartyReferenceNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     brokerPartyReferenceIDRef_ = item.Attributes["id"].Value;
                     brokerPartyReference_.Add(new PartyReference(item));
                     IDManager.SetID(brokerPartyReferenceIDRef_, brokerPartyReference_[brokerPartyReference_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     brokerPartyReferenceIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 brokerPartyReference_.Add(new PartyReference(item));
                 }
             }
             else
             {
                 brokerPartyReference_.Add(new PartyReference(item));
             }
         }
     }
     
 
     XmlNode calculationAgentNode = xmlNode.SelectSingleNode("calculationAgent");
     
     if (calculationAgentNode != null)
     {
         if (calculationAgentNode.Attributes["href"] != null || calculationAgentNode.Attributes["id"] != null) 
         {
             if (calculationAgentNode.Attributes["id"] != null) 
             {
                 calculationAgentIDRef_ = calculationAgentNode.Attributes["id"].Value;
                 CalculationAgent ob = new CalculationAgent(calculationAgentNode);
                 IDManager.SetID(calculationAgentIDRef_, ob);
             }
             else if (calculationAgentNode.Attributes["href"] != null)
             {
                 calculationAgentIDRef_ = calculationAgentNode.Attributes["href"].Value;
             }
             else
             {
                 calculationAgent_ = new CalculationAgent(calculationAgentNode);
             }
         }
         else
         {
             calculationAgent_ = new CalculationAgent(calculationAgentNode);
         }
     }
     
 
     XmlNode calculationAgentBusinessCenterNode = xmlNode.SelectSingleNode("calculationAgentBusinessCenter");
     
     if (calculationAgentBusinessCenterNode != null)
     {
         if (calculationAgentBusinessCenterNode.Attributes["href"] != null || calculationAgentBusinessCenterNode.Attributes["id"] != null) 
         {
             if (calculationAgentBusinessCenterNode.Attributes["id"] != null) 
             {
                 calculationAgentBusinessCenterIDRef_ = calculationAgentBusinessCenterNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(calculationAgentBusinessCenterNode);
                 IDManager.SetID(calculationAgentBusinessCenterIDRef_, ob);
             }
             else if (calculationAgentBusinessCenterNode.Attributes["href"] != null)
             {
                 calculationAgentBusinessCenterIDRef_ = calculationAgentBusinessCenterNode.Attributes["href"].Value;
             }
             else
             {
                 calculationAgentBusinessCenter_ = new BusinessCenter(calculationAgentBusinessCenterNode);
             }
         }
         else
         {
             calculationAgentBusinessCenter_ = new BusinessCenter(calculationAgentBusinessCenterNode);
         }
     }
     
 
     XmlNodeList determiningPartyNodeList = xmlNode.SelectNodes("determiningParty");
     
     if (determiningPartyNodeList != null)
     {
         this.determiningParty_ = new List<PartyReference>();
         foreach (XmlNode item in determiningPartyNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     determiningPartyIDRef_ = item.Attributes["id"].Value;
                     determiningParty_.Add(new PartyReference(item));
                     IDManager.SetID(determiningPartyIDRef_, determiningParty_[determiningParty_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     determiningPartyIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 determiningParty_.Add(new PartyReference(item));
                 }
             }
             else
             {
                 determiningParty_.Add(new PartyReference(item));
             }
         }
     }
     
 
     XmlNodeList hedgingPartyNodeList = xmlNode.SelectNodes("hedgingParty");
     
     if (hedgingPartyNodeList != null)
     {
         this.hedgingParty_ = new List<PartyReference>();
         foreach (XmlNode item in hedgingPartyNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     hedgingPartyIDRef_ = item.Attributes["id"].Value;
                     hedgingParty_.Add(new PartyReference(item));
                     IDManager.SetID(hedgingPartyIDRef_, hedgingParty_[hedgingParty_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     hedgingPartyIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 hedgingParty_.Add(new PartyReference(item));
                 }
             }
             else
             {
                 hedgingParty_.Add(new PartyReference(item));
             }
         }
     }
     
 
     XmlNode collateralNode = xmlNode.SelectSingleNode("collateral");
     
     if (collateralNode != null)
     {
         if (collateralNode.Attributes["href"] != null || collateralNode.Attributes["id"] != null) 
         {
             if (collateralNode.Attributes["id"] != null) 
             {
                 collateralIDRef_ = collateralNode.Attributes["id"].Value;
                 Collateral ob = new Collateral(collateralNode);
                 IDManager.SetID(collateralIDRef_, ob);
             }
             else if (collateralNode.Attributes["href"] != null)
             {
                 collateralIDRef_ = collateralNode.Attributes["href"].Value;
             }
             else
             {
                 collateral_ = new Collateral(collateralNode);
             }
         }
         else
         {
             collateral_ = new Collateral(collateralNode);
         }
     }
     
 
     XmlNode documentationNode = xmlNode.SelectSingleNode("documentation");
     
     if (documentationNode != null)
     {
         if (documentationNode.Attributes["href"] != null || documentationNode.Attributes["id"] != null) 
         {
             if (documentationNode.Attributes["id"] != null) 
             {
                 documentationIDRef_ = documentationNode.Attributes["id"].Value;
                 Documentation ob = new Documentation(documentationNode);
                 IDManager.SetID(documentationIDRef_, ob);
             }
             else if (documentationNode.Attributes["href"] != null)
             {
                 documentationIDRef_ = documentationNode.Attributes["href"].Value;
             }
             else
             {
                 documentation_ = new Documentation(documentationNode);
             }
         }
         else
         {
             documentation_ = new Documentation(documentationNode);
         }
     }
     
 
     XmlNode governingLawNode = xmlNode.SelectSingleNode("governingLaw");
     
     if (governingLawNode != null)
     {
         if (governingLawNode.Attributes["href"] != null || governingLawNode.Attributes["id"] != null) 
         {
             if (governingLawNode.Attributes["id"] != null) 
             {
                 governingLawIDRef_ = governingLawNode.Attributes["id"].Value;
                 GoverningLaw ob = new GoverningLaw(governingLawNode);
                 IDManager.SetID(governingLawIDRef_, ob);
             }
             else if (governingLawNode.Attributes["href"] != null)
             {
                 governingLawIDRef_ = governingLawNode.Attributes["href"].Value;
             }
             else
             {
                 governingLaw_ = new GoverningLaw(governingLawNode);
             }
         }
         else
         {
             governingLaw_ = new GoverningLaw(governingLawNode);
         }
     }
     
 
     XmlNode allocationsNode = xmlNode.SelectSingleNode("allocations");
     
     if (allocationsNode != null)
     {
         if (allocationsNode.Attributes["href"] != null || allocationsNode.Attributes["id"] != null) 
         {
             if (allocationsNode.Attributes["id"] != null) 
             {
                 allocationsIDRef_ = allocationsNode.Attributes["id"].Value;
                 Allocations ob = new Allocations(allocationsNode);
                 IDManager.SetID(allocationsIDRef_, ob);
             }
             else if (allocationsNode.Attributes["href"] != null)
             {
                 allocationsIDRef_ = allocationsNode.Attributes["href"].Value;
             }
             else
             {
                 allocations_ = new Allocations(allocationsNode);
             }
         }
         else
         {
             allocations_ = new Allocations(allocationsNode);
         }
     }
     
 
 }
 public ExerciseNotice(XmlNode xmlNode)
 {
     XmlNodeList partyReferenceNodeList = xmlNode.SelectNodes("partyReference");
     if (partyReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in partyReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 partyReferenceIDRef = item.Attributes["id"].Name;
                 PartyReference ob = PartyReference();
                 IDManager.SetID(partyReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 partyReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 partyReference = new PartyReference(item);
             }
         }
     }
     
 
     XmlNodeList exerciseNoticePartyReferenceNodeList = xmlNode.SelectNodes("exerciseNoticePartyReference");
     if (exerciseNoticePartyReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in exerciseNoticePartyReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 exerciseNoticePartyReferenceIDRef = item.Attributes["id"].Name;
                 PartyReference ob = PartyReference();
                 IDManager.SetID(exerciseNoticePartyReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 exerciseNoticePartyReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 exerciseNoticePartyReference = new PartyReference(item);
             }
         }
     }
     
 
     XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");
     if (businessCenterNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in businessCenterNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 businessCenterIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(businessCenterIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 businessCenterIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 businessCenter = new BusinessCenter(item);
             }
         }
     }
     
 
 }
 public ExerciseNotice(XmlNode xmlNode)
 {
     XmlNode partyReferenceNode = xmlNode.SelectSingleNode("partyReference");
     
     if (partyReferenceNode != null)
     {
         if (partyReferenceNode.Attributes["href"] != null || partyReferenceNode.Attributes["id"] != null) 
         {
             if (partyReferenceNode.Attributes["id"] != null) 
             {
                 partyReferenceIDRef_ = partyReferenceNode.Attributes["id"].Value;
                 PartyReference ob = new PartyReference(partyReferenceNode);
                 IDManager.SetID(partyReferenceIDRef_, ob);
             }
             else if (partyReferenceNode.Attributes["href"] != null)
             {
                 partyReferenceIDRef_ = partyReferenceNode.Attributes["href"].Value;
             }
             else
             {
                 partyReference_ = new PartyReference(partyReferenceNode);
             }
         }
         else
         {
             partyReference_ = new PartyReference(partyReferenceNode);
         }
     }
     
 
     XmlNode exerciseNoticePartyReferenceNode = xmlNode.SelectSingleNode("exerciseNoticePartyReference");
     
     if (exerciseNoticePartyReferenceNode != null)
     {
         if (exerciseNoticePartyReferenceNode.Attributes["href"] != null || exerciseNoticePartyReferenceNode.Attributes["id"] != null) 
         {
             if (exerciseNoticePartyReferenceNode.Attributes["id"] != null) 
             {
                 exerciseNoticePartyReferenceIDRef_ = exerciseNoticePartyReferenceNode.Attributes["id"].Value;
                 PartyReference ob = new PartyReference(exerciseNoticePartyReferenceNode);
                 IDManager.SetID(exerciseNoticePartyReferenceIDRef_, ob);
             }
             else if (exerciseNoticePartyReferenceNode.Attributes["href"] != null)
             {
                 exerciseNoticePartyReferenceIDRef_ = exerciseNoticePartyReferenceNode.Attributes["href"].Value;
             }
             else
             {
                 exerciseNoticePartyReference_ = new PartyReference(exerciseNoticePartyReferenceNode);
             }
         }
         else
         {
             exerciseNoticePartyReference_ = new PartyReference(exerciseNoticePartyReferenceNode);
         }
     }
     
 
     XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");
     
     if (businessCenterNode != null)
     {
         if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null) 
         {
             if (businessCenterNode.Attributes["id"] != null) 
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(businessCenterNode);
                 IDManager.SetID(businessCenterIDRef_, ob);
             }
             else if (businessCenterNode.Attributes["href"] != null)
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
             }
             else
             {
                 businessCenter_ = new BusinessCenter(businessCenterNode);
             }
         }
         else
         {
             businessCenter_ = new BusinessCenter(businessCenterNode);
         }
     }
     
 
 }
示例#10
0
        public CreditEventNotice(XmlNode xmlNode)
        {
            XmlNode notifyingPartyNode = xmlNode.SelectSingleNode("notifyingParty");

            if (notifyingPartyNode != null)
            {
                if (notifyingPartyNode.Attributes["href"] != null || notifyingPartyNode.Attributes["id"] != null)
                {
                    if (notifyingPartyNode.Attributes["id"] != null)
                    {
                        notifyingPartyIDRef_ = notifyingPartyNode.Attributes["id"].Value;
                        NotifyingParty ob = new NotifyingParty(notifyingPartyNode);
                        IDManager.SetID(notifyingPartyIDRef_, ob);
                    }
                    else if (notifyingPartyNode.Attributes["href"] != null)
                    {
                        notifyingPartyIDRef_ = notifyingPartyNode.Attributes["href"].Value;
                    }
                    else
                    {
                        notifyingParty_ = new NotifyingParty(notifyingPartyNode);
                    }
                }
                else
                {
                    notifyingParty_ = new NotifyingParty(notifyingPartyNode);
                }
            }


            XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");

            if (businessCenterNode != null)
            {
                if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null)
                {
                    if (businessCenterNode.Attributes["id"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                        BusinessCenter ob = new BusinessCenter(businessCenterNode);
                        IDManager.SetID(businessCenterIDRef_, ob);
                    }
                    else if (businessCenterNode.Attributes["href"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
                    }
                    else
                    {
                        businessCenter_ = new BusinessCenter(businessCenterNode);
                    }
                }
                else
                {
                    businessCenter_ = new BusinessCenter(businessCenterNode);
                }
            }


            XmlNode publiclyAvailableInformationNode = xmlNode.SelectSingleNode("publiclyAvailableInformation");

            if (publiclyAvailableInformationNode != null)
            {
                if (publiclyAvailableInformationNode.Attributes["href"] != null || publiclyAvailableInformationNode.Attributes["id"] != null)
                {
                    if (publiclyAvailableInformationNode.Attributes["id"] != null)
                    {
                        publiclyAvailableInformationIDRef_ = publiclyAvailableInformationNode.Attributes["id"].Value;
                        PubliclyAvailableInformation ob = new PubliclyAvailableInformation(publiclyAvailableInformationNode);
                        IDManager.SetID(publiclyAvailableInformationIDRef_, ob);
                    }
                    else if (publiclyAvailableInformationNode.Attributes["href"] != null)
                    {
                        publiclyAvailableInformationIDRef_ = publiclyAvailableInformationNode.Attributes["href"].Value;
                    }
                    else
                    {
                        publiclyAvailableInformation_ = new PubliclyAvailableInformation(publiclyAvailableInformationNode);
                    }
                }
                else
                {
                    publiclyAvailableInformation_ = new PubliclyAvailableInformation(publiclyAvailableInformationNode);
                }
            }
        }
 public WeatherStation(XmlNode xmlNode)
 {
     XmlNode weatherStationCityNode = xmlNode.SelectSingleNode("weatherStationCity");
     
     if (weatherStationCityNode != null)
     {
         if (weatherStationCityNode.Attributes["href"] != null || weatherStationCityNode.Attributes["id"] != null) 
         {
             if (weatherStationCityNode.Attributes["id"] != null) 
             {
                 weatherStationCityIDRef_ = weatherStationCityNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(weatherStationCityNode);
                 IDManager.SetID(weatherStationCityIDRef_, ob);
             }
             else if (weatherStationCityNode.Attributes["href"] != null)
             {
                 weatherStationCityIDRef_ = weatherStationCityNode.Attributes["href"].Value;
             }
             else
             {
                 weatherStationCity_ = new BusinessCenter(weatherStationCityNode);
             }
         }
         else
         {
             weatherStationCity_ = new BusinessCenter(weatherStationCityNode);
         }
     }
     
 
     XmlNode weatherStationAirportNode = xmlNode.SelectSingleNode("weatherStationAirport");
     
     if (weatherStationAirportNode != null)
     {
         if (weatherStationAirportNode.Attributes["href"] != null || weatherStationAirportNode.Attributes["id"] != null) 
         {
             if (weatherStationAirportNode.Attributes["id"] != null) 
             {
                 weatherStationAirportIDRef_ = weatherStationAirportNode.Attributes["id"].Value;
                 WeatherStationAirport ob = new WeatherStationAirport(weatherStationAirportNode);
                 IDManager.SetID(weatherStationAirportIDRef_, ob);
             }
             else if (weatherStationAirportNode.Attributes["href"] != null)
             {
                 weatherStationAirportIDRef_ = weatherStationAirportNode.Attributes["href"].Value;
             }
             else
             {
                 weatherStationAirport_ = new WeatherStationAirport(weatherStationAirportNode);
             }
         }
         else
         {
             weatherStationAirport_ = new WeatherStationAirport(weatherStationAirportNode);
         }
     }
     
 
     XmlNode weatherStationWBANNode = xmlNode.SelectSingleNode("weatherStationWBAN");
     
     if (weatherStationWBANNode != null)
     {
         if (weatherStationWBANNode.Attributes["href"] != null || weatherStationWBANNode.Attributes["id"] != null) 
         {
             if (weatherStationWBANNode.Attributes["id"] != null) 
             {
                 weatherStationWBANIDRef_ = weatherStationWBANNode.Attributes["id"].Value;
                 WeatherStationWBAN ob = new WeatherStationWBAN(weatherStationWBANNode);
                 IDManager.SetID(weatherStationWBANIDRef_, ob);
             }
             else if (weatherStationWBANNode.Attributes["href"] != null)
             {
                 weatherStationWBANIDRef_ = weatherStationWBANNode.Attributes["href"].Value;
             }
             else
             {
                 weatherStationWBAN_ = new WeatherStationWBAN(weatherStationWBANNode);
             }
         }
         else
         {
             weatherStationWBAN_ = new WeatherStationWBAN(weatherStationWBANNode);
         }
     }
     
 
     XmlNode weatherStationWMONode = xmlNode.SelectSingleNode("weatherStationWMO");
     
     if (weatherStationWMONode != null)
     {
         if (weatherStationWMONode.Attributes["href"] != null || weatherStationWMONode.Attributes["id"] != null) 
         {
             if (weatherStationWMONode.Attributes["id"] != null) 
             {
                 weatherStationWMOIDRef_ = weatherStationWMONode.Attributes["id"].Value;
                 WeatherStationWMO ob = new WeatherStationWMO(weatherStationWMONode);
                 IDManager.SetID(weatherStationWMOIDRef_, ob);
             }
             else if (weatherStationWMONode.Attributes["href"] != null)
             {
                 weatherStationWMOIDRef_ = weatherStationWMONode.Attributes["href"].Value;
             }
             else
             {
                 weatherStationWMO_ = new WeatherStationWMO(weatherStationWMONode);
             }
         }
         else
         {
             weatherStationWMO_ = new WeatherStationWMO(weatherStationWMONode);
         }
     }
     
 
 }
 public CreditEventNotice(XmlNode xmlNode)
 {
     XmlNodeList notifyingPartyNodeList = xmlNode.SelectNodes("notifyingParty");
     if (notifyingPartyNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in notifyingPartyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 notifyingPartyIDRef = item.Attributes["id"].Name;
                 NotifyingParty ob = NotifyingParty();
                 IDManager.SetID(notifyingPartyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 notifyingPartyIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 notifyingParty = new NotifyingParty(item);
             }
         }
     }
     
 
     XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");
     if (businessCenterNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in businessCenterNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 businessCenterIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(businessCenterIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 businessCenterIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 businessCenter = new BusinessCenter(item);
             }
         }
     }
     
 
     XmlNodeList publiclyAvailableInformationNodeList = xmlNode.SelectNodes("publiclyAvailableInformation");
     if (publiclyAvailableInformationNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in publiclyAvailableInformationNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 publiclyAvailableInformationIDRef = item.Attributes["id"].Name;
                 PubliclyAvailableInformation ob = PubliclyAvailableInformation();
                 IDManager.SetID(publiclyAvailableInformationIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 publiclyAvailableInformationIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 publiclyAvailableInformation = new PubliclyAvailableInformation(item);
             }
         }
     }
     
 
 }
示例#13
0
        public WeatherStation(XmlNode xmlNode)
        {
            XmlNode weatherStationCityNode = xmlNode.SelectSingleNode("weatherStationCity");

            if (weatherStationCityNode != null)
            {
                if (weatherStationCityNode.Attributes["href"] != null || weatherStationCityNode.Attributes["id"] != null)
                {
                    if (weatherStationCityNode.Attributes["id"] != null)
                    {
                        weatherStationCityIDRef_ = weatherStationCityNode.Attributes["id"].Value;
                        BusinessCenter ob = new BusinessCenter(weatherStationCityNode);
                        IDManager.SetID(weatherStationCityIDRef_, ob);
                    }
                    else if (weatherStationCityNode.Attributes["href"] != null)
                    {
                        weatherStationCityIDRef_ = weatherStationCityNode.Attributes["href"].Value;
                    }
                    else
                    {
                        weatherStationCity_ = new BusinessCenter(weatherStationCityNode);
                    }
                }
                else
                {
                    weatherStationCity_ = new BusinessCenter(weatherStationCityNode);
                }
            }


            XmlNode weatherStationAirportNode = xmlNode.SelectSingleNode("weatherStationAirport");

            if (weatherStationAirportNode != null)
            {
                if (weatherStationAirportNode.Attributes["href"] != null || weatherStationAirportNode.Attributes["id"] != null)
                {
                    if (weatherStationAirportNode.Attributes["id"] != null)
                    {
                        weatherStationAirportIDRef_ = weatherStationAirportNode.Attributes["id"].Value;
                        WeatherStationAirport ob = new WeatherStationAirport(weatherStationAirportNode);
                        IDManager.SetID(weatherStationAirportIDRef_, ob);
                    }
                    else if (weatherStationAirportNode.Attributes["href"] != null)
                    {
                        weatherStationAirportIDRef_ = weatherStationAirportNode.Attributes["href"].Value;
                    }
                    else
                    {
                        weatherStationAirport_ = new WeatherStationAirport(weatherStationAirportNode);
                    }
                }
                else
                {
                    weatherStationAirport_ = new WeatherStationAirport(weatherStationAirportNode);
                }
            }


            XmlNode weatherStationWBANNode = xmlNode.SelectSingleNode("weatherStationWBAN");

            if (weatherStationWBANNode != null)
            {
                if (weatherStationWBANNode.Attributes["href"] != null || weatherStationWBANNode.Attributes["id"] != null)
                {
                    if (weatherStationWBANNode.Attributes["id"] != null)
                    {
                        weatherStationWBANIDRef_ = weatherStationWBANNode.Attributes["id"].Value;
                        WeatherStationWBAN ob = new WeatherStationWBAN(weatherStationWBANNode);
                        IDManager.SetID(weatherStationWBANIDRef_, ob);
                    }
                    else if (weatherStationWBANNode.Attributes["href"] != null)
                    {
                        weatherStationWBANIDRef_ = weatherStationWBANNode.Attributes["href"].Value;
                    }
                    else
                    {
                        weatherStationWBAN_ = new WeatherStationWBAN(weatherStationWBANNode);
                    }
                }
                else
                {
                    weatherStationWBAN_ = new WeatherStationWBAN(weatherStationWBANNode);
                }
            }


            XmlNode weatherStationWMONode = xmlNode.SelectSingleNode("weatherStationWMO");

            if (weatherStationWMONode != null)
            {
                if (weatherStationWMONode.Attributes["href"] != null || weatherStationWMONode.Attributes["id"] != null)
                {
                    if (weatherStationWMONode.Attributes["id"] != null)
                    {
                        weatherStationWMOIDRef_ = weatherStationWMONode.Attributes["id"].Value;
                        WeatherStationWMO ob = new WeatherStationWMO(weatherStationWMONode);
                        IDManager.SetID(weatherStationWMOIDRef_, ob);
                    }
                    else if (weatherStationWMONode.Attributes["href"] != null)
                    {
                        weatherStationWMOIDRef_ = weatherStationWMONode.Attributes["href"].Value;
                    }
                    else
                    {
                        weatherStationWMO_ = new WeatherStationWMO(weatherStationWMONode);
                    }
                }
                else
                {
                    weatherStationWMO_ = new WeatherStationWMO(weatherStationWMONode);
                }
            }
        }
 public Trade(XmlNode xmlNode)
 {
     XmlNodeList tradeHeaderNodeList = xmlNode.SelectNodes("tradeHeader");
     if (tradeHeaderNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in tradeHeaderNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 tradeHeaderIDRef = item.Attributes["id"].Name;
                 TradeHeader ob = TradeHeader();
                 IDManager.SetID(tradeHeaderIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 tradeHeaderIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 tradeHeader = new TradeHeader(item);
             }
         }
     }
     
 
     XmlNodeList productNodeList = xmlNode.SelectNodes("product");
     if (productNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in productNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 productIDRef = item.Attributes["id"].Name;
                 Product ob = Product();
                 IDManager.SetID(productIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 productIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 product = new Product(item);
             }
         }
     }
     
 
     XmlNodeList forwardNodeList = xmlNode.SelectNodes("forward");
     if (forwardNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in forwardNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 forwardIDRef = item.Attributes["id"].Name;
                 ForwardSale ob = ForwardSale();
                 IDManager.SetID(forwardIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 forwardIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 forward = new ForwardSale(item);
             }
         }
     }
     
 
     XmlNodeList bondOptionNodeList = xmlNode.SelectNodes("bondOption");
     if (bondOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in bondOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 bondOptionIDRef = item.Attributes["id"].Name;
                 BondOption ob = BondOption();
                 IDManager.SetID(bondOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 bondOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 bondOption = new BondOption(item);
             }
         }
     }
     
 
     XmlNodeList creditDefaultSwapNodeList = xmlNode.SelectNodes("creditDefaultSwap");
     if (creditDefaultSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in creditDefaultSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 creditDefaultSwapIDRef = item.Attributes["id"].Name;
                 CreditDefaultSwap ob = CreditDefaultSwap();
                 IDManager.SetID(creditDefaultSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 creditDefaultSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 creditDefaultSwap = new CreditDefaultSwap(item);
             }
         }
     }
     
 
     XmlNodeList creditDefaultSwapOptionNodeList = xmlNode.SelectNodes("creditDefaultSwapOption");
     if (creditDefaultSwapOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in creditDefaultSwapOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 creditDefaultSwapOptionIDRef = item.Attributes["id"].Name;
                 CreditDefaultSwapOption ob = CreditDefaultSwapOption();
                 IDManager.SetID(creditDefaultSwapOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 creditDefaultSwapOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 creditDefaultSwapOption = new CreditDefaultSwapOption(item);
             }
         }
     }
     
 
     XmlNodeList commodityForwardNodeList = xmlNode.SelectNodes("commodityForward");
     if (commodityForwardNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityForwardNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityForwardIDRef = item.Attributes["id"].Name;
                 CommodityForward ob = CommodityForward();
                 IDManager.SetID(commodityForwardIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityForwardIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityForward = new CommodityForward(item);
             }
         }
     }
     
 
     XmlNodeList commodityOptionNodeList = xmlNode.SelectNodes("commodityOption");
     if (commodityOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityOptionIDRef = item.Attributes["id"].Name;
                 CommodityOption ob = CommodityOption();
                 IDManager.SetID(commodityOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityOption = new CommodityOption(item);
             }
         }
     }
     
 
     XmlNodeList commoditySwapNodeList = xmlNode.SelectNodes("commoditySwap");
     if (commoditySwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commoditySwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commoditySwapIDRef = item.Attributes["id"].Name;
                 CommoditySwap ob = CommoditySwap();
                 IDManager.SetID(commoditySwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commoditySwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commoditySwap = new CommoditySwap(item);
             }
         }
     }
     
 
     XmlNodeList commoditySwaptionNodeList = xmlNode.SelectNodes("commoditySwaption");
     if (commoditySwaptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commoditySwaptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commoditySwaptionIDRef = item.Attributes["id"].Name;
                 CommoditySwaption ob = CommoditySwaption();
                 IDManager.SetID(commoditySwaptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commoditySwaptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commoditySwaption = new CommoditySwaption(item);
             }
         }
     }
     
 
     XmlNodeList correlationSwapNodeList = xmlNode.SelectNodes("correlationSwap");
     if (correlationSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in correlationSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 correlationSwapIDRef = item.Attributes["id"].Name;
                 CorrelationSwap ob = CorrelationSwap();
                 IDManager.SetID(correlationSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 correlationSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 correlationSwap = new CorrelationSwap(item);
             }
         }
     }
     
 
     XmlNodeList dividendSwapOptionTransactionSupplementNodeList = xmlNode.SelectNodes("dividendSwapOptionTransactionSupplement");
     if (dividendSwapOptionTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in dividendSwapOptionTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 dividendSwapOptionTransactionSupplementIDRef = item.Attributes["id"].Name;
                 DividendSwapOptionTransactionSupplement ob = DividendSwapOptionTransactionSupplement();
                 IDManager.SetID(dividendSwapOptionTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 dividendSwapOptionTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 dividendSwapOptionTransactionSupplement = new DividendSwapOptionTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList dividendSwapTransactionSupplementNodeList = xmlNode.SelectNodes("dividendSwapTransactionSupplement");
     if (dividendSwapTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in dividendSwapTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 dividendSwapTransactionSupplementIDRef = item.Attributes["id"].Name;
                 DividendSwapTransactionSupplement ob = DividendSwapTransactionSupplement();
                 IDManager.SetID(dividendSwapTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 dividendSwapTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 dividendSwapTransactionSupplement = new DividendSwapTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList instrumentTradeDetailsNodeList = xmlNode.SelectNodes("instrumentTradeDetails");
     if (instrumentTradeDetailsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in instrumentTradeDetailsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 instrumentTradeDetailsIDRef = item.Attributes["id"].Name;
                 InstrumentTradeDetails ob = InstrumentTradeDetails();
                 IDManager.SetID(instrumentTradeDetailsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 instrumentTradeDetailsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 instrumentTradeDetails = new InstrumentTradeDetails(item);
             }
         }
     }
     
 
     XmlNodeList strategyNodeList = xmlNode.SelectNodes("strategy");
     if (strategyNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in strategyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 strategyIDRef = item.Attributes["id"].Name;
                 Strategy ob = Strategy();
                 IDManager.SetID(strategyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 strategyIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 strategy = new Strategy(item);
             }
         }
     }
     
 
     XmlNodeList returnSwapNodeList = xmlNode.SelectNodes("returnSwap");
     if (returnSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in returnSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 returnSwapIDRef = item.Attributes["id"].Name;
                 ReturnSwap ob = ReturnSwap();
                 IDManager.SetID(returnSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 returnSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 returnSwap = new ReturnSwap(item);
             }
         }
     }
     
 
     XmlNodeList brokerEquityOptionNodeList = xmlNode.SelectNodes("brokerEquityOption");
     if (brokerEquityOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in brokerEquityOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 brokerEquityOptionIDRef = item.Attributes["id"].Name;
                 BrokerEquityOption ob = BrokerEquityOption();
                 IDManager.SetID(brokerEquityOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 brokerEquityOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 brokerEquityOption = new BrokerEquityOption(item);
             }
         }
     }
     
 
     XmlNodeList equityForwardNodeList = xmlNode.SelectNodes("equityForward");
     if (equityForwardNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityForwardNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityForwardIDRef = item.Attributes["id"].Name;
                 EquityForward ob = EquityForward();
                 IDManager.SetID(equityForwardIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityForwardIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equityForward = new EquityForward(item);
             }
         }
     }
     
 
     XmlNodeList equityOptionNodeList = xmlNode.SelectNodes("equityOption");
     if (equityOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityOptionIDRef = item.Attributes["id"].Name;
                 EquityOption ob = EquityOption();
                 IDManager.SetID(equityOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equityOption = new EquityOption(item);
             }
         }
     }
     
 
     XmlNodeList equityOptionTransactionSupplementNodeList = xmlNode.SelectNodes("equityOptionTransactionSupplement");
     if (equityOptionTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityOptionTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityOptionTransactionSupplementIDRef = item.Attributes["id"].Name;
                 EquityOptionTransactionSupplement ob = EquityOptionTransactionSupplement();
                 IDManager.SetID(equityOptionTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityOptionTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equityOptionTransactionSupplement = new EquityOptionTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList fxSingleLegNodeList = xmlNode.SelectNodes("fxSingleLeg");
     if (fxSingleLegNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxSingleLegNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxSingleLegIDRef = item.Attributes["id"].Name;
                 FxSingleLeg ob = FxSingleLeg();
                 IDManager.SetID(fxSingleLegIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxSingleLegIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxSingleLeg = new FxSingleLeg(item);
             }
         }
     }
     
 
     XmlNodeList fxSwapNodeList = xmlNode.SelectNodes("fxSwap");
     if (fxSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxSwapIDRef = item.Attributes["id"].Name;
                 FxSwap ob = FxSwap();
                 IDManager.SetID(fxSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxSwap = new FxSwap(item);
             }
         }
     }
     
 
     XmlNodeList fxOptionNodeList = xmlNode.SelectNodes("fxOption");
     if (fxOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxOptionIDRef = item.Attributes["id"].Name;
                 FxOption ob = FxOption();
                 IDManager.SetID(fxOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxOption = new FxOption(item);
             }
         }
     }
     
 
     XmlNodeList fxDigitalOptionNodeList = xmlNode.SelectNodes("fxDigitalOption");
     if (fxDigitalOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxDigitalOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxDigitalOptionIDRef = item.Attributes["id"].Name;
                 FxDigitalOption ob = FxDigitalOption();
                 IDManager.SetID(fxDigitalOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxDigitalOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxDigitalOption = new FxDigitalOption(item);
             }
         }
     }
     
 
     XmlNodeList termDepositNodeList = xmlNode.SelectNodes("termDeposit");
     if (termDepositNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in termDepositNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 termDepositIDRef = item.Attributes["id"].Name;
                 TermDeposit ob = TermDeposit();
                 IDManager.SetID(termDepositIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 termDepositIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 termDeposit = new TermDeposit(item);
             }
         }
     }
     
 
     XmlNodeList genericProductNodeList = xmlNode.SelectNodes("genericProduct");
     if (genericProductNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in genericProductNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 genericProductIDRef = item.Attributes["id"].Name;
                 GenericProduct ob = GenericProduct();
                 IDManager.SetID(genericProductIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 genericProductIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 genericProduct = new GenericProduct(item);
             }
         }
     }
     
 
     XmlNodeList nonSchemaProductNodeList = xmlNode.SelectNodes("nonSchemaProduct");
     if (nonSchemaProductNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in nonSchemaProductNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 nonSchemaProductIDRef = item.Attributes["id"].Name;
                 GenericProduct ob = GenericProduct();
                 IDManager.SetID(nonSchemaProductIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 nonSchemaProductIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 nonSchemaProduct = new GenericProduct(item);
             }
         }
     }
     
 
     XmlNodeList bulletPaymentNodeList = xmlNode.SelectNodes("bulletPayment");
     if (bulletPaymentNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in bulletPaymentNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 bulletPaymentIDRef = item.Attributes["id"].Name;
                 BulletPayment ob = BulletPayment();
                 IDManager.SetID(bulletPaymentIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 bulletPaymentIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 bulletPayment = new BulletPayment(item);
             }
         }
     }
     
 
     XmlNodeList capFloorNodeList = xmlNode.SelectNodes("capFloor");
     if (capFloorNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in capFloorNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 capFloorIDRef = item.Attributes["id"].Name;
                 CapFloor ob = CapFloor();
                 IDManager.SetID(capFloorIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 capFloorIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 capFloor = new CapFloor(item);
             }
         }
     }
     
 
     XmlNodeList fraNodeList = xmlNode.SelectNodes("fra");
     if (fraNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fraNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fraIDRef = item.Attributes["id"].Name;
                 Fra ob = Fra();
                 IDManager.SetID(fraIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fraIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fra = new Fra(item);
             }
         }
     }
     
 
     XmlNodeList swapNodeList = xmlNode.SelectNodes("swap");
     if (swapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in swapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 swapIDRef = item.Attributes["id"].Name;
                 Swap ob = Swap();
                 IDManager.SetID(swapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 swapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 swap = new Swap(item);
             }
         }
     }
     
 
     XmlNodeList swaptionNodeList = xmlNode.SelectNodes("swaption");
     if (swaptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in swaptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 swaptionIDRef = item.Attributes["id"].Name;
                 Swaption ob = Swaption();
                 IDManager.SetID(swaptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 swaptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 swaption = new Swaption(item);
             }
         }
     }
     
 
     XmlNodeList equitySwapTransactionSupplementNodeList = xmlNode.SelectNodes("equitySwapTransactionSupplement");
     if (equitySwapTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equitySwapTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equitySwapTransactionSupplementIDRef = item.Attributes["id"].Name;
                 EquitySwapTransactionSupplement ob = EquitySwapTransactionSupplement();
                 IDManager.SetID(equitySwapTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equitySwapTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equitySwapTransactionSupplement = new EquitySwapTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList standardProductNodeList = xmlNode.SelectNodes("standardProduct");
     if (standardProductNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in standardProductNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 standardProductIDRef = item.Attributes["id"].Name;
                 StandardProduct ob = StandardProduct();
                 IDManager.SetID(standardProductIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 standardProductIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 standardProduct = new StandardProduct(item);
             }
         }
     }
     
 
     XmlNodeList varianceOptionTransactionSupplementNodeList = xmlNode.SelectNodes("varianceOptionTransactionSupplement");
     if (varianceOptionTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in varianceOptionTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 varianceOptionTransactionSupplementIDRef = item.Attributes["id"].Name;
                 VarianceOptionTransactionSupplement ob = VarianceOptionTransactionSupplement();
                 IDManager.SetID(varianceOptionTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 varianceOptionTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 varianceOptionTransactionSupplement = new VarianceOptionTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList varianceSwapNodeList = xmlNode.SelectNodes("varianceSwap");
     if (varianceSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in varianceSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 varianceSwapIDRef = item.Attributes["id"].Name;
                 VarianceSwap ob = VarianceSwap();
                 IDManager.SetID(varianceSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 varianceSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 varianceSwap = new VarianceSwap(item);
             }
         }
     }
     
 
     XmlNodeList varianceSwapTransactionSupplementNodeList = xmlNode.SelectNodes("varianceSwapTransactionSupplement");
     if (varianceSwapTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in varianceSwapTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 varianceSwapTransactionSupplementIDRef = item.Attributes["id"].Name;
                 VarianceSwapTransactionSupplement ob = VarianceSwapTransactionSupplement();
                 IDManager.SetID(varianceSwapTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 varianceSwapTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 varianceSwapTransactionSupplement = new VarianceSwapTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList otherPartyPaymentNodeList = xmlNode.SelectNodes("otherPartyPayment");
     
     foreach (XmlNode item in otherPartyPaymentNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 otherPartyPaymentIDRef = item.Attributes["id"].Name;
                 List<Payment> ob = new List<Payment>();
                 ob.Add(new Payment(item));
                 IDManager.SetID(otherPartyPaymentIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 otherPartyPaymentIDRef = item.Attributes["href"].Name;
             }
             else
             {
             otherPartyPayment.Add(new Payment(item));
             }
         }
     }
     
 
     XmlNodeList brokerPartyReferenceNodeList = xmlNode.SelectNodes("brokerPartyReference");
     
     foreach (XmlNode item in brokerPartyReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 brokerPartyReferenceIDRef = item.Attributes["id"].Name;
                 List<PartyReference> ob = new List<PartyReference>();
                 ob.Add(new PartyReference(item));
                 IDManager.SetID(brokerPartyReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 brokerPartyReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
             brokerPartyReference.Add(new PartyReference(item));
             }
         }
     }
     
 
     XmlNodeList calculationAgentNodeList = xmlNode.SelectNodes("calculationAgent");
     if (calculationAgentNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in calculationAgentNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 calculationAgentIDRef = item.Attributes["id"].Name;
                 CalculationAgent ob = CalculationAgent();
                 IDManager.SetID(calculationAgentIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 calculationAgentIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 calculationAgent = new CalculationAgent(item);
             }
         }
     }
     
 
     XmlNodeList calculationAgentBusinessCenterNodeList = xmlNode.SelectNodes("calculationAgentBusinessCenter");
     if (calculationAgentBusinessCenterNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in calculationAgentBusinessCenterNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 calculationAgentBusinessCenterIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(calculationAgentBusinessCenterIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 calculationAgentBusinessCenterIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 calculationAgentBusinessCenter = new BusinessCenter(item);
             }
         }
     }
     
 
     XmlNodeList determiningPartyNodeList = xmlNode.SelectNodes("determiningParty");
     
     foreach (XmlNode item in determiningPartyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 determiningPartyIDRef = item.Attributes["id"].Name;
                 List<PartyReference> ob = new List<PartyReference>();
                 ob.Add(new PartyReference(item));
                 IDManager.SetID(determiningPartyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 determiningPartyIDRef = item.Attributes["href"].Name;
             }
             else
             {
             determiningParty.Add(new PartyReference(item));
             }
         }
     }
     
 
     XmlNodeList hedgingPartyNodeList = xmlNode.SelectNodes("hedgingParty");
     
     foreach (XmlNode item in hedgingPartyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 hedgingPartyIDRef = item.Attributes["id"].Name;
                 List<PartyReference> ob = new List<PartyReference>();
                 ob.Add(new PartyReference(item));
                 IDManager.SetID(hedgingPartyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 hedgingPartyIDRef = item.Attributes["href"].Name;
             }
             else
             {
             hedgingParty.Add(new PartyReference(item));
             }
         }
     }
     
 
     XmlNodeList collateralNodeList = xmlNode.SelectNodes("collateral");
     if (collateralNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in collateralNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 collateralIDRef = item.Attributes["id"].Name;
                 Collateral ob = Collateral();
                 IDManager.SetID(collateralIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 collateralIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 collateral = new Collateral(item);
             }
         }
     }
     
 
     XmlNodeList documentationNodeList = xmlNode.SelectNodes("documentation");
     if (documentationNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in documentationNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 documentationIDRef = item.Attributes["id"].Name;
                 Documentation ob = Documentation();
                 IDManager.SetID(documentationIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 documentationIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 documentation = new Documentation(item);
             }
         }
     }
     
 
     XmlNodeList governingLawNodeList = xmlNode.SelectNodes("governingLaw");
     if (governingLawNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in governingLawNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 governingLawIDRef = item.Attributes["id"].Name;
                 GoverningLaw ob = GoverningLaw();
                 IDManager.SetID(governingLawIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 governingLawIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 governingLaw = new GoverningLaw(item);
             }
         }
     }
     
 
     XmlNodeList allocationsNodeList = xmlNode.SelectNodes("allocations");
     if (allocationsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in allocationsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 allocationsIDRef = item.Attributes["id"].Name;
                 Allocations ob = Allocations();
                 IDManager.SetID(allocationsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 allocationsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 allocations = new Allocations(item);
             }
         }
     }
     
 
 }
示例#15
0
        public ExerciseNotice(XmlNode xmlNode)
        {
            XmlNodeList partyReferenceNodeList = xmlNode.SelectNodes("partyReference");

            if (partyReferenceNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in partyReferenceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        partyReferenceIDRef = item.Attributes["id"].Name;
                        PartyReference ob = PartyReference();
                        IDManager.SetID(partyReferenceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        partyReferenceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        partyReference = new PartyReference(item);
                    }
                }
            }


            XmlNodeList exerciseNoticePartyReferenceNodeList = xmlNode.SelectNodes("exerciseNoticePartyReference");

            if (exerciseNoticePartyReferenceNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in exerciseNoticePartyReferenceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        exerciseNoticePartyReferenceIDRef = item.Attributes["id"].Name;
                        PartyReference ob = PartyReference();
                        IDManager.SetID(exerciseNoticePartyReferenceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        exerciseNoticePartyReferenceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        exerciseNoticePartyReference = new PartyReference(item);
                    }
                }
            }


            XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");

            if (businessCenterNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in businessCenterNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        businessCenterIDRef = item.Attributes["id"].Name;
                        BusinessCenter ob = BusinessCenter();
                        IDManager.SetID(businessCenterIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        businessCenterIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        businessCenter = new BusinessCenter(item);
                    }
                }
            }
        }
 public PricingStructurePoint(XmlNode xmlNode)
 {
     XmlNodeList coordinateNodeList = xmlNode.SelectNodes("coordinate");
     if (coordinateNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in coordinateNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 coordinateIDRef = item.Attributes["id"].Name;
                 PricingDataPointCoordinate ob = PricingDataPointCoordinate();
                 IDManager.SetID(coordinateIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 coordinateIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 coordinate = new PricingDataPointCoordinate(item);
             }
         }
     }
     
 
     XmlNodeList coordinateReferenceNodeList = xmlNode.SelectNodes("coordinateReference");
     if (coordinateReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in coordinateReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 coordinateReferenceIDRef = item.Attributes["id"].Name;
                 PricingDataPointCoordinateReference ob = PricingDataPointCoordinateReference();
                 IDManager.SetID(coordinateReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 coordinateReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 coordinateReference = new PricingDataPointCoordinateReference(item);
             }
         }
     }
     
 
     XmlNodeList underlyingAssetNodeList = xmlNode.SelectNodes("underlyingAsset");
     if (underlyingAssetNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in underlyingAssetNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 underlyingAssetIDRef = item.Attributes["id"].Name;
                 Asset ob = Asset();
                 IDManager.SetID(underlyingAssetIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 underlyingAssetIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 underlyingAsset = new Asset(item);
             }
         }
     }
     
 
     XmlNodeList basketNodeList = xmlNode.SelectNodes("basket");
     if (basketNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in basketNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 basketIDRef = item.Attributes["id"].Name;
                 Basket ob = Basket();
                 IDManager.SetID(basketIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 basketIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 basket = new Basket(item);
             }
         }
     }
     
 
     XmlNodeList bondNodeList = xmlNode.SelectNodes("bond");
     if (bondNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in bondNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 bondIDRef = item.Attributes["id"].Name;
                 Bond ob = Bond();
                 IDManager.SetID(bondIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 bondIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 bond = new Bond(item);
             }
         }
     }
     
 
     XmlNodeList cashNodeList = xmlNode.SelectNodes("cash");
     if (cashNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in cashNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 cashIDRef = item.Attributes["id"].Name;
                 Cash ob = Cash();
                 IDManager.SetID(cashIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 cashIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 cash = new Cash(item);
             }
         }
     }
     
 
     XmlNodeList commodityNodeList = xmlNode.SelectNodes("commodity");
     if (commodityNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityIDRef = item.Attributes["id"].Name;
                 Commodity ob = Commodity();
                 IDManager.SetID(commodityIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodity = new Commodity(item);
             }
         }
     }
     
 
     XmlNodeList convertibleBondNodeList = xmlNode.SelectNodes("convertibleBond");
     if (convertibleBondNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in convertibleBondNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 convertibleBondIDRef = item.Attributes["id"].Name;
                 ConvertibleBond ob = ConvertibleBond();
                 IDManager.SetID(convertibleBondIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 convertibleBondIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 convertibleBond = new ConvertibleBond(item);
             }
         }
     }
     
 
     XmlNodeList equityNodeList = xmlNode.SelectNodes("equity");
     if (equityNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityIDRef = item.Attributes["id"].Name;
                 EquityAsset ob = EquityAsset();
                 IDManager.SetID(equityIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equity = new EquityAsset(item);
             }
         }
     }
     
 
     XmlNodeList exchangeTradedFundNodeList = xmlNode.SelectNodes("exchangeTradedFund");
     if (exchangeTradedFundNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in exchangeTradedFundNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 exchangeTradedFundIDRef = item.Attributes["id"].Name;
                 ExchangeTradedFund ob = ExchangeTradedFund();
                 IDManager.SetID(exchangeTradedFundIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 exchangeTradedFundIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 exchangeTradedFund = new ExchangeTradedFund(item);
             }
         }
     }
     
 
     XmlNodeList futureNodeList = xmlNode.SelectNodes("future");
     if (futureNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in futureNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 futureIDRef = item.Attributes["id"].Name;
                 Future ob = Future();
                 IDManager.SetID(futureIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 futureIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 future = new Future(item);
             }
         }
     }
     
 
     XmlNodeList indexNodeList = xmlNode.SelectNodes("index");
     if (indexNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in indexNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 indexIDRef = item.Attributes["id"].Name;
                 Index ob = Index();
                 IDManager.SetID(indexIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 indexIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 index = new Index(item);
             }
         }
     }
     
 
     XmlNodeList loanNodeList = xmlNode.SelectNodes("loan");
     if (loanNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in loanNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 loanIDRef = item.Attributes["id"].Name;
                 Loan ob = Loan();
                 IDManager.SetID(loanIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 loanIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 loan = new Loan(item);
             }
         }
     }
     
 
     XmlNodeList mortgageNodeList = xmlNode.SelectNodes("mortgage");
     if (mortgageNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in mortgageNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 mortgageIDRef = item.Attributes["id"].Name;
                 Mortgage ob = Mortgage();
                 IDManager.SetID(mortgageIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 mortgageIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 mortgage = new Mortgage(item);
             }
         }
     }
     
 
     XmlNodeList mutualFundNodeList = xmlNode.SelectNodes("mutualFund");
     if (mutualFundNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in mutualFundNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 mutualFundIDRef = item.Attributes["id"].Name;
                 MutualFund ob = MutualFund();
                 IDManager.SetID(mutualFundIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 mutualFundIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 mutualFund = new MutualFund(item);
             }
         }
     }
     
 
     XmlNodeList underlyingAssetReferenceNodeList = xmlNode.SelectNodes("underlyingAssetReference");
     if (underlyingAssetReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in underlyingAssetReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 underlyingAssetReferenceIDRef = item.Attributes["id"].Name;
                 AssetReference ob = AssetReference();
                 IDManager.SetID(underlyingAssetReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 underlyingAssetReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 underlyingAssetReference = new AssetReference(item);
             }
         }
     }
     
 
     XmlNodeList valueNodeList = xmlNode.SelectNodes("value");
     if (valueNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in valueNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 valueIDRef = item.Attributes["id"].Name;
                 XsdTypeDecimal ob = XsdTypeDecimal();
                 IDManager.SetID(valueIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 valueIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 value = new XsdTypeDecimal(item);
             }
         }
     }
     
 
     XmlNodeList measureTypeNodeList = xmlNode.SelectNodes("measureType");
     if (measureTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in measureTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 measureTypeIDRef = item.Attributes["id"].Name;
                 AssetMeasureType ob = AssetMeasureType();
                 IDManager.SetID(measureTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 measureTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 measureType = new AssetMeasureType(item);
             }
         }
     }
     
 
     XmlNodeList quoteUnitsNodeList = xmlNode.SelectNodes("quoteUnits");
     if (quoteUnitsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in quoteUnitsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 quoteUnitsIDRef = item.Attributes["id"].Name;
                 PriceQuoteUnits ob = PriceQuoteUnits();
                 IDManager.SetID(quoteUnitsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 quoteUnitsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 quoteUnits = new PriceQuoteUnits(item);
             }
         }
     }
     
 
     XmlNodeList sideNodeList = xmlNode.SelectNodes("side");
     if (sideNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in sideNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 sideIDRef = item.Attributes["id"].Name;
                 QuotationSideEnum ob = QuotationSideEnum();
                 IDManager.SetID(sideIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 sideIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 side = new QuotationSideEnum(item);
             }
         }
     }
     
 
     XmlNodeList currencyNodeList = xmlNode.SelectNodes("currency");
     if (currencyNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in currencyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 currencyIDRef = item.Attributes["id"].Name;
                 Currency ob = Currency();
                 IDManager.SetID(currencyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 currencyIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 currency = new Currency(item);
             }
         }
     }
     
 
     XmlNodeList currencyTypeNodeList = xmlNode.SelectNodes("currencyType");
     if (currencyTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in currencyTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 currencyTypeIDRef = item.Attributes["id"].Name;
                 ReportingCurrencyType ob = ReportingCurrencyType();
                 IDManager.SetID(currencyTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 currencyTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 currencyType = new ReportingCurrencyType(item);
             }
         }
     }
     
 
     XmlNodeList timingNodeList = xmlNode.SelectNodes("timing");
     if (timingNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in timingNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 timingIDRef = item.Attributes["id"].Name;
                 QuoteTiming ob = QuoteTiming();
                 IDManager.SetID(timingIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 timingIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 timing = new QuoteTiming(item);
             }
         }
     }
     
 
     XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");
     if (businessCenterNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in businessCenterNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 businessCenterIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(businessCenterIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 businessCenterIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 businessCenter = new BusinessCenter(item);
             }
         }
     }
     
 
     XmlNodeList exchangeIdNodeList = xmlNode.SelectNodes("exchangeId");
     if (exchangeIdNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in exchangeIdNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 exchangeIdIDRef = item.Attributes["id"].Name;
                 ExchangeId ob = ExchangeId();
                 IDManager.SetID(exchangeIdIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 exchangeIdIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 exchangeId = new ExchangeId(item);
             }
         }
     }
     
 
     XmlNodeList informationSourceNodeList = xmlNode.SelectNodes("informationSource");
     
     foreach (XmlNode item in informationSourceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 informationSourceIDRef = item.Attributes["id"].Name;
                 List<InformationSource> ob = new List<InformationSource>();
                 ob.Add(new InformationSource(item));
                 IDManager.SetID(informationSourceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 informationSourceIDRef = item.Attributes["href"].Name;
             }
             else
             {
             informationSource.Add(new InformationSource(item));
             }
         }
     }
     
 
     XmlNodeList pricingModelNodeList = xmlNode.SelectNodes("pricingModel");
     if (pricingModelNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in pricingModelNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 pricingModelIDRef = item.Attributes["id"].Name;
                 PricingModel ob = PricingModel();
                 IDManager.SetID(pricingModelIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 pricingModelIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 pricingModel = new PricingModel(item);
             }
         }
     }
     
 
     XmlNodeList timeNodeList = xmlNode.SelectNodes("time");
     if (timeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in timeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 timeIDRef = item.Attributes["id"].Name;
                 XsdTypeDateTime ob = XsdTypeDateTime();
                 IDManager.SetID(timeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 timeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 time = new XsdTypeDateTime(item);
             }
         }
     }
     
 
     XmlNodeList valuationDateNodeList = xmlNode.SelectNodes("valuationDate");
     if (valuationDateNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in valuationDateNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 valuationDateIDRef = item.Attributes["id"].Name;
                 XsdTypeDate ob = XsdTypeDate();
                 IDManager.SetID(valuationDateIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 valuationDateIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 valuationDate = new XsdTypeDate(item);
             }
         }
     }
     
 
     XmlNodeList expiryTimeNodeList = xmlNode.SelectNodes("expiryTime");
     if (expiryTimeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in expiryTimeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 expiryTimeIDRef = item.Attributes["id"].Name;
                 XsdTypeDateTime ob = XsdTypeDateTime();
                 IDManager.SetID(expiryTimeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 expiryTimeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 expiryTime = new XsdTypeDateTime(item);
             }
         }
     }
     
 
     XmlNodeList cashflowTypeNodeList = xmlNode.SelectNodes("cashflowType");
     if (cashflowTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in cashflowTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 cashflowTypeIDRef = item.Attributes["id"].Name;
                 CashflowType ob = CashflowType();
                 IDManager.SetID(cashflowTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 cashflowTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 cashflowType = new CashflowType(item);
             }
         }
     }
     
 
 }
 public WeatherLegCalculation(XmlNode xmlNode)
 {
     XmlNode settlementLevelNode = xmlNode.SelectSingleNode("settlementLevel");
     
     if (settlementLevelNode != null)
     {
         if (settlementLevelNode.Attributes["href"] != null || settlementLevelNode.Attributes["id"] != null) 
         {
             if (settlementLevelNode.Attributes["id"] != null) 
             {
                 settlementLevelIDRef_ = settlementLevelNode.Attributes["id"].Value;
                 WeatherSettlementLevelEnum ob = new WeatherSettlementLevelEnum(settlementLevelNode);
                 IDManager.SetID(settlementLevelIDRef_, ob);
             }
             else if (settlementLevelNode.Attributes["href"] != null)
             {
                 settlementLevelIDRef_ = settlementLevelNode.Attributes["href"].Value;
             }
             else
             {
                 settlementLevel_ = new WeatherSettlementLevelEnum(settlementLevelNode);
             }
         }
         else
         {
             settlementLevel_ = new WeatherSettlementLevelEnum(settlementLevelNode);
         }
     }
     
 
     XmlNode referenceLevelEqualsZeroNode = xmlNode.SelectSingleNode("referenceLevelEqualsZero");
     
     if (referenceLevelEqualsZeroNode != null)
     {
         if (referenceLevelEqualsZeroNode.Attributes["href"] != null || referenceLevelEqualsZeroNode.Attributes["id"] != null) 
         {
             if (referenceLevelEqualsZeroNode.Attributes["id"] != null) 
             {
                 referenceLevelEqualsZeroIDRef_ = referenceLevelEqualsZeroNode.Attributes["id"].Value;
                 XsdTypeBoolean ob = new XsdTypeBoolean(referenceLevelEqualsZeroNode);
                 IDManager.SetID(referenceLevelEqualsZeroIDRef_, ob);
             }
             else if (referenceLevelEqualsZeroNode.Attributes["href"] != null)
             {
                 referenceLevelEqualsZeroIDRef_ = referenceLevelEqualsZeroNode.Attributes["href"].Value;
             }
             else
             {
                 referenceLevelEqualsZero_ = new XsdTypeBoolean(referenceLevelEqualsZeroNode);
             }
         }
         else
         {
             referenceLevelEqualsZero_ = new XsdTypeBoolean(referenceLevelEqualsZeroNode);
         }
     }
     
 
     XmlNode calculationDateNode = xmlNode.SelectSingleNode("calculationDate");
     
     if (calculationDateNode != null)
     {
         if (calculationDateNode.Attributes["href"] != null || calculationDateNode.Attributes["id"] != null) 
         {
             if (calculationDateNode.Attributes["id"] != null) 
             {
                 calculationDateIDRef_ = calculationDateNode.Attributes["id"].Value;
                 Period ob = new Period(calculationDateNode);
                 IDManager.SetID(calculationDateIDRef_, ob);
             }
             else if (calculationDateNode.Attributes["href"] != null)
             {
                 calculationDateIDRef_ = calculationDateNode.Attributes["href"].Value;
             }
             else
             {
                 calculationDate_ = new Period(calculationDateNode);
             }
         }
         else
         {
             calculationDate_ = new Period(calculationDateNode);
         }
     }
     
 
     XmlNode businessDaysNode = xmlNode.SelectSingleNode("businessDays");
     
     if (businessDaysNode != null)
     {
         if (businessDaysNode.Attributes["href"] != null || businessDaysNode.Attributes["id"] != null) 
         {
             if (businessDaysNode.Attributes["id"] != null) 
             {
                 businessDaysIDRef_ = businessDaysNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(businessDaysNode);
                 IDManager.SetID(businessDaysIDRef_, ob);
             }
             else if (businessDaysNode.Attributes["href"] != null)
             {
                 businessDaysIDRef_ = businessDaysNode.Attributes["href"].Value;
             }
             else
             {
                 businessDays_ = new BusinessCenter(businessDaysNode);
             }
         }
         else
         {
             businessDays_ = new BusinessCenter(businessDaysNode);
         }
     }
     
 
     XmlNode dataCorrectionNode = xmlNode.SelectSingleNode("dataCorrection");
     
     if (dataCorrectionNode != null)
     {
         if (dataCorrectionNode.Attributes["href"] != null || dataCorrectionNode.Attributes["id"] != null) 
         {
             if (dataCorrectionNode.Attributes["id"] != null) 
             {
                 dataCorrectionIDRef_ = dataCorrectionNode.Attributes["id"].Value;
                 XsdTypeBoolean ob = new XsdTypeBoolean(dataCorrectionNode);
                 IDManager.SetID(dataCorrectionIDRef_, ob);
             }
             else if (dataCorrectionNode.Attributes["href"] != null)
             {
                 dataCorrectionIDRef_ = dataCorrectionNode.Attributes["href"].Value;
             }
             else
             {
                 dataCorrection_ = new XsdTypeBoolean(dataCorrectionNode);
             }
         }
         else
         {
             dataCorrection_ = new XsdTypeBoolean(dataCorrectionNode);
         }
     }
     
 
     XmlNode correctionPeriodNode = xmlNode.SelectSingleNode("correctionPeriod");
     
     if (correctionPeriodNode != null)
     {
         if (correctionPeriodNode.Attributes["href"] != null || correctionPeriodNode.Attributes["id"] != null) 
         {
             if (correctionPeriodNode.Attributes["id"] != null) 
             {
                 correctionPeriodIDRef_ = correctionPeriodNode.Attributes["id"].Value;
                 Period ob = new Period(correctionPeriodNode);
                 IDManager.SetID(correctionPeriodIDRef_, ob);
             }
             else if (correctionPeriodNode.Attributes["href"] != null)
             {
                 correctionPeriodIDRef_ = correctionPeriodNode.Attributes["href"].Value;
             }
             else
             {
                 correctionPeriod_ = new Period(correctionPeriodNode);
             }
         }
         else
         {
             correctionPeriod_ = new Period(correctionPeriodNode);
         }
     }
     
 
     XmlNode maximumPaymentAmountNode = xmlNode.SelectSingleNode("maximumPaymentAmount");
     
     if (maximumPaymentAmountNode != null)
     {
         if (maximumPaymentAmountNode.Attributes["href"] != null || maximumPaymentAmountNode.Attributes["id"] != null) 
         {
             if (maximumPaymentAmountNode.Attributes["id"] != null) 
             {
                 maximumPaymentAmountIDRef_ = maximumPaymentAmountNode.Attributes["id"].Value;
                 NonNegativeMoney ob = new NonNegativeMoney(maximumPaymentAmountNode);
                 IDManager.SetID(maximumPaymentAmountIDRef_, ob);
             }
             else if (maximumPaymentAmountNode.Attributes["href"] != null)
             {
                 maximumPaymentAmountIDRef_ = maximumPaymentAmountNode.Attributes["href"].Value;
             }
             else
             {
                 maximumPaymentAmount_ = new NonNegativeMoney(maximumPaymentAmountNode);
             }
         }
         else
         {
             maximumPaymentAmount_ = new NonNegativeMoney(maximumPaymentAmountNode);
         }
     }
     
 
     XmlNode maximumTransactionPaymentAmountNode = xmlNode.SelectSingleNode("maximumTransactionPaymentAmount");
     
     if (maximumTransactionPaymentAmountNode != null)
     {
         if (maximumTransactionPaymentAmountNode.Attributes["href"] != null || maximumTransactionPaymentAmountNode.Attributes["id"] != null) 
         {
             if (maximumTransactionPaymentAmountNode.Attributes["id"] != null) 
             {
                 maximumTransactionPaymentAmountIDRef_ = maximumTransactionPaymentAmountNode.Attributes["id"].Value;
                 NonNegativeMoney ob = new NonNegativeMoney(maximumTransactionPaymentAmountNode);
                 IDManager.SetID(maximumTransactionPaymentAmountIDRef_, ob);
             }
             else if (maximumTransactionPaymentAmountNode.Attributes["href"] != null)
             {
                 maximumTransactionPaymentAmountIDRef_ = maximumTransactionPaymentAmountNode.Attributes["href"].Value;
             }
             else
             {
                 maximumTransactionPaymentAmount_ = new NonNegativeMoney(maximumTransactionPaymentAmountNode);
             }
         }
         else
         {
             maximumTransactionPaymentAmount_ = new NonNegativeMoney(maximumTransactionPaymentAmountNode);
         }
     }
     
 
     XmlNode roundingNode = xmlNode.SelectSingleNode("rounding");
     
     if (roundingNode != null)
     {
         if (roundingNode.Attributes["href"] != null || roundingNode.Attributes["id"] != null) 
         {
             if (roundingNode.Attributes["id"] != null) 
             {
                 roundingIDRef_ = roundingNode.Attributes["id"].Value;
                 Rounding ob = new Rounding(roundingNode);
                 IDManager.SetID(roundingIDRef_, ob);
             }
             else if (roundingNode.Attributes["href"] != null)
             {
                 roundingIDRef_ = roundingNode.Attributes["href"].Value;
             }
             else
             {
                 rounding_ = new Rounding(roundingNode);
             }
         }
         else
         {
             rounding_ = new Rounding(roundingNode);
         }
     }
     
 
 }
        public CreditEventNotice(XmlNode xmlNode)
        {
            XmlNodeList notifyingPartyNodeList = xmlNode.SelectNodes("notifyingParty");

            if (notifyingPartyNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in notifyingPartyNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        notifyingPartyIDRef = item.Attributes["id"].Name;
                        NotifyingParty ob = NotifyingParty();
                        IDManager.SetID(notifyingPartyIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        notifyingPartyIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        notifyingParty = new NotifyingParty(item);
                    }
                }
            }


            XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");

            if (businessCenterNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in businessCenterNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        businessCenterIDRef = item.Attributes["id"].Name;
                        BusinessCenter ob = BusinessCenter();
                        IDManager.SetID(businessCenterIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        businessCenterIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        businessCenter = new BusinessCenter(item);
                    }
                }
            }


            XmlNodeList publiclyAvailableInformationNodeList = xmlNode.SelectNodes("publiclyAvailableInformation");

            if (publiclyAvailableInformationNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in publiclyAvailableInformationNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        publiclyAvailableInformationIDRef = item.Attributes["id"].Name;
                        PubliclyAvailableInformation ob = PubliclyAvailableInformation();
                        IDManager.SetID(publiclyAvailableInformationIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        publiclyAvailableInformationIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        publiclyAvailableInformation = new PubliclyAvailableInformation(item);
                    }
                }
            }
        }
示例#19
0
        public MultiDimensionalPricingData(XmlNode xmlNode)
        {
            XmlNode measureTypeNode = xmlNode.SelectSingleNode("measureType");

            if (measureTypeNode != null)
            {
                if (measureTypeNode.Attributes["href"] != null || measureTypeNode.Attributes["id"] != null)
                {
                    if (measureTypeNode.Attributes["id"] != null)
                    {
                        measureTypeIDRef_ = measureTypeNode.Attributes["id"].Value;
                        AssetMeasureType ob = new AssetMeasureType(measureTypeNode);
                        IDManager.SetID(measureTypeIDRef_, ob);
                    }
                    else if (measureTypeNode.Attributes["href"] != null)
                    {
                        measureTypeIDRef_ = measureTypeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        measureType_ = new AssetMeasureType(measureTypeNode);
                    }
                }
                else
                {
                    measureType_ = new AssetMeasureType(measureTypeNode);
                }
            }


            XmlNode quoteUnitsNode = xmlNode.SelectSingleNode("quoteUnits");

            if (quoteUnitsNode != null)
            {
                if (quoteUnitsNode.Attributes["href"] != null || quoteUnitsNode.Attributes["id"] != null)
                {
                    if (quoteUnitsNode.Attributes["id"] != null)
                    {
                        quoteUnitsIDRef_ = quoteUnitsNode.Attributes["id"].Value;
                        PriceQuoteUnits ob = new PriceQuoteUnits(quoteUnitsNode);
                        IDManager.SetID(quoteUnitsIDRef_, ob);
                    }
                    else if (quoteUnitsNode.Attributes["href"] != null)
                    {
                        quoteUnitsIDRef_ = quoteUnitsNode.Attributes["href"].Value;
                    }
                    else
                    {
                        quoteUnits_ = new PriceQuoteUnits(quoteUnitsNode);
                    }
                }
                else
                {
                    quoteUnits_ = new PriceQuoteUnits(quoteUnitsNode);
                }
            }


            XmlNode sideNode = xmlNode.SelectSingleNode("side");

            if (sideNode != null)
            {
                if (sideNode.Attributes["href"] != null || sideNode.Attributes["id"] != null)
                {
                    if (sideNode.Attributes["id"] != null)
                    {
                        sideIDRef_ = sideNode.Attributes["id"].Value;
                        QuotationSideEnum ob = new QuotationSideEnum(sideNode);
                        IDManager.SetID(sideIDRef_, ob);
                    }
                    else if (sideNode.Attributes["href"] != null)
                    {
                        sideIDRef_ = sideNode.Attributes["href"].Value;
                    }
                    else
                    {
                        side_ = new QuotationSideEnum(sideNode);
                    }
                }
                else
                {
                    side_ = new QuotationSideEnum(sideNode);
                }
            }


            XmlNode currencyNode = xmlNode.SelectSingleNode("currency");

            if (currencyNode != null)
            {
                if (currencyNode.Attributes["href"] != null || currencyNode.Attributes["id"] != null)
                {
                    if (currencyNode.Attributes["id"] != null)
                    {
                        currencyIDRef_ = currencyNode.Attributes["id"].Value;
                        Currency ob = new Currency(currencyNode);
                        IDManager.SetID(currencyIDRef_, ob);
                    }
                    else if (currencyNode.Attributes["href"] != null)
                    {
                        currencyIDRef_ = currencyNode.Attributes["href"].Value;
                    }
                    else
                    {
                        currency_ = new Currency(currencyNode);
                    }
                }
                else
                {
                    currency_ = new Currency(currencyNode);
                }
            }


            XmlNode currencyTypeNode = xmlNode.SelectSingleNode("currencyType");

            if (currencyTypeNode != null)
            {
                if (currencyTypeNode.Attributes["href"] != null || currencyTypeNode.Attributes["id"] != null)
                {
                    if (currencyTypeNode.Attributes["id"] != null)
                    {
                        currencyTypeIDRef_ = currencyTypeNode.Attributes["id"].Value;
                        ReportingCurrencyType ob = new ReportingCurrencyType(currencyTypeNode);
                        IDManager.SetID(currencyTypeIDRef_, ob);
                    }
                    else if (currencyTypeNode.Attributes["href"] != null)
                    {
                        currencyTypeIDRef_ = currencyTypeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        currencyType_ = new ReportingCurrencyType(currencyTypeNode);
                    }
                }
                else
                {
                    currencyType_ = new ReportingCurrencyType(currencyTypeNode);
                }
            }


            XmlNode timingNode = xmlNode.SelectSingleNode("timing");

            if (timingNode != null)
            {
                if (timingNode.Attributes["href"] != null || timingNode.Attributes["id"] != null)
                {
                    if (timingNode.Attributes["id"] != null)
                    {
                        timingIDRef_ = timingNode.Attributes["id"].Value;
                        QuoteTiming ob = new QuoteTiming(timingNode);
                        IDManager.SetID(timingIDRef_, ob);
                    }
                    else if (timingNode.Attributes["href"] != null)
                    {
                        timingIDRef_ = timingNode.Attributes["href"].Value;
                    }
                    else
                    {
                        timing_ = new QuoteTiming(timingNode);
                    }
                }
                else
                {
                    timing_ = new QuoteTiming(timingNode);
                }
            }


            XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");

            if (businessCenterNode != null)
            {
                if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null)
                {
                    if (businessCenterNode.Attributes["id"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                        BusinessCenter ob = new BusinessCenter(businessCenterNode);
                        IDManager.SetID(businessCenterIDRef_, ob);
                    }
                    else if (businessCenterNode.Attributes["href"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
                    }
                    else
                    {
                        businessCenter_ = new BusinessCenter(businessCenterNode);
                    }
                }
                else
                {
                    businessCenter_ = new BusinessCenter(businessCenterNode);
                }
            }


            XmlNode exchangeIdNode = xmlNode.SelectSingleNode("exchangeId");

            if (exchangeIdNode != null)
            {
                if (exchangeIdNode.Attributes["href"] != null || exchangeIdNode.Attributes["id"] != null)
                {
                    if (exchangeIdNode.Attributes["id"] != null)
                    {
                        exchangeIdIDRef_ = exchangeIdNode.Attributes["id"].Value;
                        ExchangeId ob = new ExchangeId(exchangeIdNode);
                        IDManager.SetID(exchangeIdIDRef_, ob);
                    }
                    else if (exchangeIdNode.Attributes["href"] != null)
                    {
                        exchangeIdIDRef_ = exchangeIdNode.Attributes["href"].Value;
                    }
                    else
                    {
                        exchangeId_ = new ExchangeId(exchangeIdNode);
                    }
                }
                else
                {
                    exchangeId_ = new ExchangeId(exchangeIdNode);
                }
            }


            XmlNodeList informationSourceNodeList = xmlNode.SelectNodes("informationSource");

            if (informationSourceNodeList != null)
            {
                this.informationSource_ = new List <InformationSource>();
                foreach (XmlNode item in informationSourceNodeList)
                {
                    if (item.Attributes["href"] != null || item.Attributes["id"] != null)
                    {
                        if (item.Attributes["id"] != null)
                        {
                            informationSourceIDRef_ = item.Attributes["id"].Value;
                            informationSource_.Add(new InformationSource(item));
                            IDManager.SetID(informationSourceIDRef_, informationSource_[informationSource_.Count - 1]);
                        }
                        else if (item.Attributes["href"] != null)
                        {
                            informationSourceIDRef_ = item.Attributes["href"].Value;
                        }
                        else
                        {
                            informationSource_.Add(new InformationSource(item));
                        }
                    }
                    else
                    {
                        informationSource_.Add(new InformationSource(item));
                    }
                }
            }


            XmlNode pricingModelNode = xmlNode.SelectSingleNode("pricingModel");

            if (pricingModelNode != null)
            {
                if (pricingModelNode.Attributes["href"] != null || pricingModelNode.Attributes["id"] != null)
                {
                    if (pricingModelNode.Attributes["id"] != null)
                    {
                        pricingModelIDRef_ = pricingModelNode.Attributes["id"].Value;
                        PricingModel ob = new PricingModel(pricingModelNode);
                        IDManager.SetID(pricingModelIDRef_, ob);
                    }
                    else if (pricingModelNode.Attributes["href"] != null)
                    {
                        pricingModelIDRef_ = pricingModelNode.Attributes["href"].Value;
                    }
                    else
                    {
                        pricingModel_ = new PricingModel(pricingModelNode);
                    }
                }
                else
                {
                    pricingModel_ = new PricingModel(pricingModelNode);
                }
            }


            XmlNode timeNode = xmlNode.SelectSingleNode("time");

            if (timeNode != null)
            {
                if (timeNode.Attributes["href"] != null || timeNode.Attributes["id"] != null)
                {
                    if (timeNode.Attributes["id"] != null)
                    {
                        timeIDRef_ = timeNode.Attributes["id"].Value;
                        XsdTypeDateTime ob = new XsdTypeDateTime(timeNode);
                        IDManager.SetID(timeIDRef_, ob);
                    }
                    else if (timeNode.Attributes["href"] != null)
                    {
                        timeIDRef_ = timeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        time_ = new XsdTypeDateTime(timeNode);
                    }
                }
                else
                {
                    time_ = new XsdTypeDateTime(timeNode);
                }
            }


            XmlNode valuationDateNode = xmlNode.SelectSingleNode("valuationDate");

            if (valuationDateNode != null)
            {
                if (valuationDateNode.Attributes["href"] != null || valuationDateNode.Attributes["id"] != null)
                {
                    if (valuationDateNode.Attributes["id"] != null)
                    {
                        valuationDateIDRef_ = valuationDateNode.Attributes["id"].Value;
                        XsdTypeDate ob = new XsdTypeDate(valuationDateNode);
                        IDManager.SetID(valuationDateIDRef_, ob);
                    }
                    else if (valuationDateNode.Attributes["href"] != null)
                    {
                        valuationDateIDRef_ = valuationDateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        valuationDate_ = new XsdTypeDate(valuationDateNode);
                    }
                }
                else
                {
                    valuationDate_ = new XsdTypeDate(valuationDateNode);
                }
            }


            XmlNode expiryTimeNode = xmlNode.SelectSingleNode("expiryTime");

            if (expiryTimeNode != null)
            {
                if (expiryTimeNode.Attributes["href"] != null || expiryTimeNode.Attributes["id"] != null)
                {
                    if (expiryTimeNode.Attributes["id"] != null)
                    {
                        expiryTimeIDRef_ = expiryTimeNode.Attributes["id"].Value;
                        XsdTypeDateTime ob = new XsdTypeDateTime(expiryTimeNode);
                        IDManager.SetID(expiryTimeIDRef_, ob);
                    }
                    else if (expiryTimeNode.Attributes["href"] != null)
                    {
                        expiryTimeIDRef_ = expiryTimeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        expiryTime_ = new XsdTypeDateTime(expiryTimeNode);
                    }
                }
                else
                {
                    expiryTime_ = new XsdTypeDateTime(expiryTimeNode);
                }
            }


            XmlNode cashflowTypeNode = xmlNode.SelectSingleNode("cashflowType");

            if (cashflowTypeNode != null)
            {
                if (cashflowTypeNode.Attributes["href"] != null || cashflowTypeNode.Attributes["id"] != null)
                {
                    if (cashflowTypeNode.Attributes["id"] != null)
                    {
                        cashflowTypeIDRef_ = cashflowTypeNode.Attributes["id"].Value;
                        CashflowType ob = new CashflowType(cashflowTypeNode);
                        IDManager.SetID(cashflowTypeIDRef_, ob);
                    }
                    else if (cashflowTypeNode.Attributes["href"] != null)
                    {
                        cashflowTypeIDRef_ = cashflowTypeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        cashflowType_ = new CashflowType(cashflowTypeNode);
                    }
                }
                else
                {
                    cashflowType_ = new CashflowType(cashflowTypeNode);
                }
            }


            XmlNodeList pointNodeList = xmlNode.SelectNodes("point");

            if (pointNodeList != null)
            {
                this.point_ = new List <PricingStructurePoint>();
                foreach (XmlNode item in pointNodeList)
                {
                    if (item.Attributes["href"] != null || item.Attributes["id"] != null)
                    {
                        if (item.Attributes["id"] != null)
                        {
                            pointIDRef_ = item.Attributes["id"].Value;
                            point_.Add(new PricingStructurePoint(item));
                            IDManager.SetID(pointIDRef_, point_[point_.Count - 1]);
                        }
                        else if (item.Attributes["href"] != null)
                        {
                            pointIDRef_ = item.Attributes["href"].Value;
                        }
                        else
                        {
                            point_.Add(new PricingStructurePoint(item));
                        }
                    }
                    else
                    {
                        point_.Add(new PricingStructurePoint(item));
                    }
                }
            }
        }
 public WeatherStation(XmlNode xmlNode)
 {
     XmlNodeList weatherStationCityNodeList = xmlNode.SelectNodes("weatherStationCity");
     if (weatherStationCityNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in weatherStationCityNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 weatherStationCityIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(weatherStationCityIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 weatherStationCityIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 weatherStationCity = new BusinessCenter(item);
             }
         }
     }
     
 
     XmlNodeList weatherStationAirportNodeList = xmlNode.SelectNodes("weatherStationAirport");
     if (weatherStationAirportNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in weatherStationAirportNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 weatherStationAirportIDRef = item.Attributes["id"].Name;
                 WeatherStationAirport ob = WeatherStationAirport();
                 IDManager.SetID(weatherStationAirportIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 weatherStationAirportIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 weatherStationAirport = new WeatherStationAirport(item);
             }
         }
     }
     
 
     XmlNodeList weatherStationWBANNodeList = xmlNode.SelectNodes("weatherStationWBAN");
     if (weatherStationWBANNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in weatherStationWBANNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 weatherStationWBANIDRef = item.Attributes["id"].Name;
                 WeatherStationWBAN ob = WeatherStationWBAN();
                 IDManager.SetID(weatherStationWBANIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 weatherStationWBANIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 weatherStationWBAN = new WeatherStationWBAN(item);
             }
         }
     }
     
 
     XmlNodeList weatherStationWMONodeList = xmlNode.SelectNodes("weatherStationWMO");
     if (weatherStationWMONodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in weatherStationWMONodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 weatherStationWMOIDRef = item.Attributes["id"].Name;
                 WeatherStationWMO ob = WeatherStationWMO();
                 IDManager.SetID(weatherStationWMOIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 weatherStationWMOIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 weatherStationWMO = new WeatherStationWMO(item);
             }
         }
     }
     
 
 }
        public WeatherStation(XmlNode xmlNode)
        {
            XmlNodeList weatherStationCityNodeList = xmlNode.SelectNodes("weatherStationCity");

            if (weatherStationCityNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in weatherStationCityNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        weatherStationCityIDRef = item.Attributes["id"].Name;
                        BusinessCenter ob = BusinessCenter();
                        IDManager.SetID(weatherStationCityIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        weatherStationCityIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        weatherStationCity = new BusinessCenter(item);
                    }
                }
            }


            XmlNodeList weatherStationAirportNodeList = xmlNode.SelectNodes("weatherStationAirport");

            if (weatherStationAirportNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in weatherStationAirportNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        weatherStationAirportIDRef = item.Attributes["id"].Name;
                        WeatherStationAirport ob = WeatherStationAirport();
                        IDManager.SetID(weatherStationAirportIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        weatherStationAirportIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        weatherStationAirport = new WeatherStationAirport(item);
                    }
                }
            }


            XmlNodeList weatherStationWBANNodeList = xmlNode.SelectNodes("weatherStationWBAN");

            if (weatherStationWBANNodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in weatherStationWBANNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        weatherStationWBANIDRef = item.Attributes["id"].Name;
                        WeatherStationWBAN ob = WeatherStationWBAN();
                        IDManager.SetID(weatherStationWBANIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        weatherStationWBANIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        weatherStationWBAN = new WeatherStationWBAN(item);
                    }
                }
            }


            XmlNodeList weatherStationWMONodeList = xmlNode.SelectNodes("weatherStationWMO");

            if (weatherStationWMONodeList.Count > 1)
            {
                throw new Exception();
            }

            foreach (XmlNode item in weatherStationWMONodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        weatherStationWMOIDRef = item.Attributes["id"].Name;
                        WeatherStationWMO ob = WeatherStationWMO();
                        IDManager.SetID(weatherStationWMOIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        weatherStationWMOIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        weatherStationWMO = new WeatherStationWMO(item);
                    }
                }
            }
        }
 public PricingStructurePoint(XmlNode xmlNode)
 {
     XmlNode coordinateNode = xmlNode.SelectSingleNode("coordinate");
     
     if (coordinateNode != null)
     {
         if (coordinateNode.Attributes["href"] != null || coordinateNode.Attributes["id"] != null) 
         {
             if (coordinateNode.Attributes["id"] != null) 
             {
                 coordinateIDRef_ = coordinateNode.Attributes["id"].Value;
                 PricingDataPointCoordinate ob = new PricingDataPointCoordinate(coordinateNode);
                 IDManager.SetID(coordinateIDRef_, ob);
             }
             else if (coordinateNode.Attributes["href"] != null)
             {
                 coordinateIDRef_ = coordinateNode.Attributes["href"].Value;
             }
             else
             {
                 coordinate_ = new PricingDataPointCoordinate(coordinateNode);
             }
         }
         else
         {
             coordinate_ = new PricingDataPointCoordinate(coordinateNode);
         }
     }
     
 
     XmlNode coordinateReferenceNode = xmlNode.SelectSingleNode("coordinateReference");
     
     if (coordinateReferenceNode != null)
     {
         if (coordinateReferenceNode.Attributes["href"] != null || coordinateReferenceNode.Attributes["id"] != null) 
         {
             if (coordinateReferenceNode.Attributes["id"] != null) 
             {
                 coordinateReferenceIDRef_ = coordinateReferenceNode.Attributes["id"].Value;
                 PricingDataPointCoordinateReference ob = new PricingDataPointCoordinateReference(coordinateReferenceNode);
                 IDManager.SetID(coordinateReferenceIDRef_, ob);
             }
             else if (coordinateReferenceNode.Attributes["href"] != null)
             {
                 coordinateReferenceIDRef_ = coordinateReferenceNode.Attributes["href"].Value;
             }
             else
             {
                 coordinateReference_ = new PricingDataPointCoordinateReference(coordinateReferenceNode);
             }
         }
         else
         {
             coordinateReference_ = new PricingDataPointCoordinateReference(coordinateReferenceNode);
         }
     }
     
 
     XmlNode underlyingAssetNode = xmlNode.SelectSingleNode("underlyingAsset");
     
     if (underlyingAssetNode != null)
     {
         if (underlyingAssetNode.Attributes["href"] != null || underlyingAssetNode.Attributes["id"] != null) 
         {
             if (underlyingAssetNode.Attributes["id"] != null) 
             {
                 underlyingAssetIDRef_ = underlyingAssetNode.Attributes["id"].Value;
                 Asset ob = new Asset(underlyingAssetNode);
                 IDManager.SetID(underlyingAssetIDRef_, ob);
             }
             else if (underlyingAssetNode.Attributes["href"] != null)
             {
                 underlyingAssetIDRef_ = underlyingAssetNode.Attributes["href"].Value;
             }
             else
             {
                 underlyingAsset_ = new Asset(underlyingAssetNode);
             }
         }
         else
         {
             underlyingAsset_ = new Asset(underlyingAssetNode);
         }
     }
     
 
     XmlNode basketNode = xmlNode.SelectSingleNode("basket");
     
     if (basketNode != null)
     {
         if (basketNode.Attributes["href"] != null || basketNode.Attributes["id"] != null) 
         {
             if (basketNode.Attributes["id"] != null) 
             {
                 basketIDRef_ = basketNode.Attributes["id"].Value;
                 Basket ob = new Basket(basketNode);
                 IDManager.SetID(basketIDRef_, ob);
             }
             else if (basketNode.Attributes["href"] != null)
             {
                 basketIDRef_ = basketNode.Attributes["href"].Value;
             }
             else
             {
                 basket_ = new Basket(basketNode);
             }
         }
         else
         {
             basket_ = new Basket(basketNode);
         }
     }
     
 
     XmlNode bondNode = xmlNode.SelectSingleNode("bond");
     
     if (bondNode != null)
     {
         if (bondNode.Attributes["href"] != null || bondNode.Attributes["id"] != null) 
         {
             if (bondNode.Attributes["id"] != null) 
             {
                 bondIDRef_ = bondNode.Attributes["id"].Value;
                 Bond ob = new Bond(bondNode);
                 IDManager.SetID(bondIDRef_, ob);
             }
             else if (bondNode.Attributes["href"] != null)
             {
                 bondIDRef_ = bondNode.Attributes["href"].Value;
             }
             else
             {
                 bond_ = new Bond(bondNode);
             }
         }
         else
         {
             bond_ = new Bond(bondNode);
         }
     }
     
 
     XmlNode cashNode = xmlNode.SelectSingleNode("cash");
     
     if (cashNode != null)
     {
         if (cashNode.Attributes["href"] != null || cashNode.Attributes["id"] != null) 
         {
             if (cashNode.Attributes["id"] != null) 
             {
                 cashIDRef_ = cashNode.Attributes["id"].Value;
                 Cash ob = new Cash(cashNode);
                 IDManager.SetID(cashIDRef_, ob);
             }
             else if (cashNode.Attributes["href"] != null)
             {
                 cashIDRef_ = cashNode.Attributes["href"].Value;
             }
             else
             {
                 cash_ = new Cash(cashNode);
             }
         }
         else
         {
             cash_ = new Cash(cashNode);
         }
     }
     
 
     XmlNode commodityNode = xmlNode.SelectSingleNode("commodity");
     
     if (commodityNode != null)
     {
         if (commodityNode.Attributes["href"] != null || commodityNode.Attributes["id"] != null) 
         {
             if (commodityNode.Attributes["id"] != null) 
             {
                 commodityIDRef_ = commodityNode.Attributes["id"].Value;
                 Commodity ob = new Commodity(commodityNode);
                 IDManager.SetID(commodityIDRef_, ob);
             }
             else if (commodityNode.Attributes["href"] != null)
             {
                 commodityIDRef_ = commodityNode.Attributes["href"].Value;
             }
             else
             {
                 commodity_ = new Commodity(commodityNode);
             }
         }
         else
         {
             commodity_ = new Commodity(commodityNode);
         }
     }
     
 
     XmlNode convertibleBondNode = xmlNode.SelectSingleNode("convertibleBond");
     
     if (convertibleBondNode != null)
     {
         if (convertibleBondNode.Attributes["href"] != null || convertibleBondNode.Attributes["id"] != null) 
         {
             if (convertibleBondNode.Attributes["id"] != null) 
             {
                 convertibleBondIDRef_ = convertibleBondNode.Attributes["id"].Value;
                 ConvertibleBond ob = new ConvertibleBond(convertibleBondNode);
                 IDManager.SetID(convertibleBondIDRef_, ob);
             }
             else if (convertibleBondNode.Attributes["href"] != null)
             {
                 convertibleBondIDRef_ = convertibleBondNode.Attributes["href"].Value;
             }
             else
             {
                 convertibleBond_ = new ConvertibleBond(convertibleBondNode);
             }
         }
         else
         {
             convertibleBond_ = new ConvertibleBond(convertibleBondNode);
         }
     }
     
 
     XmlNode equityNode = xmlNode.SelectSingleNode("equity");
     
     if (equityNode != null)
     {
         if (equityNode.Attributes["href"] != null || equityNode.Attributes["id"] != null) 
         {
             if (equityNode.Attributes["id"] != null) 
             {
                 equityIDRef_ = equityNode.Attributes["id"].Value;
                 EquityAsset ob = new EquityAsset(equityNode);
                 IDManager.SetID(equityIDRef_, ob);
             }
             else if (equityNode.Attributes["href"] != null)
             {
                 equityIDRef_ = equityNode.Attributes["href"].Value;
             }
             else
             {
                 equity_ = new EquityAsset(equityNode);
             }
         }
         else
         {
             equity_ = new EquityAsset(equityNode);
         }
     }
     
 
     XmlNode exchangeTradedFundNode = xmlNode.SelectSingleNode("exchangeTradedFund");
     
     if (exchangeTradedFundNode != null)
     {
         if (exchangeTradedFundNode.Attributes["href"] != null || exchangeTradedFundNode.Attributes["id"] != null) 
         {
             if (exchangeTradedFundNode.Attributes["id"] != null) 
             {
                 exchangeTradedFundIDRef_ = exchangeTradedFundNode.Attributes["id"].Value;
                 ExchangeTradedFund ob = new ExchangeTradedFund(exchangeTradedFundNode);
                 IDManager.SetID(exchangeTradedFundIDRef_, ob);
             }
             else if (exchangeTradedFundNode.Attributes["href"] != null)
             {
                 exchangeTradedFundIDRef_ = exchangeTradedFundNode.Attributes["href"].Value;
             }
             else
             {
                 exchangeTradedFund_ = new ExchangeTradedFund(exchangeTradedFundNode);
             }
         }
         else
         {
             exchangeTradedFund_ = new ExchangeTradedFund(exchangeTradedFundNode);
         }
     }
     
 
     XmlNode futureNode = xmlNode.SelectSingleNode("future");
     
     if (futureNode != null)
     {
         if (futureNode.Attributes["href"] != null || futureNode.Attributes["id"] != null) 
         {
             if (futureNode.Attributes["id"] != null) 
             {
                 futureIDRef_ = futureNode.Attributes["id"].Value;
                 Future ob = new Future(futureNode);
                 IDManager.SetID(futureIDRef_, ob);
             }
             else if (futureNode.Attributes["href"] != null)
             {
                 futureIDRef_ = futureNode.Attributes["href"].Value;
             }
             else
             {
                 future_ = new Future(futureNode);
             }
         }
         else
         {
             future_ = new Future(futureNode);
         }
     }
     
 
     XmlNode indexNode = xmlNode.SelectSingleNode("index");
     
     if (indexNode != null)
     {
         if (indexNode.Attributes["href"] != null || indexNode.Attributes["id"] != null) 
         {
             if (indexNode.Attributes["id"] != null) 
             {
                 indexIDRef_ = indexNode.Attributes["id"].Value;
                 Index ob = new Index(indexNode);
                 IDManager.SetID(indexIDRef_, ob);
             }
             else if (indexNode.Attributes["href"] != null)
             {
                 indexIDRef_ = indexNode.Attributes["href"].Value;
             }
             else
             {
                 index_ = new Index(indexNode);
             }
         }
         else
         {
             index_ = new Index(indexNode);
         }
     }
     
 
     XmlNode loanNode = xmlNode.SelectSingleNode("loan");
     
     if (loanNode != null)
     {
         if (loanNode.Attributes["href"] != null || loanNode.Attributes["id"] != null) 
         {
             if (loanNode.Attributes["id"] != null) 
             {
                 loanIDRef_ = loanNode.Attributes["id"].Value;
                 Loan ob = new Loan(loanNode);
                 IDManager.SetID(loanIDRef_, ob);
             }
             else if (loanNode.Attributes["href"] != null)
             {
                 loanIDRef_ = loanNode.Attributes["href"].Value;
             }
             else
             {
                 loan_ = new Loan(loanNode);
             }
         }
         else
         {
             loan_ = new Loan(loanNode);
         }
     }
     
 
     XmlNode mortgageNode = xmlNode.SelectSingleNode("mortgage");
     
     if (mortgageNode != null)
     {
         if (mortgageNode.Attributes["href"] != null || mortgageNode.Attributes["id"] != null) 
         {
             if (mortgageNode.Attributes["id"] != null) 
             {
                 mortgageIDRef_ = mortgageNode.Attributes["id"].Value;
                 Mortgage ob = new Mortgage(mortgageNode);
                 IDManager.SetID(mortgageIDRef_, ob);
             }
             else if (mortgageNode.Attributes["href"] != null)
             {
                 mortgageIDRef_ = mortgageNode.Attributes["href"].Value;
             }
             else
             {
                 mortgage_ = new Mortgage(mortgageNode);
             }
         }
         else
         {
             mortgage_ = new Mortgage(mortgageNode);
         }
     }
     
 
     XmlNode mutualFundNode = xmlNode.SelectSingleNode("mutualFund");
     
     if (mutualFundNode != null)
     {
         if (mutualFundNode.Attributes["href"] != null || mutualFundNode.Attributes["id"] != null) 
         {
             if (mutualFundNode.Attributes["id"] != null) 
             {
                 mutualFundIDRef_ = mutualFundNode.Attributes["id"].Value;
                 MutualFund ob = new MutualFund(mutualFundNode);
                 IDManager.SetID(mutualFundIDRef_, ob);
             }
             else if (mutualFundNode.Attributes["href"] != null)
             {
                 mutualFundIDRef_ = mutualFundNode.Attributes["href"].Value;
             }
             else
             {
                 mutualFund_ = new MutualFund(mutualFundNode);
             }
         }
         else
         {
             mutualFund_ = new MutualFund(mutualFundNode);
         }
     }
     
 
     XmlNode underlyingAssetReferenceNode = xmlNode.SelectSingleNode("underlyingAssetReference");
     
     if (underlyingAssetReferenceNode != null)
     {
         if (underlyingAssetReferenceNode.Attributes["href"] != null || underlyingAssetReferenceNode.Attributes["id"] != null) 
         {
             if (underlyingAssetReferenceNode.Attributes["id"] != null) 
             {
                 underlyingAssetReferenceIDRef_ = underlyingAssetReferenceNode.Attributes["id"].Value;
                 AssetReference ob = new AssetReference(underlyingAssetReferenceNode);
                 IDManager.SetID(underlyingAssetReferenceIDRef_, ob);
             }
             else if (underlyingAssetReferenceNode.Attributes["href"] != null)
             {
                 underlyingAssetReferenceIDRef_ = underlyingAssetReferenceNode.Attributes["href"].Value;
             }
             else
             {
                 underlyingAssetReference_ = new AssetReference(underlyingAssetReferenceNode);
             }
         }
         else
         {
             underlyingAssetReference_ = new AssetReference(underlyingAssetReferenceNode);
         }
     }
     
 
     XmlNode valueNode = xmlNode.SelectSingleNode("value");
     
     if (valueNode != null)
     {
         if (valueNode.Attributes["href"] != null || valueNode.Attributes["id"] != null) 
         {
             if (valueNode.Attributes["id"] != null) 
             {
                 valueIDRef_ = valueNode.Attributes["id"].Value;
                 XsdTypeDecimal ob = new XsdTypeDecimal(valueNode);
                 IDManager.SetID(valueIDRef_, ob);
             }
             else if (valueNode.Attributes["href"] != null)
             {
                 valueIDRef_ = valueNode.Attributes["href"].Value;
             }
             else
             {
                 value_ = new XsdTypeDecimal(valueNode);
             }
         }
         else
         {
             value_ = new XsdTypeDecimal(valueNode);
         }
     }
     
 
     XmlNode measureTypeNode = xmlNode.SelectSingleNode("measureType");
     
     if (measureTypeNode != null)
     {
         if (measureTypeNode.Attributes["href"] != null || measureTypeNode.Attributes["id"] != null) 
         {
             if (measureTypeNode.Attributes["id"] != null) 
             {
                 measureTypeIDRef_ = measureTypeNode.Attributes["id"].Value;
                 AssetMeasureType ob = new AssetMeasureType(measureTypeNode);
                 IDManager.SetID(measureTypeIDRef_, ob);
             }
             else if (measureTypeNode.Attributes["href"] != null)
             {
                 measureTypeIDRef_ = measureTypeNode.Attributes["href"].Value;
             }
             else
             {
                 measureType_ = new AssetMeasureType(measureTypeNode);
             }
         }
         else
         {
             measureType_ = new AssetMeasureType(measureTypeNode);
         }
     }
     
 
     XmlNode quoteUnitsNode = xmlNode.SelectSingleNode("quoteUnits");
     
     if (quoteUnitsNode != null)
     {
         if (quoteUnitsNode.Attributes["href"] != null || quoteUnitsNode.Attributes["id"] != null) 
         {
             if (quoteUnitsNode.Attributes["id"] != null) 
             {
                 quoteUnitsIDRef_ = quoteUnitsNode.Attributes["id"].Value;
                 PriceQuoteUnits ob = new PriceQuoteUnits(quoteUnitsNode);
                 IDManager.SetID(quoteUnitsIDRef_, ob);
             }
             else if (quoteUnitsNode.Attributes["href"] != null)
             {
                 quoteUnitsIDRef_ = quoteUnitsNode.Attributes["href"].Value;
             }
             else
             {
                 quoteUnits_ = new PriceQuoteUnits(quoteUnitsNode);
             }
         }
         else
         {
             quoteUnits_ = new PriceQuoteUnits(quoteUnitsNode);
         }
     }
     
 
     XmlNode sideNode = xmlNode.SelectSingleNode("side");
     
     if (sideNode != null)
     {
         if (sideNode.Attributes["href"] != null || sideNode.Attributes["id"] != null) 
         {
             if (sideNode.Attributes["id"] != null) 
             {
                 sideIDRef_ = sideNode.Attributes["id"].Value;
                 QuotationSideEnum ob = new QuotationSideEnum(sideNode);
                 IDManager.SetID(sideIDRef_, ob);
             }
             else if (sideNode.Attributes["href"] != null)
             {
                 sideIDRef_ = sideNode.Attributes["href"].Value;
             }
             else
             {
                 side_ = new QuotationSideEnum(sideNode);
             }
         }
         else
         {
             side_ = new QuotationSideEnum(sideNode);
         }
     }
     
 
     XmlNode currencyNode = xmlNode.SelectSingleNode("currency");
     
     if (currencyNode != null)
     {
         if (currencyNode.Attributes["href"] != null || currencyNode.Attributes["id"] != null) 
         {
             if (currencyNode.Attributes["id"] != null) 
             {
                 currencyIDRef_ = currencyNode.Attributes["id"].Value;
                 Currency ob = new Currency(currencyNode);
                 IDManager.SetID(currencyIDRef_, ob);
             }
             else if (currencyNode.Attributes["href"] != null)
             {
                 currencyIDRef_ = currencyNode.Attributes["href"].Value;
             }
             else
             {
                 currency_ = new Currency(currencyNode);
             }
         }
         else
         {
             currency_ = new Currency(currencyNode);
         }
     }
     
 
     XmlNode currencyTypeNode = xmlNode.SelectSingleNode("currencyType");
     
     if (currencyTypeNode != null)
     {
         if (currencyTypeNode.Attributes["href"] != null || currencyTypeNode.Attributes["id"] != null) 
         {
             if (currencyTypeNode.Attributes["id"] != null) 
             {
                 currencyTypeIDRef_ = currencyTypeNode.Attributes["id"].Value;
                 ReportingCurrencyType ob = new ReportingCurrencyType(currencyTypeNode);
                 IDManager.SetID(currencyTypeIDRef_, ob);
             }
             else if (currencyTypeNode.Attributes["href"] != null)
             {
                 currencyTypeIDRef_ = currencyTypeNode.Attributes["href"].Value;
             }
             else
             {
                 currencyType_ = new ReportingCurrencyType(currencyTypeNode);
             }
         }
         else
         {
             currencyType_ = new ReportingCurrencyType(currencyTypeNode);
         }
     }
     
 
     XmlNode timingNode = xmlNode.SelectSingleNode("timing");
     
     if (timingNode != null)
     {
         if (timingNode.Attributes["href"] != null || timingNode.Attributes["id"] != null) 
         {
             if (timingNode.Attributes["id"] != null) 
             {
                 timingIDRef_ = timingNode.Attributes["id"].Value;
                 QuoteTiming ob = new QuoteTiming(timingNode);
                 IDManager.SetID(timingIDRef_, ob);
             }
             else if (timingNode.Attributes["href"] != null)
             {
                 timingIDRef_ = timingNode.Attributes["href"].Value;
             }
             else
             {
                 timing_ = new QuoteTiming(timingNode);
             }
         }
         else
         {
             timing_ = new QuoteTiming(timingNode);
         }
     }
     
 
     XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");
     
     if (businessCenterNode != null)
     {
         if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null) 
         {
             if (businessCenterNode.Attributes["id"] != null) 
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(businessCenterNode);
                 IDManager.SetID(businessCenterIDRef_, ob);
             }
             else if (businessCenterNode.Attributes["href"] != null)
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
             }
             else
             {
                 businessCenter_ = new BusinessCenter(businessCenterNode);
             }
         }
         else
         {
             businessCenter_ = new BusinessCenter(businessCenterNode);
         }
     }
     
 
     XmlNode exchangeIdNode = xmlNode.SelectSingleNode("exchangeId");
     
     if (exchangeIdNode != null)
     {
         if (exchangeIdNode.Attributes["href"] != null || exchangeIdNode.Attributes["id"] != null) 
         {
             if (exchangeIdNode.Attributes["id"] != null) 
             {
                 exchangeIdIDRef_ = exchangeIdNode.Attributes["id"].Value;
                 ExchangeId ob = new ExchangeId(exchangeIdNode);
                 IDManager.SetID(exchangeIdIDRef_, ob);
             }
             else if (exchangeIdNode.Attributes["href"] != null)
             {
                 exchangeIdIDRef_ = exchangeIdNode.Attributes["href"].Value;
             }
             else
             {
                 exchangeId_ = new ExchangeId(exchangeIdNode);
             }
         }
         else
         {
             exchangeId_ = new ExchangeId(exchangeIdNode);
         }
     }
     
 
     XmlNodeList informationSourceNodeList = xmlNode.SelectNodes("informationSource");
     
     if (informationSourceNodeList != null)
     {
         this.informationSource_ = new List<InformationSource>();
         foreach (XmlNode item in informationSourceNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     informationSourceIDRef_ = item.Attributes["id"].Value;
                     informationSource_.Add(new InformationSource(item));
                     IDManager.SetID(informationSourceIDRef_, informationSource_[informationSource_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     informationSourceIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 informationSource_.Add(new InformationSource(item));
                 }
             }
             else
             {
                 informationSource_.Add(new InformationSource(item));
             }
         }
     }
     
 
     XmlNode pricingModelNode = xmlNode.SelectSingleNode("pricingModel");
     
     if (pricingModelNode != null)
     {
         if (pricingModelNode.Attributes["href"] != null || pricingModelNode.Attributes["id"] != null) 
         {
             if (pricingModelNode.Attributes["id"] != null) 
             {
                 pricingModelIDRef_ = pricingModelNode.Attributes["id"].Value;
                 PricingModel ob = new PricingModel(pricingModelNode);
                 IDManager.SetID(pricingModelIDRef_, ob);
             }
             else if (pricingModelNode.Attributes["href"] != null)
             {
                 pricingModelIDRef_ = pricingModelNode.Attributes["href"].Value;
             }
             else
             {
                 pricingModel_ = new PricingModel(pricingModelNode);
             }
         }
         else
         {
             pricingModel_ = new PricingModel(pricingModelNode);
         }
     }
     
 
     XmlNode timeNode = xmlNode.SelectSingleNode("time");
     
     if (timeNode != null)
     {
         if (timeNode.Attributes["href"] != null || timeNode.Attributes["id"] != null) 
         {
             if (timeNode.Attributes["id"] != null) 
             {
                 timeIDRef_ = timeNode.Attributes["id"].Value;
                 XsdTypeDateTime ob = new XsdTypeDateTime(timeNode);
                 IDManager.SetID(timeIDRef_, ob);
             }
             else if (timeNode.Attributes["href"] != null)
             {
                 timeIDRef_ = timeNode.Attributes["href"].Value;
             }
             else
             {
                 time_ = new XsdTypeDateTime(timeNode);
             }
         }
         else
         {
             time_ = new XsdTypeDateTime(timeNode);
         }
     }
     
 
     XmlNode valuationDateNode = xmlNode.SelectSingleNode("valuationDate");
     
     if (valuationDateNode != null)
     {
         if (valuationDateNode.Attributes["href"] != null || valuationDateNode.Attributes["id"] != null) 
         {
             if (valuationDateNode.Attributes["id"] != null) 
             {
                 valuationDateIDRef_ = valuationDateNode.Attributes["id"].Value;
                 XsdTypeDate ob = new XsdTypeDate(valuationDateNode);
                 IDManager.SetID(valuationDateIDRef_, ob);
             }
             else if (valuationDateNode.Attributes["href"] != null)
             {
                 valuationDateIDRef_ = valuationDateNode.Attributes["href"].Value;
             }
             else
             {
                 valuationDate_ = new XsdTypeDate(valuationDateNode);
             }
         }
         else
         {
             valuationDate_ = new XsdTypeDate(valuationDateNode);
         }
     }
     
 
     XmlNode expiryTimeNode = xmlNode.SelectSingleNode("expiryTime");
     
     if (expiryTimeNode != null)
     {
         if (expiryTimeNode.Attributes["href"] != null || expiryTimeNode.Attributes["id"] != null) 
         {
             if (expiryTimeNode.Attributes["id"] != null) 
             {
                 expiryTimeIDRef_ = expiryTimeNode.Attributes["id"].Value;
                 XsdTypeDateTime ob = new XsdTypeDateTime(expiryTimeNode);
                 IDManager.SetID(expiryTimeIDRef_, ob);
             }
             else if (expiryTimeNode.Attributes["href"] != null)
             {
                 expiryTimeIDRef_ = expiryTimeNode.Attributes["href"].Value;
             }
             else
             {
                 expiryTime_ = new XsdTypeDateTime(expiryTimeNode);
             }
         }
         else
         {
             expiryTime_ = new XsdTypeDateTime(expiryTimeNode);
         }
     }
     
 
     XmlNode cashflowTypeNode = xmlNode.SelectSingleNode("cashflowType");
     
     if (cashflowTypeNode != null)
     {
         if (cashflowTypeNode.Attributes["href"] != null || cashflowTypeNode.Attributes["id"] != null) 
         {
             if (cashflowTypeNode.Attributes["id"] != null) 
             {
                 cashflowTypeIDRef_ = cashflowTypeNode.Attributes["id"].Value;
                 CashflowType ob = new CashflowType(cashflowTypeNode);
                 IDManager.SetID(cashflowTypeIDRef_, ob);
             }
             else if (cashflowTypeNode.Attributes["href"] != null)
             {
                 cashflowTypeIDRef_ = cashflowTypeNode.Attributes["href"].Value;
             }
             else
             {
                 cashflowType_ = new CashflowType(cashflowTypeNode);
             }
         }
         else
         {
             cashflowType_ = new CashflowType(cashflowTypeNode);
         }
     }
     
 
 }
 public BasicQuotation(XmlNode xmlNode)
 {
     XmlNode valueNode = xmlNode.SelectSingleNode("value");
     
     if (valueNode != null)
     {
         if (valueNode.Attributes["href"] != null || valueNode.Attributes["id"] != null) 
         {
             if (valueNode.Attributes["id"] != null) 
             {
                 valueIDRef_ = valueNode.Attributes["id"].Value;
                 XsdTypeDecimal ob = new XsdTypeDecimal(valueNode);
                 IDManager.SetID(valueIDRef_, ob);
             }
             else if (valueNode.Attributes["href"] != null)
             {
                 valueIDRef_ = valueNode.Attributes["href"].Value;
             }
             else
             {
                 value_ = new XsdTypeDecimal(valueNode);
             }
         }
         else
         {
             value_ = new XsdTypeDecimal(valueNode);
         }
     }
     
 
     XmlNode measureTypeNode = xmlNode.SelectSingleNode("measureType");
     
     if (measureTypeNode != null)
     {
         if (measureTypeNode.Attributes["href"] != null || measureTypeNode.Attributes["id"] != null) 
         {
             if (measureTypeNode.Attributes["id"] != null) 
             {
                 measureTypeIDRef_ = measureTypeNode.Attributes["id"].Value;
                 AssetMeasureType ob = new AssetMeasureType(measureTypeNode);
                 IDManager.SetID(measureTypeIDRef_, ob);
             }
             else if (measureTypeNode.Attributes["href"] != null)
             {
                 measureTypeIDRef_ = measureTypeNode.Attributes["href"].Value;
             }
             else
             {
                 measureType_ = new AssetMeasureType(measureTypeNode);
             }
         }
         else
         {
             measureType_ = new AssetMeasureType(measureTypeNode);
         }
     }
     
 
     XmlNode quoteUnitsNode = xmlNode.SelectSingleNode("quoteUnits");
     
     if (quoteUnitsNode != null)
     {
         if (quoteUnitsNode.Attributes["href"] != null || quoteUnitsNode.Attributes["id"] != null) 
         {
             if (quoteUnitsNode.Attributes["id"] != null) 
             {
                 quoteUnitsIDRef_ = quoteUnitsNode.Attributes["id"].Value;
                 PriceQuoteUnits ob = new PriceQuoteUnits(quoteUnitsNode);
                 IDManager.SetID(quoteUnitsIDRef_, ob);
             }
             else if (quoteUnitsNode.Attributes["href"] != null)
             {
                 quoteUnitsIDRef_ = quoteUnitsNode.Attributes["href"].Value;
             }
             else
             {
                 quoteUnits_ = new PriceQuoteUnits(quoteUnitsNode);
             }
         }
         else
         {
             quoteUnits_ = new PriceQuoteUnits(quoteUnitsNode);
         }
     }
     
 
     XmlNode sideNode = xmlNode.SelectSingleNode("side");
     
     if (sideNode != null)
     {
         if (sideNode.Attributes["href"] != null || sideNode.Attributes["id"] != null) 
         {
             if (sideNode.Attributes["id"] != null) 
             {
                 sideIDRef_ = sideNode.Attributes["id"].Value;
                 QuotationSideEnum ob = new QuotationSideEnum(sideNode);
                 IDManager.SetID(sideIDRef_, ob);
             }
             else if (sideNode.Attributes["href"] != null)
             {
                 sideIDRef_ = sideNode.Attributes["href"].Value;
             }
             else
             {
                 side_ = new QuotationSideEnum(sideNode);
             }
         }
         else
         {
             side_ = new QuotationSideEnum(sideNode);
         }
     }
     
 
     XmlNode currencyNode = xmlNode.SelectSingleNode("currency");
     
     if (currencyNode != null)
     {
         if (currencyNode.Attributes["href"] != null || currencyNode.Attributes["id"] != null) 
         {
             if (currencyNode.Attributes["id"] != null) 
             {
                 currencyIDRef_ = currencyNode.Attributes["id"].Value;
                 Currency ob = new Currency(currencyNode);
                 IDManager.SetID(currencyIDRef_, ob);
             }
             else if (currencyNode.Attributes["href"] != null)
             {
                 currencyIDRef_ = currencyNode.Attributes["href"].Value;
             }
             else
             {
                 currency_ = new Currency(currencyNode);
             }
         }
         else
         {
             currency_ = new Currency(currencyNode);
         }
     }
     
 
     XmlNode currencyTypeNode = xmlNode.SelectSingleNode("currencyType");
     
     if (currencyTypeNode != null)
     {
         if (currencyTypeNode.Attributes["href"] != null || currencyTypeNode.Attributes["id"] != null) 
         {
             if (currencyTypeNode.Attributes["id"] != null) 
             {
                 currencyTypeIDRef_ = currencyTypeNode.Attributes["id"].Value;
                 ReportingCurrencyType ob = new ReportingCurrencyType(currencyTypeNode);
                 IDManager.SetID(currencyTypeIDRef_, ob);
             }
             else if (currencyTypeNode.Attributes["href"] != null)
             {
                 currencyTypeIDRef_ = currencyTypeNode.Attributes["href"].Value;
             }
             else
             {
                 currencyType_ = new ReportingCurrencyType(currencyTypeNode);
             }
         }
         else
         {
             currencyType_ = new ReportingCurrencyType(currencyTypeNode);
         }
     }
     
 
     XmlNode timingNode = xmlNode.SelectSingleNode("timing");
     
     if (timingNode != null)
     {
         if (timingNode.Attributes["href"] != null || timingNode.Attributes["id"] != null) 
         {
             if (timingNode.Attributes["id"] != null) 
             {
                 timingIDRef_ = timingNode.Attributes["id"].Value;
                 QuoteTiming ob = new QuoteTiming(timingNode);
                 IDManager.SetID(timingIDRef_, ob);
             }
             else if (timingNode.Attributes["href"] != null)
             {
                 timingIDRef_ = timingNode.Attributes["href"].Value;
             }
             else
             {
                 timing_ = new QuoteTiming(timingNode);
             }
         }
         else
         {
             timing_ = new QuoteTiming(timingNode);
         }
     }
     
 
     XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");
     
     if (businessCenterNode != null)
     {
         if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null) 
         {
             if (businessCenterNode.Attributes["id"] != null) 
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(businessCenterNode);
                 IDManager.SetID(businessCenterIDRef_, ob);
             }
             else if (businessCenterNode.Attributes["href"] != null)
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
             }
             else
             {
                 businessCenter_ = new BusinessCenter(businessCenterNode);
             }
         }
         else
         {
             businessCenter_ = new BusinessCenter(businessCenterNode);
         }
     }
     
 
     XmlNode exchangeIdNode = xmlNode.SelectSingleNode("exchangeId");
     
     if (exchangeIdNode != null)
     {
         if (exchangeIdNode.Attributes["href"] != null || exchangeIdNode.Attributes["id"] != null) 
         {
             if (exchangeIdNode.Attributes["id"] != null) 
             {
                 exchangeIdIDRef_ = exchangeIdNode.Attributes["id"].Value;
                 ExchangeId ob = new ExchangeId(exchangeIdNode);
                 IDManager.SetID(exchangeIdIDRef_, ob);
             }
             else if (exchangeIdNode.Attributes["href"] != null)
             {
                 exchangeIdIDRef_ = exchangeIdNode.Attributes["href"].Value;
             }
             else
             {
                 exchangeId_ = new ExchangeId(exchangeIdNode);
             }
         }
         else
         {
             exchangeId_ = new ExchangeId(exchangeIdNode);
         }
     }
     
 
     XmlNodeList informationSourceNodeList = xmlNode.SelectNodes("informationSource");
     
     if (informationSourceNodeList != null)
     {
         this.informationSource_ = new List<InformationSource>();
         foreach (XmlNode item in informationSourceNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     informationSourceIDRef_ = item.Attributes["id"].Value;
                     informationSource_.Add(new InformationSource(item));
                     IDManager.SetID(informationSourceIDRef_, informationSource_[informationSource_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     informationSourceIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 informationSource_.Add(new InformationSource(item));
                 }
             }
             else
             {
                 informationSource_.Add(new InformationSource(item));
             }
         }
     }
     
 
     XmlNode pricingModelNode = xmlNode.SelectSingleNode("pricingModel");
     
     if (pricingModelNode != null)
     {
         if (pricingModelNode.Attributes["href"] != null || pricingModelNode.Attributes["id"] != null) 
         {
             if (pricingModelNode.Attributes["id"] != null) 
             {
                 pricingModelIDRef_ = pricingModelNode.Attributes["id"].Value;
                 PricingModel ob = new PricingModel(pricingModelNode);
                 IDManager.SetID(pricingModelIDRef_, ob);
             }
             else if (pricingModelNode.Attributes["href"] != null)
             {
                 pricingModelIDRef_ = pricingModelNode.Attributes["href"].Value;
             }
             else
             {
                 pricingModel_ = new PricingModel(pricingModelNode);
             }
         }
         else
         {
             pricingModel_ = new PricingModel(pricingModelNode);
         }
     }
     
 
     XmlNode timeNode = xmlNode.SelectSingleNode("time");
     
     if (timeNode != null)
     {
         if (timeNode.Attributes["href"] != null || timeNode.Attributes["id"] != null) 
         {
             if (timeNode.Attributes["id"] != null) 
             {
                 timeIDRef_ = timeNode.Attributes["id"].Value;
                 XsdTypeDateTime ob = new XsdTypeDateTime(timeNode);
                 IDManager.SetID(timeIDRef_, ob);
             }
             else if (timeNode.Attributes["href"] != null)
             {
                 timeIDRef_ = timeNode.Attributes["href"].Value;
             }
             else
             {
                 time_ = new XsdTypeDateTime(timeNode);
             }
         }
         else
         {
             time_ = new XsdTypeDateTime(timeNode);
         }
     }
     
 
     XmlNode valuationDateNode = xmlNode.SelectSingleNode("valuationDate");
     
     if (valuationDateNode != null)
     {
         if (valuationDateNode.Attributes["href"] != null || valuationDateNode.Attributes["id"] != null) 
         {
             if (valuationDateNode.Attributes["id"] != null) 
             {
                 valuationDateIDRef_ = valuationDateNode.Attributes["id"].Value;
                 XsdTypeDate ob = new XsdTypeDate(valuationDateNode);
                 IDManager.SetID(valuationDateIDRef_, ob);
             }
             else if (valuationDateNode.Attributes["href"] != null)
             {
                 valuationDateIDRef_ = valuationDateNode.Attributes["href"].Value;
             }
             else
             {
                 valuationDate_ = new XsdTypeDate(valuationDateNode);
             }
         }
         else
         {
             valuationDate_ = new XsdTypeDate(valuationDateNode);
         }
     }
     
 
     XmlNode expiryTimeNode = xmlNode.SelectSingleNode("expiryTime");
     
     if (expiryTimeNode != null)
     {
         if (expiryTimeNode.Attributes["href"] != null || expiryTimeNode.Attributes["id"] != null) 
         {
             if (expiryTimeNode.Attributes["id"] != null) 
             {
                 expiryTimeIDRef_ = expiryTimeNode.Attributes["id"].Value;
                 XsdTypeDateTime ob = new XsdTypeDateTime(expiryTimeNode);
                 IDManager.SetID(expiryTimeIDRef_, ob);
             }
             else if (expiryTimeNode.Attributes["href"] != null)
             {
                 expiryTimeIDRef_ = expiryTimeNode.Attributes["href"].Value;
             }
             else
             {
                 expiryTime_ = new XsdTypeDateTime(expiryTimeNode);
             }
         }
         else
         {
             expiryTime_ = new XsdTypeDateTime(expiryTimeNode);
         }
     }
     
 
     XmlNode cashflowTypeNode = xmlNode.SelectSingleNode("cashflowType");
     
     if (cashflowTypeNode != null)
     {
         if (cashflowTypeNode.Attributes["href"] != null || cashflowTypeNode.Attributes["id"] != null) 
         {
             if (cashflowTypeNode.Attributes["id"] != null) 
             {
                 cashflowTypeIDRef_ = cashflowTypeNode.Attributes["id"].Value;
                 CashflowType ob = new CashflowType(cashflowTypeNode);
                 IDManager.SetID(cashflowTypeIDRef_, ob);
             }
             else if (cashflowTypeNode.Attributes["href"] != null)
             {
                 cashflowTypeIDRef_ = cashflowTypeNode.Attributes["href"].Value;
             }
             else
             {
                 cashflowType_ = new CashflowType(cashflowTypeNode);
             }
         }
         else
         {
             cashflowType_ = new CashflowType(cashflowTypeNode);
         }
     }
     
 
 }
示例#24
0
        public ExerciseNotice(XmlNode xmlNode)
        {
            XmlNode partyReferenceNode = xmlNode.SelectSingleNode("partyReference");

            if (partyReferenceNode != null)
            {
                if (partyReferenceNode.Attributes["href"] != null || partyReferenceNode.Attributes["id"] != null)
                {
                    if (partyReferenceNode.Attributes["id"] != null)
                    {
                        partyReferenceIDRef_ = partyReferenceNode.Attributes["id"].Value;
                        PartyReference ob = new PartyReference(partyReferenceNode);
                        IDManager.SetID(partyReferenceIDRef_, ob);
                    }
                    else if (partyReferenceNode.Attributes["href"] != null)
                    {
                        partyReferenceIDRef_ = partyReferenceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        partyReference_ = new PartyReference(partyReferenceNode);
                    }
                }
                else
                {
                    partyReference_ = new PartyReference(partyReferenceNode);
                }
            }


            XmlNode exerciseNoticePartyReferenceNode = xmlNode.SelectSingleNode("exerciseNoticePartyReference");

            if (exerciseNoticePartyReferenceNode != null)
            {
                if (exerciseNoticePartyReferenceNode.Attributes["href"] != null || exerciseNoticePartyReferenceNode.Attributes["id"] != null)
                {
                    if (exerciseNoticePartyReferenceNode.Attributes["id"] != null)
                    {
                        exerciseNoticePartyReferenceIDRef_ = exerciseNoticePartyReferenceNode.Attributes["id"].Value;
                        PartyReference ob = new PartyReference(exerciseNoticePartyReferenceNode);
                        IDManager.SetID(exerciseNoticePartyReferenceIDRef_, ob);
                    }
                    else if (exerciseNoticePartyReferenceNode.Attributes["href"] != null)
                    {
                        exerciseNoticePartyReferenceIDRef_ = exerciseNoticePartyReferenceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        exerciseNoticePartyReference_ = new PartyReference(exerciseNoticePartyReferenceNode);
                    }
                }
                else
                {
                    exerciseNoticePartyReference_ = new PartyReference(exerciseNoticePartyReferenceNode);
                }
            }


            XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");

            if (businessCenterNode != null)
            {
                if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null)
                {
                    if (businessCenterNode.Attributes["id"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                        BusinessCenter ob = new BusinessCenter(businessCenterNode);
                        IDManager.SetID(businessCenterIDRef_, ob);
                    }
                    else if (businessCenterNode.Attributes["href"] != null)
                    {
                        businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
                    }
                    else
                    {
                        businessCenter_ = new BusinessCenter(businessCenterNode);
                    }
                }
                else
                {
                    businessCenter_ = new BusinessCenter(businessCenterNode);
                }
            }
        }
 public WeatherLegCalculation(XmlNode xmlNode)
 {
     XmlNodeList settlementLevelNodeList = xmlNode.SelectNodes("settlementLevel");
     if (settlementLevelNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in settlementLevelNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 settlementLevelIDRef = item.Attributes["id"].Name;
                 WeatherSettlementLevelEnum ob = WeatherSettlementLevelEnum();
                 IDManager.SetID(settlementLevelIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 settlementLevelIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 settlementLevel = new WeatherSettlementLevelEnum(item);
             }
         }
     }
     
 
     XmlNodeList referenceLevelEqualsZeroNodeList = xmlNode.SelectNodes("referenceLevelEqualsZero");
     if (referenceLevelEqualsZeroNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in referenceLevelEqualsZeroNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 referenceLevelEqualsZeroIDRef = item.Attributes["id"].Name;
                 XsdTypeBoolean ob = XsdTypeBoolean();
                 IDManager.SetID(referenceLevelEqualsZeroIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 referenceLevelEqualsZeroIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 referenceLevelEqualsZero = new XsdTypeBoolean(item);
             }
         }
     }
     
 
     XmlNodeList calculationDateNodeList = xmlNode.SelectNodes("calculationDate");
     if (calculationDateNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in calculationDateNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 calculationDateIDRef = item.Attributes["id"].Name;
                 Period ob = Period();
                 IDManager.SetID(calculationDateIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 calculationDateIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 calculationDate = new Period(item);
             }
         }
     }
     
 
     XmlNodeList businessDaysNodeList = xmlNode.SelectNodes("businessDays");
     if (businessDaysNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in businessDaysNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 businessDaysIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(businessDaysIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 businessDaysIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 businessDays = new BusinessCenter(item);
             }
         }
     }
     
 
     XmlNodeList dataCorrectionNodeList = xmlNode.SelectNodes("dataCorrection");
     if (dataCorrectionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in dataCorrectionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 dataCorrectionIDRef = item.Attributes["id"].Name;
                 XsdTypeBoolean ob = XsdTypeBoolean();
                 IDManager.SetID(dataCorrectionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 dataCorrectionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 dataCorrection = new XsdTypeBoolean(item);
             }
         }
     }
     
 
     XmlNodeList correctionPeriodNodeList = xmlNode.SelectNodes("correctionPeriod");
     if (correctionPeriodNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in correctionPeriodNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 correctionPeriodIDRef = item.Attributes["id"].Name;
                 Period ob = Period();
                 IDManager.SetID(correctionPeriodIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 correctionPeriodIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 correctionPeriod = new Period(item);
             }
         }
     }
     
 
     XmlNodeList maximumPaymentAmountNodeList = xmlNode.SelectNodes("maximumPaymentAmount");
     if (maximumPaymentAmountNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in maximumPaymentAmountNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 maximumPaymentAmountIDRef = item.Attributes["id"].Name;
                 NonNegativeMoney ob = NonNegativeMoney();
                 IDManager.SetID(maximumPaymentAmountIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 maximumPaymentAmountIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 maximumPaymentAmount = new NonNegativeMoney(item);
             }
         }
     }
     
 
     XmlNodeList maximumTransactionPaymentAmountNodeList = xmlNode.SelectNodes("maximumTransactionPaymentAmount");
     if (maximumTransactionPaymentAmountNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in maximumTransactionPaymentAmountNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 maximumTransactionPaymentAmountIDRef = item.Attributes["id"].Name;
                 NonNegativeMoney ob = NonNegativeMoney();
                 IDManager.SetID(maximumTransactionPaymentAmountIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 maximumTransactionPaymentAmountIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 maximumTransactionPaymentAmount = new NonNegativeMoney(item);
             }
         }
     }
     
 
     XmlNodeList roundingNodeList = xmlNode.SelectNodes("rounding");
     if (roundingNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in roundingNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 roundingIDRef = item.Attributes["id"].Name;
                 Rounding ob = Rounding();
                 IDManager.SetID(roundingIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 roundingIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 rounding = new Rounding(item);
             }
         }
     }
     
 
 }
 public CreditEventNotice(XmlNode xmlNode)
 {
     XmlNode notifyingPartyNode = xmlNode.SelectSingleNode("notifyingParty");
     
     if (notifyingPartyNode != null)
     {
         if (notifyingPartyNode.Attributes["href"] != null || notifyingPartyNode.Attributes["id"] != null) 
         {
             if (notifyingPartyNode.Attributes["id"] != null) 
             {
                 notifyingPartyIDRef_ = notifyingPartyNode.Attributes["id"].Value;
                 NotifyingParty ob = new NotifyingParty(notifyingPartyNode);
                 IDManager.SetID(notifyingPartyIDRef_, ob);
             }
             else if (notifyingPartyNode.Attributes["href"] != null)
             {
                 notifyingPartyIDRef_ = notifyingPartyNode.Attributes["href"].Value;
             }
             else
             {
                 notifyingParty_ = new NotifyingParty(notifyingPartyNode);
             }
         }
         else
         {
             notifyingParty_ = new NotifyingParty(notifyingPartyNode);
         }
     }
     
 
     XmlNode businessCenterNode = xmlNode.SelectSingleNode("businessCenter");
     
     if (businessCenterNode != null)
     {
         if (businessCenterNode.Attributes["href"] != null || businessCenterNode.Attributes["id"] != null) 
         {
             if (businessCenterNode.Attributes["id"] != null) 
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["id"].Value;
                 BusinessCenter ob = new BusinessCenter(businessCenterNode);
                 IDManager.SetID(businessCenterIDRef_, ob);
             }
             else if (businessCenterNode.Attributes["href"] != null)
             {
                 businessCenterIDRef_ = businessCenterNode.Attributes["href"].Value;
             }
             else
             {
                 businessCenter_ = new BusinessCenter(businessCenterNode);
             }
         }
         else
         {
             businessCenter_ = new BusinessCenter(businessCenterNode);
         }
     }
     
 
     XmlNode publiclyAvailableInformationNode = xmlNode.SelectSingleNode("publiclyAvailableInformation");
     
     if (publiclyAvailableInformationNode != null)
     {
         if (publiclyAvailableInformationNode.Attributes["href"] != null || publiclyAvailableInformationNode.Attributes["id"] != null) 
         {
             if (publiclyAvailableInformationNode.Attributes["id"] != null) 
             {
                 publiclyAvailableInformationIDRef_ = publiclyAvailableInformationNode.Attributes["id"].Value;
                 PubliclyAvailableInformation ob = new PubliclyAvailableInformation(publiclyAvailableInformationNode);
                 IDManager.SetID(publiclyAvailableInformationIDRef_, ob);
             }
             else if (publiclyAvailableInformationNode.Attributes["href"] != null)
             {
                 publiclyAvailableInformationIDRef_ = publiclyAvailableInformationNode.Attributes["href"].Value;
             }
             else
             {
                 publiclyAvailableInformation_ = new PubliclyAvailableInformation(publiclyAvailableInformationNode);
             }
         }
         else
         {
             publiclyAvailableInformation_ = new PubliclyAvailableInformation(publiclyAvailableInformationNode);
         }
     }
     
 
 }
 public MultiDimensionalPricingData(XmlNode xmlNode)
 {
     XmlNodeList measureTypeNodeList = xmlNode.SelectNodes("measureType");
     if (measureTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in measureTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 measureTypeIDRef = item.Attributes["id"].Name;
                 AssetMeasureType ob = AssetMeasureType();
                 IDManager.SetID(measureTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 measureTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 measureType = new AssetMeasureType(item);
             }
         }
     }
     
 
     XmlNodeList quoteUnitsNodeList = xmlNode.SelectNodes("quoteUnits");
     if (quoteUnitsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in quoteUnitsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 quoteUnitsIDRef = item.Attributes["id"].Name;
                 PriceQuoteUnits ob = PriceQuoteUnits();
                 IDManager.SetID(quoteUnitsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 quoteUnitsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 quoteUnits = new PriceQuoteUnits(item);
             }
         }
     }
     
 
     XmlNodeList sideNodeList = xmlNode.SelectNodes("side");
     if (sideNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in sideNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 sideIDRef = item.Attributes["id"].Name;
                 QuotationSideEnum ob = QuotationSideEnum();
                 IDManager.SetID(sideIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 sideIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 side = new QuotationSideEnum(item);
             }
         }
     }
     
 
     XmlNodeList currencyNodeList = xmlNode.SelectNodes("currency");
     if (currencyNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in currencyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 currencyIDRef = item.Attributes["id"].Name;
                 Currency ob = Currency();
                 IDManager.SetID(currencyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 currencyIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 currency = new Currency(item);
             }
         }
     }
     
 
     XmlNodeList currencyTypeNodeList = xmlNode.SelectNodes("currencyType");
     if (currencyTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in currencyTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 currencyTypeIDRef = item.Attributes["id"].Name;
                 ReportingCurrencyType ob = ReportingCurrencyType();
                 IDManager.SetID(currencyTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 currencyTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 currencyType = new ReportingCurrencyType(item);
             }
         }
     }
     
 
     XmlNodeList timingNodeList = xmlNode.SelectNodes("timing");
     if (timingNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in timingNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 timingIDRef = item.Attributes["id"].Name;
                 QuoteTiming ob = QuoteTiming();
                 IDManager.SetID(timingIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 timingIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 timing = new QuoteTiming(item);
             }
         }
     }
     
 
     XmlNodeList businessCenterNodeList = xmlNode.SelectNodes("businessCenter");
     if (businessCenterNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in businessCenterNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 businessCenterIDRef = item.Attributes["id"].Name;
                 BusinessCenter ob = BusinessCenter();
                 IDManager.SetID(businessCenterIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 businessCenterIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 businessCenter = new BusinessCenter(item);
             }
         }
     }
     
 
     XmlNodeList exchangeIdNodeList = xmlNode.SelectNodes("exchangeId");
     if (exchangeIdNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in exchangeIdNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 exchangeIdIDRef = item.Attributes["id"].Name;
                 ExchangeId ob = ExchangeId();
                 IDManager.SetID(exchangeIdIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 exchangeIdIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 exchangeId = new ExchangeId(item);
             }
         }
     }
     
 
     XmlNodeList informationSourceNodeList = xmlNode.SelectNodes("informationSource");
     
     foreach (XmlNode item in informationSourceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 informationSourceIDRef = item.Attributes["id"].Name;
                 List<InformationSource> ob = new List<InformationSource>();
                 ob.Add(new InformationSource(item));
                 IDManager.SetID(informationSourceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 informationSourceIDRef = item.Attributes["href"].Name;
             }
             else
             {
             informationSource.Add(new InformationSource(item));
             }
         }
     }
     
 
     XmlNodeList pricingModelNodeList = xmlNode.SelectNodes("pricingModel");
     if (pricingModelNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in pricingModelNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 pricingModelIDRef = item.Attributes["id"].Name;
                 PricingModel ob = PricingModel();
                 IDManager.SetID(pricingModelIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 pricingModelIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 pricingModel = new PricingModel(item);
             }
         }
     }
     
 
     XmlNodeList timeNodeList = xmlNode.SelectNodes("time");
     if (timeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in timeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 timeIDRef = item.Attributes["id"].Name;
                 XsdTypeDateTime ob = XsdTypeDateTime();
                 IDManager.SetID(timeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 timeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 time = new XsdTypeDateTime(item);
             }
         }
     }
     
 
     XmlNodeList valuationDateNodeList = xmlNode.SelectNodes("valuationDate");
     if (valuationDateNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in valuationDateNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 valuationDateIDRef = item.Attributes["id"].Name;
                 XsdTypeDate ob = XsdTypeDate();
                 IDManager.SetID(valuationDateIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 valuationDateIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 valuationDate = new XsdTypeDate(item);
             }
         }
     }
     
 
     XmlNodeList expiryTimeNodeList = xmlNode.SelectNodes("expiryTime");
     if (expiryTimeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in expiryTimeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 expiryTimeIDRef = item.Attributes["id"].Name;
                 XsdTypeDateTime ob = XsdTypeDateTime();
                 IDManager.SetID(expiryTimeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 expiryTimeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 expiryTime = new XsdTypeDateTime(item);
             }
         }
     }
     
 
     XmlNodeList cashflowTypeNodeList = xmlNode.SelectNodes("cashflowType");
     if (cashflowTypeNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in cashflowTypeNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 cashflowTypeIDRef = item.Attributes["id"].Name;
                 CashflowType ob = CashflowType();
                 IDManager.SetID(cashflowTypeIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 cashflowTypeIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 cashflowType = new CashflowType(item);
             }
         }
     }
     
 
     XmlNodeList pointNodeList = xmlNode.SelectNodes("point");
     
     foreach (XmlNode item in pointNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 pointIDRef = item.Attributes["id"].Name;
                 List<PricingStructurePoint> ob = new List<PricingStructurePoint>();
                 ob.Add(new PricingStructurePoint(item));
                 IDManager.SetID(pointIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 pointIDRef = item.Attributes["href"].Name;
             }
             else
             {
             point.Add(new PricingStructurePoint(item));
             }
         }
     }
     
 
 }
        public WeatherLegCalculation(XmlNode xmlNode)
        {
            XmlNode settlementLevelNode = xmlNode.SelectSingleNode("settlementLevel");

            if (settlementLevelNode != null)
            {
                if (settlementLevelNode.Attributes["href"] != null || settlementLevelNode.Attributes["id"] != null)
                {
                    if (settlementLevelNode.Attributes["id"] != null)
                    {
                        settlementLevelIDRef_ = settlementLevelNode.Attributes["id"].Value;
                        WeatherSettlementLevelEnum ob = new WeatherSettlementLevelEnum(settlementLevelNode);
                        IDManager.SetID(settlementLevelIDRef_, ob);
                    }
                    else if (settlementLevelNode.Attributes["href"] != null)
                    {
                        settlementLevelIDRef_ = settlementLevelNode.Attributes["href"].Value;
                    }
                    else
                    {
                        settlementLevel_ = new WeatherSettlementLevelEnum(settlementLevelNode);
                    }
                }
                else
                {
                    settlementLevel_ = new WeatherSettlementLevelEnum(settlementLevelNode);
                }
            }


            XmlNode referenceLevelEqualsZeroNode = xmlNode.SelectSingleNode("referenceLevelEqualsZero");

            if (referenceLevelEqualsZeroNode != null)
            {
                if (referenceLevelEqualsZeroNode.Attributes["href"] != null || referenceLevelEqualsZeroNode.Attributes["id"] != null)
                {
                    if (referenceLevelEqualsZeroNode.Attributes["id"] != null)
                    {
                        referenceLevelEqualsZeroIDRef_ = referenceLevelEqualsZeroNode.Attributes["id"].Value;
                        XsdTypeBoolean ob = new XsdTypeBoolean(referenceLevelEqualsZeroNode);
                        IDManager.SetID(referenceLevelEqualsZeroIDRef_, ob);
                    }
                    else if (referenceLevelEqualsZeroNode.Attributes["href"] != null)
                    {
                        referenceLevelEqualsZeroIDRef_ = referenceLevelEqualsZeroNode.Attributes["href"].Value;
                    }
                    else
                    {
                        referenceLevelEqualsZero_ = new XsdTypeBoolean(referenceLevelEqualsZeroNode);
                    }
                }
                else
                {
                    referenceLevelEqualsZero_ = new XsdTypeBoolean(referenceLevelEqualsZeroNode);
                }
            }


            XmlNode calculationDateNode = xmlNode.SelectSingleNode("calculationDate");

            if (calculationDateNode != null)
            {
                if (calculationDateNode.Attributes["href"] != null || calculationDateNode.Attributes["id"] != null)
                {
                    if (calculationDateNode.Attributes["id"] != null)
                    {
                        calculationDateIDRef_ = calculationDateNode.Attributes["id"].Value;
                        Period ob = new Period(calculationDateNode);
                        IDManager.SetID(calculationDateIDRef_, ob);
                    }
                    else if (calculationDateNode.Attributes["href"] != null)
                    {
                        calculationDateIDRef_ = calculationDateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        calculationDate_ = new Period(calculationDateNode);
                    }
                }
                else
                {
                    calculationDate_ = new Period(calculationDateNode);
                }
            }


            XmlNode businessDaysNode = xmlNode.SelectSingleNode("businessDays");

            if (businessDaysNode != null)
            {
                if (businessDaysNode.Attributes["href"] != null || businessDaysNode.Attributes["id"] != null)
                {
                    if (businessDaysNode.Attributes["id"] != null)
                    {
                        businessDaysIDRef_ = businessDaysNode.Attributes["id"].Value;
                        BusinessCenter ob = new BusinessCenter(businessDaysNode);
                        IDManager.SetID(businessDaysIDRef_, ob);
                    }
                    else if (businessDaysNode.Attributes["href"] != null)
                    {
                        businessDaysIDRef_ = businessDaysNode.Attributes["href"].Value;
                    }
                    else
                    {
                        businessDays_ = new BusinessCenter(businessDaysNode);
                    }
                }
                else
                {
                    businessDays_ = new BusinessCenter(businessDaysNode);
                }
            }


            XmlNode dataCorrectionNode = xmlNode.SelectSingleNode("dataCorrection");

            if (dataCorrectionNode != null)
            {
                if (dataCorrectionNode.Attributes["href"] != null || dataCorrectionNode.Attributes["id"] != null)
                {
                    if (dataCorrectionNode.Attributes["id"] != null)
                    {
                        dataCorrectionIDRef_ = dataCorrectionNode.Attributes["id"].Value;
                        XsdTypeBoolean ob = new XsdTypeBoolean(dataCorrectionNode);
                        IDManager.SetID(dataCorrectionIDRef_, ob);
                    }
                    else if (dataCorrectionNode.Attributes["href"] != null)
                    {
                        dataCorrectionIDRef_ = dataCorrectionNode.Attributes["href"].Value;
                    }
                    else
                    {
                        dataCorrection_ = new XsdTypeBoolean(dataCorrectionNode);
                    }
                }
                else
                {
                    dataCorrection_ = new XsdTypeBoolean(dataCorrectionNode);
                }
            }


            XmlNode correctionPeriodNode = xmlNode.SelectSingleNode("correctionPeriod");

            if (correctionPeriodNode != null)
            {
                if (correctionPeriodNode.Attributes["href"] != null || correctionPeriodNode.Attributes["id"] != null)
                {
                    if (correctionPeriodNode.Attributes["id"] != null)
                    {
                        correctionPeriodIDRef_ = correctionPeriodNode.Attributes["id"].Value;
                        Period ob = new Period(correctionPeriodNode);
                        IDManager.SetID(correctionPeriodIDRef_, ob);
                    }
                    else if (correctionPeriodNode.Attributes["href"] != null)
                    {
                        correctionPeriodIDRef_ = correctionPeriodNode.Attributes["href"].Value;
                    }
                    else
                    {
                        correctionPeriod_ = new Period(correctionPeriodNode);
                    }
                }
                else
                {
                    correctionPeriod_ = new Period(correctionPeriodNode);
                }
            }


            XmlNode maximumPaymentAmountNode = xmlNode.SelectSingleNode("maximumPaymentAmount");

            if (maximumPaymentAmountNode != null)
            {
                if (maximumPaymentAmountNode.Attributes["href"] != null || maximumPaymentAmountNode.Attributes["id"] != null)
                {
                    if (maximumPaymentAmountNode.Attributes["id"] != null)
                    {
                        maximumPaymentAmountIDRef_ = maximumPaymentAmountNode.Attributes["id"].Value;
                        NonNegativeMoney ob = new NonNegativeMoney(maximumPaymentAmountNode);
                        IDManager.SetID(maximumPaymentAmountIDRef_, ob);
                    }
                    else if (maximumPaymentAmountNode.Attributes["href"] != null)
                    {
                        maximumPaymentAmountIDRef_ = maximumPaymentAmountNode.Attributes["href"].Value;
                    }
                    else
                    {
                        maximumPaymentAmount_ = new NonNegativeMoney(maximumPaymentAmountNode);
                    }
                }
                else
                {
                    maximumPaymentAmount_ = new NonNegativeMoney(maximumPaymentAmountNode);
                }
            }


            XmlNode maximumTransactionPaymentAmountNode = xmlNode.SelectSingleNode("maximumTransactionPaymentAmount");

            if (maximumTransactionPaymentAmountNode != null)
            {
                if (maximumTransactionPaymentAmountNode.Attributes["href"] != null || maximumTransactionPaymentAmountNode.Attributes["id"] != null)
                {
                    if (maximumTransactionPaymentAmountNode.Attributes["id"] != null)
                    {
                        maximumTransactionPaymentAmountIDRef_ = maximumTransactionPaymentAmountNode.Attributes["id"].Value;
                        NonNegativeMoney ob = new NonNegativeMoney(maximumTransactionPaymentAmountNode);
                        IDManager.SetID(maximumTransactionPaymentAmountIDRef_, ob);
                    }
                    else if (maximumTransactionPaymentAmountNode.Attributes["href"] != null)
                    {
                        maximumTransactionPaymentAmountIDRef_ = maximumTransactionPaymentAmountNode.Attributes["href"].Value;
                    }
                    else
                    {
                        maximumTransactionPaymentAmount_ = new NonNegativeMoney(maximumTransactionPaymentAmountNode);
                    }
                }
                else
                {
                    maximumTransactionPaymentAmount_ = new NonNegativeMoney(maximumTransactionPaymentAmountNode);
                }
            }


            XmlNode roundingNode = xmlNode.SelectSingleNode("rounding");

            if (roundingNode != null)
            {
                if (roundingNode.Attributes["href"] != null || roundingNode.Attributes["id"] != null)
                {
                    if (roundingNode.Attributes["id"] != null)
                    {
                        roundingIDRef_ = roundingNode.Attributes["id"].Value;
                        Rounding ob = new Rounding(roundingNode);
                        IDManager.SetID(roundingIDRef_, ob);
                    }
                    else if (roundingNode.Attributes["href"] != null)
                    {
                        roundingIDRef_ = roundingNode.Attributes["href"].Value;
                    }
                    else
                    {
                        rounding_ = new Rounding(roundingNode);
                    }
                }
                else
                {
                    rounding_ = new Rounding(roundingNode);
                }
            }
        }