IDEACould not autowire. No beans of 'xxxMapper' type found.
作为一名刚开始使用idea的新手,最近在使用maven+springMVC框架时遇到了这样一个问题:Could not autowire. No beans of ‘xxxMapper’ type found.
这是在实现xxxService接口时,自动注入xxxMapper时,出现的错误。
(╯‵□′)╯︵┴─┴
package com.zm.mlog.service.impl;IDEAimport com.zm.mlog.mapper.AdminMapper;import com.zm.mlog.service.AdminService;import org.springframework.beans.factory.annotation.Autowired;import org.springframework.stereotype.Service;@Service("adminService")public class AdminServiceImpl implements AdminService {@Autowiredprivate AdminMapper adminMapper;
}
看了很久的代码,实在是没发现问题。甚至把代码拿到eclipes跑,没问题。
┬─┬ ノ( ’ - ‘ノ) {摆好摆好)
(再掀一次} (╯°Д°)╯︵ ┻━┻
当然此时已经意识到不是代码的问题,灵机一动一百度果然如此。(:з」∠)
好了不皮了,解决方法如下:
解决方法来源于:http://blog.csdn.net/u012453843/article/details/54906905
IDEACould not autowire. No beans of 'xxxMapper' type found.相关推荐
- Could not autowire. No beans of ‘xxxMapper‘ type found.
在使用IDEA编写代码过程中,你可能会遇到这种情况: Could not autowire. No beans of 'xxxMapper' type found. 一般情况下,这种错误是不影响正常编 ...
- Could not autowire. No beans of ‘XXXMapper‘ type found
@Repository.@Controller.@Service.@Component都是把对象交给spring管理 @Repository用在持久层的接口上,这个注解是将接口的一个实现类交给spri ...
- SpringBoot报错:Could not autowire. No beans of ‘DiscussantMapper‘ type found
SpringBoot报错:Could not autowire. No beans of 'DiscussantMapper' type found 一.资源 @Mapper和@Repository注 ...
- idea中Could not autowire. No beans of 'xxxxMapper' type found.问题解决
idea中Could not autowire. No beans of 'xxxxMapper' type found.问题解决 解决方案: 建议给Mapper增加@Repository注解,并加入 ...
- Could not autowire. No beans of 'JavaMailSender' type found..md
Could not autowire. No beans of 'JavaMailSender' type found. 导入依赖 <dependency><groupId>o ...
- 【ActiveMQ】消息生产者自动注入报错:Could not autowire. No beans of 'JmsMessagingTemplate' type found
标签:public style hat and 报错 require core ota ati 使用ActiveMQ过程中,定义消息生产者: package com.s ...
- IntelliJ Idea取消Could not autowire. No beans of 'xxxx' type found的错误提示
2019独角兽企业重金招聘Python工程师标准>>> 1.问题描述 在Idea的spring工程里,经常会遇到Could not autowire. No beans of 'xx ...
- IDEA 报 「Could not autowire. No beans of ‘UserMapper‘ type found」错误解决方案
IDEA 报 「Could not autowire. No beans of 'UserMapper' type found」错误解决方案 参考文章: (1)IDEA 报 「Could not au ...
- Could not autowire. No beans of 'StudentService' type found
Controller层 错误提示:Could not autowire. No beans of 'StudentService' type found 原因一:可能是你的Spring.xml配置文件 ...
最新文章
- J2EE业务层模式:服务门面,应用服务,以及业务委托,服务定位器
- Java版 QQ空间自动登录无需拷贝cookie一天抓取30WQQ说说数据流程分析【转】
- 命令行无法运行php,php不支持执行cmd命令行
- Matplotlib 可视化之箭头与标注的高级应用
- 【很久之前的一篇老文章】一位程序员工作10年总结的13个忠告
- Spring注解——使用@ComponentScan自动扫描组件
- 报错日常——Tomcat45秒超时问题
- Python编程基础05:运算符与表达式
- linux多线程入库hive,hiveserver2 定时挂采坑记
- .html页面缓存问题
- C++中的抽象概念详解
- 最全面计算机英语单词列表(四)
- Arranging The Sheep
- MySQL-查看数据库
- Linux修改文件时间或创建新文件:touch
- 初始python爬虫-爬取彼岸图单张到全部图片
- ios 之apns推送
- 百度地图显示多点连线+数字标注
- 新产品开发流程管理:以市场为驱动【笔记】(一)
- ubuntu和kali安装vmtool后依旧无法拖拽文件,复制粘贴,解决办法