public StateActionWithContextScheduledAsyncTask(AbstractScheduledEventExecutor executor, Action <object, object> action, object context, object state, PreciseTimeSpan deadline, CancellationToken cancellationToken) : base(executor, deadline, new TaskCompletionSource(state), cancellationToken) { this.action = action; this.context = context; }
public StateActionScheduledTask(AbstractScheduledEventExecutor executor, Action <object> action, object state, PreciseTimeSpan deadline) : base(executor, deadline, new TaskCompletionSource(state)) { this.action = action; }
public ActionScheduledAsyncTask(AbstractScheduledEventExecutor executor, Action action, PreciseTimeSpan deadline, CancellationToken cancellationToken) : base(executor, deadline, new TaskCompletionSource(), cancellationToken) { this.action = action; }
protected ScheduledTask(AbstractScheduledEventExecutor executor, PreciseTimeSpan deadline, TaskCompletionSource promise) { this.Executor = executor; this.Promise = promise; this.Deadline = deadline; }
public ActionScheduledTask(AbstractScheduledEventExecutor executor, Action action, PreciseTimeSpan deadline) : base(executor, deadline, new TaskCompletionSource()) { this.action = action; }
protected ScheduledAsyncTask(AbstractScheduledEventExecutor executor, PreciseTimeSpan deadline, TaskCompletionSource promise, CancellationToken cancellationToken) : base(executor, deadline, promise) { this.cancellationToken = cancellationToken; this.cancellationTokenRegistration = cancellationToken.Register(s => ((ScheduledAsyncTask)s).Cancel(), this); }