FREE ELECTRONIC LIBRARY - Dissertations, online materials

Pages:   || 2 | 3 |

«Abstract. Today’s graphical modelling languages, despite using sym- bols and connections, represent large model parts as structured text. We ...»

-- [ Page 1 ] --

Textual Modelling Embedded into Graphical


Markus Scheidgen

Department of Computer Science, Humboldt Universit¨t zu Berlin


Unter den Linden 6, 10099 Berlin, Germany


Abstract. Today’s graphical modelling languages, despite using sym-

bols and connections, represent large model parts as structured text.

We benefit from sophistic text editors, when we use programming lan-

guages, but we neglect the same technology, when we edit the textual parts of graphical models. Recent advances in generative engineering of textual model editors allow to create such sophisticated text editors more efficiently. Therefore, textual modelling becomes practical for the textual parts of graphical models. In this paper, we present the neces- sary techniques to embed generated EMF-based textual model editors into graphical editors created with GMF and tree-based editors gener- ated with EMF.

1 Introduction Today’s graphical modelling and domain specific languages represent large model parts as structured text. Even though, those languages use symbols and connec- tion to represent model structures visually, there are typical model elements that should only be represented as text. Examples for these elements are signatures in UML class diagrams or meta-models, mathematical expressions in many DSLs, the many constructs in SDL (a language that is a mix of graphical modelling and programming language), or the combination of structure modelling and OCL.

The last example manifests in UML tools that allow to add OCL constraints to UML models, but only offer simple text editors. These OCL editors barely provide syntactical checks and keyword highlighting. As a result, model editor users produce many errors in OCL constraints. Errors that stay unnoticed until later processing; errors that when finally noticed are hard to relate to the OCL constraint parts that caused them. In other examples, like operation signatures in UML class diagrams, we often have no textual editing capabilities at all. So we click signatures together. This process is slower and less intuitive than writing the signature down. As a general conclusion, editing the textual parts of models is less efficient than editor technology for programming languages would allow.

To program, we use modern programming environments with highly capa- ble language dependent text editors. These last generation editors allow us to program far more efficiently than we programmed with plain text editors that 2 Fig. 1. The ecore GMF editor with an embedded textual model editor.

were used before and that are still used for editing text parts in graphical model editors.

These modern text editors are complex pieces of software and have to be build for each language with extensive efforts. Recent research, however, provides us with meta-languages and meta-tools for the description and automatic generation of such highly capable text editors. An editor or language engineer only provides descriptions for language and textual notation. Meta-tools can then generate editors from those high-level language descriptions automatically. The usual feature set of these editors comprises syntax highlighting, outline views, annotation of syntactical and semantic errors, occurrence markings, content-assist, code formatting, and so on. These editors can be used to edit text or create models as instances of according meta-models. We call the usage of languages with textual notations textual modelling and the process of using such editors textual model editing. The combination of meta-language for textual notations and according meta-tools is called a textual editing framework.

In this paper, we combine textual modelling with graphical modelling; we embed generated textual model editors into graphical editors (or any other editor based on the model view controller pattern for that matter). Editor users can open embedded text editors by clicking on an element within the graphical host editor. These embedded editor are, for example, shown in small overlay windows, positioned at the selected element (see figure 1). Within these embedded editors, the user gets all the features known from modern programming environments. We use our textual editing framework (TEF) to create embedded editors for graphical editors developed with the eclipse graphical modelling framework (GMF). TEF allows to create textual notation for arbitrary EMF meta-models.

We can take a meta-model that we already have a GMF editor for, and create an additional textual notation for that meta-model.

3 This work has the potential to enhance the effectiveness of graphical modelling with languages that rely on textual representations of expressions, signatures, etc. Furthermore, it encourages the use of domain specific modelling, since it allows the efficient development of DSLs that combine the graphical and textual modelling paradigms. In general, this work could provide the tooling for a new breed of languages that combine the visualisation and editing advantages of both graphical notations and programming languages.

The remainder of this paper is structured as follows. The next section 2 gives background information about textual modelling, and introduces the background parsing strategy which is used by most textual editing frameworks. The next section 3 introduces three problems that arise, when we integrate textual model editors into other editors. We discuss the possible solutions to these problems.

