private static XDocument CreateDocument(XName rootName, string fullPath) { var document = new XDocument(new XElement(rootName)); // Add it to the file system FileSystemUtility.AddFile(fullPath, document.Save); return(document); }
/// <summary> /// Flushes any in-memory updates in the SettingsFile to disk. /// </summary> internal void SaveToDisk() { if (IsDirty) { ExecuteSynchronized(() => { FileSystemUtility.AddFile(ConfigFilePath, _xDocument.Save); }); IsDirty = false; } }
private void Save() { ExecuteSynchronized(() => FileSystemUtility.AddFile(ConfigFilePath, ConfigXDocument.Save)); }
private static XDocument CreateDocument(XDocument content, string fullPath) { // Add it to the file system FileSystemUtility.AddFile(fullPath, content.Save); return(content); }