can we create object for static class in java

Answer Posted / sandeep

an outer class cannot be static.it can only be declared as
pubic,abstract or final OR a combination..

an inner static class behaves just like a normal static member..

n yes v can creat an object of inner static class as....

Outer.Inner obj=new Outer.Inner();

Is This Answer Correct ?    38 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the difference between an inner class and a sub-class?

512


How to change the priority of thread or how to set the priority of thread?

624


How to store image in arraylist in java?

522


How many bytes is string in java?

618


Is it possible to use string in the switch case?

563






Explain java coding standards for classes or java coding conventions for classes?

630


What is a local class in java?

595


How we can declare a static variable?

658


Can we use a switch statement with strings?

559


What is += mean in java?

550


Can we sort list in java?

614


What is the significance of continue jump statement? Explain with an example.

758


What is the final class?

559


What is static import in java?

540


Lowest Common ancestor in a Binary Search Tree and Binary Tree.

566