コード例 #1
0
        public static Timer_Thread SetTimer(ThreadCall threadCall, float waitTime, Component mo)
        {
            Timer_Thread timer = new Timer_Thread();

            timer.mThreadCallBack = threadCall;
            timer.SetBody(mo);
            timer.BeginThread(waitTime);
            return(timer);
        }
コード例 #2
0
    void Start()
    {
        ThreadCall tc = ReceiveOutput;

        for (int i = 0; i < prog.Length; ++i)
        {
            System.Diagnostics.Process p;
            p = new System.Diagnostics.Process();
            p.StartInfo.FileName               = prog[i];
            p.StartInfo.UseShellExecute        = false;
            p.StartInfo.RedirectStandardOutput = true;


            p.StartInfo.Arguments = args[i];

            p.Start();

            Thread thread = new Thread(new ParameterizedThreadStart(tc));
            thread.Start(p);
        }
    }