Representing and Composing First-class Features with FeatureJ

Software product lines (SPLs) enable creating product families, set of products that differ in terms of features. Traditionally, techniques for implementing features have sided with one of the two views of features: as distinguishable characteristics or as increments/changes in program functionality of the software under consideration. We argue that in order to realize the full potential of features as a separation of concerns mechanism or a modularity mechanism in its own right, both of these views must be supported by the representation of features. Furthermore, the composition of such uniformly represented features should be streamlined so that both can evolve together. Towards this end, we present FeatureJ, an implementation technique that integrates features, variants, and product lines as first-class entities, namely types, in the Java programming language. We review the trends in the representation and composition of features in the current implementation techniques and arrive at a set of requirements to represent features as first-class entities. We demonstrate the syntax of FeatureJ and explain its compiler architecture with a running example of a product line. We compare our implementation approach with other approaches in terms of the representation and composition of features and state the advantages that our approach brings to the implementation of SPLs.

[1]  Don S. Batory,et al.  Feature-oriented programming and the AHEAD tool suite , 2004, Proceedings. 26th International Conference on Software Engineering.

[2]  John R. Gurd,et al.  Groovy AOP: a dynamic AOP system for a JVM-based language , 2008 .

[3]  Sven Apel,et al.  Virtual Separation of Concerns - A Second Chance for Preprocessors , 2009, J. Object Technol..

[4]  Christian Prehofer,et al.  Feature-Oriented Programming: A Fresh Look at Objects , 1997, ECOOP.

[5]  Thomas Leich,et al.  Aspectual Feature Modules , 2008, IEEE Transactions on Software Engineering.

[6]  Sven Apel,et al.  Type-Safe Feature-Oriented Product Lines , 2010, ArXiv.

[7]  Stanley M. Sutton,et al.  Hyper/J™: multi-dimensional separation of concerns for Java™ , 2001, ICSE '02.

[8]  Ruzanna Chitchyan,et al.  A Model for Dynamic Hyperspaces , 2003 .

[9]  William R. Cook,et al.  Safe composition of product lines , 2007, GPCE '07.

[10]  Sven Apel,et al.  Superimposition: A Language-Independent Approach to Software Composition , 2008, SC@ETAPS.

[11]  Arie van Deursen,et al.  Domain-specific language design requires feature descriptions , 2002 .

[12]  Krzysztof Czarnecki,et al.  Staged configuration through specialization and multilevel configuration of feature models , 2005, Softw. Process. Improv. Pract..

[13]  Gunter Saake,et al.  Code generation to support static and dynamic composition of software product lines , 2008, GPCE '08.

[14]  Sven Apel,et al.  Type-Checking Software Product Lines - A Formal Approach , 2008, 2008 23rd IEEE/ACM International Conference on Automated Software Engineering.

[15]  Krzysztof Czarnecki,et al.  Generative programming - methods, tools and applications , 2000 .

[16]  Torbjörn Ekman,et al.  The JastAdd system - modular extensible compiler construction , 2007, Sci. Comput. Program..

[17]  Görel Hedin,et al.  JastAdd--an aspect-oriented compiler construction system , 2003, Sci. Comput. Program..

[18]  Sven Apel,et al.  An Overview of Feature-Oriented Software Development , 2009, J. Object Technol..

[19]  Danilo Beuche,et al.  Modeling and building software product lines with eclipse , 2004, OOPSLA '04.

[20]  Gunter Saake,et al.  Features as First-class Entities – Toward a Better Representation of Features , 2008 .

[21]  Oscar Nierstrasz,et al.  Traits: A mechanism for fine-grained reuse , 2006, TOPL.

[22]  Don S. Batory,et al.  Feature Models, Grammars, and Propositional Formulas , 2005, SPLC.

[23]  Don Batory,et al.  The Expression Problem as a Product Line and i ts Implementat ion in AHEAD , 2004 .

[24]  Sebastian Günther,et al.  Feature-oriented programming with Ruby , 2009, FOSD '09.

[25]  Matthew Flatt,et al.  Jiazzi: new-age components for old-fasioned Java , 2001, OOPSLA '01.

[26]  Kyo Chul Kang,et al.  Feature-Oriented Domain Analysis (FODA) Feasibility Study , 1990 .

[27]  Merijn de Jonge,et al.  Grammars as Feature Diagrams , 2002 .

[28]  Thomas Leich,et al.  FeatureC++: on the symbiosis of feature-oriented and aspect-oriented programming , 2005, GPCE'05.

[29]  Krzysztof Czarnecki,et al.  Synchronizing Cardinality-Based Feature Models and Their Specializations , 2005, ECMDA-FA.

[30]  Krzysztof Czarnecki,et al.  Formalizing cardinality-based feature models and their specialization , 2005, Softw. Process. Improv. Pract..

[31]  William R. Cook,et al.  A machine-checked model of safe composition , 2009, FOAL '09.

[32]  Lidia Fuentes,et al.  Language Support for Managing Variability in Architectural Models , 2008, SC@ETAPS.

[33]  Roberto Erick Lopez-Herrejon,et al.  Evaluating Support for Features in Advanced Modularization Technologies , 2005, ECOOP.

[34]  Sven Apel,et al.  FEATUREHOUSE: Language-independent, automated software composition , 2009, 2009 IEEE 31st International Conference on Software Engineering.

[35]  Sagar Sunkle,et al.  Enabling Feature-Oriented Programming in Ruby , 2009 .

[36]  Mira Mezini,et al.  Variability management with feature-oriented programming and aspects , 2004, SIGSOFT '04/FSE-12.

[37]  Katharina Mehner-Heindl,et al.  Improving Alignment of Crosscutting Features with Code in Product Line Engineering , 2007, J. Object Technol..

[38]  Sven Apel,et al.  A Case Study Implementing Features Using AspectJ , 2007, 11th International Software Product Line Conference (SPLC 2007).

[39]  Jia Liu,et al.  Refinements and multi-dimensional separation of concerns , 2003, ESEC/FSE-11.