Learn Java Programming - The Object Class Tutorial

preview_player
Показать описание
Every class you will ever create is derived at some point from the Object class. It is the granddaddy of all Java objects. If you create a class and you do not specifically extend a superclass, then Java implicitly extends the Object class as a superclass for you. In the Object class there are eleven methods: eight of them are regular no-argument methods, and then there is the wait() method which has two more overloaded versions. All of the methods in the Object class are automatically inherited and available for use in every class that we create; we can also override some of these methods as well. I will go over each and every one of these methods in future tutorials. As a matter of fact, I already created a tutorial on one of the methods without telling you - the finalize() method. When I created my tutorial on Garbage Collection, I thought it would be a good opportunity to make a tutorial on the Finalize Method because the two are closely related.
In this tutorial, I will take you to the Oracle website and we will browse around the Object class page for a little while. For the code example, I will simply invoke the toString() method.
Рекомендации по теме
Комментарии
Автор

THANK YOU SO MUCH FOR THESE TUTORIALS! These really teach you how to code!

jafetvargas
visit shbcf.ru