Repository navigation
Expand file tree
/
Copy pathbeans2.xml
More file actions
31 lines (30 loc) · 1.55 KB
/
Copy pathbeans2.xml
File metadata and controls
31 lines (30 loc) · 1.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?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:context="http://www.springframework.org/schema/context"
xmlns:aop="http://www.springframework.org/schema/aop" xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop-3.0.xsd">
<context:annotation-config />
<context:component-scan base-package="cn.slg.jw.javaee.ch10spring10" />
<aop:aspectj-autoproxy />
<aop:config>
<aop:aspect id="aspect" ref="persistInteceptorXML">
<aop:pointcut
expression="execution (* cn.slg.jw.javaee.ch10spring10.PersonServiceImpl.*(..))"
id="pointCutMethod" />
<aop:before arg-names="name"
pointcut="execution (* cn.slg.jw.javaee.ch10spring10.PersonServiceImpl.*(..)) and args(name)"
method="doInit" />
<aop:after-returning method="successPersist"
returning="result" pointcut-ref="pointCutMethod" />
<aop:after-throwing method="doErrorPersit"
pointcut-ref="pointCutMethod" throwing="e" />
<aop:after method="doResRelease" pointcut-ref="pointCutMethod" />
<aop:around method="doAroundMethod" pointcut-ref="pointCutMethod" />
</aop:aspect>
</aop:config>
</beans>