arrow
返回

Pre-implementation Method Name Prediction for Object-oriented Programming

delete2023-09-29
delete0
PRE
AI
S
Shangwen Wang
文
文明 (Ming Wen) *
B
Bo Lin *
Y
Yepang Liu
T
Tegawendé F. Bissyandé
X
Xiaoguang Mao
DOI:10.1145/3597203delete
delete原文链接
delete原文求助
delete分享
delete收藏
摘要

摘要

En 中文
Method naming is a challenging development task in object-oriented programming. In recent years, several research efforts have been undertaken to provide automated tool support for assisting developers in this task. In general, literature approaches assume the availability of method implementation to infer its name. Methods, however, are usually named before their implementations. In this work, we fill the gap in the literature about method name prediction by developing an approach that predicts the names of all methods to be implemented within a class. Our work considers the class name as the input: The overall intuition is that classes with semantically similar names tend to provide similar functionalities, and hence similar method names. We first conduct a large-scale empirical analysis on 258K+ classes from real-world projects to validate our hypotheses. Then, we propose a hybrid big code-driven approach, Mario, to predict method names based on the class name: We combine a deep learning model with heuristics summarized from code analysis. Extensive experiments on 22K+ classes yielded promising results: compared to the state-of-the-art code2seq model (which leverages method implementation data), our approach achieves comparable results in terms of F-score at token-level prediction; our approach, additionally, outperforms code2seq in prediction at the name level. We further show that our approach significantly outperforms several other baselines.
Keyword:
Method name prediction
naming convention

期刊

A
ACM Transactions on Software Engineering and Methodology
IF:
6.2
论文数:
1.2K
被引数:
3.4K

机构

N
national university of defense technology - china
学者数:
1.8W
论文数: 1.4W
被引数: 9
U
university of luxembourg
学者数:
5.2K
论文数: 4.8K
被引数: 4
引用论文

引用论文

Homeobox Gene Involvement in Normal Hematopoiesis and in the Pathogenesis of Childhood Leukemias
err2017-01-01
err0
PREAI
errMaria Adamaki; Maria Goulielmaki; Ioannis Christodoulou; Spiros Vlahopoulos; Vassilis Zoumpourlis
err分享
err收藏
The impact of identifier style on effort and comprehension标识符风格对努力和理解的影响
err2012-05-03
err113
PREAI
errBinkley, Dave; Davis, Marcia; Lawrie, Dawn; Maletic, Jonathan I.; Morrell, Christopher; Sharif, Bonita
err分享
err收藏
High-Throughput Liquid Chromatography–Tandem Mass Spectrometry Quantification of Glycosaminoglycans as Biomarkers of Mucopolysaccharidosis II
err2020-07-30
err0
errOAAI
errJunhua Wang; Akhil Bhalla; Julie C. Ullman; Meng Fang; Ritesh Ravi; Annie Arguello; Elliot Thomsen; Buyankhishig Tsogtbaatar; Jing L. Guo; Lukas L. Skuja; Jason C. Dugas; Sonnet S. Davis; Suresh B. Poda; Kannan Gunasekaran; Simona Costanzo; Zachary K. Sweeney; Anastasia G. Henry; Jeffrey M. Harris; Kirk R. Henne; Giuseppe Astarita
err分享
err收藏
学者 查看更多内容