9 research outputs found
On the Composition of Design Patterns
Design patterns are usually applied in a composed form
with each other. It is crucial to be able to formally reason
about how patterns can be composed and to prove the
properties of composed patterns. Based on our previous
work on formal specification of design patterns and formal
reasoning about their properties, this paper focuses on the
composition of design patterns. A notion of composition of
patterns with respect to overlaps is formally defined based
on two operations on design patterns, which are the specialisation
of a pattern with constraints and the lifting of a
pattern with a subset of components as the key. The composition
of design patterns is illustrated by the composition
of Composite, Strategy and Observer patterns. A case
study of the formalisation of the relationship between patterns
as suggested by GoF is also reported
A Language-Independent and Formal Approach to Pattern-Based Modelling with Support for Composition and Analysis
Context: Patterns are used in different disciplines as a way to record expert knowledge for problem solving in specific areas. Their systematic use in Software Engineering promotes quality, standardization, reusability and maintainability of software artefacts. The full realisation of their power is however hindered by the lack of a standard formalization of the notion of pattern. Objective: Our goal is to provide a language-independent formalization of the notion of pattern, so that it allows its application to different modelling languages and tools, as well as generic methods to enable pattern discovery, instantiation, composition, and conflict analysis. Method: For this purpose, we present a new visual and formal, language-independent approach to the specification of patterns. The approach is formulated in a general way, based on graphs and category theory, and allows the specification of patterns in terms of (nested) variable submodels, constraints on their allowed variance, and inter-pattern synchronization across several diagrams (e.g. class and sequence diagrams for UML design patterns). Results: We provide a formal notion of pattern satisfaction by models and propose mechanisms to suggest model transformations so that models become consistent with the patterns. We define methods for pattern composition, and conflict analysis. We illustrate our proposal on UML design patterns, and discuss its generality and applicability on different types of patterns, e.g. workflow patterns, enterprise integration patterns and interaction patterns. Conclusion: The approach has proven to be powerful enough to formalize patterns from different domains, providing methods to analyse conflicts and dependencies that usually are expressed only in textual form. Its language independence makes it suitable for integration in meta-modelling tools and for use in Model-Driven Engineering.This work has been supported by the Visiting Professor Programmes of ââSapienzaâ University of Rome and its Department of Computer Science, the R&D program of the Community of Madrid (S2009/TIC-1650, project ââe-Madridâ), the CAM-UC3M project ââEXPLOREâ (CCG08-UC3M/TIC-4487), as well as by the Spanish Ministry of Science and Innovation, under project ââMETEORICâ (TIN2008-02081), and mobility Grants JC2009-00015 and PR2009-0019.Publicad
Composition-centered architectural pattern description language
International audienceArchitectural patterns are important artefacts containing specialized design knowledge to build good-quality systems. Complex systems often exhibit several architectural patterns in their design which leads to the need of architectural pattern composition. Unfortunately, information about the composition of patterns tend to be vaporized right after the composition process which causes problems of traceability and reconstructability of patterns. This paper proposes a pattern description language that first, facilitates several types of pattern merging operation and second, allows the traceability of pattern composition. More specifically, the approach consists of a proper description of pattern that supports composition operations and a two-step pattern design process that helps to preserve pattern composition information
On the theoretical foundation of meta-modelling in graphically extended BNF and first order logic
Meta-modeling plays an important role in model driven software development methodology. In our previous work, a graphic extension of BNF (GEBNF) was proposed to define the abstract syntax of graphic modeling languages. From a GEBNF syntax definition, a first order predicate logic language can be induced so that meta-modeling can be performed formally by specifying a predicate on the domain of syntactically valid models. In this paper, we investigate the theoretical foundation of this meta-modeling approach. We first formally define the semantics of GEBNF syntax definitions as algebras that contain no junk and satisfy constraints derived from GEBNF syntax rules. The semantics of the induced logic is then formally defined by regarding such algebras as models. We then formally prove that well-formed syntax definitions together with syntax morphisms form a category, where syntax morphisms represent the translations between modeling languages. The models (i.e. algebras) in a modeling language and the homomorphisms between them also form a category. Finally, we prove that the functors from GEBNF syntax definitions to the categories of models and to sentences in the induced first order logic form an institution. Therefore, GEBNF and its induced logics form a valid formal specification language for models
A Survey on Design Pattern Recovery Techniques
The evaluation of design pattern recovery techniques and tools is significant as numbers of emergent techniques are presented and used in the past to recover patterns from source code of legacy applications. The problem of very diverse precision and recall values extracted by different pattern recovery techniques and tools on the same examined applications is not investigated thoroughly. It is very desirable to compare features of existing techniques as abundance of techniques supplemented with different tools has been presented in the last decade. We believe that new innovations for this discipline can be based on the empirical evaluation of existing techniques. The selected techniques cover the whole spectrum of state of the art research in design pattern recovery. The major contribution of this paper is a comprehensive discussion on state of the art in design pattern recovery research in the last decade followed by a proposed framework for classification and evaluation of existing design pattern recovery techniques. Finally we listed our observations as lessons learned which hamper design pattern recovery research and these observations can be used for future research directions and guidelines for this discipline
Formal specification of the variants and behavioural features of design patterns
The formal specification of design patterns is widely recognized as being vital to their effective and correct use in software development. It can clarify the concepts underlying patterns, eliminate ambiguity and thereby lay a solid foundation for tool support. This paper further advances a formal meta-modelling approach that uses first order predicate logic to specify design patterns. In particular, it specifies both structural and behavioural features of design patterns and systematically captures the variants in a well-structured format. The paper reports a case study involving the formal specification of all 23 patterns in the Gang of Four catalog. It demonstrates that the approach improves the accuracy of pattern specifications by covering variations and clarifying the ambiguous parts of informal descriptions
On the Composability of Design Patterns
In real applications, design patterns are almost always to be found composed with each other. It is crucial that these compositions be validated. This paper examines the notion of validity, and develops a formal method for proving or disproving it, in a context where composition is performed with formally defined operators on formally specified patterns. In particular, for validity, we require that pattern compositions preserve the features, semantics and soundness of the composed patterns. The application of the theory is demonstrated by a formal analysis of overlap-based pattern compositions and a case study of a real pattern-oriented software design
An Algebra of Design Patterns
In a pattern-oriented software design process, design decisions are made by selecting and instanti-
ating appropriate patterns, and composing them together. In our previous work, we enabled these
decisions to be formalised by dening a set of operators on patterns with which instantiations and
compositions can be represented. In this paper, we investigate the algebraic properties of these
operators. We provide and prove a complete set of algebraic laws so that equivalence between
pattern expressions can be proven. Furthermore, we dene an always-terminating normalisation
of pattern expressions to a canonical form, which is unique modulo equivalence in rst-order logic.
By a case study, the pattern-oriented design of an extensible request-handling framework,
we demonstrate two practical applications of the algebraic framework. Firstly, we can prove
the correctness of a nished design with respect to the design decisions made and the formal
specication of the patterns. Secondly, we can even derive the design from these components
Customizable Feature based Design Pattern Recognition Integrating Multiple Techniques
Die Analyse und RĂŒckgewinnung von Architekturinformationen
aus existierenden Altsystemen ist eine komplexe, teure und zeitraubende
Aufgabe, was der kontinuierlich steigenden KomplexitÀt von Software und dem
Aufkommen der modernen Technologien geschuldet ist. Die Wartung von
Altsystemen wird immer stÀrker nachgefragt und muss dabei mit den neuesten
Technologien und neuen Kundenanforderungen umgehen können. Die
Wiederverwendung der Artefakte aus Altsystemen fĂŒr neue Entwicklungen wird
sehr bedeutsam und ĂŒberlebenswichtig fĂŒr die Softwarebranche. Die
Architekturen von Altsystemen unterliegen konstanten VerÀnderungen, deren
Projektdokumentation oft unvollstÀndig, inkonsistent und veraltet ist.
Diese Dokumente enthalten ungenĂŒgend Informationen ĂŒber die innere Struktur
der Systeme. HÀufig liefert nur der Quellcode zuverlÀssige Informationen
ĂŒber die Struktur von Altsystemen. Das Extrahieren von Artefakten aus
Quellcode von Altsystemen unterstĂŒtzt das ProgrammverstĂ€ndnis, die Wartung,
das Refactoring, das Reverse Engineering, die nachtrÀgliche Dokumentation
und Reengineering Methoden. Das Ziel dieser Dissertation ist es
Entwurfsinformationen von Altsystemen zu extrahieren, mit Fokus auf die
Wiedergewinnung von Architekturmustern. Architekturmuster sind
SchlĂŒsselelemente, um Architekturentscheidungen aus Quellcode von
Altsystemen zu extrahieren. Die Verwendung von Mustern bei der Entwicklung
von Applikationen wird allgemein als qualitÀtssteigernd betrachtet und
reduziert Entwicklungszeit und kosten. In der Vergangenheit wurden
unterschiedliche Methoden entwickelt, um Muster in Altsystemen zu erkennen.
Diese Techniken erkennen Muster mit unterschiedlicher Genauigkeit, da ein
und dasselbe Muster unterschiedlich spezifiziert und implementiert wird.
Der Lösungsansatz dieser Dissertation basiert auf anpassbaren und
wiederverwendbaren Merkmal-Typen, die statische und dynamische Parameter
nutzen, um variable Muster zu definieren. Jeder Merkmal-Typ verwendet eine
wĂ€hlbare Suchtechnik (SQL Anfragen, RegulĂ€re AusdrĂŒcke oder Quellcode
Parser), um ein bestimmtes Merkmal eines Musters im Quellcode zu
identifizieren. Insbesondere zur Erkennung verschiedener Varianten eines
Musters kommen im entwickelten Verfahren statische, dynamische und
semantische Analysen zum Einsatz. Die Verwendung unterschiedlicher
Suchtechniken erhöht die Genauigkeit der Mustererkennung bei verschiedenen
Softwaresystemen. ZusĂ€tzlich wurde eine neue Semantik fĂŒr Annotationen im
Quellcode von existierenden Softwaresystemen entwickelt, welche die
Effizienz der Mustererkennung steigert. Eine prototypische
Implementierung des Ansatzes, genannt UDDPRT, wurde zur Erkennung
verschiedener Muster in Softwaresystemenen unterschiedlicher
Programmiersprachen (JAVA, C/C++, C#) verwendet. UDDPRT erlaubt die
Anpassung der Mustererkennung durch den Benutzer. Alle Abfragen und deren
Zusammenspiel sind konfigurierbar und erlauben dadurch die Erkennung von
neuen und abgewandelten Mustern. Es wurden umfangreiche Experimente mit
diversen Open Source Software Systemen durchgefĂŒhrt und die erzielten
Ergebnisse wurden mit denen anderer AnsÀtze verglichen. Dabei war es
möglich eine deutliche Steigerung der Genauigkeit im entwickelten Verfahren
gegenĂŒber existierenden AnsĂ€tzen zu zeigen.Recovering design information from legacy applications is a
complex, expensive, quiet challenging, and time consuming task due to ever
increasing complexity of software and advent of modern technology. The
growing demand for maintenance of legacy systems, which can cope with the
latest technologies and new business requirements, the reuse of artifacts
from the existing legacy applications for new developments become very
important and vital for software industry. Due to constant evolution in
architecture of legacy systems, they often have incomplete, inconsistent
and obsolete documents which do not provide enough information about the
structure of these systems. Mostly, source code is the only reliable source
of information for recovering artifacts from legacy systems. Extraction of
design artifacts from the source code of existing legacy systems supports
program comprehension, maintenance, code refactoring, reverse engineering,
redocumentation and reengineering methodologies. The objective of approach
used in this thesis is to recover design information from legacy code with
particular focus on the recovery of design patterns. Design patterns are
key artifacts for recovering design decisions from the legacy source code.
Patterns have been extensively tested in different applications and reusing
them yield quality software with reduced cost and time frame. Different
techniques, methodologies and tools are used to recover patterns from
legacy applications in the past. Each technique recovers patterns with
different precision and recall rates due to different specifications and
implementations of same pattern. The approach used in this thesis is based
on customizable and reusable feature types which use static and dynamic
parameters to define variant pattern definitions. Each feature type allows
user to switch/select between multiple searching techniques (SQL queries,
Regular Expressions and Source Code Parsers) which are used to match
features of patterns with source code artifacts. The technique focuses on
detecting variants of different design patterns by using static, dynamic
and semantic analysis techniques. The integrated use of SQL queries, source
code parsers, regular expressions and annotations improve the precision and
recall for pattern extraction from different legacy systems. The approach
has introduced new semantics of annotations to be used in the source code
of legacy applications, which reduce search space and time for detecting
patterns. The prototypical implementation of approach, called UDDPRT is
used to recognize different design patterns from the source code of
multiple languages (Java, C/C++, C#). The prototype is flexible and
customizable that novice user can change the SQL queries and regular
expressions for detecting implementation variants of design patterns. The
approach has improved significant precision and recall of pattern
extraction by performing experiments on number of open source systems taken
as baselines for comparisons