@Autowire with constructor?

前端 未结 0 1467
轻奢々
轻奢々 2021-01-02 19:47

I was wondering what is the difference between the below solutions, why using solution 2? any benefits?

solution 1:

public A{
  @Autowire
  private B b         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题