436 research outputs found

    Refactoring OCL annotated UML class diagrams

    Get PDF
    Refactoring of UML class diagrams is an emerging research topic and heavily inspired by refactoring of program code written in object-oriented implementation languages. Current class diagram refactoring techniques concentrate on the diagrammatic part but neglect OCL constraints that might become syntactically incorrect by changing the underlying class diagram. This paper formalizes the most important refactoring rules for class diagrams and classifies them with respect to their impact on attached OCL constraints. For refactoring rules that have an impact on OCL constraints, we formalize the necessary changes of the attached constraints. Our refactoring rules are specified in a graph-grammar inspired formalism. They have been implemented as QVT transformation rules. We finally discuss for our refactoring rules the problem of syntax preservation and show, by using the KeY-system, how this can be resolve

    Refactoring OCL Annotated UML Class Diagrams

    Get PDF
    Refactoring of UML class diagrams is an emerging research topic and heavily inspired by refactoring of program code written in object-oriented implementation languages. Current class diagram refactoring techniques concentrate on the diagrammatic part but neglect OCL constraints that might become syntactically incorrect by changing the underlying class diagram. This paper formalizes the most important refactoring rules for class diagrams and classifies them with respect to their impact on annotated OCL constraints. For refactoring rules, whose application on class diagrams could make attached OCL constraints incorrect, we formally describe how the OCL constraints have to be refactored to preserve their syntactical correctness. Our refactoring rules are defined in the graph-grammar based formalism proposed by the QVT Merge Group for the specification of model transformations

    A heuristic-based approach to code-smell detection

    Get PDF
    Encapsulation and data hiding are central tenets of the object oriented paradigm. Deciding what data and behaviour to form into a class and where to draw the line between its public and private details can make the difference between a class that is an understandable, flexible and reusable abstraction and one which is not. This decision is a difficult one and may easily result in poor encapsulation which can then have serious implications for a number of system qualities. It is often hard to identify such encapsulation problems within large software systems until they cause a maintenance problem (which is usually too late) and attempting to perform such analysis manually can also be tedious and error prone. Two of the common encapsulation problems that can arise as a consequence of this decomposition process are data classes and god classes. Typically, these two problems occur together – data classes are lacking in functionality that has typically been sucked into an over-complicated and domineering god class. This paper describes the architecture of a tool which automatically detects data and god classes that has been developed as a plug-in for the Eclipse IDE. The technique has been evaluated in a controlled study on two large open source systems which compare the tool results to similar work by Marinescu, who employs a metrics-based approach to detecting such features. The study provides some valuable insights into the strengths and weaknesses of the two approache

    Model refactoring using transformations

    Get PDF
    Modern software is reaching levels of complexity encountered in biological systems; sometimes comprising systems of systems each of which may include tens of millions of lines of code. Model Driven Engineering (MDE) advocates raising the level of abstraction as an instrument to deal with software complexity. It promotes usage of software models as primary artifacts in a software development process. Traditionally, these MDE models are specified by Unified Modeling Language (UML) or by a modeling language created for a specific domain. However, in the vast area of software engineering there are other techniques used to improve quality of software under development. One of such techniques is refactoring which represents introducing structured changes in software in order to improve its readability, extensibility, and maintainability, while preserving behavior of the software. The main application area for refactorings is still programming code, despite the fact that modeling languages and techniques has significantly gained in popularity, in recent years. The main topic of this thesis is making an alliance between the two virtually orthogonal techniques: software modeling and refactoring. In this thesis we have investigated how to raise the level of abstraction of programming code refactorings to the modeling level. This resulted in a catalog of model refactorings each specified as a model transformation rule. In addition, we have investigated synchronization problems between different models used to describe one software system, i.e. when one model is refactored what is the impact on all dependent models and how this impact can be formalized. We have concentrated on UML class diagrams as domain of refactorings. As models dependent on class diagrams, we have selected Object Constraint Language (OCL) annotations, and object diagrams. This thesis formalizes the most important refactoring rules for UML class diagrams and classifies them with respect to their impact on object diagrams and annotated OCL constraints. For refactoring rules that have an impact on dependent artifacts we formalize the necessary changes of these artifacts. Moreover, in this thesis, we present a simple criterion and a proof technique for the semantic preservation of refactoring rules that are defined for UML class and object diagrams, and OCL constraints. In order to be able to prove semantic preservation, we propose a model transformation approach to specify the semantics of constraint languages

    Transformation Techniques for OCL Constraints

    Get PDF
    Constraints play a key role in the definition of conceptual schemas. In the UML, constraints are usually specified by means of invariants written in the OCL. However, due to the high expressiveness of the OCL, the designer has different syntactic alternatives to express each constraint. The techniques presented in this paper assist the designer during the definition of the constraints by means of generating equivalent alternatives for the initially defined ones. Moreover, in the context of the MDA, transformations between these different alternatives are required as part of the PIM-to-PIM, PIM-to-PSM or PIM-to-code transformations of the original conceptual schema

    Collaborative Verification-Driven Engineering of Hybrid Systems

    Full text link
    Hybrid systems with both discrete and continuous dynamics are an important model for real-world cyber-physical systems. The key challenge is to ensure their correct functioning w.r.t. safety requirements. Promising techniques to ensure safety seem to be model-driven engineering to develop hybrid systems in a well-defined and traceable manner, and formal verification to prove their correctness. Their combination forms the vision of verification-driven engineering. Often, hybrid systems are rather complex in that they require expertise from many domains (e.g., robotics, control systems, computer science, software engineering, and mechanical engineering). Moreover, despite the remarkable progress in automating formal verification of hybrid systems, the construction of proofs of complex systems often requires nontrivial human guidance, since hybrid systems verification tools solve undecidable problems. It is, thus, not uncommon for development and verification teams to consist of many players with diverse expertise. This paper introduces a verification-driven engineering toolset that extends our previous work on hybrid and arithmetic verification with tools for (i) graphical (UML) and textual modeling of hybrid systems, (ii) exchanging and comparing models and proofs, and (iii) managing verification tasks. This toolset makes it easier to tackle large-scale verification tasks

    Example-driven meta-model development

    Full text link
    The final publication is available at Springer via http://dx.doi.org/10.1007/s10270-013-0392-yThe intensive use of models in model-driven engineering (MDE) raises the need to develop meta-models with different aims, such as the construction of textual and visual modelling languages and the specification of source and target ends of model-to-model transformations. While domain experts have the knowledge about the concepts of the domain, they usually lack the skills to build meta-models. Moreover, meta-models typically need to be tailored according to their future usage and specific implementation platform, which demands knowledge available only to engineers with great expertise in specific MDE platforms. These issues hinder a wider adoption of MDE both by domain experts and software engineers. In order to alleviate this situation, we propose an interactive, iterative approach to meta-model construction, enabling the specification of example model fragments by domain experts, with the possibility of using informal drawing tools like Dia or yED. These fragments can be annotated with hints about the intention or needs for certain elements. A meta-model is then automatically induced, which can be refactored in an interactive way, and then compiled into an implementation meta-model using profiles and patterns for different platforms and purposes. Our approach includes the use of a virtual assistant, which provides suggestions for improving the meta-model based on well-known refactorings, and a validation mode, enabling the validation of the meta-model by means of examples.This work has been funded by the Spanish Ministry of Economy and Competitivity with project “Go Lite” (TIN2011-24139), and by the R&D programme of Madrid Region with project “eMadrid” (S2009/TIC-1650)

    A Graphical Approach to Prove the Semantic Preservation of UML/OCL Refactoring Rules

    Get PDF
    Refactoring is a powerful technique to improve the quality of software models including implementation code. The software developer applies successively so-called refactoring rules on the current software model and transforms it into a new model. Ideally, the application of a refactoring rule preserves the semantics of the model on which it is applied. In this paper, we present a simple criterion and a proof technique for the semantic preservation of refactoring rules that are defined for UML class diagrams and OCL constraints. Our approach is based on a novel formalization of the OCL semantics in form of graph transformation rules. We illustrate our approach using the refactoring rule MoveAttribute

    Translating alloy apecifications to UML class diagrams annotated with OCL

    Get PDF
    Proceedings of the 9th International Conference on Software Engineering and Formal MethodsModel-Driven Engineering (MDE) is a Software Engineering approach based on model transformations at different abstraction levels. It prescribes the development of software by successively transforming models from abstract (specifications) to more concrete ones (code). Alloy is an increasingly popular lightweight formal specification language that supports automatic verification. Unfortunately, its widespread industrial adoption is hampered by the lack of an ecosystem of MDE tools, namely code generators. This paper presents a model transformation between Alloy and UML Class Diagrams annotated with OCL. The proposed transformation enables current UML-based tools to also be applied to Alloy specifications, thus unleashing its potential for MDE

    UML model refactoring as refinement: a coalgebraic perspective

    Get PDF
    Although increasingly popular, Model Driven Architecture (MDA) still lacks suitable formal foundations on top of which rigorous methodologies for the description, analysis and transformation of models could be built. This paper aims to contribute in this direction: building on previous work by the authors on coalgebraic refinement for software components and architectures, it discusses refactoring of models within a coalgebraic semantic framework. Architectures are defined through aggregation based on a coalgebraic semantics for (subsets of) UML. On the other hand, such aggregations, no matter how large and complex they are, can always be dealt with as coalgebras themselves. This paves the way to a discipline of models’ transformations which, being invariant under either behavioural equivalence or refinement, are able to formally capture a large number of refactoring patterns. The main ideas underlying this research are presented through a detailed example in the context of refactoring of UML class diagrams.The work reported in this paper is partially supported by a grant from the GLANCE funding program of NWO, through project CooPer (600.643.000.05N12)
    • …
    corecore