jQuery in Action, 2nd edition*
The moose likes Beginning Java and the fly likes nested classes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "nested classes" Watch "nested classes" New topic
Author

nested classes

Jitendra Jha
Ranch Hand

Joined: Jan 28, 2007
Posts: 91
I have come across a book which says that 2 types of nested classes.static and non-static.
how to create a static nested class?


Jitendra
SCJP1.5
SCWCD1.5
Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24183
    
  34



[Jess in Action][AskingGoodQuestions]
Jim Yingst
Wanderer
Sheriff

Joined: Jan 30, 2000
Posts: 18671
Of course, it's more likely to compile if you give the nested class a different name from the outer class.


"I'm not back." - Bill Harding, Twister
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: nested classes
 
Similar Threads
Static Nested Classes
Member class vs inner class
regarding inner classes
Can a class be defined in an interface?
Static class??