当前位置 : 主页 > 编程语言 > java >

TBSchedule应用实战(二)示例代码

来源:互联网 收集:自由互联 发布时间:2021-06-28
第二节示例代码 package com.oschina.wed;import org.springframework.context.ApplicationContext;import org.springframework.context.support.ClassPathXmlApplicationContext;public class Main { /** * 由于我们已经将调度器交给了S
第二节示例代码
package com.oschina.wed;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Main {
    /**
     * 由于我们已经将调度器交给了Spring管理,
     * 那么此时我们需要做的只是启动容器就好。
     *
     * @param args
     */
    public static void main(String... args) {

        ApplicationContext context = new ClassPathXmlApplicationContext("application-context.xml");

        while (true) {

        }
    }
}
TBSchedule应用实战(二).zip TBSchedule应用实战(二).zip 第二节示例代码Spring配置
网友评论