AOP XML

<?xml version="1.0" encoding="UTF-8"?>
<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.0.xsd">
<bean name="/login" class="action.LoginAction">
  <property name="ha">
   <ref bean="hahabiz" />
  </property>
</bean>
<bean id="after" class="proxy.afterAdvice" />
<bean id="before" class="proxy.beforeAdvice" />
<bean id="around" class="proxy.aroundAdvice" />
<bean id="biz" class="biz.ha" />
<bean id="hahabiz"
  class="org.springframework.aop.framework.ProxyFactoryBean">
  <!--
   濡傛灉proxyInterfaces杩欎釜灞炴鈧娌℃湁涔熷彲浠ュ憪汊偓傘鈧瑐汊偓備负鍟ュ憿锛?
  -->
  <property name="proxyInterfaces">
   <list>
    <value>biz.haha</value>
   </list>
  </property>
  <property name="interceptorNames">
   <list>
    <!--<value>after</value>
    <value>before</value>
    --><value>around</value>
   </list>
  </property>
  <property name="target">
   <ref bean="biz" />
  </property>
</bean>
</beans>
原文地址:https://www.cnblogs.com/soundcode/p/1911892.html