This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Inner 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 » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Inner classes" Watch "Inner classes" New topic

Inner classes

Arsho, Ayan
Ranch Hand

Joined: Nov 14, 2001
Posts: 60
Hello Everybody ,
Can a non-static inner classes be extended by other classes at all, I suppose static inner classes can be extended right??
Happy new Year
Michael Ernest
High Plains Drifter

Joined: Oct 25, 2000
Posts: 7292

Non-static inner classes are only defined by their presence in an enclosing instance. If there's a way to work that to meet your requirements, I haven't figured it out yet. Here's the easier case:

Happy New Year backatcha.
Michael Ernest, co-author of: The Complete Java 2 Certification Study Guide
[This message has been edited by Michael Ernest (edited January 01, 2002).]

Make visible what, without you, might perhaps never have been seen.
- Robert Bresson
Jose Botella
Ranch Hand

Joined: Jul 03, 2001
Posts: 2120
here you can see Bruce Eckel guru doing just that:
A piece of advice. Never inherit an inner from the enclosing one

SCJP2. Please Indent your code using UBB Code
Don't get me started about those stupid light bulbs.
subject: Inner classes
Similar Threads
Traps to be aware of in any SCJP test !!!!! :)
Inner class
local-method inner class
Member class can have static variables??
Subclass & Inner class