CreateUpdatedXml() public méthode

public CreateUpdatedXml ( IViewSettings settings ) : string
settings IViewSettings
Résultat string
 //-----
 // modify functionality (below) is only for the settings dialog save functionality
 //-----
 public static void Modify(string xmlFile, ViewSettings viewSettings)
 {
     string xmlUpdated;
     using (var stream = new StreamReader(xmlFile))
     {
         var parser = new ViewSettingsParser(stream);
         xmlUpdated = parser.CreateUpdatedXml(viewSettings);
     }
     using (var stream = new StreamWriter(xmlFile))
     {
         stream.Write(xmlUpdated);
     }
 }
Exemple #2
0
        //-----
        // modify functionality (below) is only for the settings dialog save functionality
        //-----

        public static void Modify(string xmlFile, ViewSettings viewSettings)
        {
            string xmlUpdated;

            using (var stream = new StreamReader(xmlFile))
            {
                var parser = new ViewSettingsParser(stream);
                xmlUpdated = parser.CreateUpdatedXml(viewSettings);
            }
            using (var stream = new StreamWriter(xmlFile))
            {
                stream.Write(xmlUpdated);
            }
        }