What is inner class?what is the use of inner class?where we
create the object for inner class? and inner class can
extend any class or inner class can implement any interface?

Answer Posted / gajendar

In Java, just like methods, variables of a class too can have another class as its member. Writing a class within another is allowed in Java. The class written within is called the nested class, and the class that holds the inner class is called the outer class.
we can create object for inner class in methods of outer class.it can extend exactly 1 class or impliment 1 interface

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a method vs function?

738


What is the different between get and post?

703


What is procedure overloading?

2005


What are thread priorities and importance of thread priorities in java?

809


List two java ide’s?

803


What are the two types of java programming?

743


What is classname class in java?

745


How can we make string upper case or lower case?

775


Can arraylist contain null values?

742


How do you format in java?

764


What is lazy programming?

767


What is a percentage sign called?

816


What are the types of java languages?

719


How to do a true java ping from windows?

797


What are data types in oop?

764