// ------------------------- ThreadStart ----------------------------- public static void ThreadStart(CommandThread InThread) { ThreadStart job = new ThreadStart(InThread.EntryPoint); Thread t = new Thread(job); t.IsBackground = true; t.Start(); }
public void RemoveFromCommandThreadList(CommandThread InCmdThread) { int ix = mCommandThreadList.IndexOf(InCmdThread); if (ix != -1) { mCommandThreadList.RemoveAt(ix); } }
// ----------------------------- RunCommand ------------------------------------ public static void RunCommand( ThreadSupervisor InSupervisor, TelnetConnection InConn, TelnetCommandRoute InCommandRoute, RunLogListBox InRunLog, string InCmdText) { { RunLogListBox runLog = new RunLogListBox(InRunLog, "RunCommand"); CommandThread ct = new CommandThread( InSupervisor, InConn, InCommandRoute, InRunLog); ct.CommandText = InCmdText; // run the logout thread. CommandThread.ThreadStart(ct); } }
public void AddToCommandThreadList(CommandThread InCmdThread) { mCommandThreadList.Add(InCmdThread); }