Difference between revisions of "Improving API Documentation Usability with Knowledge Pushing"
m |
m |
||
Line 1: | Line 1: | ||
− | + | Source: http://www.cs.cmu.edu/~udekel/papers/udekel_emoose_icse2009.pdf | |
− | http://www.cs.cmu.edu/~udekel/papers/udekel_emoose_icse2009.pdf | + | |
+ | Uri Dekel and James D. Herbsleb | ||
+ | |||
+ | Institute for Software Research, School of Computer Science | ||
+ | |||
+ | Carnegie Mellon University | ||
+ | |||
+ | 5000 Forbes Avenue, Pittsburgh, PA 15213 USA | ||
+ | |||
+ | {udekel|jdh}@cs.cmu.edu | ||
+ | |||
+ | ==Abstract== | ||
+ | ''The documentation of API functions typically conveys detailed specifications for the benefit of interested readers. In some cases, however, it also contains usage directives, such as rules or caveats, of which authors of invoking code must be made aware to prevent errors and inefficiencies. There is a risk that these directives may be “lost” within the verbose text, or that the text would not be read because there are so many invoked functions. To address these concerns for Java, an Eclipse plug-in named eMoose decorates method invocations whose targets have associated directives. Our goal is to lead readers to investigate further, which we aid by highlighting the tagged directives in the JavaDoc hover. We present a lab study that demonstrates the directive awareness problem in traditional documentation use and the potential benefits of our approach.'' | ||
+ | ==Introduction== | ||
+ | Modern software systems combine code written by many | ||
+ | individuals and make heavy use of external libraries and Application Programming Interfaces (APIS). Stakeholders in | ||
+ | these settings are not likely to be fully acquainted with all | ||
+ | current knowledge about artifacts and services in the project | ||
+ | and third-party code. When focused on a particular code | ||
+ | fragment, however, it may be critical for them to be wellversed in all the services that it uses. A lack of awareness of | ||
+ | usage guidelines and caveats can result in runtime failures | ||
+ | and maintenance difficulties. | ||
+ | |||
+ | Since many API functions are meant for widespread use, | ||
+ | their authors are motivated to invest significant effort in | ||
+ | creating elaborate documentation that fully specifies everything that a client may need to know about a function. Such | ||
+ | specifications are crucial for assuring correctness during inspections and the development of testing plans [5, 12]. Unfortunately, the potential consumers of this documentation | ||
+ | spend much of their time browsing code [4] that includes | ||
+ | numerous method invocations. They are therefore limited | ||
+ | in the time and effort they can spend on any particular call | ||
+ | and may therefore miss important information. | ||
+ | |||
+ | |||
+ | |||
[[Category:Article]] | [[Category:Article]] |
Revision as of 09:38, 16 May 2019
Source: http://www.cs.cmu.edu/~udekel/papers/udekel_emoose_icse2009.pdf
Uri Dekel and James D. Herbsleb
Institute for Software Research, School of Computer Science
Carnegie Mellon University
5000 Forbes Avenue, Pittsburgh, PA 15213 USA
{udekel|jdh}@cs.cmu.edu
Abstract
The documentation of API functions typically conveys detailed specifications for the benefit of interested readers. In some cases, however, it also contains usage directives, such as rules or caveats, of which authors of invoking code must be made aware to prevent errors and inefficiencies. There is a risk that these directives may be “lost” within the verbose text, or that the text would not be read because there are so many invoked functions. To address these concerns for Java, an Eclipse plug-in named eMoose decorates method invocations whose targets have associated directives. Our goal is to lead readers to investigate further, which we aid by highlighting the tagged directives in the JavaDoc hover. We present a lab study that demonstrates the directive awareness problem in traditional documentation use and the potential benefits of our approach.
Introduction
Modern software systems combine code written by many individuals and make heavy use of external libraries and Application Programming Interfaces (APIS). Stakeholders in these settings are not likely to be fully acquainted with all current knowledge about artifacts and services in the project and third-party code. When focused on a particular code fragment, however, it may be critical for them to be wellversed in all the services that it uses. A lack of awareness of usage guidelines and caveats can result in runtime failures and maintenance difficulties.
Since many API functions are meant for widespread use, their authors are motivated to invest significant effort in creating elaborate documentation that fully specifies everything that a client may need to know about a function. Such specifications are crucial for assuring correctness during inspections and the development of testing plans [5, 12]. Unfortunately, the potential consumers of this documentation spend much of their time browsing code [4] that includes numerous method invocations. They are therefore limited in the time and effort they can spend on any particular call and may therefore miss important information.