In section 4, we describe the realisation of embedded textual modelling based on our textual editing framework TEF, the eclipse modelling framework EMF, and the eclipse Graphical Modelling Framework GMF, and several example projects.

The paper is closed with related work 5 and conclusions 6.

2 State of the Art in Textual Model Editing Textual model editing describes the process changing a model by changing its textual representation. The necessary textual editing tools are developed by language engineers using textual model editing frameworks. These frameworks provide a notation description language, which is used to define textual notations. The efforts of describing a textual notation is paid off in feature rich textual model editors automatically generated. Depending on the used framework, these editors support syntax highlighting, outline views, error annotations, content-assist, etc., and of course they can create a model from a textual representation.

Before we embed textual modelling into graphical modelling, we use this section to introduce textual model editing concepts based on our framework TEF. More about textual modelling and editing frameworks can be learned from [1,2,3,4].

Models and meta-models. We use the term model to refer to an


structure, where possible elements of this structure are predetermined through a meta-model. A meta-model thus defines a set of possible models. Three things are important about the term model in this paper. One, a model is always an instance of a language; a model therefore is always an instance of a metamodel. Two, we don’t care about the semantics and pragmatics of a model or its language. Therefore, we use the term for both models that are an abstraction of something, like the UML model of a software system, and for models that describe a software system in all detail, like the Java code that constitutes a software system. Three, a model needs representation. This can be a visual representation as a diagram or a piece of text. In the same way a model is an instance of a meta-model, a model representation is an instance of a notation.

Meta-model and notation have to be related.

