An Extended Concept of Delegation and its Implementation within a Modelling and Programming Language Architecture
DOI:
https://doi.org/10.18417/emisa.19.2Keywords:
Delegation, Inheritance, Specialization, Subclassing, Object-oriented Modelling, Software-architectureAbstract
Object-oriented modeling languages provide various concepts to express abstractions, which foster reuse and integrity. Among these concepts, generalization/specialization is of specific relevance. However, in many cases where generalization/specialization seems to be a natural choice, its use is likely to jeopardize a system’s integrity. Delegation has for long been known as an alternative that allows preventing the accidental damage caused by the inproper use of specialization. Nevertheless, delegation is ignored by most tools for object-oriented modeling as well as by many textbooks, which may be caused by the fact that there is no unified conception of delegation, and that delegation is not supported by most object-oriented programming languages. This paper aims at a revival of delegation. To that end, the need for delegation is motivated by the analysis of counter-intuitive effects of specialization. Based on an extensive requirements analysis, a new, extended conception of delegation is presented. It allows for using delegation between classes on any (meta-) level and introduces the "delegation to class" pattern. Delegation in multi-level environments enables an additional reduction of redundancy and, hence, promotes integrity. The paper also presents design guidelines to foster the appropriate use of delegation. With respect to the implementation of delegation with object-oriented programming languages, two alternative flavours of delegation are analyzed. Finally, a prototypical implementation within a language engineering and execution environment does not only demonstrate the use of delegation in a modeling tool, but also its seamless implementation, by featuring a common representation of models and code at runtime.
Additional Files
Published
Issue
Section
License
Copyright (c) 2024 Ulrich Frank
This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.
Authors who publish with this journal agree to the following terms: Authors retain copyright and grant the journal 'Enterprise Modelling and Information Systems Architectures - International Journal of Conceptual Modeling' and the Gesellschaft für Informatik e.V. (GI) the permission of first publication, and the non-exclusive, irrevocable and non-time limited publication permission for the submitted work including the permissions to store, copy, distribute and reproduce their work in printed and electronic form for the duration of the legal copyright. This includes the right of translation. Authors grant the journal 'Enterprise Modelling and Information Systems Architectures - International Journal of Conceptual Modeling' and the Gesellschaft für Informatik e.V. (GI) the permission to license their work under a Creative Commons BY-SA 4.0 license that allows others to share the work with an acknowledgement of the work's authorship and initial publication in this journal. Authors are able to enter into separate, additional contractual arrangements for the non-exclusive distribution of the journal's published version of the work (e.g., post it to an institutional repository or publish it in a book) given an acknowledgement of its initial publication in this journal.
Authors are permitted and encouraged to post their work online (e.g., in institutional repositories or on their website) prior to and during the submission process, as it can lead to productive exchanges, as well as earlier and greater citation of published work (See The Effect of Open Access). The submitting corresponding author on behalf of all co-authors asserts that she/he is entitled to the granting of the above mentioned permissions for the submitted work.