慕粉18755117234
2020-04-23 16:34
<bean id="testBeforeAdvice" class="com.spirng.java.aop.service.api.TestBeforeAdvice"></bean> <bean id="testAfterReturningAdvice" class="com.spirng.java.aop.service.api.TestAfterReturningAdvice"></bean> <bean id="testThrowAdvice" class="com.spirng.java.aop.service.api.TestThrowAdvice"></bean> <bean id="testMethodInterceptor" class="com.spirng.java.aop.service.api.TestMethodInterceptor"></bean> <bean id="logServiceImplTarget" class="com.spirng.java.aop.service.api.impl.LogServiceImpl"></bean> <bean id="pointcutBean" class="org.springframework.aop.support.NameMatchMethodPointcut"> <property name="mappedNames"> <list> <value>ad*</value> </list> </property> </bean> <bean id="defaultAdvisor" class="org.springframework.aop.support.DefaultPointcutAdvisor"> <property name="advice" ref="testBeforeAdvice"></property> <property name="pointcut" ref="pointcutBean"></property> </bean> <bean id="logServiceImpl" class="org.springframework.aop.framework.ProxyFactoryBean"> <property name="target" ref="logServiceImplTarget"></property> <property name="interceptorNames" > <list> <value>testBeforeAdvice</value> <value>testAfterReturningAdvice</value> <value>testThrowAdvice</value> <value>testMethodInterceptor</value> </list> </property> </bean> TestBeforeAdvice:com.sun.proxy.$Proxy14 add TestBeforeAdvice:com.sun.proxy.$Proxy11 add TestMethodInterceptor1:java.lang.reflect.Method add TestBeforeAdvice:com.spirng.java.aop.service.api.impl.LogServiceImpl add LogServiceImpl>>>>>>>>>>000000000 TestMethodInterceptor2:null TestAfterReturningAdvice:com.sun.proxy.$Proxy11 add null
还没有人回答问题,可以看看其他问题
Spring入门篇
268787 学习 · 963 问题
相似问题