Title :
Relaxing queries to detect variants of design patterns
Author :
Wegrzynowicz, Patrycja ; Stencel, Krzysztof
Author_Institution :
Inst. of Inf., Univ. of Warsaw, Warsaw, Poland
Abstract :
Design patterns codify general solutions to frequently encountered design problems. They also facilitate writing robust and readable code. Their usage happens to be particularly profitable if the documentation of the resulting system is lost, inaccurate or out of date. In reverse engineering, detection of instances of design patterns is extremely helpful as it aids grasping high level design ideas. However, the actual instances of design patterns can diverge from their canonical textbook templates. Useful pattern detection tools should thus be able to identify not only orthodox implementations but also their disparate variants. In this paper, we present a method to generate queries to detect canonical instances of design patters. We formulate these queries so that they are language-agnostic. They precisely reflect the intents of the canonical implementations of design patterns. However, they abstract from any peculiarities of programming languages. Next, we show a systematic technique to relax these queries so that they also cover variant implementations of patterns. We discuss our proof-of-concept implementation of this approach in our prototype tool D-CUBED. Finally, we report the results of an experimental comparison of D-CUBED and state-of-the-art detectors.
Keywords :
query processing; reverse engineering; software architecture; D-CUBED prototype; canonical textbook templates; design pattern variant detection; language-agnostic; programming languages; relaxing queries; reverse engineering; systematic technique; Abstracts; Observers; Reverse engineering; Semantics; Systematics; Transforms; Unified modeling language;
Conference_Titel :
Computer Science and Information Systems (FedCSIS), 2013 Federated Conference on
Conference_Location :
Krako??w