예제 #1
0
        public EquityCorporateEvents(XmlNode xmlNode)
        {
            XmlNode shareForShareNode = xmlNode.SelectSingleNode("shareForShare");

            if (shareForShareNode != null)
            {
                if (shareForShareNode.Attributes["href"] != null || shareForShareNode.Attributes["id"] != null)
                {
                    if (shareForShareNode.Attributes["id"] != null)
                    {
                        shareForShareIDRef_ = shareForShareNode.Attributes["id"].Value;
                        ShareExtraordinaryEventEnum ob = new ShareExtraordinaryEventEnum(shareForShareNode);
                        IDManager.SetID(shareForShareIDRef_, ob);
                    }
                    else if (shareForShareNode.Attributes["href"] != null)
                    {
                        shareForShareIDRef_ = shareForShareNode.Attributes["href"].Value;
                    }
                    else
                    {
                        shareForShare_ = new ShareExtraordinaryEventEnum(shareForShareNode);
                    }
                }
                else
                {
                    shareForShare_ = new ShareExtraordinaryEventEnum(shareForShareNode);
                }
            }


            XmlNode shareForOtherNode = xmlNode.SelectSingleNode("shareForOther");

            if (shareForOtherNode != null)
            {
                if (shareForOtherNode.Attributes["href"] != null || shareForOtherNode.Attributes["id"] != null)
                {
                    if (shareForOtherNode.Attributes["id"] != null)
                    {
                        shareForOtherIDRef_ = shareForOtherNode.Attributes["id"].Value;
                        ShareExtraordinaryEventEnum ob = new ShareExtraordinaryEventEnum(shareForOtherNode);
                        IDManager.SetID(shareForOtherIDRef_, ob);
                    }
                    else if (shareForOtherNode.Attributes["href"] != null)
                    {
                        shareForOtherIDRef_ = shareForOtherNode.Attributes["href"].Value;
                    }
                    else
                    {
                        shareForOther_ = new ShareExtraordinaryEventEnum(shareForOtherNode);
                    }
                }
                else
                {
                    shareForOther_ = new ShareExtraordinaryEventEnum(shareForOtherNode);
                }
            }


            XmlNode shareForCombinedNode = xmlNode.SelectSingleNode("shareForCombined");

            if (shareForCombinedNode != null)
            {
                if (shareForCombinedNode.Attributes["href"] != null || shareForCombinedNode.Attributes["id"] != null)
                {
                    if (shareForCombinedNode.Attributes["id"] != null)
                    {
                        shareForCombinedIDRef_ = shareForCombinedNode.Attributes["id"].Value;
                        ShareExtraordinaryEventEnum ob = new ShareExtraordinaryEventEnum(shareForCombinedNode);
                        IDManager.SetID(shareForCombinedIDRef_, ob);
                    }
                    else if (shareForCombinedNode.Attributes["href"] != null)
                    {
                        shareForCombinedIDRef_ = shareForCombinedNode.Attributes["href"].Value;
                    }
                    else
                    {
                        shareForCombined_ = new ShareExtraordinaryEventEnum(shareForCombinedNode);
                    }
                }
                else
                {
                    shareForCombined_ = new ShareExtraordinaryEventEnum(shareForCombinedNode);
                }
            }
        }
