当前位置: X-MOL 学术IEEE Trans. Softw. Eng. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
Automatic Detection and Repair Recommendation of Directive Defects in Java API Documentation
IEEE Transactions on Software Engineering ( IF 6.5 ) Pub Date : 2020-09-01 , DOI: 10.1109/tse.2018.2872971
Yu Zhou , Changzhi Wang , Xin Yan , Taolue Chen , Sebastiano Panichella , Harald Gall

Application Programming Interfaces (APIs) represent key tools for software developers to build complex software systems. However, several studies have revealed that even major API providers tend to have incomplete or inconsistent API documentation. This can severely hamper the API comprehension and, as a consequence, the quality of the software built on them. In this paper, we propose DRONE (Detect and Repair of dOcumentatioN dEfects), a framework to automatically detect and repair defects from API documents by leveraging techniques from program analysis, natural language processing, and constraint solving. Specifically, we target at the directives of API documents, which are related to parameter constraints and exception handling declarations. Furthermore, in presence of defects, we also provide a prototypical repair recommendation system. We evaluate our approach on parts of the well-documented APIs of JDK 1.8 APIs (including javaFX) and Android 7.0 (level 24). Across the two empirical studies, our approach can detect API defects with an average F-measure of 79.9, 71.7, and 81.4 percent, respectively. The API repairing capability has also been evaluated on the generated recommendations in a further experiment. User judgments indicate that the constraint information is addressed correctly and concisely in the rendered directives.

中文翻译:

Java API 文档中指令缺陷的自动检测和修复建议

应用程序编程接口 (API) 是软件开发人员构建复杂软件系统的关键工具。然而,多项研究表明,即使是主要的 API 提供商也往往拥有不完整或不一致的 API 文档。这会严重阻碍 API 的理解,从而影响构建在它们之上的软件的质量。在本文中,我们提出了 DRONE(检测和修复文档缺陷),这是一种利用程序分析、自然语言处理和约束求解技术自动检测和修复 API 文档中的缺陷的框架。具体来说,我们针对 API 文档的指令,这些指令与参数约束和异常处理声明相关。此外,在存在缺陷的情况下,我们还提供了一个原型修复推荐系统。我们在 JDK 1.8 API(包括 javaFX)和 Android 7.0(级别 24)的部分记录良好的 API 上评估我们的方法。在两项实证研究中,我们的方法可以检测 API 缺陷,平均 F 值分别为 79.9、71.7 和 81.4%。在进一步的实验中,还根据生成的建议评估了 API 修复能力。用户判断表明约束信息在呈现的指令中得到了正确和简洁的处理。在进一步的实验中,还根据生成的建议评估了 API 修复能力。用户判断表明约束信息在呈现的指令中得到了正确和简洁的处理。在进一步的实验中,还根据生成的建议评估了 API 修复能力。用户判断表明约束信息在呈现的指令中得到了正确和简洁的处理。
更新日期:2020-09-01
down
wechat
bug