测试Quartz的表达式

经常被问到各种quartz的表达式是否正确,这个其实我也需要给你test下的,这里把test的java发出来,很简单的

 

public static void main(String[] args) throws ParseException {
		CronExpression c = new CronExpression("0 0-59 * * * ?");
		Date temp = new Date();
		for (int i = 0; i < 100; i++) {
			Date next = c.getNextValidTimeAfter(temp);
			System.out.println(next);
			temp = next;
		}
}
 

你可能感兴趣的:(C++,c,quartz,C#)