On Sab, 8 de Enero de 2005, 18:33, Joerg Heinicke dijo: > On 08.01.2005 23:20, [EMAIL PROTECTED] wrote: >> Author: antonio >> Date: Sat Jan 8 14:20:56 2005 >> New Revision: 124685 >> >> URL: http://svn.apache.org/viewcvs?view=rev&rev=124685 >> Log: >> inner classes -> nested classes > > What's the reason for, the advantage of this change?
Inner classes has an automatic access to the members of the enclosing class (outer object). To do that, inner classes stores a reference to the particular object. If we don't need the connection between the inner class object and the outer class object, then we can make the inner class "static". And this is commonly called "nested class". Also a nested class means: 1. We don't need an outer-class object to create an object of the nested class. 2. We cannot access a non-static outer-class object from an object of a nested class. Hope this helps. Best Regards, Antonio Gallardo
