标签:blog http io ar sp on art log ef
<bean id="aopLog" class="sardine.commodity.biz.AopLog"/>
<aop:config>
<aop:aspect ref="aopLog">
<aop:around method="runOnAround" pointcut="execution (* sardine.commodity.biz.*.find*(..))"/>
</aop:aspect>
</aop:config>
AopLog类如下所示:
import org.aspectj.lang.ProceedingJoinPoint;
public class AopLog {
//方法执行的前后调用
public Object runOnAround(ProceedingJoinPoint point) throws Throwable{
System.out.println("begin around");
Object object = point.proceed();
System.out.println("end around");
return object;
}
}
参考文档如下:
http://zywang.iteye.com/blog/974226
http://blog.csdn.net/voyage_mh1987/article/details/5821238
标签:blog http io ar sp on art log ef
原文地址:http://www.cnblogs.com/usual2013blog/p/4033331.html