What type of dependency injection when we have @Autowire on a class field?
2 answers
In the case of @Autowiring in a class, for example:
public class Test {
@Autowired
TestService service;
...
}
Free your object from using reflection hence no need for Setter methods
Check this post: How Spring @Autowired Works
+1
source to share