Esempio n. 1
0
 public cPackage GetPackage(string name)
 {
     foreach (XmlNode nodePackage in _xml.SelectNodes("//package"))
     {
         cPackage newPackage = new cPackage();
         newPackage.LoadFromXml(nodePackage.OuterXml);
         if (newPackage.Name == name) return newPackage;
     }
     return null;
 }
Esempio n. 2
0
        public Collection<cPackage> GetPackages()
        {
            Collection<cPackage> retList = new Collection<cPackage>();

            foreach (XmlNode nodePackage in _xml.SelectNodes("//package"))
            {
                cPackage newPackage = new cPackage();
                newPackage.LoadFromXml(nodePackage.OuterXml);
                retList.Add(newPackage);
            }

            return retList;
        }