예제 #1
0
 public AsyncContext()
 {
     _queue = new TaskQueue();
     _synchronizationContext = new AsyncContextSynchronizationContext(this);
     _taskScheduler = new AsyncContextTaskScheduler(this);
     _taskFactory = new TaskFactory(CancellationToken.None, TaskCreationOptions.HideScheduler, TaskContinuationOptions.HideScheduler, _taskScheduler);
 }
예제 #2
0
 public AsyncContext()
 {
     _queue = new TaskQueue();
     _synchronizationContext = new AsyncContextSynchronizationContext(this);
     _taskScheduler          = new AsyncContextTaskScheduler(this);
     _taskFactory            = new TaskFactory(_taskScheduler);
 }