A Documentation-Based Constraint Generation Method For Java Apis

INTERNETWARE'18: PROCEEDINGS OF THE TENTH ASIA-PACIFIC SYMPOSIUM ON INTERNETWARE(2018)

引用 1|浏览69
暂无评分
摘要
As the efficiency of constraint solvers increases, constraint solving has been widely used in many applications of software engineering, such as test case generation, program synthesis and code search. However, encoding source code into constraints is not an easy task. Particularly, when it comes to complex data structures of library functions, existing work cannot generate effective constraints.In this paper, we propose a documentation-based method to generate constraint for Java APIs. It mainly uses Natural Language Processing (NLP) techniques to construct syntactic trees by extracting the specifications of methods. Then it uses predefined constraint templates to generate constraint models by traversing the syntactic trees. Our approach successfully models 228 methods for 11 Java container classes and string-related classes. We summarize 12 functional behavior and formulate 21 constraint templates for these classes. Compared with other tools, our approach models most of methods about string-related classes, and more importantly, generates constraint models for Java container classes that other tools cannot. In order to evaluate the effectiveness of our constraint models, we apply them into test case generation. The experimental result shows that constraint models we generate have practical use.
更多
查看译文
关键词
Constraint model, Sequence theory, NLP techniques
AI 理解论文
溯源树
样例
生成溯源树,研究论文发展脉络
Chat Paper
正在生成论文摘要