public UnderlyingIndex(XmlNode xmlNode)
 {
     XmlNode stockIndexNode = xmlNode.SelectSingleNode("stockIndex");
     
     if (stockIndexNode != null)
     {
         if (stockIndexNode.Attributes["href"] != null || stockIndexNode.Attributes["id"] != null) 
         {
             if (stockIndexNode.Attributes["id"] != null) 
             {
                 stockIndexIDRef_ = stockIndexNode.Attributes["id"].Value;
                 StockIndex ob = new StockIndex(stockIndexNode);
                 IDManager.SetID(stockIndexIDRef_, ob);
             }
             else if (stockIndexNode.Attributes["href"] != null)
             {
                 stockIndexIDRef_ = stockIndexNode.Attributes["href"].Value;
             }
             else
             {
                 stockIndex_ = new StockIndex(stockIndexNode);
             }
         }
         else
         {
             stockIndex_ = new StockIndex(stockIndexNode);
         }
     }
     
 
     XmlNode interestrateIndexNode = xmlNode.SelectSingleNode("interestrateIndex");
     
     if (interestrateIndexNode != null)
     {
         if (interestrateIndexNode.Attributes["href"] != null || interestrateIndexNode.Attributes["id"] != null) 
         {
             if (interestrateIndexNode.Attributes["id"] != null) 
             {
                 interestrateIndexIDRef_ = interestrateIndexNode.Attributes["id"].Value;
                 InterestrateIndex ob = new InterestrateIndex(interestrateIndexNode);
                 IDManager.SetID(interestrateIndexIDRef_, ob);
             }
             else if (interestrateIndexNode.Attributes["href"] != null)
             {
                 interestrateIndexIDRef_ = interestrateIndexNode.Attributes["href"].Value;
             }
             else
             {
                 interestrateIndex_ = new InterestrateIndex(interestrateIndexNode);
             }
         }
         else
         {
             interestrateIndex_ = new InterestrateIndex(interestrateIndexNode);
         }
     }
     
 
     XmlNode commodityIndexNode = xmlNode.SelectSingleNode("commodityIndex");
     
     if (commodityIndexNode != null)
     {
         if (commodityIndexNode.Attributes["href"] != null || commodityIndexNode.Attributes["id"] != null) 
         {
             if (commodityIndexNode.Attributes["id"] != null) 
             {
                 commodityIndexIDRef_ = commodityIndexNode.Attributes["id"].Value;
                 CommodityIndex ob = new CommodityIndex(commodityIndexNode);
                 IDManager.SetID(commodityIndexIDRef_, ob);
             }
             else if (commodityIndexNode.Attributes["href"] != null)
             {
                 commodityIndexIDRef_ = commodityIndexNode.Attributes["href"].Value;
             }
             else
             {
                 commodityIndex_ = new CommodityIndex(commodityIndexNode);
             }
         }
         else
         {
             commodityIndex_ = new CommodityIndex(commodityIndexNode);
         }
     }
     
 
 }
 public UnderlyingIndex(XmlNode xmlNode)
 {
     XmlNodeList stockIndexNodeList = xmlNode.SelectNodes("stockIndex");
     if (stockIndexNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in stockIndexNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 stockIndexIDRef = item.Attributes["id"].Name;
                 StockIndex ob = StockIndex();
                 IDManager.SetID(stockIndexIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 stockIndexIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 stockIndex = new StockIndex(item);
             }
         }
     }
     
 
     XmlNodeList interestrateIndexNodeList = xmlNode.SelectNodes("interestrateIndex");
     if (interestrateIndexNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in interestrateIndexNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 interestrateIndexIDRef = item.Attributes["id"].Name;
                 InterestrateIndex ob = InterestrateIndex();
                 IDManager.SetID(interestrateIndexIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 interestrateIndexIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 interestrateIndex = new InterestrateIndex(item);
             }
         }
     }
     
 
     XmlNodeList commodityIndexNodeList = xmlNode.SelectNodes("commodityIndex");
     if (commodityIndexNodeList.Count > 1 )
     {
             throw new Exception();
     }
     
     foreach (XmlNode item in commodityIndexNodeList)
     {
         if (item.Attributes["href"] != null || item.Attributes["id"] == null) 
         {
             if (item.Attributes["id"] != null) 
             {
                 commodityIndexIDRef = item.Attributes["id"].Name;
                 CommodityIndex ob = CommodityIndex();
                 IDManager.SetID(commodityIndexIDRef, ob);
             }
             else if (item.Attributes.ToString() == "href")
             {
                 commodityIndexIDRef = item.Attributes["href"].Name;
             }
             else
             {
                 commodityIndex = new CommodityIndex(item);
             }
         }
     }
     
 
 }
 public Index(XmlNode xmlNode)
 : base(xmlNode)
 {
     XmlNode typeNode = xmlNode.SelectSingleNode("type");
     
     if (typeNode != null)
     {
         if (typeNode.Attributes["href"] != null || typeNode.Attributes["id"] != null) 
         {
             if (typeNode.Attributes["id"] != null) 
             {
                 typeIDRef_ = typeNode.Attributes["id"].Value;
                 XsdTypeToken ob = new XsdTypeToken(typeNode);
                 IDManager.SetID(typeIDRef_, ob);
             }
             else if (typeNode.Attributes["href"] != null)
             {
                 typeIDRef_ = typeNode.Attributes["href"].Value;
             }
             else
             {
                 type_ = new XsdTypeToken(typeNode);
             }
         }
         else
         {
             type_ = new XsdTypeToken(typeNode);
         }
     }
     
 
     XmlNode krCodeNode = xmlNode.SelectSingleNode("krCode");
     
     if (krCodeNode != null)
     {
         if (krCodeNode.Attributes["href"] != null || krCodeNode.Attributes["id"] != null) 
         {
             if (krCodeNode.Attributes["id"] != null) 
             {
                 krCodeIDRef_ = krCodeNode.Attributes["id"].Value;
                 XsdTypeToken ob = new XsdTypeToken(krCodeNode);
                 IDManager.SetID(krCodeIDRef_, ob);
             }
             else if (krCodeNode.Attributes["href"] != null)
             {
                 krCodeIDRef_ = krCodeNode.Attributes["href"].Value;
             }
             else
             {
                 krCode_ = new XsdTypeToken(krCodeNode);
             }
         }
         else
         {
             krCode_ = new XsdTypeToken(krCodeNode);
         }
     }
     
 
     XmlNode nameNode = xmlNode.SelectSingleNode("name");
     
     if (nameNode != null)
     {
         if (nameNode.Attributes["href"] != null || nameNode.Attributes["id"] != null) 
         {
             if (nameNode.Attributes["id"] != null) 
             {
                 nameIDRef_ = nameNode.Attributes["id"].Value;
                 XsdTypeToken ob = new XsdTypeToken(nameNode);
                 IDManager.SetID(nameIDRef_, ob);
             }
             else if (nameNode.Attributes["href"] != null)
             {
                 nameIDRef_ = nameNode.Attributes["href"].Value;
             }
             else
             {
                 name_ = new XsdTypeToken(nameNode);
             }
         }
         else
         {
             name_ = new XsdTypeToken(nameNode);
         }
     }
     
 
     XmlNode basePriceNode = xmlNode.SelectSingleNode("basePrice");
     
     if (basePriceNode != null)
     {
         if (basePriceNode.Attributes["href"] != null || basePriceNode.Attributes["id"] != null) 
         {
             if (basePriceNode.Attributes["id"] != null) 
             {
                 basePriceIDRef_ = basePriceNode.Attributes["id"].Value;
                 XsdTypeToken ob = new XsdTypeToken(basePriceNode);
                 IDManager.SetID(basePriceIDRef_, ob);
             }
             else if (basePriceNode.Attributes["href"] != null)
             {
                 basePriceIDRef_ = basePriceNode.Attributes["href"].Value;
             }
             else
             {
                 basePrice_ = new XsdTypeToken(basePriceNode);
             }
         }
         else
         {
             basePrice_ = new XsdTypeToken(basePriceNode);
         }
     }
     
 
     XmlNode interestRateIndexNode = xmlNode.SelectSingleNode("interestRateIndex");
     
     if (interestRateIndexNode != null)
     {
         if (interestRateIndexNode.Attributes["href"] != null || interestRateIndexNode.Attributes["id"] != null) 
         {
             if (interestRateIndexNode.Attributes["id"] != null) 
             {
                 interestRateIndexIDRef_ = interestRateIndexNode.Attributes["id"].Value;
                 InterestRateIndex ob = new InterestRateIndex(interestRateIndexNode);
                 IDManager.SetID(interestRateIndexIDRef_, ob);
             }
             else if (interestRateIndexNode.Attributes["href"] != null)
             {
                 interestRateIndexIDRef_ = interestRateIndexNode.Attributes["href"].Value;
             }
             else
             {
                 interestRateIndex_ = new InterestRateIndex(interestRateIndexNode);
             }
         }
         else
         {
             interestRateIndex_ = new InterestRateIndex(interestRateIndexNode);
         }
     }
     
 
     XmlNode stockIndexNode = xmlNode.SelectSingleNode("stockIndex");
     
     if (stockIndexNode != null)
     {
         if (stockIndexNode.Attributes["href"] != null || stockIndexNode.Attributes["id"] != null) 
         {
             if (stockIndexNode.Attributes["id"] != null) 
             {
                 stockIndexIDRef_ = stockIndexNode.Attributes["id"].Value;
                 StockIndex ob = new StockIndex(stockIndexNode);
                 IDManager.SetID(stockIndexIDRef_, ob);
             }
             else if (stockIndexNode.Attributes["href"] != null)
             {
                 stockIndexIDRef_ = stockIndexNode.Attributes["href"].Value;
             }
             else
             {
                 stockIndex_ = new StockIndex(stockIndexNode);
             }
         }
         else
         {
             stockIndex_ = new StockIndex(stockIndexNode);
         }
     }
     
 
 }
        public UnderlyingIndex(XmlNode xmlNode)
        {
            XmlNodeList stockIndexNodeList = xmlNode.SelectNodes("stockIndex");

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

            foreach (XmlNode item in stockIndexNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        stockIndexIDRef = item.Attributes["id"].Name;
                        StockIndex ob = StockIndex();
                        IDManager.SetID(stockIndexIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        stockIndexIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        stockIndex = new StockIndex(item);
                    }
                }
            }


            XmlNodeList interestrateIndexNodeList = xmlNode.SelectNodes("interestrateIndex");

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

            foreach (XmlNode item in interestrateIndexNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        interestrateIndexIDRef = item.Attributes["id"].Name;
                        InterestrateIndex ob = InterestrateIndex();
                        IDManager.SetID(interestrateIndexIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        interestrateIndexIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        interestrateIndex = new InterestrateIndex(item);
                    }
                }
            }


            XmlNodeList commodityIndexNodeList = xmlNode.SelectNodes("commodityIndex");

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

            foreach (XmlNode item in commodityIndexNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        commodityIndexIDRef = item.Attributes["id"].Name;
                        CommodityIndex ob = CommodityIndex();
                        IDManager.SetID(commodityIndexIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        commodityIndexIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        commodityIndex = new CommodityIndex(item);
                    }
                }
            }
        }
        public Index(XmlNode xmlNode)
            : base(xmlNode)
        {
            XmlNode typeNode = xmlNode.SelectSingleNode("type");

            if (typeNode != null)
            {
                if (typeNode.Attributes["href"] != null || typeNode.Attributes["id"] != null)
                {
                    if (typeNode.Attributes["id"] != null)
                    {
                        typeIDRef_ = typeNode.Attributes["id"].Value;
                        XsdTypeToken ob = new XsdTypeToken(typeNode);
                        IDManager.SetID(typeIDRef_, ob);
                    }
                    else if (typeNode.Attributes["href"] != null)
                    {
                        typeIDRef_ = typeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        type_ = new XsdTypeToken(typeNode);
                    }
                }
                else
                {
                    type_ = new XsdTypeToken(typeNode);
                }
            }


            XmlNode krCodeNode = xmlNode.SelectSingleNode("krCode");

            if (krCodeNode != null)
            {
                if (krCodeNode.Attributes["href"] != null || krCodeNode.Attributes["id"] != null)
                {
                    if (krCodeNode.Attributes["id"] != null)
                    {
                        krCodeIDRef_ = krCodeNode.Attributes["id"].Value;
                        XsdTypeToken ob = new XsdTypeToken(krCodeNode);
                        IDManager.SetID(krCodeIDRef_, ob);
                    }
                    else if (krCodeNode.Attributes["href"] != null)
                    {
                        krCodeIDRef_ = krCodeNode.Attributes["href"].Value;
                    }
                    else
                    {
                        krCode_ = new XsdTypeToken(krCodeNode);
                    }
                }
                else
                {
                    krCode_ = new XsdTypeToken(krCodeNode);
                }
            }


            XmlNode nameNode = xmlNode.SelectSingleNode("name");

            if (nameNode != null)
            {
                if (nameNode.Attributes["href"] != null || nameNode.Attributes["id"] != null)
                {
                    if (nameNode.Attributes["id"] != null)
                    {
                        nameIDRef_ = nameNode.Attributes["id"].Value;
                        XsdTypeToken ob = new XsdTypeToken(nameNode);
                        IDManager.SetID(nameIDRef_, ob);
                    }
                    else if (nameNode.Attributes["href"] != null)
                    {
                        nameIDRef_ = nameNode.Attributes["href"].Value;
                    }
                    else
                    {
                        name_ = new XsdTypeToken(nameNode);
                    }
                }
                else
                {
                    name_ = new XsdTypeToken(nameNode);
                }
            }


            XmlNode basePriceNode = xmlNode.SelectSingleNode("basePrice");

            if (basePriceNode != null)
            {
                if (basePriceNode.Attributes["href"] != null || basePriceNode.Attributes["id"] != null)
                {
                    if (basePriceNode.Attributes["id"] != null)
                    {
                        basePriceIDRef_ = basePriceNode.Attributes["id"].Value;
                        XsdTypeToken ob = new XsdTypeToken(basePriceNode);
                        IDManager.SetID(basePriceIDRef_, ob);
                    }
                    else if (basePriceNode.Attributes["href"] != null)
                    {
                        basePriceIDRef_ = basePriceNode.Attributes["href"].Value;
                    }
                    else
                    {
                        basePrice_ = new XsdTypeToken(basePriceNode);
                    }
                }
                else
                {
                    basePrice_ = new XsdTypeToken(basePriceNode);
                }
            }


            XmlNode interestRateIndexNode = xmlNode.SelectSingleNode("interestRateIndex");

            if (interestRateIndexNode != null)
            {
                if (interestRateIndexNode.Attributes["href"] != null || interestRateIndexNode.Attributes["id"] != null)
                {
                    if (interestRateIndexNode.Attributes["id"] != null)
                    {
                        interestRateIndexIDRef_ = interestRateIndexNode.Attributes["id"].Value;
                        InterestRateIndex ob = new InterestRateIndex(interestRateIndexNode);
                        IDManager.SetID(interestRateIndexIDRef_, ob);
                    }
                    else if (interestRateIndexNode.Attributes["href"] != null)
                    {
                        interestRateIndexIDRef_ = interestRateIndexNode.Attributes["href"].Value;
                    }
                    else
                    {
                        interestRateIndex_ = new InterestRateIndex(interestRateIndexNode);
                    }
                }
                else
                {
                    interestRateIndex_ = new InterestRateIndex(interestRateIndexNode);
                }
            }


            XmlNode stockIndexNode = xmlNode.SelectSingleNode("stockIndex");

            if (stockIndexNode != null)
            {
                if (stockIndexNode.Attributes["href"] != null || stockIndexNode.Attributes["id"] != null)
                {
                    if (stockIndexNode.Attributes["id"] != null)
                    {
                        stockIndexIDRef_ = stockIndexNode.Attributes["id"].Value;
                        StockIndex ob = new StockIndex(stockIndexNode);
                        IDManager.SetID(stockIndexIDRef_, ob);
                    }
                    else if (stockIndexNode.Attributes["href"] != null)
                    {
                        stockIndexIDRef_ = stockIndexNode.Attributes["href"].Value;
                    }
                    else
                    {
                        stockIndex_ = new StockIndex(stockIndexNode);
                    }
                }
                else
                {
                    stockIndex_ = new StockIndex(stockIndexNode);
                }
            }
        }
