A Framework for Generating Query Language Code from OCL Invariants

Florian Heidenreich, Christian Wende, Birgit Demuth. A Framework for Generating Query Language Code from OCL Invariants. ECEASST, 9, 2008. [doi]


The semantical integrity of business data is of great importance for the implementation of business applications. Model-Driven Software Development (MDSD) allows for specifying the relevant domain concepts, their interrelations and their concise semantics using a plethora of modelling languages. Since model transformations enable an automatic mapping of platform independent models (PIMs) to platform specific models (PSMs) and code, it is reasonable to utilise them to derive data schemas and integrity rules for business applications. Most current approaches only focus on transforming structural descriptions of software systems while semantical specifications are neglected. However, to preserve also the semantical integrity rules we propose a Query Code Generation Framework that enables Model-Driven Integrity Engineering. This framework allows for mapping UML models to arbitrary data schemas and for mapping OCL invariants to sentences in corresponding declarative query languages, enforcing semantical data integrity on implementation level. This supersedes the manual translation of integrity constraints and, thus, decreases development costs while increasing software quality.