157 research outputs found

    Towards rule-based visual programming of generic visual systems

    Full text link
    This paper illustrates how the diagram programming language DiaPlan can be used to program visual systems. DiaPlan is a visual rule-based language that is founded on the computational model of graph transformation. The language supports object-oriented programming since its graphs are hierarchically structured. Typing allows the shape of these graphs to be specified recursively in order to increase program security. Thanks to its genericity, DiaPlan allows to implement systems that represent and manipulate data in arbitrary diagram notations. The environment for the language exploits the diagram editor generator DiaGen for providing genericity, and for implementing its user interface and type checker.Comment: 15 pages, 16 figures contribution to the First International Workshop on Rule-Based Programming (RULE'2000), September 19, 2000, Montreal, Canad

    Parsing of Adaptive Star Grammars

    Get PDF
    In a recent paper, adaptive star grammars have been proposed as an extension of node and hyperedge replacement grammars. A rule in an adaptive star grammar is actually a rule schema which, via the so-called cloning operation, yields a potentially infinite number of concrete rules. Adaptive star grammars are motivated by application areas such as modeling and refactoring object-oriented programs, and they are more powerful than node and hyperedge replacement grammars by this mechanism. It has been shown that the membership problem is decidable for a reasonably large subclass of adaptive star grammars, however no parser has been proposed. This paper describes such a parser for this subclass motivated by the well-known string parser by Cocke, Younger, and Kasami

    Generating Meta-Model-Based Freehand Editors

    Get PDF
    Most visual languages as of today (e.g., UML) are specified using a model in a meta-model-based approach. Editors for such languages have supported structured editing as the only editing mode so far. Free-hand editing that leaves the user more freedom during editing was not supported by any editor or editor framework since parsing has not yet been considered for meta-model-based specifications. This paper describes the diagram editor generator framework DiaMeta that makes use of meta-model-based language specifications and supports free-hand as well as structured editing. For analyzing freely drawn diagrams, DiaMeta parses a graph representation of the diagram by solving a constraint satisfaction problem

    Generating Instance Graphs from Class Diagrams with Adaptive Star Grammars

    Get PDF
    In model-driven software engineering, class diagrams are used to define the structure of object-oriented software and valid object configurations, i.e., what objects may occur in a program and how they are related. Object configurations are essentially graphs, so that class diagrams define graph languages. Class diagrams are declarative, i.e., it is quite easy to check whether a graph is an instance of a class diagram. Graph grammars, on the other hand, define a graph language by derivation and are thus well suited for constructing instance graphs. This paper describes how a class diagram can be translated into a graph grammar that defines the same graph language as the original class diagram. Such a graph grammar may then be used for, e.g., automatically generating valid object configurations as test cases. In contrast to earlier attempts, the presented approach allows to translate class diagrams with arbitrary multiplicities, unique and non-unique associations, composition associations, class generalization, association subsetting and redefinition. This is made possible by using adaptive star grammars, a special kind of graph grammars

    A Static Layout Algorithm for DiaMeta

    Get PDF
    The diagram editor generator framework DiaMeta utilizes meta-model-based language specifications and supports free-hand as well as structured editing. In this paper we present a layouting approach that is especially well suited for a static layout. It is based on the layout algorithm presented in a previous paper that uses the two concepts constraint satisfaction and attribute evaluation. This algorithm is combined with graph transformations and the result is a natural way of describing the layout of visual languages. As an example we use a simplified version of Sugiyama's algorithm, applied to statechart diagrams

    Specifying and Generating Editing Environments for Interactive Animated Visual Models

    Get PDF
    The behavior of a dynamic system is most easily understood if it is illustrated by a visual model that is animated over time. Graphs are a widely accepted approach for representing such dynamic models in an abstract way. System behavior and, therefore, model behavior corresponds to modifications of its representing graph over time. Graph transformations are an obvious choice for specifying these graph modifications and, hence, model behavior. Existing approaches use a graph to represent the static state of a model whereas modifications of this graph are described by graph transformations that happen instantaneously, but whose durations are stretched over time in order to allow for smooth animations. However, long-running and simultaneous animations of different parts of a model as well as interactions during animations are difficult to specify and realize that way. This paper describes a different approach. A graph does not necessarily represent the static aspect of a model, but rather represents the currently changing model. Graph transformations, when triggered at specific points of time, modify such graphs and thus start, change, or stop animations. Several concurrent animations may simultaneously take place in a model. Graph transformations can easily describe interactions within the model or between user and model, too. This approach has been integrated into the DiaMeta framework that now allows for specifying and generating editing environments for interactive animated visual models. The approach is demonstrated using the game Avalanche where many parallel and interacting movements take place

    Ambiguity Resolution for Sketched Diagrams by Syntax Analysis Based on Graph Grammars

    Get PDF
    Sketching, i.e., drawing diagrams by hand and directly on the screen, is gaining popularity, as it is a comfortable and natural way to create and edit diagrams. Hand drawing is inherently imprecise, and often sloppy. As a consequence, when processing hand drawn diagrams with a computer, ambiguities arise: it is not always clear what part of the drawing is meant to represent what component. Resolution of these ambiguities is the main issue of sketching. Ambiguity can only be solved by exploring the context of ambiguous components. This paper describes ambiguity resolution by syntax analysis in DiaGen, a generic framework for generating diagram editors. Such editors support free-hand editing (which is closely related to sketching), and allow for analyzing the created diagrams based on a hypergraph grammar. Our approach adds support for sketching to the generated editors. In order to resolve the ambiguities in sketched diagrams, DiaGen's diagram analysis based on graph parsing is used. The necessary modifications to DiaGen and its graph parser in particular are discussed

    Generating Correctness-Preserving Editing Operations for Diagram Editors

    Get PDF
    In previous work it has already been shown that syntax-directed and free-hand editing can be gainfully integrated into a single diagram editor. That way, the user can arrange diagram components on the screen without any restrictions in free-hand editing mode, whereas syntax-directed editing operations provide powerful assistance. So far, editing operations had to be specified or programmed by the editor developer. In contrast, this paper proposes an approach where diagram-specific editing operations are generated on the fly during the editing process and without any additional specification effort. These operations provably preserve the correctness of the diagram. The proposed approach requires a specification of the visual language by a hypergraph grammar

    Combination of Different Layout Approaches

    Get PDF
    In an interactive environment such as a visual language editor, it is not sufficient to apply the same layout algorithm in every situation. Instead, the user often wants to select the layout behavior at runtime. With the approach presented, the user can control the layout behavior by choosing different layout patterns for different parts of a diagram, e.g., a graph drawing algorithm may be applied to some selected components while others are aligned vertically or horizontally. To enable the specification of layout behavior, we introduced the concept of layout patterns in previous work. Each layout pattern encapsulates certain layout behavior, and hence enables modularization and reuse. To specify user-controlled layout behavior, a flexible combination of arbitrary layout patterns needs to be enabled. Therefore, we introduce an approach that is capable of combining diverse layout approaches, such as standard graph drawing algorithms, constraint-based algorithms, or rule-based layout algorithms. More specifically, an algorithm is presented that automatically computes the complete layout in a straightforward way
    • …
    corecore