Win a copy of Design for the Mind this week in the Design forum!
    Bookmark Topic Watch Topic
  • New Topic

non-static inner class

 
Honey Khumalo
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Report post to moderator
WHAT IS THE MAIN PURPOSE OF USING THE NON-STATIC INNER CLASS?
*IS IT TO GET ACCESS TO OTHER CLASSES IN OTHER PACKAGES?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Report post to moderator
Please keep it down. Thank you.
 
Neha Agarwal
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
  • Report post to moderator
non-static inner classes keep a reference to the outer class allowing it to access member variables of the outer class
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Report post to moderator
Honey,

You've been asked several times to stop shouting in these forums.
If you continue to do this we will have to assume that you are deliberately being rude which violates our number one rule, "Be Nice".
Threads that contains questions which are not nice are subject to being deleted.

-Ben
 
    Bookmark Topic Watch Topic
  • New Topic