예제 #2
0
        public EquityCorporateEvents(XmlNode xmlNode)
        {
            XmlNodeList shareForShareNodeList = xmlNode.SelectNodes("shareForShare");

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

            foreach (XmlNode item in shareForShareNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        shareForShareIDRef = item.Attributes["id"].Name;
                        ShareExtraordinaryEventEnum ob = ShareExtraordinaryEventEnum();
                        IDManager.SetID(shareForShareIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        shareForShareIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        shareForShare = new ShareExtraordinaryEventEnum(item);
                    }
                }
            }


            XmlNodeList shareForOtherNodeList = xmlNode.SelectNodes("shareForOther");

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

            foreach (XmlNode item in shareForOtherNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        shareForOtherIDRef = item.Attributes["id"].Name;
                        ShareExtraordinaryEventEnum ob = ShareExtraordinaryEventEnum();
                        IDManager.SetID(shareForOtherIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        shareForOtherIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        shareForOther = new ShareExtraordinaryEventEnum(item);
                    }
                }
            }


            XmlNodeList shareForCombinedNodeList = xmlNode.SelectNodes("shareForCombined");

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

            foreach (XmlNode item in shareForCombinedNodeList)
            {
                if (item.Attributes["href"] != null || item.Attributes["id"] == null)
                {
                    if (item.Attributes["id"] != null)
                    {
                        shareForCombinedIDRef = item.Attributes["id"].Name;
                        ShareExtraordinaryEventEnum ob = ShareExtraordinaryEventEnum();
                        IDManager.SetID(shareForCombinedIDRef, ob);
                    }
                    else if (item.Attributes.ToString() == "href")
                    {
                        shareForCombinedIDRef = item.Attributes["href"].Name;
                    }
                    else
                    {
                        shareForCombined = new ShareExtraordinaryEventEnum(item);
                    }
                }
            }
        }
 public EquityCorporateEvents(XmlNode xmlNode)
 {
     XmlNode shareForShareNode = xmlNode.SelectSingleNode("shareForShare");
     
     if (shareForShareNode != null)
     {
         if (shareForShareNode.Attributes["href"] != null || shareForShareNode.Attributes["id"] != null) 
         {
             if (shareForShareNode.Attributes["id"] != null) 
             {
                 shareForShareIDRef_ = shareForShareNode.Attributes["id"].Value;
                 ShareExtraordinaryEventEnum ob = new ShareExtraordinaryEventEnum(shareForShareNode);
                 IDManager.SetID(shareForShareIDRef_, ob);
             }
             else if (shareForShareNode.Attributes["href"] != null)
             {
                 shareForShareIDRef_ = shareForShareNode.Attributes["href"].Value;
             }
             else
             {
                 shareForShare_ = new ShareExtraordinaryEventEnum(shareForShareNode);
             }
         }
         else
         {
             shareForShare_ = new ShareExtraordinaryEventEnum(shareForShareNode);
         }
     }
     
 
     XmlNode shareForOtherNode = xmlNode.SelectSingleNode("shareForOther");
     
     if (shareForOtherNode != null)
     {
         if (shareForOtherNode.Attributes["href"] != null || shareForOtherNode.Attributes["id"] != null) 
         {
             if (shareForOtherNode.Attributes["id"] != null) 
             {
                 shareForOtherIDRef_ = shareForOtherNode.Attributes["id"].Value;
                 ShareExtraordinaryEventEnum ob = new ShareExtraordinaryEventEnum(shareForOtherNode);
                 IDManager.SetID(shareForOtherIDRef_, ob);
             }
             else if (shareForOtherNode.Attributes["href"] != null)
             {
                 shareForOtherIDRef_ = shareForOtherNode.Attributes["href"].Value;
             }
             else
             {
                 shareForOther_ = new ShareExtraordinaryEventEnum(shareForOtherNode);
             }
         }
         else
         {
             shareForOther_ = new ShareExtraordinaryEventEnum(shareForOtherNode);
         }
     }
     
 
     XmlNode shareForCombinedNode = xmlNode.SelectSingleNode("shareForCombined");
     
     if (shareForCombinedNode != null)
     {
         if (shareForCombinedNode.Attributes["href"] != null || shareForCombinedNode.Attributes["id"] != null) 
         {
             if (shareForCombinedNode.Attributes["id"] != null) 
             {
                 shareForCombinedIDRef_ = shareForCombinedNode.Attributes["id"].Value;
                 ShareExtraordinaryEventEnum ob = new ShareExtraordinaryEventEnum(shareForCombinedNode);
                 IDManager.SetID(shareForCombinedIDRef_, ob);
             }
             else if (shareForCombinedNode.Attributes["href"] != null)
             {
                 shareForCombinedIDRef_ = shareForCombinedNode.Attributes["href"].Value;
             }
             else
             {
                 shareForCombined_ = new ShareExtraordinaryEventEnum(shareForCombinedNode);
             }
         }
         else
         {
             shareForCombined_ = new ShareExtraordinaryEventEnum(shareForCombinedNode);
         }
     }
     
 
 }