On the Use of Domain Terms in Source Code

On the Use of Domain Terms in Source Code
复制标题

DOI:
10.1109/icpc.2008.29
复制
发表时间:
2008-06
期刊:
2008 16th IEEE International Conference on Program Comprehension
影响因子:
--
通讯作者:
S. Haiduc;Andrian Marcus
S. Haiduc;Andrian Marcus
中科院分区:
其他
文献类型:
--
作者:
S. Haiduc;Andrian Marcus

文献摘要

被引文献

相似文献

有关软件问题域及其实现的解决方案的信息通常由开发人员嵌入在注释和标识符中。当使用别人开发的软件或刚刚接触一个项目时,程序员对领域信息如何在源代码中反映知之甚少。程序员经常从书籍、文章等外部来源了解该领域。因此,在注释和标识符中使用领域文献中众所周知的术语非常重要,因为程序员在搜索源代码时很可能会使用这些术语。本文提出了一个案例研究,调查了如何在注释和标识符中使用领域术语。该研究集中于三个研究问题:(1)在特定问题领域的软件源代码中发现领域术语的程度如何? (2) 哪个是领域术语的主要来源:标识符还是注释?; (3)来自同一问题域的多个系统之间的域术语共享程度如何?在所研究的软件中,我们发现平均而言: 42% 的领域术语在源代码中使用;源代码中使用的领域术语中有 23% 仅出现在注释中,而仅在标识符中仅出现 11%,并且任何两个软件系统之间在领域术语的使用上有 63% 的一致性。
Information about the problem domain of the software and the solution it implements is often embedded by developers in comments and identifiers. When using software developed by others or when are new to a project, programmers know little about how domain information is reflected in the source code. Programmers often learn about the domain from external sources such as books, articles, etc. Hence, it is important to use in comments and identifiers terms that are commonly known in the domain literature, as it is likely that programmers will use such terms when searching the source code. The paper presents a case study that investigated how domain terms are used in comments and identifiers. The study focused on three research questions: (1) to what degree are domain terms found in the source code of software from a particular problem domain?; (2) which is the preponderant source of domain terms: identifiers or comments?; and (3) to what degree are domain terms shared between several systems from the same problem domain? Within the studied software, we found that in average: 42% of the domain terms were used in the source code; 23% of the domain terms used in the source code are present in comments only, whereas only 11% in the identifiers alone, and there is a 63% agreement in the use of domain terms between any two software systems.