spring/springBoot注解介绍
一、@Component & @ConfigurationProperties
pojo对象,需要@Component定义Spring管理Bean,@ConfigurationProperties指定前缀内容。
@Component注解相当于:@Service,@Controller,@Repository,并下面类纳入进spring容器中管理。这样才能被下一层@Autowired注入...
转载
2019-08-11 14:51:03 ·
104 阅读 ·
0 评论