Ejemplo n.º 1
0
        void ISchedulable.Schedule(TaskScheduler scheduler, IFuture future)
        {
            long until;

            var timeProvider = scheduler.TimeProvider;

            if (timeProvider != DefaultTimeProvider)
            {
                _InitialNow = null;
            }

            if (_InitialNow.HasValue)
            {
                until       = _InitialNow.Value + _Duration;
                _InitialNow = null;
            }
            else
            {
                until = timeProvider.Ticks + _Duration;
            }

            scheduler.QueueSleep(until, future);
        }
Ejemplo n.º 2
0
 void ISchedulable.Schedule(TaskScheduler scheduler, IFuture future)
 {
     scheduler.QueueSleep(_EndWhen, future);
 }
Ejemplo n.º 3
0
 void ISchedulable.Schedule(TaskScheduler scheduler, IFuture future)
 {
     scheduler.QueueSleep(Time.Ticks + _Duration, future);
 }