"org.springframework.beans.factory.BeanNotOfRequiredTypeException……" 错误解决方案
2017-03-01 09:08
507 查看
在写Spring AOP 的时候,发现报了个错:org.springframework.beans.factory.BeanNotOfRequiredTypeException……
报错时我的注入方式是类注入
报错时我的注入方式是类注入
@Autowired private PerformanceImpl performanceImpl;//类注入改成接口注入方式:
@Autowired private Performance performance;//接口注入就可以通过测试了,原因是Spring的动态代理机制只支持接口注入
相关文章推荐
- org.springframework.beans.factory.BeanNotOfRequiredTypeException 错误,
- 运用spring时出现org.springframework.beans.factory.BeanNotOfRequiredTypeException: 错误
- org.springframework.beans.factory.BeanNotOfRequiredTypeException: Bean named "" must be of type [org.apache.struts.action.Action
- org.springframework.beans.factory.BeanNotOfRequiredTypeException
- Spring-org.springframework.beans.factory.BeanNotOfRequiredTypeException
- org.springframework.beans.factory.BeanNotOfRequiredTypeException must be of type
- Aurora-hec4.0_scaninvoice_异常_04_org.springframework.beans.factory.BeanNotOfRequiredTypeException
- org.springframework.beans.factory.BeanNotOfRequiredTypeException: Bean named 'faceAction' must be of
- 处理异常:org.springframework.beans.factory.BeanNotOfRequiredTypeException
- org.springframework.beans.factory.BeanNotOfRequiredTypeException
- org.springframework.beans.factory.BeanNotOfRequiredTypeException的解决办法
- org.springframework.beans.factory.BeanNotOfRequiredTypeException:
- Caused by: org.springframework.beans.factory.BeanNotOfRequiredTypeException: Bean named 'dao' is exp
- 代理及注入之org.springframework.beans.factory.BeanNotOfRequiredTypeException
- 在使用Spring AOP 时,启动服务抛出异常: org.springframework.beans.factory.BeanNotOfRequiredTypeException
- 解决: org.springframework.beans.factory.BeanNotOfRequiredTypeException
- org.springframework.beans.factory.BeanNotOfRequiredTypeException:
- 异常:org.springframework.beans.factory.BeanNotOfRequiredTypeException
- 【异常篇-spring】org.springframework.beans.factory.BeanNotOfRequiredTypeException
- shiro错误 org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type