Can you have an inner class inside a method and what
variables can you access?
Answer Posted / kabita
yes we have.it is called local inner class.it can access
only final variables of outer class.
| Is This Answer Correct ? | 7 Yes | 0 No |
Post New Answer View All Answers
What is the basic concepts of OOPS?
Can we have a method name same as class name in java?
1.IN CASE OF DYNAMIC METHOD DISPATCH WHY WE USE REFERENCE VARIABLE,WE CAN USE THE DIFFERENT DEFINED OBJECT DIRECTLY TO ACCESS THE DATA MEMBER AND MEMBER FUNCTION OF THAT RESPECTIVE CLASS?WHAT IS THE MAIN FUNCTION OF "REFERENCE VARIABLE" HERE?
When is an object subject to garbage collection?
What about anonymous inner classes in java?
What is the difference between compare and compareto in java?
Explain serialization and deserialization in java?
What is console based application in java?
What is the Difference between Final Class && Abstract Class?
What is a java string?
What is the purpose of main function in java?
Can you make a constructor final?
Where is const variable stored?
How do you square a number?
What is string made of?