Ejemplo n.º 1
0
 ISchedulerContext IScheduler.GetContext(ITaskQueue taskQueue, ITaskCollection items, CancellationTokenSource cts, SchedulerContextData queueData)
 {
     return(GetContext((ITaskQueue <TTaskInfo>)taskQueue, (ITaskCollection <TTaskInfo>)items, cts, queueData));
 }
Ejemplo n.º 2
0
        public override SchedulerContext <TaskInfo> GetContext(ITaskQueue <TaskInfo> taskQueue, ITaskCollection <TaskInfo> items, CancellationTokenSource cts, SchedulerContextData queueData)
        {
            return(new SchedulerContext <TaskInfo>(items, cts)
            {
                Delay = taskQueue.Delay,
                CancelOnException = taskQueue.CancelOnException,

                _queueEmpty = queueData._queueEmpty,

                _queueStarted = queueData._queueStarted,
                _queueStopped = queueData._queueStopped,

                _taskScheduled = queueData._taskScheduled,
                _taskCanceled = queueData._taskCanceled,
                _taskCanceling = queueData._taskCanceling,
                _taskExecuting = queueData._taskExecuting,
                _taskExecuted = queueData._taskExecuted,
                _taskException = queueData._taskException
            });
        }
Ejemplo n.º 3
0
 public abstract TSchedulerContext GetContext(ITaskQueue <TTaskInfo> taskQueue, ITaskCollection <TTaskInfo> items, CancellationTokenSource cts, SchedulerContextData queueData);