File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Beginning Java and the fly likes anonymous local class Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "anonymous local class" Watch "anonymous local class" New topic
Author

anonymous local class

Syamsul Hussin
Ranch Hand

Joined: Feb 09, 2003
Posts: 59
please explain to me about anonymous local class and when should we use them. thanks
Elouise Kivineva
Ranch Hand

Joined: Feb 07, 2002
Posts: 154
An anonymous inner class is an inner class without a name. To my knowlege they are usually used as event handlers. If you only need a certain event handler in one place, why bother creating it as a separate class when you can just give all the relevant information right where the object is used?

[ February 25, 2003: Message edited by: Elouise Kivineva ]
 
 
subject: anonymous local class
 
Threads others viewed
Inner class basics. (Marcus Green's mock exam 2)
Anonymous inner class
anonymous?
Anonymous class...please help
anonymous class in methods
developer file tools

cast iron skillet 49er

more from paul wheaton's glorious empire of web junk: cast iron skillet diatomaceous earth rocket mass heater sepp holzer raised garden beds raising chickens lawn care CFL flea control missoula heat permaculture