期刊文献+
共找到242篇文章
< 1 2 … 13 >
每页显示 20 50 100
Application of Refactoring and Design Pattern in Land Information System Development 被引量:1
1
作者 CHEN Luyao YUE Jianwei +2 位作者 JIANG Weiguo LI Jing CHEN Yunhao 《Geo-Spatial Information Science》 EI 2007年第4期299-302,共4页
The unceasing change problem of land information systems can be resolved through the refactoring and design pattern. To promote the implementation of design pattern and refactoring methods in developing land informati... The unceasing change problem of land information systems can be resolved through the refactoring and design pattern. To promote the implementation of design pattern and refactoring methods in developing land information systems reusing software design, applying refactoring methods to the abstract factory and decorator design patterns in land information system development is discussed. 展开更多
关键词 design pattern refactoring land information system
下载PDF
Refactoring Software Packages via Community Detection in Complex Software Networks 被引量:4
2
作者 Wei-Feng Pan Bo Jiang Bing Li 《International Journal of Automation and computing》 CSCD 2013年第2期157-166,共10页
An intrinsic property of software in a real-world environment is its need to evolve, which is usually accompanied by the increase of software complexity and deterioration of software quality, making software maintenan... An intrinsic property of software in a real-world environment is its need to evolve, which is usually accompanied by the increase of software complexity and deterioration of software quality, making software maintenance a tough problem. Refactoring is regarded as an effective way to address this problem. Many refactoring approaches at the method and class level have been proposed. But the research on software refactoring at the package level is very little. This paper presents a novel approach to refactor the package structures of object oriented software. It uses software networks to represent classes and their dependencies. It proposes a constrained community detection algorithm to obtain the optimized community structures in software networks, which also correspond to the optimized package structures. And it finally provides a list of classes as refactoring candidates by comparing the optimized package structures with the real package structures. The empirical evaluation of the proposed approach has been performed in two open source Java projects, and the benefits of our approach are illustrated in comparison with the other three approaches. 展开更多
关键词 refactoring community detection complex networks package software
下载PDF
Automated pattern-directed refactoring for complex conditional statements
3
作者 刘伟 胡志刚 +1 位作者 刘宏韬 杨柳 《Journal of Central South University》 SCIE EI CAS 2014年第5期1935-1945,共11页
Complex conditional statement is one of the bad code smells, which affects the quality of the code and design of software. In the proposed approach, two commonly-used design patterns for handling complex conditional s... Complex conditional statement is one of the bad code smells, which affects the quality of the code and design of software. In the proposed approach, two commonly-used design patterns for handling complex conditional statements are selected, and they are the factory method pattern and the strategy pattem. Two pattern-directed refactoring approaches based on the two design patterns are proposed. Each approach contains a refactoring opportunities identification algorithm and an automated refactoring algorithm. After parsing the abstract syntax tree generated from source code, the refactoring opportunities are identified effectively and automatically. Then, for candidate code, refactoring algorithms are executed automatically, which are used to simplify or remove complex conditional statements. By empirical analysis and quality assessment, the code after refactoring has better maintainability and extensibility, and the proposed approach for automated pattern-directed refactoring succeeds to reduce code size and complexity of classes. 展开更多
关键词 refactoring abstract syntax tree complex conditional statements design patterns factory method pattem strategypattem
下载PDF
用Refactoring来改善设计
4
作者 周警伟 罗晓沛 《计算机仿真》 2002年第4期124-125,共2页
面向对象的技术提高了软件重用能力 ,人们经验的不断总结也不断地改善了设计方法。如何去改善我们原有的系统是一个比较复杂的课题 ,也是一个不可回避的问题。这篇论文论述了如何使用Refactoring技术来改善原有设计。
关键词 refactoring 软件开发 面向对象 软件重用 软件重构
下载PDF
Source-to-Source Refactoring and Elimination of Global Variables in C Programs
5
作者 Hemaiyer Sankaranarayanan Prasad A. Kulkarni 《Journal of Software Engineering and Applications》 2013年第5期264-273,共10页
A global variable in C/C++ is one that is declared outside a function, and whose scope extends the lifetime of the entire program. Global variables cause problems for program dependability, maintainability, extensibil... A global variable in C/C++ is one that is declared outside a function, and whose scope extends the lifetime of the entire program. Global variables cause problems for program dependability, maintainability, extensibility, verification, and thread-safety. However, global variables can also make coding more convenient and improve program performance. We have found the use of global variables to remain unabated and extensive in real-world software. In this paper we present a source-to-source refactoring tool to automatically detect and localize global variables in a program. We implement a compiler based transformation to find the best location to redefine each global variable as a local. For each global, our algorithm initializes the corresponding new local variable, passes it as an argument to necessary functions, and updates the source lines that used the global to now instead use the corresponding local or argument. We also characterize the use of global variables in standard benchmark programs. We study the effect of our transformation on static program properties, such as change in the number of function arguments and program state visibility. Additionally, we quantify dynamic program features, including memory and runtime performance, before and after our localizing transformation. 展开更多
关键词 Global Variable Program refactoring Compiler Transformations
下载PDF
A splitting-after-merging approach to multi-FIB compression and fast refactoring in virtual routers
6
作者 Da-fang ZHANG Dan CHEN +2 位作者 Yan-biao LI Kun XIE Tong SHEN 《Frontiers of Information Technology & Electronic Engineering》 SCIE EI CSCD 2016年第12期1266-1274,共9页
Virtual routers are gaining increasing attention in the research field of future networks. As the core network device to achieve network virtualization, virtual routers have multiple virtual instances coexisting on a ... Virtual routers are gaining increasing attention in the research field of future networks. As the core network device to achieve network virtualization, virtual routers have multiple virtual instances coexisting on a physical router platform, and each instance retains its own forwarding information base (FIB). Thus, memory scalability suffers from the limited on-chip memory. In this paper, we present a splitting-after-merging approach to compress the FIBs, which not only improves the memory efficiency but also offers an ideal split position to achieve system refactoring. Moreover, we propose an improved strategy to save the time used for system rebuilding to achieve fast refactoring. Experiments with 14 real-world routing data sets show that our approach needs only a unibit trie holding 134 188 nodes, while the original number of nodes is 4 569 133. Moreover, our approach has a good performance in scalability, guaranteeing 90 000 000 prefixes and 65 600 FIBs. 展开更多
关键词 Virtual routers Merging Splitting Compression Fast refactoring
下载PDF
A Feature Model Based Framework for Refactoring Software Product Line Architecture 被引量:3
7
作者 Mohammad Tanhaei Jafar Habibi Seyed-Hassan Mirian-Hosseinabadi 《Journal of Computer Science & Technology》 SCIE EI CSCD 2016年第5期951-986,共36页
Software product line(SPL)is an approach used to develop a range of software products with a high degree of similarity.In this approach,a feature model is usually used to keep track of similarities and differences.Ove... Software product line(SPL)is an approach used to develop a range of software products with a high degree of similarity.In this approach,a feature model is usually used to keep track of similarities and differences.Over time,as modifications are made to the SPL,inconsistencies with the feature model could arise.The first approach to dealing with these inconsistencies is refactoring.Refactoring consists of small steps which,when accumulated,may lead to large-scale changes in the SPL,resulting in features being added to or eliminated from the SPL.In this paper,we propose a framework for refactoring SPLs,which helps keep SPLs consistent with the feature model.After some introductory remarks,we describe a formal model for representing the feature model.We express various refactoring patterns applicable to the feature model and the SPL formally,and then introduce an algorithm for finding them in the SPL.In the end,we use a real-world case study of an SPL to illustrate the applicability of the framework introduced in the paper. 展开更多
关键词 software product line feature model refactoring software architecture
下载PDF
Major motivations for extract method refactorings: analysis based on interviews and change histories
8
作者 Wenmei LIU Hui LIU 《Frontiers of Computer Science》 SCIE EI CSCD 2016年第4期644-656,共13页
Extract method is one of the most popular soft- ware refactorings. However, little work has been done to investigate or validate the major motivations for such refactorings. Digging into this issue might help research... Extract method is one of the most popular soft- ware refactorings. However, little work has been done to investigate or validate the major motivations for such refactorings. Digging into this issue might help researchers to improve tool support for extract method refactorings, e.g., proposing better tools to recommend refactoring opportunities, and to select fragments to be extracted. To this end, we conducted an interview with 25 developers, and our results suggest that current reuse, decomposition of long methods, clone resolution, and future reuse are the major motivations for extract method refactorings. We also validated the results by analyzing the refactoring history of seven open-source applications. Analysis results suggest that current reuse was the primary motivation for 56% of extract method refactorings, decomposition of methods was the primary motivation for 28% of extract method refactorings, and clone resolution was the primary motivation for 16% of extract method refactorings. These findings might suggest that recommending extract method opportunities by analyzing only the inner structure (e.g., complexity and length) of methods alone would miss many extract method opportunities. These findings also suggest that extract method refactorings are often driven by current and immediate reuse. Consequently, how to recognize or predict reuse requirements timely during software evolution may play a key role in the recommendation and automation of extract method refactorings. We also investigated the likelihood for the extracted methods to be reused in future, and our results suggest that such methods have a small chance (12%) to be reused in future unless the extracted fragment could be reused immediately in software evolution and extracting such a fragment can resolve existing clones at the same time. 展开更多
关键词 software refactoring extract method motivation data mining software quality
下载PDF
Pragmatic model transformations for refactoring in Scilab/Xcos
9
作者 Umut Durak 《International Journal of Modeling, Simulation, and Scientific Computing》 EI 2016年第1期39-61,共23页
Model-Based Development has become an industry wide standard paradigm.As an open source alternative,Scilab/Xcos is being widely employed as a hybrid dynamic systems modeling tool.With the increasing efficiency in impl... Model-Based Development has become an industry wide standard paradigm.As an open source alternative,Scilab/Xcos is being widely employed as a hybrid dynamic systems modeling tool.With the increasing efficiency in implementation using graphical model development and code generation,the modeling and simulation community is struggling with assuring quality as well as maintainability and extendibility.Refactoring is defined as an evolutionary modernization activity where,most of the time,the structure of the artifact is changed to alter its quality characteristics,while keeping its behavior unchanged.It has been widely established as a technique for textual programming languages to improve the code structure and quality.While refactoring is also regarded as one of the key practices of model engineering,the methodologies and approaches for model refactoring are still under development.Architecture-Driven Modernization(ADM)has been introduced by the software engineering community as a model-based approach to software modernization,in which the implicit information that lies in software artifacts is extracted to models and model transformations are applied for modernization tasks.Regarding refactoring as a low level modernization task,the practices from ADM are adaptable.Accordingly,this paper proposes a model-based approach for model refactoring in order to come up with more efficient and effective model refactoring methodology that is accessible and extendable by modelers.Like other graphical modeling tools,Scilab/Xcos also possesses a formalized model specification conforming to its implicit metamodel.Rather than proposing another metamodel for knowledge extraction,this pragmatic approach proposes to conduct in place model-to-model transformations for refactoring employing the Scilab/Xcos model specification.To construct a structured model-based approach,the implicit Scilab/Xcos metamodel is explicitly presented utilizing ECORE as a meta-metamodel.Then a practical model transformation approach is established based on Scilab scripting.A Scilab toolset is provided to the modeler for in-place model-to-model transformations.Using a sample case study,it is demonstrated that proposed model transformation functions in Scilab provide a valuable refactoring tool. 展开更多
关键词 Model refactoring Scilab/Xcos model engineering model transformations
下载PDF
东北地区旅游资源赋存演化特征与旅游业空间重构 被引量:41
10
作者 杨友宝 王荣成 +1 位作者 李秋雨 曹洪华 《经济地理》 CSSCI 北大核心 2015年第10期194-201,209,共8页
基于东北地区2002、2007、2013年A级旅游景区数据,采用多样化指数、等级结构金字塔、品质度、最邻近点指数、点密度分析、不平衡指数等数理与空间分析方法,探讨了东北地区旅游资源赋存的时空演化状况,研究发现:1从数理演化特征来看,东... 基于东北地区2002、2007、2013年A级旅游景区数据,采用多样化指数、等级结构金字塔、品质度、最邻近点指数、点密度分析、不平衡指数等数理与空间分析方法,探讨了东北地区旅游资源赋存的时空演化状况,研究发现:1从数理演化特征来看,东北地区旅游资源类型丰度缓慢提升,同时省际差异较为显著;旅游资源等级体系呈"中间等级数量丰富,低、高端景区缺乏"的纺锤形结构,且伴随旅游景区数量及属性结构比例变化,纺锤形结构呈现"结构破缺—平衡稳定—重心偏离"的演变特征;旅游资源品质度整体呈上升趋势,但增长速率省际分异明显。2从空间演化特征来看,东北地区旅游资源空间分布具有凝聚型特征,景区省际空间分布演变对东北全局没有必然影响;2002年以来旅游资源集聚热点不断增多,景区分布盲区不断消亡,集聚格局由单核空间扩张向跨行政区重组联动发展;旅游资源分布不平衡指数呈下降趋势,景区空间集聚态势逐步弱化,扩散化倾向不断加强。在上述研究结果的基础上,从旅游产业轴带、旅游产业圈层、旅游产业组团三种模式出发,提出了东北地区旅游产业空间的重构构想。 展开更多
关键词 东北地区 旅游资源赋存 产业空间重构 A级旅游景区
下载PDF
煤矿复垦重构土壤呼吸季节变化特征及其环境影响因子 被引量:13
11
作者 郑永红 张治国 +2 位作者 胡友彪 姚多喜 陈孝杨 《煤炭学报》 EI CAS CSCD 北大核心 2014年第11期2300-2306,共7页
为了研究采煤沉陷地复垦生态系统土壤呼吸季节特征,探讨各主要环境影响因子对土壤呼吸的影响,利用Li-8100A自动土壤碳通量系统,测定潘一矿复垦区不同季节土壤呼吸速率,同时测定土壤温度、大气温度等环境影响因子。结果表明:1在季节尺度... 为了研究采煤沉陷地复垦生态系统土壤呼吸季节特征,探讨各主要环境影响因子对土壤呼吸的影响,利用Li-8100A自动土壤碳通量系统,测定潘一矿复垦区不同季节土壤呼吸速率,同时测定土壤温度、大气温度等环境影响因子。结果表明:1在季节尺度上土壤温度(10 cm)、大气温度和土壤含水率(10 cm)与土壤呼吸速率呈显著正相关。2土壤呼吸速率在日间呈单峰曲线型变化,土壤呼吸速率观测最大值出现在12:00—14:00,观测最小值出现在8:00和18:00两个时间点。土壤呼吸速率均表现出明显的季节变化特征,不同季节具有显著差异。与正常农田观测点数据对比知,大气温度和相对湿度差异不大,土壤呼吸速率、土壤温度和土壤含水率平均值略高于复垦区土壤观测点数据。3潘一矿复垦区重构土壤呼吸的Q10值为1.94,低于暖温带Q10平均值,低于中国土壤呼吸Q10平均值和农田生态系统的Q10平均值。研究结果初步阐明煤矿复垦区重构土壤呼吸的季节变化特征。 展开更多
关键词 复垦区 重构土壤 土壤呼吸 温度敏感值
下载PDF
面向Java多线程机制的软件重构方法 被引量:9
12
作者 张杨 柳晨光 +2 位作者 张冬雯 郑琨 郑雅洁 《北京理工大学学报》 EI CAS CSCD 北大核心 2018年第11期1149-1155,共7页
针对Java语言中Thread和Executor两种线程机制在线程管理模式、代码编写量和性能上的不同,提出了一种面向Java多线程机制的软件自动重构方法,该方法可以实现Thread和Executor之间的自动重构转换,进而帮助程序员选择更适合的线程机制.在E... 针对Java语言中Thread和Executor两种线程机制在线程管理模式、代码编写量和性能上的不同,提出了一种面向Java多线程机制的软件自动重构方法,该方法可以实现Thread和Executor之间的自动重构转换,进而帮助程序员选择更适合的线程机制.在Eclipse JDT环境下实现了从Thread到Executor的自动重构工具Rethreader.在实验中,使用Rethreader对JGF基准测试程序套件中的Series、Crypt、Lufact、Sparsematmult和Montecarlo等基准程序进行了重构测试,实验结果表明,Rethreader可以在小于1s的短时间内实现从Thread到Executor的转换. 展开更多
关键词 Thread框架 Executor框架 软件重构 软件分析 抽象语法树
下载PDF
富平石川河的生态修复 被引量:16
13
作者 魏静 王欢元 +1 位作者 孙增慧 张露 《生态学杂志》 CAS CSCD 北大核心 2019年第8期2545-2552,共8页
自国家提出构建山水林田湖草生命共同体以来,已启动第三批山水林田湖草生态保护修复工程试点申报,但一些工程设计缺乏整体性,造成“真破坏”和“伪生态”的现象时有发生.本研究以石川河综合整治项目为例,针对石川河乱采乱挖河道砂石,工... 自国家提出构建山水林田湖草生命共同体以来,已启动第三批山水林田湖草生态保护修复工程试点申报,但一些工程设计缺乏整体性,造成“真破坏”和“伪生态”的现象时有发生.本研究以石川河综合整治项目为例,针对石川河乱采乱挖河道砂石,工业污染,附近村民焚烧垃圾造成气、水和土污染极其严重,生态、人居环境持续恶化,鱼虾绝迹,污水横流,垃圾成堆等问题,采用重建生态河道、恢复生态、景观重塑、土地平整、PE复合土工膜、土壤修复等技术构建山水林田湖草生命共同体,并分析了生态、经济和社会效益,通过项目实施,为石川河流域提供了洁净的土壤环境、稳定的土体结构,有效改善了生态环境,提高了生活质量,实现生产发展、生态良好,不断满足社会发展建设美丽乡村的需要,同时为构建流域山水林田湖草生命共同体提供理论依据和实践支撑. 展开更多
关键词 生态河道 生态恢复 土体有机重构 景观重塑
下载PDF
代码坏味的处理顺序 被引量:11
14
作者 高原 刘辉 +2 位作者 樊孝忠 牛振东 邵维忠 《软件学报》 EI CSCD 北大核心 2012年第8期1965-1977,共13页
选取了10种具有代表性的代码坏味进行研究.从每种代码坏味的产生原因、症状、对软件的影响以及相应的处理这4个方面进行分析,提出了一个代码坏味处理顺序的优先级.通过问卷调查和两个实验,对代码坏味处理顺序优先级进行了初步验证.
关键词 代码坏味 软件重构 处理顺序 软件维护 优先级 调度
下载PDF
电力系统快速静态安全分析的改进算法 被引量:20
15
作者 丁平 李亚楼 +3 位作者 徐得超 田芳 严剑峰 于之虹 《中国电机工程学报》 EI 北大核心 2010年第31期77-82,共6页
传统的静态安全分析研究集中在处理电力系统元件开断后的分配不平衡功率和快速潮流算法上。电网发展和安全需求的提高要求静态安全分析系统能容纳多种复杂模型,适应不同种类多个元件的切除、增加和参数修改。结合PQ分解法的收敛特性提... 传统的静态安全分析研究集中在处理电力系统元件开断后的分配不平衡功率和快速潮流算法上。电网发展和安全需求的提高要求静态安全分析系统能容纳多种复杂模型,适应不同种类多个元件的切除、增加和参数修改。结合PQ分解法的收敛特性提出统一的模型处理原则;基于部分因子修正的快速算法提出因子表附加链技术;用动态网络接线分析方法减少计算用时。这些原则和方法解决了静态安全分析系统对模型和新增元件的要求,实现了快速性、准确性和收敛性相结合,具有较好的理论价值和应用前景。中国电网的算例证明了所提方法的有效性。 展开更多
关键词 静态安全分析 PQ分解 模型处理 部分因子分解 因子表附加链 动态网络接线分析
下载PDF
基于量子粒子群算法多目标优化的配电网动态重构 被引量:34
16
作者 文娟 谭阳红 雷可君 《电力系统保护与控制》 CSCD 北大核心 2015年第16期73-78,共6页
为保证配电网动态重构后系统安全稳定的运行,提出了以网损和节点电压稳定性为目标函数的量子粒子群算法的配电网动态重构。针对配电网动态重构过程中时段划分问题,提出以负荷曲线的单调性和幅值变化大小为依据初步划分时间段落。采用整... 为保证配电网动态重构后系统安全稳定的运行,提出了以网损和节点电压稳定性为目标函数的量子粒子群算法的配电网动态重构。针对配电网动态重构过程中时段划分问题,提出以负荷曲线的单调性和幅值变化大小为依据初步划分时间段落。采用整数型量子粒子群算法进行动态重构,重构过程中以相邻时段的网损变化值的关系获取最佳重构段落,然后综合考虑配电网网损最小和节点电压值最大且波动最小为目标寻找最佳重构结构。以IEEE33配电系统为例验证了所提方法的有效性和实用性。 展开更多
关键词 配电网 动态重构 最优重构次数 多目标 整数型量子粒子群算法
下载PDF
一种改进的基于层次聚类的软件重构技术研究 被引量:10
17
作者 钟林辉 张能伟 +1 位作者 侯长源 宗鸿雁 《计算机工程与应用》 CSCD 北大核心 2015年第20期50-54,共5页
为了改善Java源程序的质量,使之尽可能地符合"高内聚、低耦合"的设计要求,提出了扩展的Jaccard系数,并将其作为实体间相似性的度量公式,采用层次聚类算法将Java类图划分为若干个候选包。在基于交互及度量重构策略的引导下,对J... 为了改善Java源程序的质量,使之尽可能地符合"高内聚、低耦合"的设计要求,提出了扩展的Jaccard系数,并将其作为实体间相似性的度量公式,采用层次聚类算法将Java类图划分为若干个候选包。在基于交互及度量重构策略的引导下,对Java程序结构进行调整。通过实验表明,经过调整以后的Java源程序,在结构上更符合"高内聚、低耦合"的特征。 展开更多
关键词 软件重构 高内聚 低耦合 Jaccard系数
下载PDF
克隆代码技术研究综述 被引量:13
18
作者 史庆庆 孟繁军 +1 位作者 张丽萍 刘东升 《计算机应用研究》 CSCD 北大核心 2013年第6期1617-1623,共7页
软件系统中克隆代码的检测与管理是软件工程中的基本问题之一,在软件的质量、维护、架构、进化、专利和剽窃等众多领域有着广泛的应用需求。综述了克隆检测的过程、技术及其优缺点、克隆进化方向上的相关研究,以及克隆管理的一些技术,... 软件系统中克隆代码的检测与管理是软件工程中的基本问题之一,在软件的质量、维护、架构、进化、专利和剽窃等众多领域有着广泛的应用需求。综述了克隆检测的过程、技术及其优缺点、克隆进化方向上的相关研究,以及克隆管理的一些技术,并特别介绍了克隆重构技术。最后概括了该领域所取得的研究成果,并讨论了目前克隆代码研究中所遇到的挑战性问题。 展开更多
关键词 克隆代码 克隆检测 克隆进化 克隆管理 克隆重构
下载PDF
一种基于深度学习的上帝类检测方法 被引量:17
19
作者 卜依凡 刘辉 李光杰 《软件学报》 EI CSCD 北大核心 2019年第5期1359-1374,共16页
上帝类是指某个承担了本应由多个类分别承担的多个职责的类.上帝类违背了分而治之的基本思想以及单一职责的设计原则,严重影响软件的可维护性和可理解性.但上帝类又是一种比较常见的代码坏味.因此,针对上帝类的检测与重构一直是代码重... 上帝类是指某个承担了本应由多个类分别承担的多个职责的类.上帝类违背了分而治之的基本思想以及单一职责的设计原则,严重影响软件的可维护性和可理解性.但上帝类又是一种比较常见的代码坏味.因此,针对上帝类的检测与重构一直是代码重构领域的研究热点之一.为此,提出了一种基于深度神经网络的上帝类检测方法.该方法不仅利用了常见的软件度量,而且充分利用了代码中的文本信息,意图通过挖掘文本语义揭示每个类所承担的主要角色.此外,为了解决有监督深度学习所需的海量标签数据,提出了一种基于开源代码构造标签数据的方法.最后,基于开源数据集对所提出的方法进行了实验验证.实验结果表明,这些方法优于现有的上帝类检测方法,尤其是在查全率上有大幅度的提升(提高了35.58%). 展开更多
关键词 代码坏味 软件重构 深度学习
下载PDF
单例模式导向的源代码自动重构研究 被引量:6
20
作者 刘伟 胡志刚 刘宏韬 《小型微型计算机系统》 CSCD 北大核心 2014年第12期2664-2669,共6页
针对手工重构存在容易引入错误且重构效率较低等问题,本文提出了一种以单例模式为导向的源代码自动重构方法.首先将源代码转换成抽象语法树,然后对抽象语法树进行操作,按照单例模式的要求修改抽象语法树,并自动生成重构后的单例类.该方... 针对手工重构存在容易引入错误且重构效率较低等问题,本文提出了一种以单例模式为导向的源代码自动重构方法.首先将源代码转换成抽象语法树,然后对抽象语法树进行操作,按照单例模式的要求修改抽象语法树,并自动生成重构后的单例类.该方法不仅可以对指定类进行自动单例化重构,还可以对源代码中所有创建该类实例的代码进行自动重构.对方法进行正确性检验并将其应用于两个不同规模的软件项目,实验结果表明该方法可以准确、高效地实现类的自动单例化重构,重构算法的执行时间与系统规模呈线性关系. 展开更多
关键词 源代码解析 抽象语法树 重构 自动重构 单例模式 模式导向重构
下载PDF
上一页 1 2 … 13 下一页 到第 页
使用帮助 返回顶部