首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > J2EE开发 >

aop的这段代码有神马有关问题?

2013-09-11 
aop的这段代码有神马问题??在线等啊本帖最后由 xuxinsong1991 于 2013-07-04 13:48:36 编辑aop:configa

aop的这段代码有神马问题??在线等啊
本帖最后由 xuxinsong1991 于 2013-07-04 13:48:36 编辑 <aop:config>  
        <aop:aspect id="logBefore" ref="BeforeAdvice">  
            <aop:before pointcut="execution(* hbn.myUtil..*.*(..))" 
                        method="before"/>
        </aop:aspect>
    </aop:config>


报错:
   org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'myUtil' defined in ServletContext resource [/WEB-INF/hbn.xml]: BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.springframework.aop.aspectj.AspectJPointcutAdvisor#0': Cannot create inner bean '(inner bean)' of type [org.springframework.aop.aspectj.AspectJMethodBeforeAdvice] while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '(inner bean)': Cannot create inner bean '(inner bean)' of type [org.springframework.aop.aspectj.AspectJExpressionPointcut] while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name '(inner bean)': Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: org/aspectj/weaver/tools/PointcutDesignatorHandler
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:457) AOP Bean 异常
[解决办法]
缺少aspectjweaver-1.7.2.jar。


[解决办法]
或者重复了。再有就是和xwork-2.1.2.jar冲突了。

热点排行