Spring @Autowired注入对象为NULL



public class XXService {

@Autowired
DaoImpl DaoImpl;
}

@Autowired注入对象为NULL

方法:在所有使用了dao的地方,包括调用它的servcie都要进行@Autowired注入,否则之后的注入就会失败..



猜你喜欢

转载自lovejavah123.iteye.com/blog/2270637