private Task CreateServerCore(string pipeName)
            {
                Action action = () =>
                {
                    var compilerServerHost = new DesktopCompilerServerHost(ClientDirectory, SdkDirectory);
                    var clientConnectionHost = new NamedPipeClientConnectionHost(compilerServerHost, pipeName);
                    var mutexName = $"{pipeName}.server";
                    VBCSCompiler.Run(mutexName, clientConnectionHost, TimeSpan.FromSeconds(3));
                };

                var task = new Task(action, TaskCreationOptions.LongRunning);
                task.Start(TaskScheduler.Default);
                return task;
            }
Beispiel #2
0
            private Task CreateServerCore(string pipeName)
            {
                Action action = () =>
                {
                    var compilerServerHost   = new DesktopCompilerServerHost(ClientDirectory, SdkDirectory);
                    var clientConnectionHost = new NamedPipeClientConnectionHost(compilerServerHost, pipeName);
                    var mutexName            = $"{pipeName}.server";
                    VBCSCompiler.Run(mutexName, clientConnectionHost, TimeSpan.FromSeconds(3));
                };

                var task = new Task(action, TaskCreationOptions.LongRunning);

                task.Start(TaskScheduler.Default);
                return(task);
            }