Generating flexible code for associations

Mayer Goldberg, Guy Wiener

Research output: Chapter in Book/Report/Conference proceedingConference contributionpeer-review

Abstract

Generating code for associations is one of the most fundamental requirements from a model-based code generator. There are several approaches for implementing associations, ranging from using basic collections frameworks to using a database. The choice between them derive from the current requirements of the software: Whether parallelism, caching or persistency required for a relation. Hard-coding a specific design choice makes it difficult to alter it later. In this work, we propose a scheme that allows for automatic code generations of associations with different features, without requiring manual changes to the code. These features include using indices, traversing the association in parallel, or using an external database. Instead of the sequential iterator interface, we propose to use an interface that is based on operations over collections, such as Foreach, Filter, Map and Fold. This interface allows for writing operations that traverse the association without being dependent on the implementation details of the generated code.

Original languageEnglish
Title of host publicationENASE 2010 - Proceedings of the 5th International Conference on Evaluation of Novel Approaches to Software Engineering
Pages96-104
Number of pages9
StatePublished - 1 Dec 2010
Event5th International Conference on Evaluation of Novel Approaches to Software Engineering, ENASE 2010 - Athens, Greece
Duration: 22 Jul 201024 Jul 2010

Conference

Conference5th International Conference on Evaluation of Novel Approaches to Software Engineering, ENASE 2010
Country/TerritoryGreece
CityAthens
Period22/07/1024/07/10

Keywords

  • Associations
  • Code generation
  • Meta-programming
  • Model-driven architecture

ASJC Scopus subject areas

  • Software

Fingerprint

Dive into the research topics of 'Generating flexible code for associations'. Together they form a unique fingerprint.

Cite this