Amazon Interview Question
Software Engineer / Developers4 Type of inner class
1) static class
2) member class
3) local class
4) anonymous class
member class is used to add more object oriented the touch to the language.
Read article for tree and tree search algorithm example.
anonymous class are used as callback methods mainly used in case of event handlers. These classes donot have any name but they use already existing class name to add more specific functionality.
Anonynous inner class are useful for even handling.
- Anonymous October 20, 2008