refactor: 格式化说明文字
This commit is contained in:
parent
7af446bef8
commit
cdcea1571b
|
@ -29,7 +29,7 @@
|
|||
TaskServicesManager.GetOrAdd("简单任务", token => Task.Delay(1000));
|
||||
</code>
|
||||
</p>
|
||||
<p>2. 周期性任务 (1 分钟后间隔 5 秒执行2次任务)</p>
|
||||
<p>2. 周期性任务 (1 分钟后间隔 5 秒执行 2 次任务)</p>
|
||||
<p>
|
||||
<code>
|
||||
var trigger = TriggerBuilder.Default.WithInterval(TimeSpan.FromSeconds(5)).WithRepeatCount(2).WithStartTime(DateTimeOffset.Now.AddMinutes(1)).Build();
|
||||
|
@ -37,7 +37,7 @@
|
|||
TaskServicesManager.GetOrAdd("测试任务", token => Task.Delay(1000), trigger);
|
||||
</code>
|
||||
</p>
|
||||
<p>3. Cron表达式任务 (间隔 5 秒循环执行任务)</p>
|
||||
<p>3. Cron 表达式任务 (间隔 5 秒循环执行任务)</p>
|
||||
<p>
|
||||
<code>
|
||||
TaskServicesManager.GetOrAdd("Cron表达式任务", token => Task.Delay(1000), TriggerBuilder.Build("*/5 * * * * *"));
|
||||
|
|
Loading…
Reference in New Issue