<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-2.0.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.0.xsd">
<bean id="securityHandler" class="com.neusoft.ptboss.record.interceptor.RecordInterceptor">
<property name="recordBO" ref="RecordBO" />
</bean>
<aop:config>
<aop:aspect id="security" ref="securityHandler">
<aop:pointcut id="allAddMethod" expression="execution(* com.neusoft.ptboss.tas.dao.*.save*(..))"/>
<aop:after method="doRecord" pointcut-ref="allAddMethod"/>
<aop:pointcut id="allAddMethod2" expression="execution(* com.neusoft.ptboss.tas.dao.*.add*(..))"/>
<aop:after method="doRecord" pointcut-ref="allAddMethod2"/>
<aop:pointcut id="allAddMethod3" expression="execution(* com.neusoft.ptboss.tas.dao.*.del*(..))"/>
<aop:after method="doRecord" pointcut-ref="allAddMethod3"/>
<aop:pointcut id="allAddMethod4" expression="execution(* com.neusoft.ptboss.tas.dao.*.update*(..))"/>
<aop:after method="doRecord" pointcut-ref="allAddMethod4"/>
<aop:pointcut id="allAddMethod5" expression="execution(* com.neusoft.ptboss.tas.dao.*.modify*(..))"/>
<aop:after method="doRecord" pointcut-ref="allAddMethod5"/>
<aop:pointcut id="allAddMethod6" expression="execution(* com.neusoft.ptboss.tas.dao.*.insert*(..))"/>
<aop:after method="doRecord" pointcut-ref="allAddMethod6"/>
<aop:pointcut id="allAddMethod7" expression="execution(* com.neusoft.ptboss.bos.dao.*.insert*(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod7"/>
<aop:pointcut id="allAddMethod9" expression="execution(* com.neusoft.ptboss.bos.dao.*.update*(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod9"/>
<aop:pointcut id="allAddMethod10" expression="execution(* com.neusoft.ptboss.bos.dao.*.save*(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod10"/>
<aop:pointcut id="allAddMethod11" expression="execution(* com.neusoft.ptboss.bos.dao.*.del*(..))"/>
<aop:before method="doBosRecord" pointcut-ref="allAddMethod11"/>
<aop:pointcut id="allAddMethod12" expression="execution(* com.neusoft.ptboss.bos.dao.*.modify*(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod12"/>
<aop:pointcut id="allAddMethod13" expression="execution(* com.neusoft.ptboss.bos.dao.*.changeStatus(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod13"/>
<aop:pointcut id="allAddMethod14" expression="execution(* com.neusoft.ptboss.sts.dao.PriceDAOImpl.modifyPrice(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod14"/>
<aop:pointcut id="allAddMethod15" expression="execution(* com.neusoft.ptboss.sts.dao.PriceDAOImpl.savePrice(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod15"/>
<aop:pointcut id="allAddMethod16" expression="execution(* com.neusoft.ptboss.sts.dao.PriceDAOImpl.delPrice(..))"/>
<aop:before method="doBosRecord" pointcut-ref="allAddMethod16"/>
<aop:pointcut id="allAddMethod17" expression="execution(* com.neusoft.ptboss.sts.dao.PriceDAOImpl.modifyDate(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod17"/>
<aop:pointcut id="allAddMethod18" expression="execution(* com.neusoft.ptboss.sts.dao.RTPriceDAOImpl.modifyRTPrice(..))"/>
<aop:after method="doBosRecord" pointcut-ref="allAddMethod18"/>
</aop:aspect>
</aop:config>
<bean id="RecordBO"
class="com.neusoft.ptboss.record.bo.RecordBOImpl">
<property name="recordDAO" ref="recordDAO" />
</bean>
<bean id="recordDAO"
class="com.neusoft.ptboss.record.dao.RecordDAOImpl">
<property name="sqlMapClient">
<ref bean="sqlMapClient" />
</property>
</bean>
</beans>
分享到:
相关推荐
Spring之AOP配置文件详解.txt Spring之AOP配置文件详解.txt 帮助你更快张握Java的学习!
使用Spring配置文件实现AOP
博文链接:https://shaqiang32.iteye.com/blog/201915
spring-aop标签和配置文件两种方式实例,spring要求2.5及以上
包含了spring的ioc,aop,任务调度,cxf、jws示例以及邮件发送跟任务调度。里面包含了需要用到的jar包以及xml配置文件。还有示例代码。很方便学习
一个基于配置文件的Spring AOP的实现。实现了前置通知,后置通知,以及拦截器的功能,配置中有详细的注释。
@Component("userService")等价于在spring配置文件中定义一个<bean id="userService"/> @Resource(name="userDAO")将userDA注入进来 写一个拦截器的类 package com.spring.aop; import org.springframework....
压缩包中函数Spring AOP开发时使用注解和xml文件配置demo
spring aop demo 通过注解和配置文件的两种实现方式 包含jar包 下载直接运行
spring aop 的配置文件,新手可以用来学习学习
spring 配置文件 归类 IOC AOPspring 配置文件 归类 IOC AOP
NULL 博文链接:https://baobeituping.iteye.com/blog/964399
赠送Maven依赖信息文件:spring-aop-5.1.3.RELEASE.pom; 包含翻译后的API文档:spring-aop-5.1.3.RELEASE-javadoc-API文档-中文(简体)-英语-对照版.zip; Maven坐标:org.springframework:spring-aop:5.1.3.RELEASE...
在Spring1.2或之前的版本中,实现AOP的传统方式就是通过实现Spring的AOP API来定义Advice,并设置代理对象。Spring根据Adivce加入到业务流程的时机的不同,提供了四种不同的Advice:Before Advice、After Advice、...
最简单的SpringAOP入门案例,对于配置文件有详细的解释,适合初学者去理解AOP编程
spring-aop.xsd 的文件, 自己配置本地xsd文件,里面有spring aop
spring框架使用xml配置文件实现aop
spring相关配置资料,几乎在里面。包括spring-aop-3.1等文件。
spring实现aop、ioc,注入,拦截demo,包含spring所需的所有jar
spring配置文件的汇总,参考后对spring的配置将会学到很多