Management of legacy software and its code, generally written in procedural languages, is often costly and time-consuming. To help this management, a migration from procedural to object oriented paradigm could be a cost effective option. One approach for such migration can be based on the underlying dependency structure of the procedural source code. In this work, we propose a new heuristic algorithm that utilizes such structure for the design migration using agglomerative hierarchical clustering. The dependency structure that has been used involve functions, parameters and global data of the procedural code. Given a procedural code, the proposed approach produces candidate classes for an object oriented design. The proposed algorithm was tested against a database of procedural codes. The results obtained have been empirically validated using Jaccard similarity coefficient. It is observed that the proposed method yields 75.6% similarity with respect to the ground truth in the average case.
The prolific growth of the Internet density has replaced native applications with web based applications. Current trend of web applications is moving towards fat client architecture, which results in a large codebase of the client side of web applications. Manual management of this huge code is tedious and time consuming for developers. We present a technique to construct a dependency graph to provide an overview of the code showing the inter-dependency of the code elements. We conduct a dynamic analysis to make the JavaScript call graph to address the dynamic nature of JavaScript. We further integrate HTML and CSS with the JavaScript call graph to make a dependency graph. Because we can accurately identify the HTML and CSS relations, the result of the dependency graph depends on the JavaScript call graph. Our evaluation of the JavaScript call graph on six web applications demonstrates that the precision is high for the large applications and relatively low for small applications. The recall is low for large applications and relatively higher for small applications.
scite is a Brooklyn-based organization that helps researchers better discover and understand research articles through Smart Citations–citations that display the context of the citation and describe whether the article provides supporting or contrasting evidence. scite is used by students and researchers from around the world and is funded in part by the National Science Foundation and the National Institute on Drug Abuse of the National Institutes of Health.