Exemple #1
0
 /// <summary>
 /// The start once at.
 /// </summary>
 /// <param name="task">
 /// The task.
 /// </param>
 /// <param name="dateTime">
 /// The date time.
 /// </param>
 public static void StartOnceAt(this TaskBase task, DateTime dateTime)
 {
     TaskManager.AddTask(task.Execute, t => t.WithName(task.Name).ToRunOnceAt(dateTime));
 }
Exemple #2
0
 /// <summary>
 /// The start once in.
 /// </summary>
 /// <param name="task">
 /// The task.
 /// </param>
 /// <param name="interval">
 /// The interval.
 /// </param>
 public static void StartOnceIn(this TaskBase task, int interval)
 {
     TaskManager.AddTask(task.Execute, t => t.WithName(task.Name).ToRunOnceIn(interval));
 }
Exemple #3
0
 /// <summary>
 /// The start now.
 /// </summary>
 /// <param name="task">
 /// The task.
 /// </param>
 public static void StartNow(this TaskBase task)
 {
     TaskManager.AddTask(task.Execute, t => t.WithName(task.Name).ToRunNow());
 }