使用Spring框架的AspectJ需要哪些jar? [英] which jars are needed for using AspectJ of Spring framework?

查看:243
本文介绍了使用Spring框架的AspectJ需要哪些jar?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Around;
import org.aspectj.lang.ProceedingJoinPoint;

@Aspect
public class AroundExample {

  @Around("com.xyz.myapp.SystemArchitecture.businessService()")
  public Object doBasicProfiling(ProceedingJoinPoint pjp) throws Throwable {
    // start stopwatch
    Object retVal = pjp.proceed();
    // stop stopwatch
    return retVal;
  }
}


推荐答案

你将需要当前版本的aspectj jars即 aspectjrt-1.6.6.jar aspectjweaver-1.7.2.jar with下图中显示的其他jar与Spring框架的AspectJ一起使用。

You will need current version of aspectj jars i.e. aspectjrt-1.6.6.jar and aspectjweaver-1.7.2.jar with other jars shown in the below image to work with AspectJ of Spring framework.

这篇关于使用Spring框架的AspectJ需要哪些jar?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