GENERIC TRAITS IN STATICALLY TYPED LANGUAGES - How to do It?

Andreas Svendsen, Birger Mller-Pedersen

2008

Abstract

Traits have been proposed as a code reuse mechanism for dynamically typed languages. The paper addresses the issues that come up when introducing traits in statically typed languages, such as Java. These issues can be resolved by introducing generic traits, but at some cost. The paper studies three different generic mechanisms: Java Generics, Templates and Virtual Types, by implementing them all by a preprocessor to Java. The three different approaches are tested by a number of examples. Based on this, the paper gives a first answer to which of the three generic mechanisms that are most adequate.

Download


Paper Citation


in Harvard Style

Svendsen A. and Mller-Pedersen B. (2008). GENERIC TRAITS IN STATICALLY TYPED LANGUAGES - How to do It? . In Proceedings of the Third International Conference on Software and Data Technologies - Volume 1: ICSOFT, ISBN 978-989-8111-51-7, pages 39-46. DOI: 10.5220/0001870700390046

in Bibtex Style

@conference{icsoft08,
author={Andreas Svendsen and Birger Mller-Pedersen},
title={GENERIC TRAITS IN STATICALLY TYPED LANGUAGES - How to do It?},
booktitle={Proceedings of the Third International Conference on Software and Data Technologies - Volume 1: ICSOFT,},
year={2008},
pages={39-46},
publisher={SciTePress},
organization={INSTICC},
doi={10.5220/0001870700390046},
isbn={978-989-8111-51-7},
}


in EndNote Style

TY - CONF
JO - Proceedings of the Third International Conference on Software and Data Technologies - Volume 1: ICSOFT,
TI - GENERIC TRAITS IN STATICALLY TYPED LANGUAGES - How to do It?
SN - 978-989-8111-51-7
AU - Svendsen A.
AU - Mller-Pedersen B.
PY - 2008
SP - 39
EP - 46
DO - 10.5220/0001870700390046