File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Top level nested classes?

 
Mike Kelly
Ranch Hand
Posts: 78
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which of the following statements are true about Inner classes?
A top level nested class is a static class and thus does not need an instance of it's enclosing class. (Jwhiz exam #1,Q13)
My Question: Top level class means non-inner, nested class means inner, how can there be a top level nested class?
 
Dave Vick
Ranch Hand
Posts: 3244
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Mike
A static inner clas is commonly refered to as a top level nested class. Because it's static, like all other static variables, it doesn't need an instance of the outer class to be created.
hope that helps
Dave
 
Mike Kelly
Ranch Hand
Posts: 78
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Dave Vick:
Mike
A static inner clas is commonly refered to as a top level nested class. Because it's static, like all other static variables, it doesn't need an instance of the outer class to be created.
hope that helps
Dave

Alrighty then. Because I have no other programming experience, I'm suceptible to mistakes like these. I had never heard the term. I knew top level and nested, but not toplevel nested.
Thanks again.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic