What is the use of anonymous inner classes ?
Answer Posted / bindhu
We can declare an inner class within the body of a method
without naming it. These classes are known as anonymous
inner classes
Very useful for controlled access to the innards
of another class. and useful when we need one instance of a
special class.
| Is This Answer Correct ? | 11 Yes | 6 No |
Post New Answer View All Answers
Why are the objects immutable in java?
What is a super method?
What is java oops?
Why do we need hashset in java?
What is fail fast in java?
What is string intern in java?
Can we create an object of static class in java?
If we don’t want some of the fields not to serialize how to do that?
what is recursion in java
How many types of methods are there?
Can we sort hashmap in java?
what is the use of bean managed and container managed with example?
Write a program to reverse array in place?
How do you sing an Applet ?
Are variables stored in ram?