<?xml version="1.0" encoding="UTF-8"?>http://www.easy518.com/
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-2.5.xsd"
default-lazy-init="false">
<bean id="job1" class="com.job.Job1" />//任务1
<bean id="job2" class="com.job.Job2" />//任务2
<bean id="jobDetail_1"
class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
<property name="targetObject">
<ref bean="job1" />
</property>
<property name="targetMethod">
<value>jobMethod1</value>//执行的方法
</property>
</bean>
<bean id="jobDetail_2"
class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean">
<property name="targetObject">
<ref bean="job2" />
</property>
<property name="targetMethod">
<value>jobMethod2</value>
</property>
</bean>
本内容试读结束,登录后可阅读更多
下载后可阅读完整内容,剩余2页未读,立即下载