예제 #1
0
파일: ThreadWorker.cs 프로젝트: ztzg/mono
		public ThreadWorker (ThreadWorker[] others,
		                     int workerPosition,
		                     IProducerConsumerCollection<Task> sharedWorkQueue,
		                     IConcurrentDeque<Task> dDeque,
		                     ThreadPriority priority,
		                     ManualResetEvent handle)
		{
			this.others          = others;
			this.dDeque          = dDeque;
			this.sharedWorkQueue = sharedWorkQueue;
			this.workerLength    = others.Length;
			this.workerPosition  = workerPosition;
			this.waitHandle      = handle;
			this.threadPriority  = priority;

			InitializeUnderlyingThread ();
		}
예제 #2
0
파일: ThreadWorker.cs 프로젝트: yonder/mono
        public ThreadWorker(ThreadWorker[] others,
                            int workerPosition,
                            IProducerConsumerCollection <Task> sharedWorkQueue,
                            IConcurrentDeque <Task> dDeque,
                            ThreadPriority priority,
                            ManualResetEvent handle)
        {
            this.others          = others;
            this.dDeque          = dDeque;
            this.sharedWorkQueue = sharedWorkQueue;
            this.workerLength    = others.Length;
            this.workerPosition  = workerPosition;
            this.waitHandle      = handle;
            this.threadPriority  = priority;
            this.adder           = new Action <Task> (ChildWorkAdder);

            InitializeUnderlyingThread();
        }