Please join our new Meetup page where all future BeJUG events will get published.

Java Generics


Since version 5, Java supports the definition of generic classes and generic interfaces. Even before their final release, the new language constructs were praised by some and critized by others. In this talk, we start with a short overview of the basic concepts for defining and instantiating generic classes in Java. We then discuss "type erasure" as a technique to ensure backward compatibility. At the same time, we pinpoint potential dangers of that approach. In the second part of the talk focus is on inheritance. We start this part with a short overview of wild cards in specifying generic arguments, and discuss their pros and cons. We conclude with problems that arise in developing hierarchies of generic classes and interfaces.

Eric Steegmans Biography

Eric Steegmans is a professor at the department of computer science of the K.U.Leuven. After a decade of research in compiler construction, he directed his research activities to the area of software engineering. Since the early nineties, his expertise is in object-oriented analysis, design and implementation. He is leading a small research group that experiments with new language concepts at different levels of abstraction. Since a few years, he is program director for the bachelor-master in informatics. He teaches basic courses on object-oriented programming in the bachelor informatics and the bachelor computer science. In the master programs, he is in charge of courses on object-oriented programming languages and on object-oriented analysis.

Presentation Slides

Code Examples

Download the presentation code examples.

Related Examples

Generic DAO example

Related Links

Feel free to add any interesting Java Generics links!

Adaptavist Theme Builder Powered by Atlassian Confluence