arrow
返回

Assisting Example-Based API Misuse Detection via Complementary Artificial Examples

delete2022-09-01
delete2
PRE
AI
M
Maxime Lamothe *
H
Heng Li
W
Weiyi Shang
DOI:10.1109/TSE.2021.3093246delete
delete原文链接
delete分享
delete收藏
摘要

摘要

En 中文
Application Programming Interfaces (APIs) allow their users to reuse existing software functionality without implementing it by themselves. However, using external functionality can come at a cost. Because developers are decoupled from the API's inner workings, they face the possibility of misunderstanding, and therefore misusing APIs. Prior research has proposed state-of-the-art example-based API misuse detectors that rely on existing API usage examples mined from existing code bases. Intuitively, without a varied dataset of API usage examples, it is challenging for the example-based API misuse detectors to differentiate between infrequent but correct API usages and API misuses. Such mistakes lead to false positives in the API misuse detection results, which was reported in a recent study as a major limitation of the state-of-the-art. To tackle this challenge, in this paper, we first undertake a qualitative study of 384 falsely detected API misuses. We find that around one third of the false-positives are due to missing alternative correct API usage examples. Based on the knowledge gained from the qualitative study, we uncover five patterns which can be followed to generate artificial examples for complementing existing API usage examples in the API misuse detection. To evaluate the usefulness of the generated artificial examples, we apply a state-of-the-art example-based API misuse detector on 50 open source Java projects. We find that our artificial examples can complement the existing API usage examples by preventing the detection of 55 false API misuses. Furthermore, we conduct a pre-designed experiment in an automated API misuse detection benchmark (MUBench), in order to evaluate the impact of generated artificial examples on recall. We find that the API misuse detector covers the same true positive results with and without the artificial example, i.e., obtains the same recall of 94.7 percent. Our findings highlight the potential of improving API misuse detection by pattern-guided source code transformation techniques.
Keyword:
Detectors
Software
Tools
Usability
Java
Data mining
Task analysis
API-misuse detection
mining software repositories
empirical software engineering
software reuse
AI总结

AI总结

对已上传原文的论文进行重点信息的提取,主要内容包括:简要概述、研究摘要、背景介绍、关键亮点、图文解析、展望与总结。

A3: Assisting Android API Migrations Using Code Examples
err2022-02-01
err21
errOAAI
errLamothe, Maxime; Shang, Weiyi; Chen, Tse-Hsun (Peter)
err分享
err收藏
API beauty is in the eye of the clients: 2.2 million Maven dependencies reveal the spectrum of client-API usages
err2022-02-01
err12
errOAAI
errHarrand, Nicolas; Benelallam, Amine; Soto-Valero, Cesar; Bettega, Francois; Barais, Olivier; Baudry, Benoit
err分享
err收藏
Use and Misuse of the Term Experiment in Mining Software Repositories Research
err2022-11-01
err9
errOAAI
errAyala, Claudia; Turhan, Burak; Franch, Xavier; Juristo, Natalia
err分享
err收藏
The Impact of API Change- and Fault-Proneness on the User Ratings of Android Apps
err2015-04-01
err151
errOAAI
errBavota, Gabriele; Linares-Vasquez, Mario; Bernal-Cardenas, Carlos Eduardo; Di Penta, Massimiliano; Oliveto, Rocco; Poshyvanyk, Denys
err分享
err收藏

期刊

IEEE Transactions on Software Engineering 封面图
IEEE Transactions on Software Engineering
IF:
5.6
论文数:
3.0K
被引数:
1.3W

机构

P
Polytechnique Montréal
学者数:
194
论文数: 87
被引数: 2.2K
U
université de montréal
学者数:
1.0K
论文数: 435
被引数: 2.3W
引用论文

引用论文

err
IF0
err
err0
PREAI
err
err分享
err收藏
Overexpression of Mitochondrial IF1 Prevents Metastatic Disease of Colorectal Cancer by Enhancing Anoikis and Tumor Infiltration of NK Cells
err2019-12-19
err0
errOAAI
errLucía González-Llorente; Fulvio Santacatterina; Ana García-Aguilar; Cristina Nuevo-Tapioles; Sara González-García; Zuzana Tirpakova; María Luisa Toribio; José M. Cuezva
err分享
err收藏
err分享
err收藏
Subnormal parasympathetic activity after cardiac transplantation
err1990-11-01
err0
PREAI
errMichael L. Smith; Kenneth A. Ellenbogen; Dwain L. Eckberg; Helen M. Sheehan; Marc D. Thames
err分享
err收藏
Incidence of urinary tract complications with myelomeningocele
err1985-04-01
err0
PREAI
errA.S. Cass; M. Luxenberg; C.F. Johnson; P. Gleich
err分享
err收藏
学者 查看更多内容