Ejemplo n.º 1
0
        private ConfigFileDBInfo ReadDBSection(string sectionName, XElement root)
        {
            ConfigFileDBInfo dbInfo = new ConfigFileDBInfo(sectionName, ReadDBMSType(root, sectionName));

            foreach (XElement el in root.Element(sectionName).Elements())
            {
                string elName = el.Name.LocalName;
                dbInfo.AddProperty(ReadDbProperty(root, sectionName, elName));
            }

            return(dbInfo);
        }
Ejemplo n.º 2
0
 private void ReadFile(string osPlatformVersion)
 {
     using (FileStream fs = File.OpenRead(_configFilePath))
     {
         XElement root = XElement.Load(fs);
         _dbPlatformDetails = ReadDbPlatformInfo(root);
         if (!(osPlatformVersion.StartsWith("10.")))
         {
             _dbLoggingDetails = ReadDbLoggingInfo(root);
         }
         _dbSessionDetails = ReadDbSessionInfo(root);
     }
 }