The 'this' keyword

In the body of a mehtod definition, there are times where we need to refer to the object to which the method belongs. 
To refer to the object in these cases, use the this keyword where we normally would refer to an object’s name.
The this keyword refer to the current object, and you can use it anywhere a reference to an object might appear.
this.setvisible(true);
Calls the setvisible method, and refer it to the current method.

Leave a Comment

Your email address will not be published. Required fields are marked *