Click here to load reader
Upload
sebastiano-panichella
View
239
Download
1
Embed Size (px)
DESCRIPTION
Program comprehension is a crucial activity, preliminary to any software maintenance task. Such an activity can be diffcult when the source code is not adequately documented, or the documentation is outdated. Differently from the many existing software re-documentation approaches, based on different kinds of code analysis, this paper describes CODES (mining sourCe cOde Descriptions from developErs diScussions), a tool which applies a \social" approach to software re-documentation. Specically, CODES extracts candidate method documentation from StackOver ow discussions, and creates Javadoc descriptions from it. We evaluated CODES to mine Lucene and Hibernate method descriptions. The results indicate that CODES is able to extract descriptions for 20% and 28% of the Lucene and Hibernate methods with a precision of 84% and 91% respectively. Demo URL: http://youtu.be/Rnc5ni1AAzc Demo Web Page: www.ing.unisannio.it/spanichella/pages/tools/CODES
Citation preview
CODES: mining sourCecOde Descriptions from developeErs diScussions
Carmine Sebastiano Massimiliano GerardoVassallo Panichella Di Penta Canfora
S. Panichella, J. Aponte, M. Di Penta, A. Marcus, G. Canfora - ICPC 2012
Such communications are… unstructured usually not explicitly meant to describe specific parts of the
source code.
Example: Eclipse (Java System)
METHOD: searchMainMethods
..........................
Problem seems to come from
in org.eclipse.jdt.internal.debug.ui.launcher.
,there's a to
addSubTypes(List, IProgressMonitor,
IJavaSearchScope) if includesSubtypes flag
is ON. This add all types sub-types as soon
as the given scope encloses them without testing
if sub-types have a main !
..........................
CLASS: MainMethodSearchEngine Parameters: “ORANGE”
Keywords: “GREEN”
searchMainMethods
MainMethodSearchEngine
(IProgressMonitor,
IJavaSearchScope, boolean) cal
l
method
method
method
Method
Bug Report and Mailing List
• Step 1: Downloading SO discussions relying on
its REST interface and tracing them onto classes
• Step 2: Extracting paragraphs
• Step 3: Tracing paragraphs onto methods( Discards Paragraphs of discussions with 0 Votes)
• Step 4: Heuristic based Filtering
• Step 5: Similarity based Filtering
CODES:
Approach for Mining Method Descriptions
DEMO
http://youtu.be/Rnc5ni1AAzc
CODES Results:
System MinedDescriptions
True Positives
False Positives
Apache Lucene2.9.0
9,343(about 20% of the
Methods)
84 16
Hibernate3.5.0
10,608(about 28% of the
Methods)
91 9
We sampled 100 descriptions from each project