Example #1
0
 /// <summary>
 /// 取消工作
 /// </summary>
 /// <param name="worker">工作者</param>
 /// <param name="job">工作</param>
 public static void Remove(this IWorker worker, IDisposable job)
 {
     if (!(job is IJob))
     {
         throw new ArgumentException(nameof(job));
     }
     worker.Remove(job.AsJob().Id);
 }