Exemplo n.º 1
0
 public static Task SaveAsync(string fileName, WizardData data)
 {
     return Task.Run(() =>
     {
         var serializer = new XmlSerializer(typeof(WizardData));
         using (var fs = File.Create(fileName))
         {
             serializer.Serialize(fs, data);
         }
     });
 }
Exemplo n.º 2
0
 private WizardData CreateWizardData(string destinationFolder)
 {
     WizardData wizardData = new WizardData
     {
         Title = $"New {_wizardConfiguration.Description}",
         Solutions = _wizardConfiguration.Solutions
             .Select(info => CreateSolutionData(info, destinationFolder))
             .ToArray()
     };
     return wizardData;
 }