posts - 15,  comments - 34,  trackbacks - 27
spring配置如下:
<bean id="shedulerServiceProxy" 
  class
="org.springframework.transaction.interceptor.TransactionProxyFactoryBean">
  
<property name="transactionManager">
   
<ref bean="transactionManager"/>
  
</property>
  
<property name="target">
   
<ref local="shedulerService"/>
  
</property>
  
<property name="transactionAttributes">
   
<props>
    
<prop key="find*">
     PROPAGATION_REQUIRED,readOnly,-Exception
</prop>
    
<prop key="pickup*">PROPAGATION_REQUIRED,-Exception</prop>
   
</props>
  
</property>
 
</bean>
 
<bean id="shedulerService" class="com.tydic.asset.ejbs.service.SchedulerImpl">
  
<property name="fiTaskDAO">
   
<ref local="fiTaskDAOProxy"></ref>
  
</property>
  
<property name="fiTaskDetailDAO">
   
<ref local="fiTaskDetailDAOProxy"></ref>
  
</property>
 
</bean>

接下来实现Scheduler接口,
public class SchedulerImpl implements Scheduler{   //注意"implements Scheduler"如不实现接口类spring会出错!
//
}

posted on 2005-05-20 18:13 jacky 阅读(1066) 评论(0)  编辑  收藏 所属分类: Open source

只有注册用户登录后才能发表评论。


网站导航:
 
<2024年5月>
2829301234
567891011
12131415161718
19202122232425
2627282930311
2345678

常用链接

留言簿(10)

随笔档案

文章分类

文章档案

相册

收藏夹

java

搜索

  •  

最新评论