@Resource = @Autowired + @Qualifier 如果接口实现只有一个,则使用@Autowired即可,也不需要规定名字。如果接口实现有多个,则用@Resource,并指定name。或者使用@Autowired + @Qualifier,并指定@Qualifier的name。