Waits until a thread has indicated its done processing
Ejemplo n.º 1
0
        /// <summary>
        /// Initializes a new instance of the <see cref="StopThread"/> class.
        /// </summary>
        /// <param name="abortWorkerThread">The abort worker thread.</param>
        /// <param name="waitForThreadToFinish">The wait for thread to finish.</param>
        public StopThread(IAbortWorkerThread abortWorkerThread,
                          WaitForThreadToFinish waitForThreadToFinish)
        {
            Guard.NotNull(() => abortWorkerThread, abortWorkerThread);
            Guard.NotNull(() => waitForThreadToFinish, waitForThreadToFinish);

            _abortWorkerThread     = abortWorkerThread;
            _waitForThreadToFinish = waitForThreadToFinish;
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="StopThread"/> class.
        /// </summary>
        /// <param name="abortWorkerThread">The abort worker thread.</param>
        /// <param name="waitForThreadToFinish">The wait for thread to finish.</param>
        public StopThread(IAbortWorkerThread abortWorkerThread,
            WaitForThreadToFinish waitForThreadToFinish)
        {
            Guard.NotNull(() => abortWorkerThread, abortWorkerThread);
            Guard.NotNull(() => waitForThreadToFinish, waitForThreadToFinish);

            _abortWorkerThread = abortWorkerThread;
            _waitForThreadToFinish = waitForThreadToFinish; 
        }