/// <summary> /// Loads the content from XML file to <see cref="ProjectProperties"/> instance. /// </summary> /// <param name="filePath">The XML file path.</param> public static void LoadFromFile(string filePath) { // Dessearialize XML to a new instance var fileStream = new FileStream(filePath, FileMode.Open, FileAccess.Read); _instance = (ProjectProperties) new XmlSerializer(Instance.GetType()).Deserialize(fileStream); fileStream.Close(); }
/// <summary> /// Initializes a new instance of the <see cref="ProjectProperties"/> class and sets it to a singleton instance. /// </summary> public static void New() { _instance = new ProjectProperties(); }