How can the Java – @ Autowired annotation be used for private fields?

See English answers > what is reflection and why is it useful? 21

Solution

It applies to reflection Here you can find examples of how to set up public fields However, setting a private field does not make a difference

The content of this article comes from the network collection of netizens. It is used as a learning reference. The copyright belongs to the original author.
THE END
分享
二维码
< <上一篇
下一篇>>