Uni-Logo

Institut für Informatik
 

Technical Report No. 247 - Abstract


Stefan Wehr, Peter Thiemann
JavaGI in the Battlefield: Practical Experience with Generalized Interfaces

Generalized interfaces are an extension of the interface concept found in object-oriented languages such as Java or C\#. The extension is inspired by Haskell's type classes. It supports retroactive and type-conditional interface implementations, binary methods, symmetric multimethods, interfaces over families of types, and static interface methods. This article reports practical experience with generalized interfaces as implemented in the JavaGI language. Several real-world case studies demonstrate how generalized interfaces provide solutions to extension and integration problems with components in binary form, how they make certain design patterns redundant, and how they eliminate various run-time errors. In each case study, the use of JavaGI results in elegant and highly readable code. Furthermore, the article discusses the implementation of a compiler and a run-time system for JavaGI. Benchmarks show that our implementation offers acceptable performance.


Report No. 247 (PostScript)