Model-driven Transformation for Optimizing PSMs - A Case Study of Rule Design for Multi-device GUI Generation

Software design and implementation, in general, have to take many alternatives into account for decision making. Still, current approaches to Model-driven Architecture (MDA) typically transform in one and only one thread from Platform-independent Models (PIMs) to Platform-specific Models (PSMs). Also in the special case of automatically generating graphical user interfaces (GUIs) according to MDA, in most approaches one thread derives a Final User Interface Model from some higher-level model(s). We think that this is one reason for less than optimal usability of automatically generated GUIs. Our transformation approach (as implemented for GUI generation) allows exploring different design alternatives and evaluating the resulting PSMs according to given optimization objectives. Such a search approach leads to optimal PSMs according to these objectives. In this way, resulting GUIs can be tailored for different devices such as tablet PCs and smartphones. In this context, we design transformation rules for optimizing PSMs independently from concrete device properties, which are given in separate device specifications (Platform Models). We present a related case study for multi-device GUI generation and show that this approach facilitates the automated optimization of PSMs for several devices. 1 BACKGROUND AND INTRODUCTION The Object Management Group’s Model Driven Architecture1 (MDA) proposes a generic concept to refine models over different levels of abstraction to source code. Between these levels, MDA proposes the use of transformation rules that transform a certain source model to a certain target model, as illustrated in Figure 1 for a transformation from Platform-independent Model (PIM) to Platformspecific Model (PSM). Important promises of MDA are, e.g., faster time-to-market and easier maintenance (Truyen, 2006). Figure 1: Standard Model-driven Transformation. Transformation languages like the Atlas Transformation Language2 (ATL) or Query / View / Trans1http://www.omg.org/mda/ 2http://www.eclipse.org/atl/ formations3 (QVT) have been developed to support the specification of transformation rules. These languages can reference any meta-model specified in an appropriate modeling language (typically Meta Object Facility4 (MOF) compliant languages like the Unified Modeling Language5 (UML) or Ecore) and are thus also applicable for model-driven UI generation. Each of these languages comes with its own transformation engine, which supports the execution of the specified transformation rules. These engines do not contain conflict resolution mechanisms, thus they allow for exactly one rule to match a certain pattern in the source model. In effect, each source model can be transformed to exactly one target model, as illustrated in Figure 1 for a transformation from PIM to PSM according to MDA. We consider this a major restriction, since software design (and implementation), in general, have to take many alternatives into account (Eramo et al., 2012). Ideally, the “best” design resulting from all possible alternatives should be taken. While software 3http://www.omg.org/spec/QVT/1.1/ 4http://www.omg.org/mof/ 5http://www.uml.org/ 496 Raneburger D., Popp R. and Kaindl H.. Model-driven Transformation for Optimizing PSMs A Case Study of Rule Design for Multi-device GUI Generation. DOI: 10.5220/0004490104960503 In Proceedings of the 8th International Joint Conference on Software Technologies (ICSOFT-PT-2013), pages 496-503 ISBN: 978-989-8565-68-6 Copyright c 2013 SCITEPRESS (Science and Technology Publications, Lda.) design as specified in practice may typically suggest that there is only the documented solution, many alternatives are typically considered and discussed. Automated generation of graphical user interfaces (GUIs) can also apply MDA, typically starting from high-level interaction models (e.g., Task Models according to (Paternò et al., 1997) and UsiXML6 or Discourse-based Communication Models (Falb et al., 2006; Popp and Raneburger, 2011)) and transforming them over different levels of abstraction to the source code of a GUI. Such approaches also apply transformation rules to transform the corresponding models between different levels of abstraction (Calvary et al., 2003). For automatically generated GUIs according to such an approach, the restriction through a singlethreaded transformation is even more obvious, since it is a major reason for the less than optimal usability visible to and experienced by the end-user. Multidevice GUI generation from a single source model obviously needs at least alternatives for each generated GUI, e.g., for a PC, a tablet PC and a smartphone. While several GUIs may be achieved through a specific set of transformation rules for each GUI, we strive for a single set of transformation rules for all supported devices. They should define a kind of search space, where a heuristic search can find optimal PSMs according to given optimization criteria and constraints posed by a given device (Platform). Figure 2 sketches this approach of modeldriven transformation with alternatives, where the Optimal PSMs correspond to different Platforms. The optimization happens in the course of the Transformation indicated through the rounded box, which Figure 3 zooms into for further illustration of this optimization approach to be explained below. A transformation engine that allows for matching more than one rule for the same source model pattern as required for this kind of optimization was developed by (Popp et al., 2012). While this engine is specific to GUI generation, we think that this optimization approach is generally applicable to model-driven software generation. This paper presents our approach to model-driven transformation including PSM optimization. A case study investigates the important aspect of designing transformation rules in such a context. In particular, we show characteristics that need to be considered when designing transformation rules that support multi-device GUI generation, where device specifications are given as separate Platform Models. In this way, the transformation rules can be defined indepen6USer Interface eXtensible Mark-up Language – http: //www.usixml.eu/ Figure 2: Model-driven Transformation with Alternatives for Optimization. dently from concrete device properties. The remainder of this paper is organized in the following manner. First, we discuss the state of the art, followed by a presentation of our new conceptual approach to PSM optimization. Then we provide some background material for our case study in the context of GUI generation, in order to make this paper selfcontained. Based on that, we elaborate on our case study on rule design for multi-device GUI generation and include lessons learned.

[1]  Krzysztof Z. Gajos,et al.  SUPPLE: automatically generating user interfaces , 2004, IUI '04.

[2]  Oscar Pastor,et al.  Model-Driven Development , 2008, Informatik-Spektrum.

[3]  Sophie Dupuy-Chessa,et al.  UsiComp: an extensible model-driven composer , 2012, EICS '12.

[4]  Fabio Paternò,et al.  ConcurTaskTrees: A Diagrammatic Notation for Specifying Task Models , 1997, INTERACT.

[5]  Jean Vanderdonckt,et al.  A Unifying Reference Framework for multi-target user interfaces , 2003, Interact. Comput..

[6]  Hermann Kaindl,et al.  Optimized GUI Generation for Small Screens , 2011, Model-Driven Development of Advanced User Interfaces.

[7]  Oscar Pastor,et al.  Using Profiles to Support Model Transformations in the Model-Driven Development of User Interfaces , 2008, CADUI.

[8]  Ragnhild Van Der Straeten,et al.  Module superimposition: a composition technique for rule-based model transformation languages , 2010, Software & Systems Modeling.

[9]  Henry Muccini,et al.  A model-driven approach to automate the propagation of changes among Architecture Description Languages , 2010, Software & Systems Modeling.

[10]  Fabio Paternò,et al.  One Model, Many Interfaces , 2002, CADUI.

[11]  David Raneburger,et al.  A High-Level Agent Interaction Protocol Based on a Communication Ontology , 2011, EC-Web.

[12]  Hermann Kaindl,et al.  Transforming Discourse Models to Structural User Interface Models , 2008, MoDELS.

[13]  Hermann Kaindl,et al.  A discourse model for interaction design based on theories of human communication , 2006, CHI EA '06.

[14]  Hermann Kaindl,et al.  A transformation engine for model-driven UI generation , 2012, EICS '12.