public AltVAsync() { mainThread = Thread.CurrentThread; mainThread.Name = "main"; scheduler = new TickScheduler(mainThread); taskFactory = new TaskFactory( CancellationToken.None, TaskCreationOptions.DenyChildAttach, TaskContinuationOptions.None, scheduler); AltAsync.Setup(this); }
public AltVAsync(ITickSchedulerFactory tickSchedulerFactory) { mainThread = Thread.CurrentThread; if (mainThread.Name == "") { mainThread.Name = "main"; } scheduler = tickSchedulerFactory.Create(mainThread); taskFactory = new TaskFactory( CancellationToken.None, TaskCreationOptions.DenyChildAttach, TaskContinuationOptions.None, scheduler); AltAsync.Setup(this); TickDelegate = FirstTick; }