java - 这个checkLMDao是接口,为什么可以调方法?
PHPz
PHPz 2017-04-18 10:55:22
0
2
480

1.并没有实现类啊?
2.@Autowired有什么用?

PHPz
PHPz

学习是最好的投资!

reply all(2)
PHPzhong

Because the specific implementation method is implemented for you by mybatis. You can study it in depth

巴扎黑

1. What is the use of @Autowired?

@AutowiredYou can annotate member variables, methods and constructors to complete automatic assembly.

To put it simply: Spring helps you find a class that implements this interface and instantiates the marked variable.

2. There is no implemented class?

Because the variable is marked @Autowired.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template