public StrategyComponentIdentification(XmlNode xmlNode)
 {
     XmlNodeList tradeIdentifierReferenceNodeList = xmlNode.SelectNodes("tradeIdentifierReference");
     if (tradeIdentifierReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in tradeIdentifierReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 tradeIdentifierReferenceIDRef = item.Attributes["id"].Name;
                 PartyTradeIdentifierReference ob = PartyTradeIdentifierReference();
                 IDManager.SetID(tradeIdentifierReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 tradeIdentifierReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 tradeIdentifierReference = new PartyTradeIdentifierReference(item);
             }
         }
     }
     
 
     XmlNodeList componentReferenceNodeList = xmlNode.SelectNodes("componentReference");
     if (componentReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in componentReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 componentReferenceIDRef = item.Attributes["id"].Name;
                 ProductReference ob = ProductReference();
                 IDManager.SetID(componentReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 componentReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 componentReference = new ProductReference(item);
             }
         }
     }
     
 
 }
Пример #2
0
        public StrategyComponentIdentification(XmlNode xmlNode)
        {
            XmlNodeList tradeIdentifierReferenceNodeList = xmlNode.SelectNodes("tradeIdentifierReference");

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

            foreach (XmlNode item in tradeIdentifierReferenceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        tradeIdentifierReferenceIDRef = item.Attributes["id"].Name;
                        PartyTradeIdentifierReference ob = PartyTradeIdentifierReference();
                        IDManager.SetID(tradeIdentifierReferenceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        tradeIdentifierReferenceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        tradeIdentifierReference = new PartyTradeIdentifierReference(item);
                    }
                }
            }


            XmlNodeList componentReferenceNodeList = xmlNode.SelectNodes("componentReference");

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

            foreach (XmlNode item in componentReferenceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        componentReferenceIDRef = item.Attributes["id"].Name;
                        ProductReference ob = ProductReference();
                        IDManager.SetID(componentReferenceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        componentReferenceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        componentReference = new ProductReference(item);
                    }
                }
            }
        }
        public StrategyComponentIdentification(XmlNode xmlNode)
        {
            XmlNode tradeIdentifierReferenceNode = xmlNode.SelectSingleNode("tradeIdentifierReference");

            if (tradeIdentifierReferenceNode != null)
            {
                if (tradeIdentifierReferenceNode.Attributes["href"] != null || tradeIdentifierReferenceNode.Attributes["id"] != null)
                {
                    if (tradeIdentifierReferenceNode.Attributes["id"] != null)
                    {
                        tradeIdentifierReferenceIDRef_ = tradeIdentifierReferenceNode.Attributes["id"].Value;
                        PartyTradeIdentifierReference ob = new PartyTradeIdentifierReference(tradeIdentifierReferenceNode);
                        IDManager.SetID(tradeIdentifierReferenceIDRef_, ob);
                    }
                    else if (tradeIdentifierReferenceNode.Attributes["href"] != null)
                    {
                        tradeIdentifierReferenceIDRef_ = tradeIdentifierReferenceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        tradeIdentifierReference_ = new PartyTradeIdentifierReference(tradeIdentifierReferenceNode);
                    }
                }
                else
                {
                    tradeIdentifierReference_ = new PartyTradeIdentifierReference(tradeIdentifierReferenceNode);
                }
            }


            XmlNode componentReferenceNode = xmlNode.SelectSingleNode("componentReference");

            if (componentReferenceNode != null)
            {
                if (componentReferenceNode.Attributes["href"] != null || componentReferenceNode.Attributes["id"] != null)
                {
                    if (componentReferenceNode.Attributes["id"] != null)
                    {
                        componentReferenceIDRef_ = componentReferenceNode.Attributes["id"].Value;
                        ProductReference ob = new ProductReference(componentReferenceNode);
                        IDManager.SetID(componentReferenceIDRef_, ob);
                    }
                    else if (componentReferenceNode.Attributes["href"] != null)
                    {
                        componentReferenceIDRef_ = componentReferenceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        componentReference_ = new ProductReference(componentReferenceNode);
                    }
                }
                else
                {
                    componentReference_ = new ProductReference(componentReferenceNode);
                }
            }
        }
        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 Strategy(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNodeList strategyComponentIdentifierNodeList = xmlNode.SelectNodes("strategyComponentIdentifier");
     
     foreach (XmlNode item in strategyComponentIdentifierNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 strategyComponentIdentifierIDRef = item.Attributes["id"].Name;
                 List<StrategyComponentIdentification> ob = new List<StrategyComponentIdentification>();
                 ob.Add(new StrategyComponentIdentification(item));
                 IDManager.SetID(strategyComponentIdentifierIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 strategyComponentIdentifierIDRef = item.Attributes["href"].Name;
             }
             else
             {
             strategyComponentIdentifier.Add(new StrategyComponentIdentification(item));
             }
         }
     }
     
 
     XmlNodeList premiumProductReferenceNodeList = xmlNode.SelectNodes("premiumProductReference");
     if (premiumProductReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in premiumProductReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 premiumProductReferenceIDRef = item.Attributes["id"].Name;
                 ProductReference ob = ProductReference();
                 IDManager.SetID(premiumProductReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 premiumProductReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 premiumProductReference = new ProductReference(item);
             }
         }
     }
     
 
     XmlNodeList productNodeList = xmlNode.SelectNodes("product");
     if (productNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in productNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 productIDRef = item.Attributes["id"].Name;
                 Product ob = Product();
                 IDManager.SetID(productIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 productIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 product = new Product(item);
             }
         }
     }
     
 
     XmlNodeList forwardNodeList = xmlNode.SelectNodes("forward");
     if (forwardNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in forwardNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 forwardIDRef = item.Attributes["id"].Name;
                 ForwardSale ob = ForwardSale();
                 IDManager.SetID(forwardIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 forwardIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 forward = new ForwardSale(item);
             }
         }
     }
     
 
     XmlNodeList bondOptionNodeList = xmlNode.SelectNodes("bondOption");
     if (bondOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in bondOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 bondOptionIDRef = item.Attributes["id"].Name;
                 BondOption ob = BondOption();
                 IDManager.SetID(bondOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 bondOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 bondOption = new BondOption(item);
             }
         }
     }
     
 
     XmlNodeList creditDefaultSwapNodeList = xmlNode.SelectNodes("creditDefaultSwap");
     if (creditDefaultSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in creditDefaultSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 creditDefaultSwapIDRef = item.Attributes["id"].Name;
                 CreditDefaultSwap ob = CreditDefaultSwap();
                 IDManager.SetID(creditDefaultSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 creditDefaultSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 creditDefaultSwap = new CreditDefaultSwap(item);
             }
         }
     }
     
 
     XmlNodeList creditDefaultSwapOptionNodeList = xmlNode.SelectNodes("creditDefaultSwapOption");
     if (creditDefaultSwapOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in creditDefaultSwapOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 creditDefaultSwapOptionIDRef = item.Attributes["id"].Name;
                 CreditDefaultSwapOption ob = CreditDefaultSwapOption();
                 IDManager.SetID(creditDefaultSwapOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 creditDefaultSwapOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 creditDefaultSwapOption = new CreditDefaultSwapOption(item);
             }
         }
     }
     
 
     XmlNodeList commodityForwardNodeList = xmlNode.SelectNodes("commodityForward");
     if (commodityForwardNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityForwardNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityForwardIDRef = item.Attributes["id"].Name;
                 CommodityForward ob = CommodityForward();
                 IDManager.SetID(commodityForwardIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityForwardIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityForward = new CommodityForward(item);
             }
         }
     }
     
 
     XmlNodeList commodityOptionNodeList = xmlNode.SelectNodes("commodityOption");
     if (commodityOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityOptionIDRef = item.Attributes["id"].Name;
                 CommodityOption ob = CommodityOption();
                 IDManager.SetID(commodityOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityOption = new CommodityOption(item);
             }
         }
     }
     
 
     XmlNodeList commoditySwapNodeList = xmlNode.SelectNodes("commoditySwap");
     if (commoditySwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commoditySwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commoditySwapIDRef = item.Attributes["id"].Name;
                 CommoditySwap ob = CommoditySwap();
                 IDManager.SetID(commoditySwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commoditySwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commoditySwap = new CommoditySwap(item);
             }
         }
     }
     
 
     XmlNodeList commoditySwaptionNodeList = xmlNode.SelectNodes("commoditySwaption");
     if (commoditySwaptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commoditySwaptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commoditySwaptionIDRef = item.Attributes["id"].Name;
                 CommoditySwaption ob = CommoditySwaption();
                 IDManager.SetID(commoditySwaptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commoditySwaptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commoditySwaption = new CommoditySwaption(item);
             }
         }
     }
     
 
     XmlNodeList correlationSwapNodeList = xmlNode.SelectNodes("correlationSwap");
     if (correlationSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in correlationSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 correlationSwapIDRef = item.Attributes["id"].Name;
                 CorrelationSwap ob = CorrelationSwap();
                 IDManager.SetID(correlationSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 correlationSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 correlationSwap = new CorrelationSwap(item);
             }
         }
     }
     
 
     XmlNodeList dividendSwapOptionTransactionSupplementNodeList = xmlNode.SelectNodes("dividendSwapOptionTransactionSupplement");
     if (dividendSwapOptionTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in dividendSwapOptionTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 dividendSwapOptionTransactionSupplementIDRef = item.Attributes["id"].Name;
                 DividendSwapOptionTransactionSupplement ob = DividendSwapOptionTransactionSupplement();
                 IDManager.SetID(dividendSwapOptionTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 dividendSwapOptionTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 dividendSwapOptionTransactionSupplement = new DividendSwapOptionTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList dividendSwapTransactionSupplementNodeList = xmlNode.SelectNodes("dividendSwapTransactionSupplement");
     if (dividendSwapTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in dividendSwapTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 dividendSwapTransactionSupplementIDRef = item.Attributes["id"].Name;
                 DividendSwapTransactionSupplement ob = DividendSwapTransactionSupplement();
                 IDManager.SetID(dividendSwapTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 dividendSwapTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 dividendSwapTransactionSupplement = new DividendSwapTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList instrumentTradeDetailsNodeList = xmlNode.SelectNodes("instrumentTradeDetails");
     if (instrumentTradeDetailsNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in instrumentTradeDetailsNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 instrumentTradeDetailsIDRef = item.Attributes["id"].Name;
                 InstrumentTradeDetails ob = InstrumentTradeDetails();
                 IDManager.SetID(instrumentTradeDetailsIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 instrumentTradeDetailsIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 instrumentTradeDetails = new InstrumentTradeDetails(item);
             }
         }
     }
     
 
     XmlNodeList strategyNodeList = xmlNode.SelectNodes("strategy");
     if (strategyNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in strategyNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 strategyIDRef = item.Attributes["id"].Name;
                 Strategy ob = Strategy();
                 IDManager.SetID(strategyIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 strategyIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 strategy = new Strategy(item);
             }
         }
     }
     
 
     XmlNodeList returnSwapNodeList = xmlNode.SelectNodes("returnSwap");
     if (returnSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in returnSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 returnSwapIDRef = item.Attributes["id"].Name;
                 ReturnSwap ob = ReturnSwap();
                 IDManager.SetID(returnSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 returnSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 returnSwap = new ReturnSwap(item);
             }
         }
     }
     
 
     XmlNodeList brokerEquityOptionNodeList = xmlNode.SelectNodes("brokerEquityOption");
     if (brokerEquityOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in brokerEquityOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 brokerEquityOptionIDRef = item.Attributes["id"].Name;
                 BrokerEquityOption ob = BrokerEquityOption();
                 IDManager.SetID(brokerEquityOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 brokerEquityOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 brokerEquityOption = new BrokerEquityOption(item);
             }
         }
     }
     
 
     XmlNodeList equityForwardNodeList = xmlNode.SelectNodes("equityForward");
     if (equityForwardNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityForwardNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityForwardIDRef = item.Attributes["id"].Name;
                 EquityForward ob = EquityForward();
                 IDManager.SetID(equityForwardIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityForwardIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equityForward = new EquityForward(item);
             }
         }
     }
     
 
     XmlNodeList equityOptionNodeList = xmlNode.SelectNodes("equityOption");
     if (equityOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityOptionIDRef = item.Attributes["id"].Name;
                 EquityOption ob = EquityOption();
                 IDManager.SetID(equityOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equityOption = new EquityOption(item);
             }
         }
     }
     
 
     XmlNodeList equityOptionTransactionSupplementNodeList = xmlNode.SelectNodes("equityOptionTransactionSupplement");
     if (equityOptionTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equityOptionTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equityOptionTransactionSupplementIDRef = item.Attributes["id"].Name;
                 EquityOptionTransactionSupplement ob = EquityOptionTransactionSupplement();
                 IDManager.SetID(equityOptionTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equityOptionTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equityOptionTransactionSupplement = new EquityOptionTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList fxSingleLegNodeList = xmlNode.SelectNodes("fxSingleLeg");
     if (fxSingleLegNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxSingleLegNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxSingleLegIDRef = item.Attributes["id"].Name;
                 FxSingleLeg ob = FxSingleLeg();
                 IDManager.SetID(fxSingleLegIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxSingleLegIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxSingleLeg = new FxSingleLeg(item);
             }
         }
     }
     
 
     XmlNodeList fxSwapNodeList = xmlNode.SelectNodes("fxSwap");
     if (fxSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxSwapIDRef = item.Attributes["id"].Name;
                 FxSwap ob = FxSwap();
                 IDManager.SetID(fxSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxSwap = new FxSwap(item);
             }
         }
     }
     
 
     XmlNodeList fxOptionNodeList = xmlNode.SelectNodes("fxOption");
     if (fxOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxOptionIDRef = item.Attributes["id"].Name;
                 FxOption ob = FxOption();
                 IDManager.SetID(fxOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxOption = new FxOption(item);
             }
         }
     }
     
 
     XmlNodeList fxDigitalOptionNodeList = xmlNode.SelectNodes("fxDigitalOption");
     if (fxDigitalOptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fxDigitalOptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fxDigitalOptionIDRef = item.Attributes["id"].Name;
                 FxDigitalOption ob = FxDigitalOption();
                 IDManager.SetID(fxDigitalOptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fxDigitalOptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fxDigitalOption = new FxDigitalOption(item);
             }
         }
     }
     
 
     XmlNodeList termDepositNodeList = xmlNode.SelectNodes("termDeposit");
     if (termDepositNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in termDepositNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 termDepositIDRef = item.Attributes["id"].Name;
                 TermDeposit ob = TermDeposit();
                 IDManager.SetID(termDepositIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 termDepositIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 termDeposit = new TermDeposit(item);
             }
         }
     }
     
 
     XmlNodeList genericProductNodeList = xmlNode.SelectNodes("genericProduct");
     if (genericProductNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in genericProductNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 genericProductIDRef = item.Attributes["id"].Name;
                 GenericProduct ob = GenericProduct();
                 IDManager.SetID(genericProductIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 genericProductIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 genericProduct = new GenericProduct(item);
             }
         }
     }
     
 
     XmlNodeList nonSchemaProductNodeList = xmlNode.SelectNodes("nonSchemaProduct");
     if (nonSchemaProductNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in nonSchemaProductNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 nonSchemaProductIDRef = item.Attributes["id"].Name;
                 GenericProduct ob = GenericProduct();
                 IDManager.SetID(nonSchemaProductIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 nonSchemaProductIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 nonSchemaProduct = new GenericProduct(item);
             }
         }
     }
     
 
     XmlNodeList bulletPaymentNodeList = xmlNode.SelectNodes("bulletPayment");
     if (bulletPaymentNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in bulletPaymentNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 bulletPaymentIDRef = item.Attributes["id"].Name;
                 BulletPayment ob = BulletPayment();
                 IDManager.SetID(bulletPaymentIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 bulletPaymentIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 bulletPayment = new BulletPayment(item);
             }
         }
     }
     
 
     XmlNodeList capFloorNodeList = xmlNode.SelectNodes("capFloor");
     if (capFloorNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in capFloorNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 capFloorIDRef = item.Attributes["id"].Name;
                 CapFloor ob = CapFloor();
                 IDManager.SetID(capFloorIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 capFloorIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 capFloor = new CapFloor(item);
             }
         }
     }
     
 
     XmlNodeList fraNodeList = xmlNode.SelectNodes("fra");
     if (fraNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in fraNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 fraIDRef = item.Attributes["id"].Name;
                 Fra ob = Fra();
                 IDManager.SetID(fraIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 fraIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 fra = new Fra(item);
             }
         }
     }
     
 
     XmlNodeList swapNodeList = xmlNode.SelectNodes("swap");
     if (swapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in swapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 swapIDRef = item.Attributes["id"].Name;
                 Swap ob = Swap();
                 IDManager.SetID(swapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 swapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 swap = new Swap(item);
             }
         }
     }
     
 
     XmlNodeList swaptionNodeList = xmlNode.SelectNodes("swaption");
     if (swaptionNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in swaptionNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 swaptionIDRef = item.Attributes["id"].Name;
                 Swaption ob = Swaption();
                 IDManager.SetID(swaptionIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 swaptionIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 swaption = new Swaption(item);
             }
         }
     }
     
 
     XmlNodeList equitySwapTransactionSupplementNodeList = xmlNode.SelectNodes("equitySwapTransactionSupplement");
     if (equitySwapTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in equitySwapTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 equitySwapTransactionSupplementIDRef = item.Attributes["id"].Name;
                 EquitySwapTransactionSupplement ob = EquitySwapTransactionSupplement();
                 IDManager.SetID(equitySwapTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 equitySwapTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 equitySwapTransactionSupplement = new EquitySwapTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList standardProductNodeList = xmlNode.SelectNodes("standardProduct");
     if (standardProductNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in standardProductNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 standardProductIDRef = item.Attributes["id"].Name;
                 StandardProduct ob = StandardProduct();
                 IDManager.SetID(standardProductIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 standardProductIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 standardProduct = new StandardProduct(item);
             }
         }
     }
     
 
     XmlNodeList varianceOptionTransactionSupplementNodeList = xmlNode.SelectNodes("varianceOptionTransactionSupplement");
     if (varianceOptionTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in varianceOptionTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 varianceOptionTransactionSupplementIDRef = item.Attributes["id"].Name;
                 VarianceOptionTransactionSupplement ob = VarianceOptionTransactionSupplement();
                 IDManager.SetID(varianceOptionTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 varianceOptionTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 varianceOptionTransactionSupplement = new VarianceOptionTransactionSupplement(item);
             }
         }
     }
     
 
     XmlNodeList varianceSwapNodeList = xmlNode.SelectNodes("varianceSwap");
     if (varianceSwapNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in varianceSwapNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 varianceSwapIDRef = item.Attributes["id"].Name;
                 VarianceSwap ob = VarianceSwap();
                 IDManager.SetID(varianceSwapIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 varianceSwapIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 varianceSwap = new VarianceSwap(item);
             }
         }
     }
     
 
     XmlNodeList varianceSwapTransactionSupplementNodeList = xmlNode.SelectNodes("varianceSwapTransactionSupplement");
     if (varianceSwapTransactionSupplementNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in varianceSwapTransactionSupplementNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 varianceSwapTransactionSupplementIDRef = item.Attributes["id"].Name;
                 VarianceSwapTransactionSupplement ob = VarianceSwapTransactionSupplement();
                 IDManager.SetID(varianceSwapTransactionSupplementIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 varianceSwapTransactionSupplementIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 varianceSwapTransactionSupplement = new VarianceSwapTransactionSupplement(item);
             }
         }
     }
     
 
 }
        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 ProductComponentIdentifier(XmlNode xmlNode)
        {
            XmlNode premiumProductReferenceNode = xmlNode.SelectSingleNode("premiumProductReference");

            if (premiumProductReferenceNode != null)
            {
                if (premiumProductReferenceNode.Attributes["href"] != null || premiumProductReferenceNode.Attributes["id"] != null)
                {
                    if (premiumProductReferenceNode.Attributes["id"] != null)
                    {
                        premiumProductReferenceIDRef_ = premiumProductReferenceNode.Attributes["id"].Value;
                        ProductReference ob = new ProductReference(premiumProductReferenceNode);
                        IDManager.SetID(premiumProductReferenceIDRef_, ob);
                    }
                    else if (premiumProductReferenceNode.Attributes["href"] != null)
                    {
                        premiumProductReferenceIDRef_ = premiumProductReferenceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        premiumProductReference_ = new ProductReference(premiumProductReferenceNode);
                    }
                }
                else
                {
                    premiumProductReference_ = new ProductReference(premiumProductReferenceNode);
                }
            }


            XmlNode issuerNode = xmlNode.SelectSingleNode("issuer");

            if (issuerNode != null)
            {
                if (issuerNode.Attributes["href"] != null || issuerNode.Attributes["id"] != null)
                {
                    if (issuerNode.Attributes["id"] != null)
                    {
                        issuerIDRef_ = issuerNode.Attributes["id"].Value;
                        IssuerId ob = new IssuerId(issuerNode);
                        IDManager.SetID(issuerIDRef_, ob);
                    }
                    else if (issuerNode.Attributes["href"] != null)
                    {
                        issuerIDRef_ = issuerNode.Attributes["href"].Value;
                    }
                    else
                    {
                        issuer_ = new IssuerId(issuerNode);
                    }
                }
                else
                {
                    issuer_ = new IssuerId(issuerNode);
                }
            }


            XmlNode tradeIdNode = xmlNode.SelectSingleNode("tradeId");

            if (tradeIdNode != null)
            {
                if (tradeIdNode.Attributes["href"] != null || tradeIdNode.Attributes["id"] != null)
                {
                    if (tradeIdNode.Attributes["id"] != null)
                    {
                        tradeIdIDRef_ = tradeIdNode.Attributes["id"].Value;
                        TradeId ob = new TradeId(tradeIdNode);
                        IDManager.SetID(tradeIdIDRef_, ob);
                    }
                    else if (tradeIdNode.Attributes["href"] != null)
                    {
                        tradeIdIDRef_ = tradeIdNode.Attributes["href"].Value;
                    }
                    else
                    {
                        tradeId_ = new TradeId(tradeIdNode);
                    }
                }
                else
                {
                    tradeId_ = new TradeId(tradeIdNode);
                }
            }
        }
 public Strategy(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNodeList strategyComponentIdentifierNodeList = xmlNode.SelectNodes("strategyComponentIdentifier");
     
     if (strategyComponentIdentifierNodeList != null)
     {
         this.strategyComponentIdentifier_ = new List<StrategyComponentIdentification>();
         foreach (XmlNode item in strategyComponentIdentifierNodeList)
         {
             if (item.Attributes["href"] != null || item.Attributes["id"] != null) 
             {
                 if (item.Attributes["id"] != null) 
                 {
                     strategyComponentIdentifierIDRef_ = item.Attributes["id"].Value;
                     strategyComponentIdentifier_.Add(new StrategyComponentIdentification(item));
                     IDManager.SetID(strategyComponentIdentifierIDRef_, strategyComponentIdentifier_[strategyComponentIdentifier_.Count - 1 ]);
                 }
                 else if (item.Attributes["href"] != null)
                 {
                     strategyComponentIdentifierIDRef_ = item.Attributes["href"].Value;
                 }
                 else
                 {
                 strategyComponentIdentifier_.Add(new StrategyComponentIdentification(item));
                 }
             }
             else
             {
                 strategyComponentIdentifier_.Add(new StrategyComponentIdentification(item));
             }
         }
     }
     
 
     XmlNode premiumProductReferenceNode = xmlNode.SelectSingleNode("premiumProductReference");
     
     if (premiumProductReferenceNode != null)
     {
         if (premiumProductReferenceNode.Attributes["href"] != null || premiumProductReferenceNode.Attributes["id"] != null) 
         {
             if (premiumProductReferenceNode.Attributes["id"] != null) 
             {
                 premiumProductReferenceIDRef_ = premiumProductReferenceNode.Attributes["id"].Value;
                 ProductReference ob = new ProductReference(premiumProductReferenceNode);
                 IDManager.SetID(premiumProductReferenceIDRef_, ob);
             }
             else if (premiumProductReferenceNode.Attributes["href"] != null)
             {
                 premiumProductReferenceIDRef_ = premiumProductReferenceNode.Attributes["href"].Value;
             }
             else
             {
                 premiumProductReference_ = new ProductReference(premiumProductReferenceNode);
             }
         }
         else
         {
             premiumProductReference_ = new ProductReference(premiumProductReferenceNode);
         }
     }
     
 
     XmlNode productNode = xmlNode.SelectSingleNode("product");
     
     if (productNode != null)
     {
         if (productNode.Attributes["href"] != null || productNode.Attributes["id"] != null) 
         {
             if (productNode.Attributes["id"] != null) 
             {
                 productIDRef_ = productNode.Attributes["id"].Value;
                 Product ob = new Product(productNode);
                 IDManager.SetID(productIDRef_, ob);
             }
             else if (productNode.Attributes["href"] != null)
             {
                 productIDRef_ = productNode.Attributes["href"].Value;
             }
             else
             {
                 product_ = new Product(productNode);
             }
         }
         else
         {
             product_ = new Product(productNode);
         }
     }
     
 
     XmlNode forwardNode = xmlNode.SelectSingleNode("forward");
     
     if (forwardNode != null)
     {
         if (forwardNode.Attributes["href"] != null || forwardNode.Attributes["id"] != null) 
         {
             if (forwardNode.Attributes["id"] != null) 
             {
                 forwardIDRef_ = forwardNode.Attributes["id"].Value;
                 ForwardSale ob = new ForwardSale(forwardNode);
                 IDManager.SetID(forwardIDRef_, ob);
             }
             else if (forwardNode.Attributes["href"] != null)
             {
                 forwardIDRef_ = forwardNode.Attributes["href"].Value;
             }
             else
             {
                 forward_ = new ForwardSale(forwardNode);
             }
         }
         else
         {
             forward_ = new ForwardSale(forwardNode);
         }
     }
     
 
     XmlNode bondOptionNode = xmlNode.SelectSingleNode("bondOption");
     
     if (bondOptionNode != null)
     {
         if (bondOptionNode.Attributes["href"] != null || bondOptionNode.Attributes["id"] != null) 
         {
             if (bondOptionNode.Attributes["id"] != null) 
             {
                 bondOptionIDRef_ = bondOptionNode.Attributes["id"].Value;
                 BondOption ob = new BondOption(bondOptionNode);
                 IDManager.SetID(bondOptionIDRef_, ob);
             }
             else if (bondOptionNode.Attributes["href"] != null)
             {
                 bondOptionIDRef_ = bondOptionNode.Attributes["href"].Value;
             }
             else
             {
                 bondOption_ = new BondOption(bondOptionNode);
             }
         }
         else
         {
             bondOption_ = new BondOption(bondOptionNode);
         }
     }
     
 
     XmlNode creditDefaultSwapNode = xmlNode.SelectSingleNode("creditDefaultSwap");
     
     if (creditDefaultSwapNode != null)
     {
         if (creditDefaultSwapNode.Attributes["href"] != null || creditDefaultSwapNode.Attributes["id"] != null) 
         {
             if (creditDefaultSwapNode.Attributes["id"] != null) 
             {
                 creditDefaultSwapIDRef_ = creditDefaultSwapNode.Attributes["id"].Value;
                 CreditDefaultSwap ob = new CreditDefaultSwap(creditDefaultSwapNode);
                 IDManager.SetID(creditDefaultSwapIDRef_, ob);
             }
             else if (creditDefaultSwapNode.Attributes["href"] != null)
             {
                 creditDefaultSwapIDRef_ = creditDefaultSwapNode.Attributes["href"].Value;
             }
             else
             {
                 creditDefaultSwap_ = new CreditDefaultSwap(creditDefaultSwapNode);
             }
         }
         else
         {
             creditDefaultSwap_ = new CreditDefaultSwap(creditDefaultSwapNode);
         }
     }
     
 
     XmlNode creditDefaultSwapOptionNode = xmlNode.SelectSingleNode("creditDefaultSwapOption");
     
     if (creditDefaultSwapOptionNode != null)
     {
         if (creditDefaultSwapOptionNode.Attributes["href"] != null || creditDefaultSwapOptionNode.Attributes["id"] != null) 
         {
             if (creditDefaultSwapOptionNode.Attributes["id"] != null) 
             {
                 creditDefaultSwapOptionIDRef_ = creditDefaultSwapOptionNode.Attributes["id"].Value;
                 CreditDefaultSwapOption ob = new CreditDefaultSwapOption(creditDefaultSwapOptionNode);
                 IDManager.SetID(creditDefaultSwapOptionIDRef_, ob);
             }
             else if (creditDefaultSwapOptionNode.Attributes["href"] != null)
             {
                 creditDefaultSwapOptionIDRef_ = creditDefaultSwapOptionNode.Attributes["href"].Value;
             }
             else
             {
                 creditDefaultSwapOption_ = new CreditDefaultSwapOption(creditDefaultSwapOptionNode);
             }
         }
         else
         {
             creditDefaultSwapOption_ = new CreditDefaultSwapOption(creditDefaultSwapOptionNode);
         }
     }
     
 
     XmlNode commodityForwardNode = xmlNode.SelectSingleNode("commodityForward");
     
     if (commodityForwardNode != null)
     {
         if (commodityForwardNode.Attributes["href"] != null || commodityForwardNode.Attributes["id"] != null) 
         {
             if (commodityForwardNode.Attributes["id"] != null) 
             {
                 commodityForwardIDRef_ = commodityForwardNode.Attributes["id"].Value;
                 CommodityForward ob = new CommodityForward(commodityForwardNode);
                 IDManager.SetID(commodityForwardIDRef_, ob);
             }
             else if (commodityForwardNode.Attributes["href"] != null)
             {
                 commodityForwardIDRef_ = commodityForwardNode.Attributes["href"].Value;
             }
             else
             {
                 commodityForward_ = new CommodityForward(commodityForwardNode);
             }
         }
         else
         {
             commodityForward_ = new CommodityForward(commodityForwardNode);
         }
     }
     
 
     XmlNode commodityOptionNode = xmlNode.SelectSingleNode("commodityOption");
     
     if (commodityOptionNode != null)
     {
         if (commodityOptionNode.Attributes["href"] != null || commodityOptionNode.Attributes["id"] != null) 
         {
             if (commodityOptionNode.Attributes["id"] != null) 
             {
                 commodityOptionIDRef_ = commodityOptionNode.Attributes["id"].Value;
                 CommodityOption ob = new CommodityOption(commodityOptionNode);
                 IDManager.SetID(commodityOptionIDRef_, ob);
             }
             else if (commodityOptionNode.Attributes["href"] != null)
             {
                 commodityOptionIDRef_ = commodityOptionNode.Attributes["href"].Value;
             }
             else
             {
                 commodityOption_ = new CommodityOption(commodityOptionNode);
             }
         }
         else
         {
             commodityOption_ = new CommodityOption(commodityOptionNode);
         }
     }
     
 
     XmlNode commoditySwapNode = xmlNode.SelectSingleNode("commoditySwap");
     
     if (commoditySwapNode != null)
     {
         if (commoditySwapNode.Attributes["href"] != null || commoditySwapNode.Attributes["id"] != null) 
         {
             if (commoditySwapNode.Attributes["id"] != null) 
             {
                 commoditySwapIDRef_ = commoditySwapNode.Attributes["id"].Value;
                 CommoditySwap ob = new CommoditySwap(commoditySwapNode);
                 IDManager.SetID(commoditySwapIDRef_, ob);
             }
             else if (commoditySwapNode.Attributes["href"] != null)
             {
                 commoditySwapIDRef_ = commoditySwapNode.Attributes["href"].Value;
             }
             else
             {
                 commoditySwap_ = new CommoditySwap(commoditySwapNode);
             }
         }
         else
         {
             commoditySwap_ = new CommoditySwap(commoditySwapNode);
         }
     }
     
 
     XmlNode commoditySwaptionNode = xmlNode.SelectSingleNode("commoditySwaption");
     
     if (commoditySwaptionNode != null)
     {
         if (commoditySwaptionNode.Attributes["href"] != null || commoditySwaptionNode.Attributes["id"] != null) 
         {
             if (commoditySwaptionNode.Attributes["id"] != null) 
             {
                 commoditySwaptionIDRef_ = commoditySwaptionNode.Attributes["id"].Value;
                 CommoditySwaption ob = new CommoditySwaption(commoditySwaptionNode);
                 IDManager.SetID(commoditySwaptionIDRef_, ob);
             }
             else if (commoditySwaptionNode.Attributes["href"] != null)
             {
                 commoditySwaptionIDRef_ = commoditySwaptionNode.Attributes["href"].Value;
             }
             else
             {
                 commoditySwaption_ = new CommoditySwaption(commoditySwaptionNode);
             }
         }
         else
         {
             commoditySwaption_ = new CommoditySwaption(commoditySwaptionNode);
         }
     }
     
 
     XmlNode correlationSwapNode = xmlNode.SelectSingleNode("correlationSwap");
     
     if (correlationSwapNode != null)
     {
         if (correlationSwapNode.Attributes["href"] != null || correlationSwapNode.Attributes["id"] != null) 
         {
             if (correlationSwapNode.Attributes["id"] != null) 
             {
                 correlationSwapIDRef_ = correlationSwapNode.Attributes["id"].Value;
                 CorrelationSwap ob = new CorrelationSwap(correlationSwapNode);
                 IDManager.SetID(correlationSwapIDRef_, ob);
             }
             else if (correlationSwapNode.Attributes["href"] != null)
             {
                 correlationSwapIDRef_ = correlationSwapNode.Attributes["href"].Value;
             }
             else
             {
                 correlationSwap_ = new CorrelationSwap(correlationSwapNode);
             }
         }
         else
         {
             correlationSwap_ = new CorrelationSwap(correlationSwapNode);
         }
     }
     
 
     XmlNode dividendSwapOptionTransactionSupplementNode = xmlNode.SelectSingleNode("dividendSwapOptionTransactionSupplement");
     
     if (dividendSwapOptionTransactionSupplementNode != null)
     {
         if (dividendSwapOptionTransactionSupplementNode.Attributes["href"] != null || dividendSwapOptionTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (dividendSwapOptionTransactionSupplementNode.Attributes["id"] != null) 
             {
                 dividendSwapOptionTransactionSupplementIDRef_ = dividendSwapOptionTransactionSupplementNode.Attributes["id"].Value;
                 DividendSwapOptionTransactionSupplement ob = new DividendSwapOptionTransactionSupplement(dividendSwapOptionTransactionSupplementNode);
                 IDManager.SetID(dividendSwapOptionTransactionSupplementIDRef_, ob);
             }
             else if (dividendSwapOptionTransactionSupplementNode.Attributes["href"] != null)
             {
                 dividendSwapOptionTransactionSupplementIDRef_ = dividendSwapOptionTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 dividendSwapOptionTransactionSupplement_ = new DividendSwapOptionTransactionSupplement(dividendSwapOptionTransactionSupplementNode);
             }
         }
         else
         {
             dividendSwapOptionTransactionSupplement_ = new DividendSwapOptionTransactionSupplement(dividendSwapOptionTransactionSupplementNode);
         }
     }
     
 
     XmlNode dividendSwapTransactionSupplementNode = xmlNode.SelectSingleNode("dividendSwapTransactionSupplement");
     
     if (dividendSwapTransactionSupplementNode != null)
     {
         if (dividendSwapTransactionSupplementNode.Attributes["href"] != null || dividendSwapTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (dividendSwapTransactionSupplementNode.Attributes["id"] != null) 
             {
                 dividendSwapTransactionSupplementIDRef_ = dividendSwapTransactionSupplementNode.Attributes["id"].Value;
                 DividendSwapTransactionSupplement ob = new DividendSwapTransactionSupplement(dividendSwapTransactionSupplementNode);
                 IDManager.SetID(dividendSwapTransactionSupplementIDRef_, ob);
             }
             else if (dividendSwapTransactionSupplementNode.Attributes["href"] != null)
             {
                 dividendSwapTransactionSupplementIDRef_ = dividendSwapTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 dividendSwapTransactionSupplement_ = new DividendSwapTransactionSupplement(dividendSwapTransactionSupplementNode);
             }
         }
         else
         {
             dividendSwapTransactionSupplement_ = new DividendSwapTransactionSupplement(dividendSwapTransactionSupplementNode);
         }
     }
     
 
     XmlNode instrumentTradeDetailsNode = xmlNode.SelectSingleNode("instrumentTradeDetails");
     
     if (instrumentTradeDetailsNode != null)
     {
         if (instrumentTradeDetailsNode.Attributes["href"] != null || instrumentTradeDetailsNode.Attributes["id"] != null) 
         {
             if (instrumentTradeDetailsNode.Attributes["id"] != null) 
             {
                 instrumentTradeDetailsIDRef_ = instrumentTradeDetailsNode.Attributes["id"].Value;
                 InstrumentTradeDetails ob = new InstrumentTradeDetails(instrumentTradeDetailsNode);
                 IDManager.SetID(instrumentTradeDetailsIDRef_, ob);
             }
             else if (instrumentTradeDetailsNode.Attributes["href"] != null)
             {
                 instrumentTradeDetailsIDRef_ = instrumentTradeDetailsNode.Attributes["href"].Value;
             }
             else
             {
                 instrumentTradeDetails_ = new InstrumentTradeDetails(instrumentTradeDetailsNode);
             }
         }
         else
         {
             instrumentTradeDetails_ = new InstrumentTradeDetails(instrumentTradeDetailsNode);
         }
     }
     
 
     XmlNode strategyNode = xmlNode.SelectSingleNode("strategy");
     
     if (strategyNode != null)
     {
         if (strategyNode.Attributes["href"] != null || strategyNode.Attributes["id"] != null) 
         {
             if (strategyNode.Attributes["id"] != null) 
             {
                 strategyIDRef_ = strategyNode.Attributes["id"].Value;
                 Strategy ob = new Strategy(strategyNode);
                 IDManager.SetID(strategyIDRef_, ob);
             }
             else if (strategyNode.Attributes["href"] != null)
             {
                 strategyIDRef_ = strategyNode.Attributes["href"].Value;
             }
             else
             {
                 strategy_ = new Strategy(strategyNode);
             }
         }
         else
         {
             strategy_ = new Strategy(strategyNode);
         }
     }
     
 
     XmlNode returnSwapNode = xmlNode.SelectSingleNode("returnSwap");
     
     if (returnSwapNode != null)
     {
         if (returnSwapNode.Attributes["href"] != null || returnSwapNode.Attributes["id"] != null) 
         {
             if (returnSwapNode.Attributes["id"] != null) 
             {
                 returnSwapIDRef_ = returnSwapNode.Attributes["id"].Value;
                 ReturnSwap ob = new ReturnSwap(returnSwapNode);
                 IDManager.SetID(returnSwapIDRef_, ob);
             }
             else if (returnSwapNode.Attributes["href"] != null)
             {
                 returnSwapIDRef_ = returnSwapNode.Attributes["href"].Value;
             }
             else
             {
                 returnSwap_ = new ReturnSwap(returnSwapNode);
             }
         }
         else
         {
             returnSwap_ = new ReturnSwap(returnSwapNode);
         }
     }
     
 
     XmlNode brokerEquityOptionNode = xmlNode.SelectSingleNode("brokerEquityOption");
     
     if (brokerEquityOptionNode != null)
     {
         if (brokerEquityOptionNode.Attributes["href"] != null || brokerEquityOptionNode.Attributes["id"] != null) 
         {
             if (brokerEquityOptionNode.Attributes["id"] != null) 
             {
                 brokerEquityOptionIDRef_ = brokerEquityOptionNode.Attributes["id"].Value;
                 BrokerEquityOption ob = new BrokerEquityOption(brokerEquityOptionNode);
                 IDManager.SetID(brokerEquityOptionIDRef_, ob);
             }
             else if (brokerEquityOptionNode.Attributes["href"] != null)
             {
                 brokerEquityOptionIDRef_ = brokerEquityOptionNode.Attributes["href"].Value;
             }
             else
             {
                 brokerEquityOption_ = new BrokerEquityOption(brokerEquityOptionNode);
             }
         }
         else
         {
             brokerEquityOption_ = new BrokerEquityOption(brokerEquityOptionNode);
         }
     }
     
 
     XmlNode equityForwardNode = xmlNode.SelectSingleNode("equityForward");
     
     if (equityForwardNode != null)
     {
         if (equityForwardNode.Attributes["href"] != null || equityForwardNode.Attributes["id"] != null) 
         {
             if (equityForwardNode.Attributes["id"] != null) 
             {
                 equityForwardIDRef_ = equityForwardNode.Attributes["id"].Value;
                 EquityForward ob = new EquityForward(equityForwardNode);
                 IDManager.SetID(equityForwardIDRef_, ob);
             }
             else if (equityForwardNode.Attributes["href"] != null)
             {
                 equityForwardIDRef_ = equityForwardNode.Attributes["href"].Value;
             }
             else
             {
                 equityForward_ = new EquityForward(equityForwardNode);
             }
         }
         else
         {
             equityForward_ = new EquityForward(equityForwardNode);
         }
     }
     
 
     XmlNode equityOptionNode = xmlNode.SelectSingleNode("equityOption");
     
     if (equityOptionNode != null)
     {
         if (equityOptionNode.Attributes["href"] != null || equityOptionNode.Attributes["id"] != null) 
         {
             if (equityOptionNode.Attributes["id"] != null) 
             {
                 equityOptionIDRef_ = equityOptionNode.Attributes["id"].Value;
                 EquityOption ob = new EquityOption(equityOptionNode);
                 IDManager.SetID(equityOptionIDRef_, ob);
             }
             else if (equityOptionNode.Attributes["href"] != null)
             {
                 equityOptionIDRef_ = equityOptionNode.Attributes["href"].Value;
             }
             else
             {
                 equityOption_ = new EquityOption(equityOptionNode);
             }
         }
         else
         {
             equityOption_ = new EquityOption(equityOptionNode);
         }
     }
     
 
     XmlNode equityOptionTransactionSupplementNode = xmlNode.SelectSingleNode("equityOptionTransactionSupplement");
     
     if (equityOptionTransactionSupplementNode != null)
     {
         if (equityOptionTransactionSupplementNode.Attributes["href"] != null || equityOptionTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (equityOptionTransactionSupplementNode.Attributes["id"] != null) 
             {
                 equityOptionTransactionSupplementIDRef_ = equityOptionTransactionSupplementNode.Attributes["id"].Value;
                 EquityOptionTransactionSupplement ob = new EquityOptionTransactionSupplement(equityOptionTransactionSupplementNode);
                 IDManager.SetID(equityOptionTransactionSupplementIDRef_, ob);
             }
             else if (equityOptionTransactionSupplementNode.Attributes["href"] != null)
             {
                 equityOptionTransactionSupplementIDRef_ = equityOptionTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 equityOptionTransactionSupplement_ = new EquityOptionTransactionSupplement(equityOptionTransactionSupplementNode);
             }
         }
         else
         {
             equityOptionTransactionSupplement_ = new EquityOptionTransactionSupplement(equityOptionTransactionSupplementNode);
         }
     }
     
 
     XmlNode fxSingleLegNode = xmlNode.SelectSingleNode("fxSingleLeg");
     
     if (fxSingleLegNode != null)
     {
         if (fxSingleLegNode.Attributes["href"] != null || fxSingleLegNode.Attributes["id"] != null) 
         {
             if (fxSingleLegNode.Attributes["id"] != null) 
             {
                 fxSingleLegIDRef_ = fxSingleLegNode.Attributes["id"].Value;
                 FxSingleLeg ob = new FxSingleLeg(fxSingleLegNode);
                 IDManager.SetID(fxSingleLegIDRef_, ob);
             }
             else if (fxSingleLegNode.Attributes["href"] != null)
             {
                 fxSingleLegIDRef_ = fxSingleLegNode.Attributes["href"].Value;
             }
             else
             {
                 fxSingleLeg_ = new FxSingleLeg(fxSingleLegNode);
             }
         }
         else
         {
             fxSingleLeg_ = new FxSingleLeg(fxSingleLegNode);
         }
     }
     
 
     XmlNode fxSwapNode = xmlNode.SelectSingleNode("fxSwap");
     
     if (fxSwapNode != null)
     {
         if (fxSwapNode.Attributes["href"] != null || fxSwapNode.Attributes["id"] != null) 
         {
             if (fxSwapNode.Attributes["id"] != null) 
             {
                 fxSwapIDRef_ = fxSwapNode.Attributes["id"].Value;
                 FxSwap ob = new FxSwap(fxSwapNode);
                 IDManager.SetID(fxSwapIDRef_, ob);
             }
             else if (fxSwapNode.Attributes["href"] != null)
             {
                 fxSwapIDRef_ = fxSwapNode.Attributes["href"].Value;
             }
             else
             {
                 fxSwap_ = new FxSwap(fxSwapNode);
             }
         }
         else
         {
             fxSwap_ = new FxSwap(fxSwapNode);
         }
     }
     
 
     XmlNode fxOptionNode = xmlNode.SelectSingleNode("fxOption");
     
     if (fxOptionNode != null)
     {
         if (fxOptionNode.Attributes["href"] != null || fxOptionNode.Attributes["id"] != null) 
         {
             if (fxOptionNode.Attributes["id"] != null) 
             {
                 fxOptionIDRef_ = fxOptionNode.Attributes["id"].Value;
                 FxOption ob = new FxOption(fxOptionNode);
                 IDManager.SetID(fxOptionIDRef_, ob);
             }
             else if (fxOptionNode.Attributes["href"] != null)
             {
                 fxOptionIDRef_ = fxOptionNode.Attributes["href"].Value;
             }
             else
             {
                 fxOption_ = new FxOption(fxOptionNode);
             }
         }
         else
         {
             fxOption_ = new FxOption(fxOptionNode);
         }
     }
     
 
     XmlNode fxDigitalOptionNode = xmlNode.SelectSingleNode("fxDigitalOption");
     
     if (fxDigitalOptionNode != null)
     {
         if (fxDigitalOptionNode.Attributes["href"] != null || fxDigitalOptionNode.Attributes["id"] != null) 
         {
             if (fxDigitalOptionNode.Attributes["id"] != null) 
             {
                 fxDigitalOptionIDRef_ = fxDigitalOptionNode.Attributes["id"].Value;
                 FxDigitalOption ob = new FxDigitalOption(fxDigitalOptionNode);
                 IDManager.SetID(fxDigitalOptionIDRef_, ob);
             }
             else if (fxDigitalOptionNode.Attributes["href"] != null)
             {
                 fxDigitalOptionIDRef_ = fxDigitalOptionNode.Attributes["href"].Value;
             }
             else
             {
                 fxDigitalOption_ = new FxDigitalOption(fxDigitalOptionNode);
             }
         }
         else
         {
             fxDigitalOption_ = new FxDigitalOption(fxDigitalOptionNode);
         }
     }
     
 
     XmlNode termDepositNode = xmlNode.SelectSingleNode("termDeposit");
     
     if (termDepositNode != null)
     {
         if (termDepositNode.Attributes["href"] != null || termDepositNode.Attributes["id"] != null) 
         {
             if (termDepositNode.Attributes["id"] != null) 
             {
                 termDepositIDRef_ = termDepositNode.Attributes["id"].Value;
                 TermDeposit ob = new TermDeposit(termDepositNode);
                 IDManager.SetID(termDepositIDRef_, ob);
             }
             else if (termDepositNode.Attributes["href"] != null)
             {
                 termDepositIDRef_ = termDepositNode.Attributes["href"].Value;
             }
             else
             {
                 termDeposit_ = new TermDeposit(termDepositNode);
             }
         }
         else
         {
             termDeposit_ = new TermDeposit(termDepositNode);
         }
     }
     
 
     XmlNode genericProductNode = xmlNode.SelectSingleNode("genericProduct");
     
     if (genericProductNode != null)
     {
         if (genericProductNode.Attributes["href"] != null || genericProductNode.Attributes["id"] != null) 
         {
             if (genericProductNode.Attributes["id"] != null) 
             {
                 genericProductIDRef_ = genericProductNode.Attributes["id"].Value;
                 GenericProduct ob = new GenericProduct(genericProductNode);
                 IDManager.SetID(genericProductIDRef_, ob);
             }
             else if (genericProductNode.Attributes["href"] != null)
             {
                 genericProductIDRef_ = genericProductNode.Attributes["href"].Value;
             }
             else
             {
                 genericProduct_ = new GenericProduct(genericProductNode);
             }
         }
         else
         {
             genericProduct_ = new GenericProduct(genericProductNode);
         }
     }
     
 
     XmlNode nonSchemaProductNode = xmlNode.SelectSingleNode("nonSchemaProduct");
     
     if (nonSchemaProductNode != null)
     {
         if (nonSchemaProductNode.Attributes["href"] != null || nonSchemaProductNode.Attributes["id"] != null) 
         {
             if (nonSchemaProductNode.Attributes["id"] != null) 
             {
                 nonSchemaProductIDRef_ = nonSchemaProductNode.Attributes["id"].Value;
                 GenericProduct ob = new GenericProduct(nonSchemaProductNode);
                 IDManager.SetID(nonSchemaProductIDRef_, ob);
             }
             else if (nonSchemaProductNode.Attributes["href"] != null)
             {
                 nonSchemaProductIDRef_ = nonSchemaProductNode.Attributes["href"].Value;
             }
             else
             {
                 nonSchemaProduct_ = new GenericProduct(nonSchemaProductNode);
             }
         }
         else
         {
             nonSchemaProduct_ = new GenericProduct(nonSchemaProductNode);
         }
     }
     
 
     XmlNode bulletPaymentNode = xmlNode.SelectSingleNode("bulletPayment");
     
     if (bulletPaymentNode != null)
     {
         if (bulletPaymentNode.Attributes["href"] != null || bulletPaymentNode.Attributes["id"] != null) 
         {
             if (bulletPaymentNode.Attributes["id"] != null) 
             {
                 bulletPaymentIDRef_ = bulletPaymentNode.Attributes["id"].Value;
                 BulletPayment ob = new BulletPayment(bulletPaymentNode);
                 IDManager.SetID(bulletPaymentIDRef_, ob);
             }
             else if (bulletPaymentNode.Attributes["href"] != null)
             {
                 bulletPaymentIDRef_ = bulletPaymentNode.Attributes["href"].Value;
             }
             else
             {
                 bulletPayment_ = new BulletPayment(bulletPaymentNode);
             }
         }
         else
         {
             bulletPayment_ = new BulletPayment(bulletPaymentNode);
         }
     }
     
 
     XmlNode capFloorNode = xmlNode.SelectSingleNode("capFloor");
     
     if (capFloorNode != null)
     {
         if (capFloorNode.Attributes["href"] != null || capFloorNode.Attributes["id"] != null) 
         {
             if (capFloorNode.Attributes["id"] != null) 
             {
                 capFloorIDRef_ = capFloorNode.Attributes["id"].Value;
                 CapFloor ob = new CapFloor(capFloorNode);
                 IDManager.SetID(capFloorIDRef_, ob);
             }
             else if (capFloorNode.Attributes["href"] != null)
             {
                 capFloorIDRef_ = capFloorNode.Attributes["href"].Value;
             }
             else
             {
                 capFloor_ = new CapFloor(capFloorNode);
             }
         }
         else
         {
             capFloor_ = new CapFloor(capFloorNode);
         }
     }
     
 
     XmlNode fraNode = xmlNode.SelectSingleNode("fra");
     
     if (fraNode != null)
     {
         if (fraNode.Attributes["href"] != null || fraNode.Attributes["id"] != null) 
         {
             if (fraNode.Attributes["id"] != null) 
             {
                 fraIDRef_ = fraNode.Attributes["id"].Value;
                 Fra ob = new Fra(fraNode);
                 IDManager.SetID(fraIDRef_, ob);
             }
             else if (fraNode.Attributes["href"] != null)
             {
                 fraIDRef_ = fraNode.Attributes["href"].Value;
             }
             else
             {
                 fra_ = new Fra(fraNode);
             }
         }
         else
         {
             fra_ = new Fra(fraNode);
         }
     }
     
 
     XmlNode swapNode = xmlNode.SelectSingleNode("swap");
     
     if (swapNode != null)
     {
         if (swapNode.Attributes["href"] != null || swapNode.Attributes["id"] != null) 
         {
             if (swapNode.Attributes["id"] != null) 
             {
                 swapIDRef_ = swapNode.Attributes["id"].Value;
                 Swap ob = new Swap(swapNode);
                 IDManager.SetID(swapIDRef_, ob);
             }
             else if (swapNode.Attributes["href"] != null)
             {
                 swapIDRef_ = swapNode.Attributes["href"].Value;
             }
             else
             {
                 swap_ = new Swap(swapNode);
             }
         }
         else
         {
             swap_ = new Swap(swapNode);
         }
     }
     
 
     XmlNode swaptionNode = xmlNode.SelectSingleNode("swaption");
     
     if (swaptionNode != null)
     {
         if (swaptionNode.Attributes["href"] != null || swaptionNode.Attributes["id"] != null) 
         {
             if (swaptionNode.Attributes["id"] != null) 
             {
                 swaptionIDRef_ = swaptionNode.Attributes["id"].Value;
                 Swaption ob = new Swaption(swaptionNode);
                 IDManager.SetID(swaptionIDRef_, ob);
             }
             else if (swaptionNode.Attributes["href"] != null)
             {
                 swaptionIDRef_ = swaptionNode.Attributes["href"].Value;
             }
             else
             {
                 swaption_ = new Swaption(swaptionNode);
             }
         }
         else
         {
             swaption_ = new Swaption(swaptionNode);
         }
     }
     
 
     XmlNode equitySwapTransactionSupplementNode = xmlNode.SelectSingleNode("equitySwapTransactionSupplement");
     
     if (equitySwapTransactionSupplementNode != null)
     {
         if (equitySwapTransactionSupplementNode.Attributes["href"] != null || equitySwapTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (equitySwapTransactionSupplementNode.Attributes["id"] != null) 
             {
                 equitySwapTransactionSupplementIDRef_ = equitySwapTransactionSupplementNode.Attributes["id"].Value;
                 EquitySwapTransactionSupplement ob = new EquitySwapTransactionSupplement(equitySwapTransactionSupplementNode);
                 IDManager.SetID(equitySwapTransactionSupplementIDRef_, ob);
             }
             else if (equitySwapTransactionSupplementNode.Attributes["href"] != null)
             {
                 equitySwapTransactionSupplementIDRef_ = equitySwapTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 equitySwapTransactionSupplement_ = new EquitySwapTransactionSupplement(equitySwapTransactionSupplementNode);
             }
         }
         else
         {
             equitySwapTransactionSupplement_ = new EquitySwapTransactionSupplement(equitySwapTransactionSupplementNode);
         }
     }
     
 
     XmlNode standardProductNode = xmlNode.SelectSingleNode("standardProduct");
     
     if (standardProductNode != null)
     {
         if (standardProductNode.Attributes["href"] != null || standardProductNode.Attributes["id"] != null) 
         {
             if (standardProductNode.Attributes["id"] != null) 
             {
                 standardProductIDRef_ = standardProductNode.Attributes["id"].Value;
                 StandardProduct ob = new StandardProduct(standardProductNode);
                 IDManager.SetID(standardProductIDRef_, ob);
             }
             else if (standardProductNode.Attributes["href"] != null)
             {
                 standardProductIDRef_ = standardProductNode.Attributes["href"].Value;
             }
             else
             {
                 standardProduct_ = new StandardProduct(standardProductNode);
             }
         }
         else
         {
             standardProduct_ = new StandardProduct(standardProductNode);
         }
     }
     
 
     XmlNode varianceOptionTransactionSupplementNode = xmlNode.SelectSingleNode("varianceOptionTransactionSupplement");
     
     if (varianceOptionTransactionSupplementNode != null)
     {
         if (varianceOptionTransactionSupplementNode.Attributes["href"] != null || varianceOptionTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (varianceOptionTransactionSupplementNode.Attributes["id"] != null) 
             {
                 varianceOptionTransactionSupplementIDRef_ = varianceOptionTransactionSupplementNode.Attributes["id"].Value;
                 VarianceOptionTransactionSupplement ob = new VarianceOptionTransactionSupplement(varianceOptionTransactionSupplementNode);
                 IDManager.SetID(varianceOptionTransactionSupplementIDRef_, ob);
             }
             else if (varianceOptionTransactionSupplementNode.Attributes["href"] != null)
             {
                 varianceOptionTransactionSupplementIDRef_ = varianceOptionTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 varianceOptionTransactionSupplement_ = new VarianceOptionTransactionSupplement(varianceOptionTransactionSupplementNode);
             }
         }
         else
         {
             varianceOptionTransactionSupplement_ = new VarianceOptionTransactionSupplement(varianceOptionTransactionSupplementNode);
         }
     }
     
 
     XmlNode varianceSwapNode = xmlNode.SelectSingleNode("varianceSwap");
     
     if (varianceSwapNode != null)
     {
         if (varianceSwapNode.Attributes["href"] != null || varianceSwapNode.Attributes["id"] != null) 
         {
             if (varianceSwapNode.Attributes["id"] != null) 
             {
                 varianceSwapIDRef_ = varianceSwapNode.Attributes["id"].Value;
                 VarianceSwap ob = new VarianceSwap(varianceSwapNode);
                 IDManager.SetID(varianceSwapIDRef_, ob);
             }
             else if (varianceSwapNode.Attributes["href"] != null)
             {
                 varianceSwapIDRef_ = varianceSwapNode.Attributes["href"].Value;
             }
             else
             {
                 varianceSwap_ = new VarianceSwap(varianceSwapNode);
             }
         }
         else
         {
             varianceSwap_ = new VarianceSwap(varianceSwapNode);
         }
     }
     
 
     XmlNode varianceSwapTransactionSupplementNode = xmlNode.SelectSingleNode("varianceSwapTransactionSupplement");
     
     if (varianceSwapTransactionSupplementNode != null)
     {
         if (varianceSwapTransactionSupplementNode.Attributes["href"] != null || varianceSwapTransactionSupplementNode.Attributes["id"] != null) 
         {
             if (varianceSwapTransactionSupplementNode.Attributes["id"] != null) 
             {
                 varianceSwapTransactionSupplementIDRef_ = varianceSwapTransactionSupplementNode.Attributes["id"].Value;
                 VarianceSwapTransactionSupplement ob = new VarianceSwapTransactionSupplement(varianceSwapTransactionSupplementNode);
                 IDManager.SetID(varianceSwapTransactionSupplementIDRef_, ob);
             }
             else if (varianceSwapTransactionSupplementNode.Attributes["href"] != null)
             {
                 varianceSwapTransactionSupplementIDRef_ = varianceSwapTransactionSupplementNode.Attributes["href"].Value;
             }
             else
             {
                 varianceSwapTransactionSupplement_ = new VarianceSwapTransactionSupplement(varianceSwapTransactionSupplementNode);
             }
         }
         else
         {
             varianceSwapTransactionSupplement_ = new VarianceSwapTransactionSupplement(varianceSwapTransactionSupplementNode);
         }
     }
     
 
 }
        public ProductComponentIdentifier(XmlNode xmlNode)
        {
            XmlNodeList premiumProductReferenceNodeList = xmlNode.SelectNodes("premiumProductReference");

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

            foreach (XmlNode item in premiumProductReferenceNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        premiumProductReferenceIDRef = item.Attributes["id"].Name;
                        ProductReference ob = ProductReference();
                        IDManager.SetID(premiumProductReferenceIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        premiumProductReferenceIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        premiumProductReference = new ProductReference(item);
                    }
                }
            }


            XmlNodeList issuerNodeList = xmlNode.SelectNodes("issuer");

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

            foreach (XmlNode item in issuerNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        issuerIDRef = item.Attributes["id"].Name;
                        IssuerId ob = IssuerId();
                        IDManager.SetID(issuerIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        issuerIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        issuer = new IssuerId(item);
                    }
                }
            }


            XmlNodeList tradeIdNodeList = xmlNode.SelectNodes("tradeId");

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

            foreach (XmlNode item in tradeIdNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        tradeIdIDRef = item.Attributes["id"].Name;
                        TradeId ob = TradeId();
                        IDManager.SetID(tradeIdIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        tradeIdIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        tradeId = new TradeId(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 ProductComponentIdentifier(XmlNode xmlNode)
 {
     XmlNode premiumProductReferenceNode = xmlNode.SelectSingleNode("premiumProductReference");
     
     if (premiumProductReferenceNode != null)
     {
         if (premiumProductReferenceNode.Attributes["href"] != null || premiumProductReferenceNode.Attributes["id"] != null) 
         {
             if (premiumProductReferenceNode.Attributes["id"] != null) 
             {
                 premiumProductReferenceIDRef_ = premiumProductReferenceNode.Attributes["id"].Value;
                 ProductReference ob = new ProductReference(premiumProductReferenceNode);
                 IDManager.SetID(premiumProductReferenceIDRef_, ob);
             }
             else if (premiumProductReferenceNode.Attributes["href"] != null)
             {
                 premiumProductReferenceIDRef_ = premiumProductReferenceNode.Attributes["href"].Value;
             }
             else
             {
                 premiumProductReference_ = new ProductReference(premiumProductReferenceNode);
             }
         }
         else
         {
             premiumProductReference_ = new ProductReference(premiumProductReferenceNode);
         }
     }
     
 
     XmlNode issuerNode = xmlNode.SelectSingleNode("issuer");
     
     if (issuerNode != null)
     {
         if (issuerNode.Attributes["href"] != null || issuerNode.Attributes["id"] != null) 
         {
             if (issuerNode.Attributes["id"] != null) 
             {
                 issuerIDRef_ = issuerNode.Attributes["id"].Value;
                 IssuerId ob = new IssuerId(issuerNode);
                 IDManager.SetID(issuerIDRef_, ob);
             }
             else if (issuerNode.Attributes["href"] != null)
             {
                 issuerIDRef_ = issuerNode.Attributes["href"].Value;
             }
             else
             {
                 issuer_ = new IssuerId(issuerNode);
             }
         }
         else
         {
             issuer_ = new IssuerId(issuerNode);
         }
     }
     
 
     XmlNode tradeIdNode = xmlNode.SelectSingleNode("tradeId");
     
     if (tradeIdNode != null)
     {
         if (tradeIdNode.Attributes["href"] != null || tradeIdNode.Attributes["id"] != null) 
         {
             if (tradeIdNode.Attributes["id"] != null) 
             {
                 tradeIdIDRef_ = tradeIdNode.Attributes["id"].Value;
                 TradeId ob = new TradeId(tradeIdNode);
                 IDManager.SetID(tradeIdIDRef_, ob);
             }
             else if (tradeIdNode.Attributes["href"] != null)
             {
                 tradeIdIDRef_ = tradeIdNode.Attributes["href"].Value;
             }
             else
             {
                 tradeId_ = new TradeId(tradeIdNode);
             }
         }
         else
         {
             tradeId_ = new TradeId(tradeIdNode);
         }
     }
     
 
 }
 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 ProductComponentIdentifier(XmlNode xmlNode)
 {
     XmlNodeList premiumProductReferenceNodeList = xmlNode.SelectNodes("premiumProductReference");
     if (premiumProductReferenceNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in premiumProductReferenceNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 premiumProductReferenceIDRef = item.Attributes["id"].Name;
                 ProductReference ob = ProductReference();
                 IDManager.SetID(premiumProductReferenceIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 premiumProductReferenceIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 premiumProductReference = new ProductReference(item);
             }
         }
     }
     
 
     XmlNodeList issuerNodeList = xmlNode.SelectNodes("issuer");
     if (issuerNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in issuerNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 issuerIDRef = item.Attributes["id"].Name;
                 IssuerId ob = IssuerId();
                 IDManager.SetID(issuerIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 issuerIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 issuer = new IssuerId(item);
             }
         }
     }
     
 
     XmlNodeList tradeIdNodeList = xmlNode.SelectNodes("tradeId");
     if (tradeIdNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in tradeIdNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 tradeIdIDRef = item.Attributes["id"].Name;
                 TradeId ob = TradeId();
                 IDManager.SetID(tradeIdIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 tradeIdIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 tradeId = new TradeId(item);
             }
         }
     }
     
 
 }