4 syntax(Package) ”models/Ecore.ecore” { Package:element(EPackage) package” IDENTIFIER:composite(name) ”{” (PackageContents)* ”}”;

PackageContents - Package:composite(eSubpackages);

PackageContents - Class:composite(eClassifiers);

PackageContents - DataType:composite(eClassifiers);

Class:element(EClass) class” IDENTIFIER:composite(name) (SuperClasses)?

”{” (ClassContents)* ”}”;

SuperClasses - ”extends” ClassRef:reference(eSuperTypes) (”,” ClassRef:reference(eSuperTypes))*;

ClassRef:element(EClass) - IDENTIFIER:composite(name);

DataType:element(EDataType) -...

ClassContents - ”attribute” Attribute:composite(eStructuralFeatures);

ClassContents - ”reference” Reference:composite(eStructuralFeatures);

ClassContents - Operation:composite(eOperations);

Attribute:element(EAttribute) - IDENTIFIER:composite(name) ”:” TypeRef:reference(eType) Multiplicity;

Reference:element(EReference) -...;

Operation:element(EOperation) - IDENTIFIER:composite(name) ”(” (Parameter:composite(eParameters) (”,” Parameter:composite(eParameters))*)? ”)” ”:” OperationReturn;

OperationReturn - TypeRef:reference(eType) Multiplicity;

OperationReturn - ”void”;

Parameter:element(EParameter) - IDENTIFIER:composite(name) ”:” TypeRef:reference(eType) Multiplicity;

TypeRef:element(EClassifier) - IDENTIFIER:composite(name);

Multiplicity - (”[” INTEGER:composite(lowerBound) ”:” UNLIMITED INTEGER:composite(upperBound) ”]”)?;

–  –  –

package namespaces { class NamedElement { attribute name:EString[0,1] } class Namespace extends NamedElement { reference contents:NamedElement[0,*] getQualifiedName(separator:EString[0,1]):EString[1,1] } } parsing

–  –  –

Fig. 3. An example background parsing within an textual ecore editor.

Textual representations and notations. Textual modelling uses text to represent models. Textual model editors show the edited model in its textual representation and allow users to change the edited model by changing its textual representation. Textual modelling is based on textual notations. A textual notation consists of a context-free grammar, and a mapping that relates this grammar with the language’s meta-model. The grammar defines a set of syntactical correct textual representations. The mapping identifies the model corresponding 6 to a representation. Figure 2 shows an example notation. This notation for the ecore language is mapped to the ecore meta-model. A possible instance of this notation is shown in the top of figure 3. This textual notation instance is the representation for the ecore model represented graphically on the right side of the same figure.

Over the time, several languages for the definition of textual model notations have been created (refer to the related works section). The notation shown in figure 2 is written for our TEF framework. It is basically a combination of an context-free grammar with BNF elements, augmented with mappings to a metamodel. All string literals function as fixed terminals; all capitalized symbols are morphems for integers or identifiers; everything else are non-terminals. The bold printed elements map grammar elements to meta-model classes and features. If sucha meta-model relation is attached to the left-hand-side of a rule, the rule is related to a meta-model class; if attached to a right-hands-side symbol, this right-hand-side rule part is related to a feature. We distinguish between different kinds of meta-model relations: (1) element relations relate to classes, composite relations relate to attributes or other compositional structural features, and reference references refer to non compositional structural features.

The background parsing process. Most existing textual model editors use background parsing. Background parsing is a strategy to technically realise textual editing for context-free grammar based notations. Background parsing is done in three continuously repeated steps. First, the user edits text using a normal text editor. Second, the inserted text is parsed according to the notation’s grammar.

Third, a model is created from the resulting parse-tree based on a given metamodel and grammar to meta-model mapping. The user is unaware of the parsing process, and continuous repetition gives the impression that the user edits the model directly. Background parsing, as opposed to other editing strategies, does not change the model. Instead, is creates a completely new model with each change to the textual representation. This distinct characteristic will become important later.

Creating models from parse-trees. The result of parsing a textual representation is a syntax-tree or parse-tree. Each node in a parse-tree is an instance of the grammar rule that was used to produce the node. To create a model from a parse-tree, editors perform two depth-first traversals of the tree.

In the first run, editors use the element relations attached to a node’s rule to create an instance of the according meta-model class. The created object becomes the value represented by this node. It also serves as the context for traversing the children of this node. Morphems create according primitive values, e.g. integers or strings. During the same traversal, we use the composite relations, attached to right-hand-side symbols to add the values created by the respective child nodes to the referenced features in the actual context objects.

Pages:   || 2 | 3 |

Similar works:

«How to use this document: What is this document? In this document, you will find an introduction to mapping and the parameters used, as well as how Microsoft Certifications and IT Academy learning curriculum relate to popular international frameworks. This is an independent and informed assessment of the certification and learning materials in  the context of international and country-specific education standards (mapping prepared on cert behalf of Microsoft by IT Solutions Ltd.). The...»

«“Isa Genzken in conversation with Wolfgang Tillmans.” Camera Austria (2003): 7-18 Isa Genzken in conversation with Wolfgang Tillmans Wolfgang Tillmans: Chicago was the first city to have skyscrapers? Isa Genzken: Chicago was the birthplace of skyscrapers; there was a big fire once that destroyed almost all the houses – at one fell s woop – and then they started building up. That’s how the first skyscrapers came about. Earlier than in New York. W. Tillmans: It was because they invented...»

«DOCUMENT RESUME EC 307 741 ED 439 562 Miller, Maurice; Fritz, Marie F.AUTHOR What Do Special Education Students Think of School TITLE Placements? 2000-00-00 PUB DATE NOTE 29p. Research (143) Reports Information Analyses (070) PUB TYPE MF01/PCO2 Plus Postage.EDRS PRICE *Disabilities; Elementary Secondary Education; *Inclusive DESCRIPTORS Schools; *Resource Room Programs; Social Integration; Special Programs; *Student Attitudes; *Student Placement ABSTRACT This report discusses the findings of a...»

«WATER SUPPLY REPORT SERIES II INFORMATION FOR ENHANCING INSTREAM FLOWS TO BENEFIT SALMONIDS IN THE UPPER CLARK FORK RIVER PREPARED FOR: CLARK FORK RIVER BASIN TASK FORCE AND MONTANA DNRC (RFP #145041FSU) MAY 28, 2015 KIRK ENGINEERING & NATURAL RESOURCES, INC. SHERIDAN & MISSOULA, MONTANA Table of Contents Report Oveview Chapter 1. Metals Limitation to Salmonids of the Upper Clark Fork River Chapter 2. Flow and Salmonid Habitat Conditions in Gravel Bed Rivers Chapter 3. Methods for Determining...»

«División de los Derechos de los Palestinos Noviembre de 2009 Volumen XXXII, Boletín núm. 11 Boletín sobre las actividades del sistema de las Naciones Unidas y las organizaciones intergubernamentales relacionadas con la cuestión de Palestina Índice Página I. El Secretario General expresa su consternación por el hecho de que continúen las demoliciones y las actividades de asentamiento en Jerusalén Oriental.................. 3 II. La Asamblea General aprueba la...»

«User's Guide Digital Datalogging Sound Level Meter Model HD600 Introduction Congratulations on your purchase of the Extech HD600 Digital Sound Level Meter. This meter measures and displays sound pressure levels in dB (decibels) from 30 to 130dB in three measurement ranges. In addition to the LCD numerical displays, a bargraph is included for quick and easy viewing of sound level changes. Features include selectable Frequency Weighting („A‟ and „C‟), selectable Response Time (Fast and...»

«Appendix B – Survey of Water Softener Penetration into the Residential Market in the Phoenix Metropolitan Area Survey of Water Softener Penetration Into the Residential Market in The Phoenix Metropolitan Area Prepared For: U.S. DEPARTMENT OF THE INTERIOR BUREAU OF RECLAMATION LOWER COLORADO REGION PHOENIX AREA OFFICE 1 November 11, 2004 Prepared By: Insights & Solutions, Inc. 8222 S. 48th St. Suite 210 Phoenix Arizona 85044 (480) 874-1222 1 Fax (480) 874-2111 insightssolutions.com 1 TABLE OF...»

«CASE: IB-52 DATE: 01/26/04 ANGOLA’S MISLAID BILLIONS Oil is the devil’s excrement. We are drowning in the devil’s excrement. —Juan Pablo Pérez Alfonso, Venezuelan founder of the Organization of Petroleum Exporting Countries1 The problem is that the good Lord didn’t see fit to always put oil and gas resources where there are democratic governments. —Dick Cheney, when CEO of the oil-services company Halliburton2 This is all lies. —Manuel Vicente, head of the Angolan state-owned oil...»

«ORDEM DOS ADVOGADOS DO BRASIL XVII EXAME DE ORDEM UNIFICADO PROVA PRÁTICO-PROFISSIONAL Aplicada em 13/09/2015 ÁREA: DIREITO EMPRESARIAL “O gabarito preliminar da prova prático-profissional corresponde apenas a uma expectativa de resposta, podendo ser alterado até a divulgação do padrão de respostas definitivo.” Qualquer semelhança nominal e/ou situacional presente nos enunciados das questões é mera coincidência.” RETIFICAÇÃO DO PADRÃO DE RESPOSTA PEÇA PROFISSIONAL Enunciado...»

«A Theoretical Framework for Analysis of Image Transfer in Multiple Sponsorships Pi-Hsuan Monica Chien, Queensland University of Technology T. Bettina Cornwell, University of Queensland Robyn Stokes, Queensland University of Technology Abstract Despite the growing importance of sponsorship as a marketing communication function, little is known about how consumers process this information in their brand assessment. Although many scholars have sought to provide theoretical explanations about the...»

«ROUTLEDGE STUDIES IN RELIGION, TRAVEL, AND TOURISM International Perspectives on Pilgrimage Studies Itineraries, Gaps and Obstacles Edited by Dionigi Albera and John Eade ROUTLEDGE STUDIES IN RELIGION, TRAVEL, AND TOURISM Edited by John Ead e, Roehampton University; Ian R ead er, Lancaster University; A la n a H arris, University of O xford an d Ellen B ad o n e, MacMaster University P ilg rim ag e to the N atio nal P a rk s Religion and Nature in the United States Lynn Ross-Bryant P ilg rim ag...»

«A NOBLE GROOM JODY HEDLUND 5 Jody Hedlund, A Noble Groom Bethany House, a division of Baker Publishing Group, © 2013. Used by permission. © 2013 by Jody Hedlund Published by Bethany House Publishers 11400 Hampshire Avenue South Bloomington, Minnesota 55438 www.bethanyhouse.com Bethany House Publishers is a division of Baker Publishing Group, Grand Rapids, Michigan Printed in the United States of America All rights reserved. No part of this publication may be reproduced, stored in a retrieval...»

<<  HOME   |    CONTACTS
2016 www.dissertation.xlibx.info - Dissertations, online materials

Materials of this site are available for review, all rights belong to their respective owners.
If you do not agree with the fact that your material is placed on this site, please, email us, we will within 1-2 business days delete him.