Ejemplo n.º 1
0
 public static void LoadFromDisk()
 {
     InitToDefaults();
     if (File.Exists(xmlExportFileName))
     {
         try
         {
             if (!SerializeStatic.Load(typeof(ConfigManager), xmlExportFileName))
             {
                 RestoreDefaults();
                 Logger.WriteMsg("Lack of entries found in saved ConfigManagerExport, returned false;");
             }
         }
         catch (Exception e)
         {
             //using the defaults which were already set
             Logger.WriteError("Unable to restore ConfigManager due to: " + e.ToString());
         }
     }
 }
Ejemplo n.º 2
0
 public static void SaveToDisk()
 {
     SerializeStatic.Save(typeof(ConfigManager), xmlExportFileName);
 }