Distinguishing similar design pattern instances through temporal behavior analysis
Design patterns (DPs) encapsulate valuable design knowledge of object-oriented systems. Detecting DP instances helps to reveal the underlying rationale, thus facilitates the maintenance of legacy code. Resulting from the internal similarity of DPs, implementation variants, and missing roles, approac...
Saved in:
Main Authors: | , , |
---|---|
Format: | text |
Language: | English |
Published: |
Institutional Knowledge at Singapore Management University
2020
|
Subjects: | |
Online Access: | https://ink.library.smu.edu.sg/sis_research/5614 https://ink.library.smu.edu.sg/context/sis_research/article/6617/viewcontent/saner_2020.pdf |
Tags: |
Add Tag
No Tags, Be the first to tag this record!
|
Institution: | Singapore Management University |
Language: | English |
id |
sg-smu-ink.sis_research-6617 |
---|---|
record_format |
dspace |
spelling |
sg-smu-ink.sis_research-66172021-05-27T03:55:34Z Distinguishing similar design pattern instances through temporal behavior analysis XIONG, Renhao LO, David LI, Bixin Design patterns (DPs) encapsulate valuable design knowledge of object-oriented systems. Detecting DP instances helps to reveal the underlying rationale, thus facilitates the maintenance of legacy code. Resulting from the internal similarity of DPs, implementation variants, and missing roles, approaches based on static analysis are unable to well identify structurally similar instances. Existing approaches further employ dynamic techniques to test the runtime behaviors of candidate instances. Automatically verifying the runtime behaviors of DP instances is a challenging task in multiple aspects. This paper presents an approach to improve the verification process of existing approaches. To exercise the runtime behaviors of DP instances in cases that test cases of legacy systems are often unavailable, we propose a markup language, TSML (Test Script Markup Language), to direct the generation of test cases by putting a DP instance into use. The execution of test cases is monitored based on a trace method that enables us to specify runtime events of interest using regular expressions. To characterize runtime behaviors, we introduce a modeling and specification method employing Allen's interval-based temporal relations, which supports variant behaviors in a flexible way without hard-coded algorithms. A prototype tool has been implemented and evaluated on six open source systems to verify 466 instances reported by five existing approaches with respect to five DPs. The results show that the dynamic analysis increases the F 1 -score by 53.6% in distinguishing similar DP instances. 2020-02-01T08:00:00Z text application/pdf https://ink.library.smu.edu.sg/sis_research/5614 info:doi/10.1109/SANER48275.2020.9054804 https://ink.library.smu.edu.sg/context/sis_research/article/6617/viewcontent/saner_2020.pdf http://creativecommons.org/licenses/by-nc-nd/4.0/ Research Collection School Of Computing and Information Systems eng Institutional Knowledge at Singapore Management University Design Pattern Detection Temporal Analysis Reverse Engineering Software Comprehension Knowledge Representation Software Engineering |
institution |
Singapore Management University |
building |
SMU Libraries |
continent |
Asia |
country |
Singapore Singapore |
content_provider |
SMU Libraries |
collection |
InK@SMU |
language |
English |
topic |
Design Pattern Detection Temporal Analysis Reverse Engineering Software Comprehension Knowledge Representation Software Engineering |
spellingShingle |
Design Pattern Detection Temporal Analysis Reverse Engineering Software Comprehension Knowledge Representation Software Engineering XIONG, Renhao LO, David LI, Bixin Distinguishing similar design pattern instances through temporal behavior analysis |
description |
Design patterns (DPs) encapsulate valuable design knowledge of object-oriented systems. Detecting DP instances helps to reveal the underlying rationale, thus facilitates the maintenance of legacy code. Resulting from the internal similarity of DPs, implementation variants, and missing roles, approaches based on static analysis are unable to well identify structurally similar instances. Existing approaches further employ dynamic techniques to test the runtime behaviors of candidate instances. Automatically verifying the runtime behaviors of DP instances is a challenging task in multiple aspects. This paper presents an approach to improve the verification process of existing approaches. To exercise the runtime behaviors of DP instances in cases that test cases of legacy systems are often unavailable, we propose a markup language, TSML (Test Script Markup Language), to direct the generation of test cases by putting a DP instance into use. The execution of test cases is monitored based on a trace method that enables us to specify runtime events of interest using regular expressions. To characterize runtime behaviors, we introduce a modeling and specification method employing Allen's interval-based temporal relations, which supports variant behaviors in a flexible way without hard-coded algorithms. A prototype tool has been implemented and evaluated on six open source systems to verify 466 instances reported by five existing approaches with respect to five DPs. The results show that the dynamic analysis increases the F 1 -score by 53.6% in distinguishing similar DP instances. |
format |
text |
author |
XIONG, Renhao LO, David LI, Bixin |
author_facet |
XIONG, Renhao LO, David LI, Bixin |
author_sort |
XIONG, Renhao |
title |
Distinguishing similar design pattern instances through temporal behavior analysis |
title_short |
Distinguishing similar design pattern instances through temporal behavior analysis |
title_full |
Distinguishing similar design pattern instances through temporal behavior analysis |
title_fullStr |
Distinguishing similar design pattern instances through temporal behavior analysis |
title_full_unstemmed |
Distinguishing similar design pattern instances through temporal behavior analysis |
title_sort |
distinguishing similar design pattern instances through temporal behavior analysis |
publisher |
Institutional Knowledge at Singapore Management University |
publishDate |
2020 |
url |
https://ink.library.smu.edu.sg/sis_research/5614 https://ink.library.smu.edu.sg/context/sis_research/article/6617/viewcontent/saner_2020.pdf |
_version_ |
1770575531301928960 |