0
我requeriment是要建立一个Quartz.net任务运行:Quartz.net计划任务5分钟
- 运行在特定的时间的分钟变量,然后完成?
我有这个类:
public class Proccess
{
public static void Start()
{
Console.WriteLine("I'm starting");
}
public static void End()
{
Console.WriteLine("I'm finishing");
}
}
有什么办法与Quartz.Net)配置作业调用的Process.Start(等待X分钟和呼叫Process.End()?
也许有些事情也是这样吗?
public class TapWaterJob : IJob
{
public TapWaterJob()
{
// quartz requires a public empty constructor so that the
// scheduler can instantiate the class whenever it needs.
}
public void Execute(IJobExecutionContext context)
{
Proccess.Start();
System.Threading.Thread.Sleep(10000);
Process.End();
}
}
“运行在指定时间的分钟变量,然后 完成” 不清楚多久应该被触发 – Valentin
这将只运行一次 – Marc
[配置Quartz.Net的可能的复制,从执行停止作业,如果超过规定的时间跨度要长(http://stackoverflow.com/questions/24446215/configuring-quartz-net-to-stop-a-job-from-executing-if-it-is-taking-longer - ) – Najera