public static GoodProcessThread RunProcessThread(string path, string arguments, Action <GoodProcessThread> completeCallback, System.Collections.Specialized.StringDictionary env) { GoodProcessThread worker = new GoodProcessThread(path, arguments, completeCallback, env); worker.Thread = new Thread(worker.Work) { IsBackground = true, Priority = ThreadPriority }; worker.Thread.Start(); return(worker); }
public static Action <GoodProcessThread> TryInvoke(this Action <GoodProcessThread> action, GoodProcessThread worker) { if (action != null) { action.Invoke(worker); } return(action); }
public static GoodProcessThread RunProcessThread(string path, string arguments, Action <GoodProcessThread> completeCallback) { GoodProcessThread worker = new GoodProcessThread(path, arguments, completeCallback); return(worker.RunThread()); }