Пример #1
0
 static void Main(string[] args)
 {
     if (args.Contains(RunAsServiceFlag))
     {
         var service     = new UniversalDashboardService();
         var serviceHost = new Win32ServiceHost(service);
         serviceHost.Run();
     }
     else
     {
         var dashboardManager = new DashboardManager();
         dashboardManager.Start();
     }
 }
Пример #2
0
        static void Main(string[] args)
        {
            var dontSetExecutionPolicy = args.Contains(NoExecutionPolicy);

            if (args.Contains(RunAsServiceFlag))
            {
                var service     = new UniversalDashboardService(dontSetExecutionPolicy);
                var serviceHost = new Win32ServiceHost(service);
                serviceHost.Run();
            }
            else
            {
                var dashboardManager = new DashboardManager(dontSetExecutionPolicy);
                dashboardManager.Start();
            }
        }