Esempio n. 6
0
        public UnderlyingIndex(XmlNode xmlNode)
        {
            XmlNode stockIndexNode = xmlNode.SelectSingleNode("stockIndex");

            if (stockIndexNode != null)
            {
                if (stockIndexNode.Attributes["href"] != null || stockIndexNode.Attributes["id"] != null)
                {
                    if (stockIndexNode.Attributes["id"] != null)
                    {
                        stockIndexIDRef_ = stockIndexNode.Attributes["id"].Value;
                        StockIndex ob = new StockIndex(stockIndexNode);
                        IDManager.SetID(stockIndexIDRef_, ob);
                    }
                    else if (stockIndexNode.Attributes["href"] != null)
                    {
                        stockIndexIDRef_ = stockIndexNode.Attributes["href"].Value;
                    }
                    else
                    {
                        stockIndex_ = new StockIndex(stockIndexNode);
                    }
                }
                else
                {
                    stockIndex_ = new StockIndex(stockIndexNode);
                }
            }


            XmlNode interestrateIndexNode = xmlNode.SelectSingleNode("interestrateIndex");

            if (interestrateIndexNode != null)
            {
                if (interestrateIndexNode.Attributes["href"] != null || interestrateIndexNode.Attributes["id"] != null)
                {
                    if (interestrateIndexNode.Attributes["id"] != null)
                    {
                        interestrateIndexIDRef_ = interestrateIndexNode.Attributes["id"].Value;
                        InterestrateIndex ob = new InterestrateIndex(interestrateIndexNode);
                        IDManager.SetID(interestrateIndexIDRef_, ob);
                    }
                    else if (interestrateIndexNode.Attributes["href"] != null)
                    {
                        interestrateIndexIDRef_ = interestrateIndexNode.Attributes["href"].Value;
                    }
                    else
                    {
                        interestrateIndex_ = new InterestrateIndex(interestrateIndexNode);
                    }
                }
                else
                {
                    interestrateIndex_ = new InterestrateIndex(interestrateIndexNode);
                }
            }


            XmlNode commodityIndexNode = xmlNode.SelectSingleNode("commodityIndex");

            if (commodityIndexNode != null)
            {
                if (commodityIndexNode.Attributes["href"] != null || commodityIndexNode.Attributes["id"] != null)
                {
                    if (commodityIndexNode.Attributes["id"] != null)
                    {
                        commodityIndexIDRef_ = commodityIndexNode.Attributes["id"].Value;
                        CommodityIndex ob = new CommodityIndex(commodityIndexNode);
                        IDManager.SetID(commodityIndexIDRef_, ob);
                    }
                    else if (commodityIndexNode.Attributes["href"] != null)
                    {
                        commodityIndexIDRef_ = commodityIndexNode.Attributes["href"].Value;
                    }
                    else
                    {
                        commodityIndex_ = new CommodityIndex(commodityIndexNode);
                    }
                }
                else
                {
                    commodityIndex_ = new CommodityIndex(commodityIndexNode);
                }
            }
        }