Ejemplo n.º 1
0
 public NetworkType(pNetworkType n)
 {
     Time = 0;
     name = n.Name;
     for (int i = 0; i < n.Count(); i++)
     {
         members.Add(n[i]);
     }
 }
Ejemplo n.º 2
0
        public override pNetworkType pGetNetwork()
        {
            string name = "Unknown network";
            pNetworkType network;
            List<string> memberList;
            try
            {
                reader.Read();
                name = pGetString();
                network = new pNetworkType(name);
                while ("Member" == reader.Name) // Maintain backward compatibility
                {
                    memberList = pGetStringList(commaRegex);
                    for (int i = 0; i < memberList.Count; i++) network.Add(memberList[i]);

                    //  network.Add(member);
                }
                reader.ReadEndElement();
            }
            catch (System.Exception e)
            {
                throw new ApplicationException("Error reading Network named "
                    + name + ": ", e);
            }
            return network;
        }