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));
             }
         }
     }
     
 
 }
示例#2
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 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);
         }
     }
     
 
 }
        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 UnderlyingAsset(XmlNode xmlNode)
            : base(xmlNode)
        {
            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;
                        IdentifiedCurrency ob = new IdentifiedCurrency(currencyNode);
                        IDManager.SetID(currencyIDRef_, ob);
                    }
                    else if (currencyNode.Attributes["href"] != null)
                    {
                        currencyIDRef_ = currencyNode.Attributes["href"].Value;
                    }
                    else
                    {
                        currency_ = new IdentifiedCurrency(currencyNode);
                    }
                }
                else
                {
                    currency_ = new IdentifiedCurrency(currencyNode);
                }
            }


            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);
                }
            }


            XmlNode clearanceSystemNode = xmlNode.SelectSingleNode("clearanceSystem");

            if (clearanceSystemNode != null)
            {
                if (clearanceSystemNode.Attributes["href"] != null || clearanceSystemNode.Attributes["id"] != null)
                {
                    if (clearanceSystemNode.Attributes["id"] != null)
                    {
                        clearanceSystemIDRef_ = clearanceSystemNode.Attributes["id"].Value;
                        ClearanceSystem ob = new ClearanceSystem(clearanceSystemNode);
                        IDManager.SetID(clearanceSystemIDRef_, ob);
                    }
                    else if (clearanceSystemNode.Attributes["href"] != null)
                    {
                        clearanceSystemIDRef_ = clearanceSystemNode.Attributes["href"].Value;
                    }
                    else
                    {
                        clearanceSystem_ = new ClearanceSystem(clearanceSystemNode);
                    }
                }
                else
                {
                    clearanceSystem_ = new ClearanceSystem(clearanceSystemNode);
                }
            }


            XmlNode definitionNode = xmlNode.SelectSingleNode("definition");

            if (definitionNode != null)
            {
                if (definitionNode.Attributes["href"] != null || definitionNode.Attributes["id"] != null)
                {
                    if (definitionNode.Attributes["id"] != null)
                    {
                        definitionIDRef_ = definitionNode.Attributes["id"].Value;
                        ProductReference ob = new ProductReference(definitionNode);
                        IDManager.SetID(definitionIDRef_, ob);
                    }
                    else if (definitionNode.Attributes["href"] != null)
                    {
                        definitionIDRef_ = definitionNode.Attributes["href"].Value;
                    }
                    else
                    {
                        definition_ = new ProductReference(definitionNode);
                    }
                }
                else
                {
                    definition_ = new ProductReference(definitionNode);
                }
            }
        }
 public Commodity(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNodeList commodityBaseNodeList = xmlNode.SelectNodes("commodityBase");
     if (commodityBaseNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityBaseNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityBaseIDRef = item.Attributes["id"].Name;
                 CommodityBase ob = CommodityBase();
                 IDManager.SetID(commodityBaseIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityBaseIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityBase = new CommodityBase(item);
             }
         }
     }
     
 
     XmlNodeList commodityDetailsNodeList = xmlNode.SelectNodes("commodityDetails");
     if (commodityDetailsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityDetailsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityDetailsIDRef = item.Attributes["id"].Name;
                 CommodityDetails ob = CommodityDetails();
                 IDManager.SetID(commodityDetailsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityDetailsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityDetails = new CommodityDetails(item);
             }
         }
     }
     
 
     XmlNodeList unitNodeList = xmlNode.SelectNodes("unit");
     if (unitNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in unitNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 unitIDRef = item.Attributes["id"].Name;
                 QuantityUnit ob = QuantityUnit();
                 IDManager.SetID(unitIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 unitIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 unit = new QuantityUnit(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 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 publicationNodeList = xmlNode.SelectNodes("publication");
     if (publicationNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in publicationNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 publicationIDRef = item.Attributes["id"].Name;
                 CommodityInformationSource ob = CommodityInformationSource();
                 IDManager.SetID(publicationIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 publicationIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 publication = new CommodityInformationSource(item);
             }
         }
     }
     
 
     XmlNodeList specifiedPriceNodeList = xmlNode.SelectNodes("specifiedPrice");
     if (specifiedPriceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in specifiedPriceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 specifiedPriceIDRef = item.Attributes["id"].Name;
                 SpecifiedPriceEnum ob = SpecifiedPriceEnum();
                 IDManager.SetID(specifiedPriceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 specifiedPriceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 specifiedPrice = new SpecifiedPriceEnum(item);
             }
         }
     }
     
 
     XmlNodeList deliveryDatesNodeList = xmlNode.SelectNodes("deliveryDates");
     if (deliveryDatesNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in deliveryDatesNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 deliveryDatesIDRef = item.Attributes["id"].Name;
                 DeliveryDatesEnum ob = DeliveryDatesEnum();
                 IDManager.SetID(deliveryDatesIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 deliveryDatesIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 deliveryDates = new DeliveryDatesEnum(item);
             }
         }
     }
     
 
     XmlNodeList deliveryDateNodeList = xmlNode.SelectNodes("deliveryDate");
     if (deliveryDateNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in deliveryDateNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 deliveryDateIDRef = item.Attributes["id"].Name;
                 AdjustableDate ob = AdjustableDate();
                 IDManager.SetID(deliveryDateIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 deliveryDateIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 deliveryDate = new AdjustableDate(item);
             }
         }
     }
     
 
     XmlNodeList deliveryDateYearMonthNodeList = xmlNode.SelectNodes("deliveryDateYearMonth");
     if (deliveryDateYearMonthNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in deliveryDateYearMonthNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 deliveryDateYearMonthIDRef = item.Attributes["id"].Name;
                 XsdTypeGYearMonth ob = XsdTypeGYearMonth();
                 IDManager.SetID(deliveryDateYearMonthIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 deliveryDateYearMonthIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 deliveryDateYearMonth = new XsdTypeGYearMonth(item);
             }
         }
     }
     
 
     XmlNodeList deliveryDateRollConventionNodeList = xmlNode.SelectNodes("deliveryDateRollConvention");
     if (deliveryDateRollConventionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in deliveryDateRollConventionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 deliveryDateRollConventionIDRef = item.Attributes["id"].Name;
                 Offset ob = Offset();
                 IDManager.SetID(deliveryDateRollConventionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 deliveryDateRollConventionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 deliveryDateRollConvention = new Offset(item);
             }
         }
     }
     
 
     XmlNodeList multiplierNodeList = xmlNode.SelectNodes("multiplier");
     if (multiplierNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in multiplierNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 multiplierIDRef = item.Attributes["id"].Name;
                 PositiveDecimal ob = PositiveDecimal();
                 IDManager.SetID(multiplierIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 multiplierIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 multiplier = new PositiveDecimal(item);
             }
         }
     }
     
 
 }
        public UnderlyingAsset(XmlNode xmlNode)
            : base(xmlNode)
        {
            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;
                        IdentifiedCurrency ob = IdentifiedCurrency();
                        IDManager.SetID(currencyIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        currencyIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        currency = new IdentifiedCurrency(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 clearanceSystemNodeList = xmlNode.SelectNodes("clearanceSystem");

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

            foreach (XmlNode item in clearanceSystemNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        clearanceSystemIDRef = item.Attributes["id"].Name;
                        ClearanceSystem ob = ClearanceSystem();
                        IDManager.SetID(clearanceSystemIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        clearanceSystemIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        clearanceSystem = new ClearanceSystem(item);
                    }
                }
            }


            XmlNodeList definitionNodeList = xmlNode.SelectNodes("definition");

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

            foreach (XmlNode item in definitionNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        definitionIDRef = item.Attributes["id"].Name;
                        ProductReference ob = ProductReference();
                        IDManager.SetID(definitionIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        definitionIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        definition = new ProductReference(item);
                    }
                }
            }
        }
 public UnderlyingAsset(XmlNode xmlNode)
 : base(xmlNode)
 {
     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;
                 IdentifiedCurrency ob = IdentifiedCurrency();
                 IDManager.SetID(currencyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 currencyIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 currency = new IdentifiedCurrency(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 clearanceSystemNodeList = xmlNode.SelectNodes("clearanceSystem");
     if (clearanceSystemNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in clearanceSystemNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 clearanceSystemIDRef = item.Attributes["id"].Name;
                 ClearanceSystem ob = ClearanceSystem();
                 IDManager.SetID(clearanceSystemIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 clearanceSystemIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 clearanceSystem = new ClearanceSystem(item);
             }
         }
     }
     
 
     XmlNodeList definitionNodeList = xmlNode.SelectNodes("definition");
     if (definitionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in definitionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 definitionIDRef = item.Attributes["id"].Name;
                 ProductReference ob = ProductReference();
                 IDManager.SetID(definitionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 definitionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 definition = new ProductReference(item);
             }
         }
     }
     
 
 }
        public Commodity(XmlNode xmlNode)
            : base(xmlNode)
        {
            XmlNode commodityBaseNode = xmlNode.SelectSingleNode("commodityBase");

            if (commodityBaseNode != null)
            {
                if (commodityBaseNode.Attributes["href"] != null || commodityBaseNode.Attributes["id"] != null)
                {
                    if (commodityBaseNode.Attributes["id"] != null)
                    {
                        commodityBaseIDRef_ = commodityBaseNode.Attributes["id"].Value;
                        CommodityBase ob = new CommodityBase(commodityBaseNode);
                        IDManager.SetID(commodityBaseIDRef_, ob);
                    }
                    else if (commodityBaseNode.Attributes["href"] != null)
                    {
                        commodityBaseIDRef_ = commodityBaseNode.Attributes["href"].Value;
                    }
                    else
                    {
                        commodityBase_ = new CommodityBase(commodityBaseNode);
                    }
                }
                else
                {
                    commodityBase_ = new CommodityBase(commodityBaseNode);
                }
            }


            XmlNode commodityDetailsNode = xmlNode.SelectSingleNode("commodityDetails");

            if (commodityDetailsNode != null)
            {
                if (commodityDetailsNode.Attributes["href"] != null || commodityDetailsNode.Attributes["id"] != null)
                {
                    if (commodityDetailsNode.Attributes["id"] != null)
                    {
                        commodityDetailsIDRef_ = commodityDetailsNode.Attributes["id"].Value;
                        CommodityDetails ob = new CommodityDetails(commodityDetailsNode);
                        IDManager.SetID(commodityDetailsIDRef_, ob);
                    }
                    else if (commodityDetailsNode.Attributes["href"] != null)
                    {
                        commodityDetailsIDRef_ = commodityDetailsNode.Attributes["href"].Value;
                    }
                    else
                    {
                        commodityDetails_ = new CommodityDetails(commodityDetailsNode);
                    }
                }
                else
                {
                    commodityDetails_ = new CommodityDetails(commodityDetailsNode);
                }
            }


            XmlNode unitNode = xmlNode.SelectSingleNode("unit");

            if (unitNode != null)
            {
                if (unitNode.Attributes["href"] != null || unitNode.Attributes["id"] != null)
                {
                    if (unitNode.Attributes["id"] != null)
                    {
                        unitIDRef_ = unitNode.Attributes["id"].Value;
                        QuantityUnit ob = new QuantityUnit(unitNode);
                        IDManager.SetID(unitIDRef_, ob);
                    }
                    else if (unitNode.Attributes["href"] != null)
                    {
                        unitIDRef_ = unitNode.Attributes["href"].Value;
                    }
                    else
                    {
                        unit_ = new QuantityUnit(unitNode);
                    }
                }
                else
                {
                    unit_ = new QuantityUnit(unitNode);
                }
            }


            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 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);
                }
            }


            XmlNode publicationNode = xmlNode.SelectSingleNode("publication");

            if (publicationNode != null)
            {
                if (publicationNode.Attributes["href"] != null || publicationNode.Attributes["id"] != null)
                {
                    if (publicationNode.Attributes["id"] != null)
                    {
                        publicationIDRef_ = publicationNode.Attributes["id"].Value;
                        CommodityInformationSource ob = new CommodityInformationSource(publicationNode);
                        IDManager.SetID(publicationIDRef_, ob);
                    }
                    else if (publicationNode.Attributes["href"] != null)
                    {
                        publicationIDRef_ = publicationNode.Attributes["href"].Value;
                    }
                    else
                    {
                        publication_ = new CommodityInformationSource(publicationNode);
                    }
                }
                else
                {
                    publication_ = new CommodityInformationSource(publicationNode);
                }
            }


            XmlNode specifiedPriceNode = xmlNode.SelectSingleNode("specifiedPrice");

            if (specifiedPriceNode != null)
            {
                if (specifiedPriceNode.Attributes["href"] != null || specifiedPriceNode.Attributes["id"] != null)
                {
                    if (specifiedPriceNode.Attributes["id"] != null)
                    {
                        specifiedPriceIDRef_ = specifiedPriceNode.Attributes["id"].Value;
                        SpecifiedPriceEnum ob = new SpecifiedPriceEnum(specifiedPriceNode);
                        IDManager.SetID(specifiedPriceIDRef_, ob);
                    }
                    else if (specifiedPriceNode.Attributes["href"] != null)
                    {
                        specifiedPriceIDRef_ = specifiedPriceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        specifiedPrice_ = new SpecifiedPriceEnum(specifiedPriceNode);
                    }
                }
                else
                {
                    specifiedPrice_ = new SpecifiedPriceEnum(specifiedPriceNode);
                }
            }


            XmlNode deliveryDatesNode = xmlNode.SelectSingleNode("deliveryDates");

            if (deliveryDatesNode != null)
            {
                if (deliveryDatesNode.Attributes["href"] != null || deliveryDatesNode.Attributes["id"] != null)
                {
                    if (deliveryDatesNode.Attributes["id"] != null)
                    {
                        deliveryDatesIDRef_ = deliveryDatesNode.Attributes["id"].Value;
                        DeliveryDatesEnum ob = new DeliveryDatesEnum(deliveryDatesNode);
                        IDManager.SetID(deliveryDatesIDRef_, ob);
                    }
                    else if (deliveryDatesNode.Attributes["href"] != null)
                    {
                        deliveryDatesIDRef_ = deliveryDatesNode.Attributes["href"].Value;
                    }
                    else
                    {
                        deliveryDates_ = new DeliveryDatesEnum(deliveryDatesNode);
                    }
                }
                else
                {
                    deliveryDates_ = new DeliveryDatesEnum(deliveryDatesNode);
                }
            }


            XmlNode deliveryDateNode = xmlNode.SelectSingleNode("deliveryDate");

            if (deliveryDateNode != null)
            {
                if (deliveryDateNode.Attributes["href"] != null || deliveryDateNode.Attributes["id"] != null)
                {
                    if (deliveryDateNode.Attributes["id"] != null)
                    {
                        deliveryDateIDRef_ = deliveryDateNode.Attributes["id"].Value;
                        AdjustableDate ob = new AdjustableDate(deliveryDateNode);
                        IDManager.SetID(deliveryDateIDRef_, ob);
                    }
                    else if (deliveryDateNode.Attributes["href"] != null)
                    {
                        deliveryDateIDRef_ = deliveryDateNode.Attributes["href"].Value;
                    }
                    else
                    {
                        deliveryDate_ = new AdjustableDate(deliveryDateNode);
                    }
                }
                else
                {
                    deliveryDate_ = new AdjustableDate(deliveryDateNode);
                }
            }


            XmlNode deliveryDateYearMonthNode = xmlNode.SelectSingleNode("deliveryDateYearMonth");

            if (deliveryDateYearMonthNode != null)
            {
                if (deliveryDateYearMonthNode.Attributes["href"] != null || deliveryDateYearMonthNode.Attributes["id"] != null)
                {
                    if (deliveryDateYearMonthNode.Attributes["id"] != null)
                    {
                        deliveryDateYearMonthIDRef_ = deliveryDateYearMonthNode.Attributes["id"].Value;
                        XsdTypeGYearMonth ob = new XsdTypeGYearMonth(deliveryDateYearMonthNode);
                        IDManager.SetID(deliveryDateYearMonthIDRef_, ob);
                    }
                    else if (deliveryDateYearMonthNode.Attributes["href"] != null)
                    {
                        deliveryDateYearMonthIDRef_ = deliveryDateYearMonthNode.Attributes["href"].Value;
                    }
                    else
                    {
                        deliveryDateYearMonth_ = new XsdTypeGYearMonth(deliveryDateYearMonthNode);
                    }
                }
                else
                {
                    deliveryDateYearMonth_ = new XsdTypeGYearMonth(deliveryDateYearMonthNode);
                }
            }


            XmlNode deliveryDateRollConventionNode = xmlNode.SelectSingleNode("deliveryDateRollConvention");

            if (deliveryDateRollConventionNode != null)
            {
                if (deliveryDateRollConventionNode.Attributes["href"] != null || deliveryDateRollConventionNode.Attributes["id"] != null)
                {
                    if (deliveryDateRollConventionNode.Attributes["id"] != null)
                    {
                        deliveryDateRollConventionIDRef_ = deliveryDateRollConventionNode.Attributes["id"].Value;
                        Offset ob = new Offset(deliveryDateRollConventionNode);
                        IDManager.SetID(deliveryDateRollConventionIDRef_, ob);
                    }
                    else if (deliveryDateRollConventionNode.Attributes["href"] != null)
                    {
                        deliveryDateRollConventionIDRef_ = deliveryDateRollConventionNode.Attributes["href"].Value;
                    }
                    else
                    {
                        deliveryDateRollConvention_ = new Offset(deliveryDateRollConventionNode);
                    }
                }
                else
                {
                    deliveryDateRollConvention_ = new Offset(deliveryDateRollConventionNode);
                }
            }


            XmlNode multiplierNode = xmlNode.SelectSingleNode("multiplier");

            if (multiplierNode != null)
            {
                if (multiplierNode.Attributes["href"] != null || multiplierNode.Attributes["id"] != null)
                {
                    if (multiplierNode.Attributes["id"] != null)
                    {
                        multiplierIDRef_ = multiplierNode.Attributes["id"].Value;
                        PositiveDecimal ob = new PositiveDecimal(multiplierNode);
                        IDManager.SetID(multiplierIDRef_, ob);
                    }
                    else if (multiplierNode.Attributes["href"] != null)
                    {
                        multiplierIDRef_ = multiplierNode.Attributes["href"].Value;
                    }
                    else
                    {
                        multiplier_ = new PositiveDecimal(multiplierNode);
                    }
                }
                else
                {
                    multiplier_ = new PositiveDecimal(multiplierNode);
                }
            }
        }
 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 Commodity(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNode commodityBaseNode = xmlNode.SelectSingleNode("commodityBase");
     
     if (commodityBaseNode != null)
     {
         if (commodityBaseNode.Attributes["href"] != null || commodityBaseNode.Attributes["id"] != null) 
         {
             if (commodityBaseNode.Attributes["id"] != null) 
             {
                 commodityBaseIDRef_ = commodityBaseNode.Attributes["id"].Value;
                 CommodityBase ob = new CommodityBase(commodityBaseNode);
                 IDManager.SetID(commodityBaseIDRef_, ob);
             }
             else if (commodityBaseNode.Attributes["href"] != null)
             {
                 commodityBaseIDRef_ = commodityBaseNode.Attributes["href"].Value;
             }
             else
             {
                 commodityBase_ = new CommodityBase(commodityBaseNode);
             }
         }
         else
         {
             commodityBase_ = new CommodityBase(commodityBaseNode);
         }
     }
     
 
     XmlNode commodityDetailsNode = xmlNode.SelectSingleNode("commodityDetails");
     
     if (commodityDetailsNode != null)
     {
         if (commodityDetailsNode.Attributes["href"] != null || commodityDetailsNode.Attributes["id"] != null) 
         {
             if (commodityDetailsNode.Attributes["id"] != null) 
             {
                 commodityDetailsIDRef_ = commodityDetailsNode.Attributes["id"].Value;
                 CommodityDetails ob = new CommodityDetails(commodityDetailsNode);
                 IDManager.SetID(commodityDetailsIDRef_, ob);
             }
             else if (commodityDetailsNode.Attributes["href"] != null)
             {
                 commodityDetailsIDRef_ = commodityDetailsNode.Attributes["href"].Value;
             }
             else
             {
                 commodityDetails_ = new CommodityDetails(commodityDetailsNode);
             }
         }
         else
         {
             commodityDetails_ = new CommodityDetails(commodityDetailsNode);
         }
     }
     
 
     XmlNode unitNode = xmlNode.SelectSingleNode("unit");
     
     if (unitNode != null)
     {
         if (unitNode.Attributes["href"] != null || unitNode.Attributes["id"] != null) 
         {
             if (unitNode.Attributes["id"] != null) 
             {
                 unitIDRef_ = unitNode.Attributes["id"].Value;
                 QuantityUnit ob = new QuantityUnit(unitNode);
                 IDManager.SetID(unitIDRef_, ob);
             }
             else if (unitNode.Attributes["href"] != null)
             {
                 unitIDRef_ = unitNode.Attributes["href"].Value;
             }
             else
             {
                 unit_ = new QuantityUnit(unitNode);
             }
         }
         else
         {
             unit_ = new QuantityUnit(unitNode);
         }
     }
     
 
     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 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);
         }
     }
     
 
     XmlNode publicationNode = xmlNode.SelectSingleNode("publication");
     
     if (publicationNode != null)
     {
         if (publicationNode.Attributes["href"] != null || publicationNode.Attributes["id"] != null) 
         {
             if (publicationNode.Attributes["id"] != null) 
             {
                 publicationIDRef_ = publicationNode.Attributes["id"].Value;
                 CommodityInformationSource ob = new CommodityInformationSource(publicationNode);
                 IDManager.SetID(publicationIDRef_, ob);
             }
             else if (publicationNode.Attributes["href"] != null)
             {
                 publicationIDRef_ = publicationNode.Attributes["href"].Value;
             }
             else
             {
                 publication_ = new CommodityInformationSource(publicationNode);
             }
         }
         else
         {
             publication_ = new CommodityInformationSource(publicationNode);
         }
     }
     
 
     XmlNode specifiedPriceNode = xmlNode.SelectSingleNode("specifiedPrice");
     
     if (specifiedPriceNode != null)
     {
         if (specifiedPriceNode.Attributes["href"] != null || specifiedPriceNode.Attributes["id"] != null) 
         {
             if (specifiedPriceNode.Attributes["id"] != null) 
             {
                 specifiedPriceIDRef_ = specifiedPriceNode.Attributes["id"].Value;
                 SpecifiedPriceEnum ob = new SpecifiedPriceEnum(specifiedPriceNode);
                 IDManager.SetID(specifiedPriceIDRef_, ob);
             }
             else if (specifiedPriceNode.Attributes["href"] != null)
             {
                 specifiedPriceIDRef_ = specifiedPriceNode.Attributes["href"].Value;
             }
             else
             {
                 specifiedPrice_ = new SpecifiedPriceEnum(specifiedPriceNode);
             }
         }
         else
         {
             specifiedPrice_ = new SpecifiedPriceEnum(specifiedPriceNode);
         }
     }
     
 
     XmlNode deliveryDatesNode = xmlNode.SelectSingleNode("deliveryDates");
     
     if (deliveryDatesNode != null)
     {
         if (deliveryDatesNode.Attributes["href"] != null || deliveryDatesNode.Attributes["id"] != null) 
         {
             if (deliveryDatesNode.Attributes["id"] != null) 
             {
                 deliveryDatesIDRef_ = deliveryDatesNode.Attributes["id"].Value;
                 DeliveryDatesEnum ob = new DeliveryDatesEnum(deliveryDatesNode);
                 IDManager.SetID(deliveryDatesIDRef_, ob);
             }
             else if (deliveryDatesNode.Attributes["href"] != null)
             {
                 deliveryDatesIDRef_ = deliveryDatesNode.Attributes["href"].Value;
             }
             else
             {
                 deliveryDates_ = new DeliveryDatesEnum(deliveryDatesNode);
             }
         }
         else
         {
             deliveryDates_ = new DeliveryDatesEnum(deliveryDatesNode);
         }
     }
     
 
     XmlNode deliveryDateNode = xmlNode.SelectSingleNode("deliveryDate");
     
     if (deliveryDateNode != null)
     {
         if (deliveryDateNode.Attributes["href"] != null || deliveryDateNode.Attributes["id"] != null) 
         {
             if (deliveryDateNode.Attributes["id"] != null) 
             {
                 deliveryDateIDRef_ = deliveryDateNode.Attributes["id"].Value;
                 AdjustableDate ob = new AdjustableDate(deliveryDateNode);
                 IDManager.SetID(deliveryDateIDRef_, ob);
             }
             else if (deliveryDateNode.Attributes["href"] != null)
             {
                 deliveryDateIDRef_ = deliveryDateNode.Attributes["href"].Value;
             }
             else
             {
                 deliveryDate_ = new AdjustableDate(deliveryDateNode);
             }
         }
         else
         {
             deliveryDate_ = new AdjustableDate(deliveryDateNode);
         }
     }
     
 
     XmlNode deliveryDateYearMonthNode = xmlNode.SelectSingleNode("deliveryDateYearMonth");
     
     if (deliveryDateYearMonthNode != null)
     {
         if (deliveryDateYearMonthNode.Attributes["href"] != null || deliveryDateYearMonthNode.Attributes["id"] != null) 
         {
             if (deliveryDateYearMonthNode.Attributes["id"] != null) 
             {
                 deliveryDateYearMonthIDRef_ = deliveryDateYearMonthNode.Attributes["id"].Value;
                 XsdTypeGYearMonth ob = new XsdTypeGYearMonth(deliveryDateYearMonthNode);
                 IDManager.SetID(deliveryDateYearMonthIDRef_, ob);
             }
             else if (deliveryDateYearMonthNode.Attributes["href"] != null)
             {
                 deliveryDateYearMonthIDRef_ = deliveryDateYearMonthNode.Attributes["href"].Value;
             }
             else
             {
                 deliveryDateYearMonth_ = new XsdTypeGYearMonth(deliveryDateYearMonthNode);
             }
         }
         else
         {
             deliveryDateYearMonth_ = new XsdTypeGYearMonth(deliveryDateYearMonthNode);
         }
     }
     
 
     XmlNode deliveryDateRollConventionNode = xmlNode.SelectSingleNode("deliveryDateRollConvention");
     
     if (deliveryDateRollConventionNode != null)
     {
         if (deliveryDateRollConventionNode.Attributes["href"] != null || deliveryDateRollConventionNode.Attributes["id"] != null) 
         {
             if (deliveryDateRollConventionNode.Attributes["id"] != null) 
             {
                 deliveryDateRollConventionIDRef_ = deliveryDateRollConventionNode.Attributes["id"].Value;
                 Offset ob = new Offset(deliveryDateRollConventionNode);
                 IDManager.SetID(deliveryDateRollConventionIDRef_, ob);
             }
             else if (deliveryDateRollConventionNode.Attributes["href"] != null)
             {
                 deliveryDateRollConventionIDRef_ = deliveryDateRollConventionNode.Attributes["href"].Value;
             }
             else
             {
                 deliveryDateRollConvention_ = new Offset(deliveryDateRollConventionNode);
             }
         }
         else
         {
             deliveryDateRollConvention_ = new Offset(deliveryDateRollConventionNode);
         }
     }
     
 
     XmlNode multiplierNode = xmlNode.SelectSingleNode("multiplier");
     
     if (multiplierNode != null)
     {
         if (multiplierNode.Attributes["href"] != null || multiplierNode.Attributes["id"] != null) 
         {
             if (multiplierNode.Attributes["id"] != null) 
             {
                 multiplierIDRef_ = multiplierNode.Attributes["id"].Value;
                 PositiveDecimal ob = new PositiveDecimal(multiplierNode);
                 IDManager.SetID(multiplierIDRef_, ob);
             }
             else if (multiplierNode.Attributes["href"] != null)
             {
                 multiplierIDRef_ = multiplierNode.Attributes["href"].Value;
             }
             else
             {
                 multiplier_ = new PositiveDecimal(multiplierNode);
             }
         }
         else
         {
             multiplier_ = new PositiveDecimal(multiplierNode);
         }
     }
     
 
 }
