Sciweavers

ECOOP
2000
Springer

Jam - A Smooth Extension of Java with Mixins

13 years 9 months ago
Jam - A Smooth Extension of Java with Mixins
Abstract. In this paper we present Jam, an extension of the Java language supporting mixins, that is, parametric heir classes. A mixin declaration in Jam is similar to a Java heir class declaration, except that it does not extend a fixed parent class, but simply specifies the set of fields and methods a generic parent should provide. In this way, the same mixin can be instantiated on many parent classes, producing different heirs, thus avoiding code duplication and largely improving modularity and reuse. Moreover, as happens for classes and interfaces, mixin names are reference types, and all the classes obtained instantiating the same mixin are considered subtypes of the corresponding type, hence can be handled in a uniform way through the common interface. This possibility allows a programming style where different ingredients are “mixed” together in defining a class; this paradigm is somehow similar to that based on multiple inheritance, but avoids the associated complicat...
Davide Ancona, Giovanni Lagorio, Elena Zucca
Added 02 Aug 2010
Updated 02 Aug 2010
Type Conference
Year 2000
Where ECOOP
Authors Davide Ancona, Giovanni Lagorio, Elena Zucca
Comments (0)