/// <summary> Entry point of the application. </summary> /// <param name="args"></param> public static void Main(string[] args) { try { // Load platform settings LoadIniFile(); // Start the Resource Service ResourceService.Instance.Handshake(); // Initialize Preference Store Manager PreferenceStoreManager.GetInstance().Initialize(); // Start Plug-in Service PluginService.Instance.Start(); // Start Extension Service ExtensionService.Instance.Start(); // Start Application Manager ApplicationManager.Instance.DoWork(); } catch (Exception ex) { _log.Error(ex.Message, ex); Environment.Exit(-1); } finally { ApplicationManager.Instance.HomeTime(); ExtensionService.Instance.Stop(); PluginService.Instance.Stop(); PreferenceStoreManager.GetInstance().Dispose(); ResourceService.Instance.Destroy(); PlatformSettings.Instance.Dispose(); } }
/// <summary> Returns the associated preference store. </summary> /// <returns>Associated preference store</returns> private IPreferenceStore GetPreferenceStore() => PreferenceStoreManager.GetInstance().GetStore(PreferenceStoreName, EStoreScope.User);