示例#12
0
        public Commodity(XmlNode xmlNode)
            : base(xmlNode)
        {
            XmlNodeList commodityBaseNodeList = xmlNode.SelectNodes("commodityBase");

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

            foreach (XmlNode item in commodityBaseNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        commodityBaseIDRef = item.Attributes["id"].Name;
                        CommodityBase ob = CommodityBase();
                        IDManager.SetID(commodityBaseIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        commodityBaseIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        commodityBase = new CommodityBase(item);
                    }
                }
            }


            XmlNodeList commodityDetailsNodeList = xmlNode.SelectNodes("commodityDetails");

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

            foreach (XmlNode item in commodityDetailsNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        commodityDetailsIDRef = item.Attributes["id"].Name;
                        CommodityDetails ob = CommodityDetails();
                        IDManager.SetID(commodityDetailsIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        commodityDetailsIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        commodityDetails = new CommodityDetails(item);
                    }
                }
            }


            XmlNodeList unitNodeList = xmlNode.SelectNodes("unit");

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

            foreach (XmlNode item in unitNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        unitIDRef = item.Attributes["id"].Name;
                        QuantityUnit ob = QuantityUnit();
                        IDManager.SetID(unitIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        unitIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        unit = new QuantityUnit(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 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 publicationNodeList = xmlNode.SelectNodes("publication");

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

            foreach (XmlNode item in publicationNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        publicationIDRef = item.Attributes["id"].Name;
                        CommodityInformationSource ob = CommodityInformationSource();
                        IDManager.SetID(publicationIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        publicationIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        publication = new CommodityInformationSource(item);
                    }
                }
            }


            XmlNodeList specifiedPriceNodeList = xmlNode.SelectNodes("specifiedPrice");

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

            foreach (XmlNode item in specifiedPriceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        specifiedPriceIDRef = item.Attributes["id"].Name;
                        SpecifiedPriceEnum ob = SpecifiedPriceEnum();
                        IDManager.SetID(specifiedPriceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        specifiedPriceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        specifiedPrice = new SpecifiedPriceEnum(item);
                    }
                }
            }


            XmlNodeList deliveryDatesNodeList = xmlNode.SelectNodes("deliveryDates");

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

            foreach (XmlNode item in deliveryDatesNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        deliveryDatesIDRef = item.Attributes["id"].Name;
                        DeliveryDatesEnum ob = DeliveryDatesEnum();
                        IDManager.SetID(deliveryDatesIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        deliveryDatesIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        deliveryDates = new DeliveryDatesEnum(item);
                    }
                }
            }


            XmlNodeList deliveryDateNodeList = xmlNode.SelectNodes("deliveryDate");

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

            foreach (XmlNode item in deliveryDateNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        deliveryDateIDRef = item.Attributes["id"].Name;
                        AdjustableDate ob = AdjustableDate();
                        IDManager.SetID(deliveryDateIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        deliveryDateIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        deliveryDate = new AdjustableDate(item);
                    }
                }
            }


            XmlNodeList deliveryDateYearMonthNodeList = xmlNode.SelectNodes("deliveryDateYearMonth");

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

            foreach (XmlNode item in deliveryDateYearMonthNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        deliveryDateYearMonthIDRef = item.Attributes["id"].Name;
                        XsdTypeGYearMonth ob = XsdTypeGYearMonth();
                        IDManager.SetID(deliveryDateYearMonthIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        deliveryDateYearMonthIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        deliveryDateYearMonth = new XsdTypeGYearMonth(item);
                    }
                }
            }


            XmlNodeList deliveryDateRollConventionNodeList = xmlNode.SelectNodes("deliveryDateRollConvention");

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

            foreach (XmlNode item in deliveryDateRollConventionNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        deliveryDateRollConventionIDRef = item.Attributes["id"].Name;
                        Offset ob = Offset();
                        IDManager.SetID(deliveryDateRollConventionIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        deliveryDateRollConventionIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        deliveryDateRollConvention = new Offset(item);
                    }
                }
            }


            XmlNodeList multiplierNodeList = xmlNode.SelectNodes("multiplier");

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

            foreach (XmlNode item in multiplierNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        multiplierIDRef = item.Attributes["id"].Name;
                        PositiveDecimal ob = PositiveDecimal();
                        IDManager.SetID(multiplierIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        multiplierIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        multiplier = new PositiveDecimal(item);
                    }
                }
            }
        }
 public CurveInstrument(XmlNode xmlNode)
 : base(xmlNode)
 {
     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 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);
         }
     }
     
 
     XmlNode clearanceSystemNode = xmlNode.SelectSingleNode("clearanceSystem");
     
     if (clearanceSystemNode != null)
     {
         if (clearanceSystemNode.Attributes["href"] != null || clearanceSystemNode.Attributes["id"] != null) 
         {
             if (clearanceSystemNode.Attributes["id"] != null) 
             {
                 clearanceSystemIDRef_ = clearanceSystemNode.Attributes["id"].Value;
                 ClearanceSystem ob = new ClearanceSystem(clearanceSystemNode);
                 IDManager.SetID(clearanceSystemIDRef_, ob);
             }
             else if (clearanceSystemNode.Attributes["href"] != null)
             {
                 clearanceSystemIDRef_ = clearanceSystemNode.Attributes["href"].Value;
             }
             else
             {
                 clearanceSystem_ = new ClearanceSystem(clearanceSystemNode);
             }
         }
         else
         {
             clearanceSystem_ = new ClearanceSystem(clearanceSystemNode);
         }
     }
     
 
     XmlNode definitionNode = xmlNode.SelectSingleNode("definition");
     
     if (definitionNode != null)
     {
         if (definitionNode.Attributes["href"] != null || definitionNode.Attributes["id"] != null) 
         {
             if (definitionNode.Attributes["id"] != null) 
             {
                 definitionIDRef_ = definitionNode.Attributes["id"].Value;
                 ProductReference ob = new ProductReference(definitionNode);
                 IDManager.SetID(definitionIDRef_, ob);
             }
             else if (definitionNode.Attributes["href"] != null)
             {
                 definitionIDRef_ = definitionNode.Attributes["href"].Value;
             }
             else
             {
                 definition_ = new ProductReference(definitionNode);
             }
         }
         else
         {
             definition_ = new ProductReference(definitionNode);
         }
     }
     
 
 }
 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);
         }
     }
     
 
 }