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

inner class

 
prasanna pati
Ranch Hand
Posts: 46
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Inner may be -> a class inside a class AND a class inside a method . So what is the difference between the two ?
 
Jeff Albertson
Ranch Hand
Posts: 1780
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Scope.

A class defined inside a method can access final variables, including local
ones. A member class can't access final local variables of a method.

Also, defining a local class inside a method gives the class name local
scope so that it can't be referenced elsewhere. It becomes an implementation
detail of the method.

 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic