What is the difference between void and Void in java
This article mainly introduces "what is the difference between void and Void in java". In daily operation, I believe that many people have doubts about the difference between void and Void in java. The editor consulted all kinds of materials and sorted out simple and easy-to-use methods of operation. I hope it will be helpful to answer the question of "what is the difference between void and Void in java?" Next, please follow the editor to study!
Difference
Void
Method definition for no return value.
Void
Void is a wrapper method for void. Unlike other basic types of wrapper methods, Void cannot be instantiated. Void can also be used for methods that always return null or generics that return null.
At this point, the study on "what is the difference between void and Void in java" is over. I hope to be able to solve your doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!