An interesting article about reducing the amount of code needed to implement a certain objectmodel, using JDK1.5’s generics.
“Model-View-Controller (MVC) is a widely used design pattern, especially popular in graphical user interface (GUI) programming. JDK 1.5 introduces parameterized types, or generics. Combining the two allows for a generic implementation of the MVC design pattern, freeing the programmer from writing code that handles the registration and notification of listeners, as well as from writing getter and setter methods for the properties of models. This article shows how this can be accomplished.”
I’m not sure if i find the code better readable, but that may also be because i’m not yet that accustomed to read code that uses generics..