예제 #1
0
        public static ChildProcess Exec(string filename, string[] arguments = null)
        {
            var childProcess = new ChildProcess(filename, arguments);

            childProcess.Start();
            return(childProcess);
        }
예제 #2
0
 private bool Launch()
 {
     _childProcess =
         _config.LaunchMode == LaunchMode.Normal
         ? new ChildProcess(_config.Javaw, _arguments.ToArray())
         : new ChildProcess(_config.Javaw, _versionDirectory, _arguments.ToArray());
     if (!_childProcess.Start())
     {
         return(false);
     }
     _childProcess.OnStdOut += OnStdOut;
     _childProcess.OnStdErr += OnStdOut;
     _childProcess.OnExit   += ChildProcessOnExit;
     _errorCount             = CountError();
     return(true);
 }