Explain the use of ‘this’ keyword in Java?



Explain the use of ‘this’ keyword in Java?..

Answer / hrindows@gmail.com

In Java, ‘this’ keyword represents a specific reference on the current object. There are multiple uses for this keyword for referring to the current class properties from a variable, constructors, methods, and more. You can also pass this as an argument within constructors or methods. You can also fetch this as a return value from the current class instance. You can also refer to this as a static context.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More Dot Net General Interview Questions

Please tell us what is the difference between override and overload in a method?

0 Answers  


Explain what is the difference between a class and an object?

0 Answers  


How do you generate a strong name?

0 Answers  


which is the best dot net coaching center in visakhapatnam??

3 Answers  


Explain what is mutex?

0 Answers  


What are the Characteristics of .NET?

1 Answers  


What is web.config in .net?

0 Answers  


How to get the number after decimal point in .net?

0 Answers  


What is the difference between a class and an object, and how do these terms relate to each other?

0 Answers  


Explain weg config settings for exception managment in asp.net?

1 Answers   C Squared Systems,


can we use private assembly in other project in dot net.

3 Answers  


Do you know the difference between the stack and the heap?

0 Answers  


Categories