Hello World!
2
findbugs/LWJake2.fbf
Normal file
@@ -0,0 +1,2 @@
|
||||
<FindBugsFilter>
|
||||
</FindBugsFilter>
|
||||
6
findbugs/LWJake2.fbp
Normal file
@@ -0,0 +1,6 @@
|
||||
<Project projectName="LWJake2">
|
||||
<Jar>../built/jar/lwjake2.jar</Jar>
|
||||
<AuxClasspathEntry>../lib/lwjgl.jar</AuxClasspathEntry>
|
||||
<AuxClasspathEntry>../lib/lwjgl_util.jar</AuxClasspathEntry>
|
||||
<SrcDir>../src</SrcDir>
|
||||
</Project>
|
||||
20
findbugs/findbugs-2.0.0/README.txt
Normal file
@@ -0,0 +1,20 @@
|
||||
To get started, see doc/index.html and doc/manual/index.html
|
||||
|
||||
The FindBugs source license is in the file LICENSE.txt
|
||||
|
||||
Both the name FindBugs and the FindBugs bug mark are
|
||||
trademarked by the University of Maryland.
|
||||
|
||||
The Apache BCEL license is in the file LICENSE-bcel.txt
|
||||
|
||||
The ASM license is in the file LICENSE-ASM.txt
|
||||
|
||||
The dom4j license is in the file LICENSE-dom4j.txt
|
||||
|
||||
The AppleJavaExtensions license is in the file LICENSE-AppleJavaExtensions.txt
|
||||
|
||||
The Docbook 4.2 XML DTD license is in the file LICENSE-docbook.txt
|
||||
|
||||
The JSR-305 reference implementation license is in LICENSE-jsr305.txt
|
||||
|
||||
The Jaxen license is in LICENSE-jaxen.txt
|
||||
73
findbugs/findbugs-2.0.0/bin/addMessages
Executable file
@@ -0,0 +1,73 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.AddMessages
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
78
findbugs/findbugs-2.0.0/bin/computeBugHistory
Executable file
@@ -0,0 +1,78 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Merge a historical bug collection and a bug collection, producing an updated
|
||||
# historical bug collection
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.Update
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
73
findbugs/findbugs-2.0.0/bin/convertXmlToText
Executable file
@@ -0,0 +1,73 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.PrintingBugReporter
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
75
findbugs/findbugs-2.0.0/bin/copyBuggySource
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.CopyBuggySource
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
77
findbugs/findbugs-2.0.0/bin/defectDensity
Executable file
@@ -0,0 +1,77 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Generate a defect density table from a bug collection
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.DefectDensity
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/deprecated/bugHistory
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.BugHistory
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
78
findbugs/findbugs-2.0.0/bin/deprecated/unionBugs
Executable file
@@ -0,0 +1,78 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Create the union of two results files, preserving
|
||||
# annotations in both files in the result.
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.UnionResults
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
80
findbugs/findbugs-2.0.0/bin/deprecated/unionResults
Executable file
@@ -0,0 +1,80 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Deprecated
|
||||
|
||||
# Create the union of two results files, preserving
|
||||
# annotations in both files in the result.
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.UnionResults
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
78
findbugs/findbugs-2.0.0/bin/deprecated/updateBugs
Executable file
@@ -0,0 +1,78 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Merge a historical bug collection and a bug collection, producing an updated
|
||||
# historical bug collection
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.Update
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/experimental/backdateHistoryUsingSource
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.BackdateHistoryUsingSource
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/experimental/churn
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.Churn
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/experimental/obfuscate
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.ObfuscateBugs
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/experimental/treemapVisualization
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.TreemapVisualization
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
192
findbugs/findbugs-2.0.0/bin/fb
Executable file
@@ -0,0 +1,192 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Launch FindBugs from the command line.
|
||||
|
||||
escape_arg() {
|
||||
echo "$1" | sed -e "s,\\([\\\"' ]\\),\\\\\\1,g"
|
||||
}
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
|
||||
fb_appjar="$findbugs_home/lib/findbugs.jar"
|
||||
|
||||
ShowHelpAndExit() {
|
||||
fb_mainclass="edu.umd.cs.findbugs.ShowHelp"
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
exit 0
|
||||
}
|
||||
|
||||
# Set defaults
|
||||
fb_mainclass="edu.umd.cs.findbugs.workflow.FB"
|
||||
user_jvmargs=''
|
||||
ea_arg=''
|
||||
debug_arg=''
|
||||
conservespace_arg=''
|
||||
workhard_arg=''
|
||||
user_props=''
|
||||
|
||||
# Handle command line arguments.
|
||||
while [ $# -gt 0 ]; do
|
||||
case $1 in
|
||||
-textui)
|
||||
fb_mainclass="edu.umd.cs.findbugs.FindBugs2"
|
||||
;;
|
||||
|
||||
-jvmArgs)
|
||||
shift
|
||||
user_jvmargs="$1"
|
||||
;;
|
||||
|
||||
-ea)
|
||||
ea_arg='-ea'
|
||||
;;
|
||||
|
||||
-maxHeap)
|
||||
shift
|
||||
fb_maxheap="-Xmx$1m"
|
||||
;;
|
||||
|
||||
-javahome)
|
||||
shift
|
||||
fb_javacmd="$1/bin/java"
|
||||
;;
|
||||
|
||||
-debug)
|
||||
debug_arg="-Dfindbugs.debug=true"
|
||||
;;
|
||||
|
||||
-conserveSpace)
|
||||
conservespace_arg="-Dfindbugs.conserveSpace=true"
|
||||
;;
|
||||
|
||||
-property)
|
||||
shift
|
||||
user_props="-D$1 $user_props"
|
||||
;;
|
||||
|
||||
-D*=*)
|
||||
user_props="$1 $user_props"
|
||||
;;
|
||||
|
||||
-version)
|
||||
fb_mainclass=edu.umd.cs.findbugs.Version
|
||||
fb_appargs="-release"
|
||||
while [ $# -gt 0 ]; do
|
||||
shift
|
||||
done
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
exit 0
|
||||
;;
|
||||
|
||||
-help)
|
||||
ShowHelpAndExit
|
||||
;;
|
||||
|
||||
# All unrecognized arguments will be accumulated and
|
||||
# passed to the application.
|
||||
*)
|
||||
fb_appargs="$fb_appargs `escape_arg "$1"`"
|
||||
;;
|
||||
esac
|
||||
|
||||
shift
|
||||
done
|
||||
|
||||
fb_jvmargs="$user_jvmargs $debug_arg $conservespace_arg $workhard_arg $user_props $ea_arg"
|
||||
if [ $maxheap ]; then
|
||||
fb_maxheap="-Xmx${maxheap}m"
|
||||
fi
|
||||
|
||||
# Extra JVM args for MacOSX.
|
||||
if [ $fb_osname = "Darwin" ]; then
|
||||
fb_jvmargs="$fb_jvmargs \
|
||||
-Xdock:name=FindBugs -Xdock:icon=${findbugs_home}/lib/buggy.icns \
|
||||
-Dapple.laf.useScreenMenuBar=true"
|
||||
fi
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
84
findbugs/findbugs-2.0.0/bin/fbwrap
Executable file
@@ -0,0 +1,84 @@
|
||||
#! /bin/sh
|
||||
|
||||
# A convenient way to call the main() method of a class
|
||||
# in findbugs.jar.
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
if [ $# -eq 0 ]; then
|
||||
echo "Usage: fbwrap <main class name> <args...>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
fb_mainclass="$1"
|
||||
shift
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
78
findbugs/findbugs-2.0.0/bin/filterBugs
Executable file
@@ -0,0 +1,78 @@
|
||||
#! /bin/sh
|
||||
|
||||
# General purpose utility for filtering/transforming
|
||||
# bug collection and/or historical bug collections
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.Filter
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
199
findbugs/findbugs-2.0.0/bin/findbugs
Executable file
@@ -0,0 +1,199 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Launch FindBugs from the command line.
|
||||
|
||||
escape_arg() {
|
||||
echo "$1" | sed -e "s,\\([\\\"' ]\\),\\\\\\1,g"
|
||||
}
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_appjar="$findbugs_home/lib/findbugs.jar"
|
||||
|
||||
ShowHelpAndExit() {
|
||||
fb_mainclass="edu.umd.cs.findbugs.ShowHelp"
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
exit 0
|
||||
}
|
||||
|
||||
# Set defaults
|
||||
fb_mainclass="edu.umd.cs.findbugs.LaunchAppropriateUI"
|
||||
user_jvmargs=''
|
||||
ea_arg=''
|
||||
debug_arg=''
|
||||
conservespace_arg=''
|
||||
workhard_arg=''
|
||||
user_props=''
|
||||
|
||||
# Handle command line arguments.
|
||||
while [ $# -gt 0 ]; do
|
||||
case $1 in
|
||||
-gui)
|
||||
# this is the default
|
||||
;;
|
||||
|
||||
-gui1)
|
||||
user_props="-Dfindbugs.launchUI=1 $user_props"
|
||||
;;
|
||||
|
||||
-textui)
|
||||
fb_mainclass="edu.umd.cs.findbugs.FindBugs2"
|
||||
;;
|
||||
|
||||
-jvmArgs)
|
||||
shift
|
||||
user_jvmargs="$1"
|
||||
;;
|
||||
|
||||
-ea)
|
||||
ea_arg='-ea'
|
||||
;;
|
||||
|
||||
-maxHeap)
|
||||
shift
|
||||
fb_maxheap="-Xmx$1m"
|
||||
;;
|
||||
|
||||
-javahome)
|
||||
shift
|
||||
fb_javacmd="$1/bin/java"
|
||||
;;
|
||||
|
||||
-debug)
|
||||
debug_arg="-Dfindbugs.debug=true"
|
||||
;;
|
||||
|
||||
-conserveSpace)
|
||||
conservespace_arg="-Dfindbugs.conserveSpace=true"
|
||||
;;
|
||||
|
||||
-property)
|
||||
shift
|
||||
user_props="-D$1 $user_props"
|
||||
;;
|
||||
|
||||
-D*=*)
|
||||
user_props="$1 $user_props"
|
||||
;;
|
||||
|
||||
-version)
|
||||
fb_mainclass=edu.umd.cs.findbugs.Version
|
||||
fb_appargs="-release"
|
||||
while [ $# -gt 0 ]; do
|
||||
shift
|
||||
done
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
exit 0
|
||||
;;
|
||||
|
||||
-help)
|
||||
ShowHelpAndExit
|
||||
;;
|
||||
|
||||
# All unrecognized arguments will be accumulated and
|
||||
# passed to the application.
|
||||
*)
|
||||
fb_appargs="$fb_appargs `escape_arg "$1"`"
|
||||
;;
|
||||
esac
|
||||
|
||||
shift
|
||||
done
|
||||
|
||||
fb_jvmargs="$user_jvmargs $debug_arg $conservespace_arg $workhard_arg $user_props $ea_arg"
|
||||
if [ $maxheap ]; then
|
||||
fb_maxheap="-Xmx${maxheap}m"
|
||||
fi
|
||||
|
||||
# Extra JVM args for MacOSX.
|
||||
if [ $fb_osname = "Darwin" ]; then
|
||||
fb_jvmargs="$fb_jvmargs \
|
||||
-Xdock:name=FindBugs -Xdock:icon=${findbugs_home}/lib/buggy.icns \
|
||||
-Dapple.laf.useScreenMenuBar=true"
|
||||
fi
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
76
findbugs/findbugs-2.0.0/bin/findbugs-csr
Executable file
@@ -0,0 +1,76 @@
|
||||
#! /bin/sh
|
||||
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.CloudSyncAndReport
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
76
findbugs/findbugs-2.0.0/bin/findbugs-dbStats
Executable file
@@ -0,0 +1,76 @@
|
||||
#! /bin/sh
|
||||
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.cloud.db.DBStats
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
76
findbugs/findbugs-2.0.0/bin/findbugs-msv
Executable file
@@ -0,0 +1,76 @@
|
||||
#! /bin/sh
|
||||
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.MergeSummarizeAndView
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
240
findbugs/findbugs-2.0.0/bin/findbugs.bat
Normal file
@@ -0,0 +1,240 @@
|
||||
@echo off
|
||||
:: Launch FindBugs on a Windows system.
|
||||
:: Adapted from scripts found at http://www.ericphelps.com/batch/
|
||||
:: This will only work on Windows NT or later!
|
||||
|
||||
:: Don't affect environment outside of this invocation
|
||||
setlocal
|
||||
|
||||
:: ----------------------------------------------------------------------
|
||||
:: Set up default values
|
||||
:: ----------------------------------------------------------------------
|
||||
set appjar=findbugs.jar
|
||||
set javahome=
|
||||
set launcher=java.exe
|
||||
set start=start "FindBugs"
|
||||
set jvmargs=
|
||||
set debugArg=
|
||||
set conserveSpaceArg=
|
||||
set workHardArg=
|
||||
set args=
|
||||
set javaProps=
|
||||
set maxheap=768
|
||||
|
||||
REM default UI is gui2
|
||||
set launchUI=2
|
||||
|
||||
:: Try finding the default FINDBUGS_HOME directory
|
||||
:: from the directory path of this script
|
||||
set default_findbugs_home=%~dp0..
|
||||
|
||||
:: Honor JAVA_HOME environment variable if it is set
|
||||
if "%JAVA_HOME%"=="" goto nojavahome
|
||||
if not exist "%JAVA_HOME%\bin\javaw.exe" goto nojavahome
|
||||
set javahome=%JAVA_HOME%\bin\
|
||||
:nojavahome
|
||||
|
||||
goto loop
|
||||
|
||||
:: ----------------------------------------------------------------------
|
||||
:: Process command-line arguments
|
||||
:: ----------------------------------------------------------------------
|
||||
|
||||
:shift2
|
||||
shift
|
||||
:shift1
|
||||
shift
|
||||
|
||||
:loop
|
||||
|
||||
:: Remove surrounding quotes from %1 and %2
|
||||
set firstArg=%~1
|
||||
set secondArg=%~2
|
||||
|
||||
if "%firstArg%"=="" goto launch
|
||||
|
||||
:: AddMessages
|
||||
if not "%firstArg%"=="-addMessages" goto notAddMessages
|
||||
set fb_mainclass=edu.umd.cs.findbugs.AddMessages
|
||||
goto shift1
|
||||
:notAddMessages
|
||||
|
||||
:: computeBugHistory
|
||||
if not "%firstArg%"=="-computeBugHistory" goto notUpdate
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.Update
|
||||
goto shift1
|
||||
:notUpdate
|
||||
|
||||
:: convertXmlToText
|
||||
if not "%firstArg%"=="-xmltotext" goto notXmlToText
|
||||
set fb_mainclass=edu.umd.cs.findbugs.PrintingBugReporter
|
||||
goto shift1
|
||||
:notXmlToText
|
||||
|
||||
:: copyBuggySource
|
||||
if not "%firstArg%"=="-copyBS" goto notCopyBS
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.CopyBuggySource
|
||||
goto shift1
|
||||
:notCopyBS
|
||||
|
||||
:: defectDensity
|
||||
if not "%firstArg%"=="-defectDensity" goto notDefectDensity
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.DefectDensity
|
||||
goto shift1
|
||||
:notDefectDensity
|
||||
|
||||
:: filterBugs
|
||||
if not "%firstArg%"=="-filterBugs" goto notFilterBugs
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.Filter
|
||||
goto shift1
|
||||
:notFilterBugs
|
||||
|
||||
:: listBugDatabaseInfo
|
||||
if not "%firstArg%"=="-listBugDatabaseInfo" goto notListBugDatabaseInfo
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.ListBugDatabaseInfo
|
||||
goto shift1
|
||||
:notListBugDatabaseInfo
|
||||
|
||||
:: mineBugHistory
|
||||
if not "%firstArg%"=="-mineBugHistory" goto notMineBugHistory
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.MineBugHistory
|
||||
goto shift1
|
||||
:notMineBugHistory
|
||||
|
||||
:: printAppVersion
|
||||
if not "%firstArg%"=="-printAppVersion" goto notPrintAppVersion
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.PrintAppVersion
|
||||
goto shift1
|
||||
:notPrintAppVersion
|
||||
|
||||
:: printClass
|
||||
if not "%firstArg%"=="-printClass" goto notPrintClass
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.PrintClass
|
||||
goto shift1
|
||||
:notPrintClass
|
||||
|
||||
:: rejarForAnalysis
|
||||
if not "%firstArg%"=="-rejar" goto notRejar
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.RejarClassesForAnalysis
|
||||
goto shift1
|
||||
:notRejar
|
||||
|
||||
:: setBugDatabaseInfo
|
||||
if not "%firstArg%"=="-setInfo" goto notSetBugDatabaseInfo
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.SetBugDatabaseInfo
|
||||
goto shift1
|
||||
:notSetBugDatabaseInfo
|
||||
|
||||
:: unionBugs
|
||||
if not "%firstArg%"=="-unionBugs" goto notUnionBugs
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.UnionResults
|
||||
goto shift1
|
||||
:notUnionBugs
|
||||
|
||||
:: xpathFind
|
||||
if not "%firstArg%"=="-xpathFind" goto notXPathFind
|
||||
set fb_mainclass=edu.umd.cs.findbugs.workflow.XPathFind
|
||||
goto shift1
|
||||
:notXPathFind
|
||||
|
||||
if not "%firstArg%"=="-gui" goto notGui
|
||||
set launchUI=2
|
||||
set launcher=javaw.exe
|
||||
goto shift1
|
||||
:notGui
|
||||
|
||||
if not "%firstArg%"=="-gui1" goto notGui1
|
||||
set launchUI=1
|
||||
set javaProps=-Dfindbugs.launchUI=1 %javaProps%
|
||||
set launcher=javaw.exe
|
||||
goto shift1
|
||||
:notGui1
|
||||
|
||||
if not "%firstArg%"=="-textui" goto notTextui
|
||||
set launchUI=0
|
||||
set launcher=java.exe
|
||||
set start=
|
||||
goto shift1
|
||||
:notTextui
|
||||
|
||||
if not "%firstArg%"=="-debug" goto notDebug
|
||||
set launcher=java.exe
|
||||
set start=
|
||||
set debugArg=-Dfindbugs.debug=true
|
||||
goto shift1
|
||||
:notDebug
|
||||
|
||||
if not "%firstArg%"=="-help" goto notHelp
|
||||
set launchUI=help
|
||||
set launcher=java.exe
|
||||
set start=
|
||||
goto shift1
|
||||
:notHelp
|
||||
|
||||
if not "%firstArg%"=="-version" goto notVersion
|
||||
set launchUI=version
|
||||
set launcher=java.exe
|
||||
set start=
|
||||
goto shift1
|
||||
:notVersion
|
||||
|
||||
if "%firstArg%"=="-home" set FINDBUGS_HOME=%secondArg%
|
||||
if "%firstArg%"=="-home" goto shift2
|
||||
|
||||
if "%firstArg%"=="-jvmArgs" set jvmargs=%secondArg%
|
||||
if "%firstArg%"=="-jvmArgs" goto shift2
|
||||
|
||||
if "%firstArg%"=="-maxHeap" set maxheap=%secondArg%
|
||||
if "%firstArg%"=="-maxHeap" goto shift2
|
||||
|
||||
if "%firstArg%"=="-conserveSpace" set conserveSpaceArg=-Dfindbugs.conserveSpace=true
|
||||
if "%firstArg%"=="-conserveSpace" goto shift1
|
||||
|
||||
if "%firstArg%"=="-workHard" set workHardArg=-Dfindbugs.workHard=true
|
||||
if "%firstArg%"=="-workHard" goto shift1
|
||||
|
||||
if "%firstArg%"=="-javahome" set javahome=%secondArg%\bin\
|
||||
if "%firstArg%"=="-javahome" goto shift2
|
||||
|
||||
if "%firstArg%"=="-property" set javaProps=-D%secondArg% %javaProps%
|
||||
if "%firstArg%"=="-property" goto shift2
|
||||
|
||||
if "%firstArg%"=="" goto launch
|
||||
|
||||
set args=%args% "%firstArg%"
|
||||
goto shift1
|
||||
|
||||
:: ----------------------------------------------------------------------
|
||||
:: Launch FindBugs
|
||||
:: ----------------------------------------------------------------------
|
||||
:launch
|
||||
:: Make sure FINDBUGS_HOME is set.
|
||||
:: If it isn't, try using the default value based on the
|
||||
:: directory path of the invoked script.
|
||||
:: Note that this will fail miserably if the value of FINDBUGS_HOME
|
||||
:: has quote characters in it.
|
||||
if not "%FINDBUGS_HOME%"=="" goto checkHomeValid
|
||||
set FINDBUGS_HOME=%default_findbugs_home%
|
||||
|
||||
:checkHomeValid
|
||||
if not exist "%FINDBUGS_HOME%\lib\%appjar%" goto homeNotSet
|
||||
|
||||
:found_home
|
||||
:: Launch FindBugs!
|
||||
if "%fb_mainclass%"=="" goto runJar
|
||||
"%javahome%%launcher%" %debugArg% %conserveSpaceArg% %workHardArg% %javaProps% "-Dfindbugs.home=%FINDBUGS_HOME%" -Xmx%maxheap%m %jvmargs% "-Dfindbugs.launchUI=%launchUI%" -cp "%FINDBUGS_HOME%\lib\%appjar%" %fb_mainclass% %args%
|
||||
goto end
|
||||
:runjar
|
||||
%start% "%javahome%%launcher%" %debugArg% %conserveSpaceArg% %workHardArg% %javaProps% "-Dfindbugs.home=%FINDBUGS_HOME%" -Xmx%maxheap%m %jvmargs% "-Dfindbugs.launchUI=%launchUI%" -jar "%FINDBUGS_HOME%\lib\%appjar%" %args%
|
||||
goto end
|
||||
|
||||
:: ----------------------------------------------------------------------
|
||||
:: Report that FINDBUGS_HOME is not set (and was not specified)
|
||||
:: ----------------------------------------------------------------------
|
||||
:homeNotSet
|
||||
echo Could not find FindBugs home directory. There may be a problem
|
||||
echo with the FindBugs installation. Try setting FINDBUGS_HOME, or
|
||||
echo re-installing.
|
||||
goto end
|
||||
|
||||
:end
|
||||
177
findbugs/findbugs-2.0.0/bin/findbugs2
Executable file
@@ -0,0 +1,177 @@
|
||||
#! /bin/sh
|
||||
|
||||
#
|
||||
# Simplified findbugs startup script.
|
||||
# This is an experiment.
|
||||
#
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
# Default UI is GUI2
|
||||
fb_launchui="2"
|
||||
|
||||
#
|
||||
# Stuff we're going to pass to the JVM as JVM arguments.
|
||||
#
|
||||
jvm_debug=""
|
||||
jvm_maxheap="-Xmx768m"
|
||||
jvm_ea=""
|
||||
jvm_conservespace=""
|
||||
jvm_user_props=""
|
||||
|
||||
#
|
||||
# Process command line args until we hit one we don't recognize.
|
||||
#
|
||||
finishedArgs=false
|
||||
while [ $# -gt 0 ] && [ "$finishedArgs" = "false" ]; do
|
||||
|
||||
arg=$1
|
||||
|
||||
case $arg in
|
||||
-textui)
|
||||
shift
|
||||
fb_launchui="0"
|
||||
;;
|
||||
|
||||
-gui)
|
||||
shift
|
||||
fb_launchui="2"
|
||||
;;
|
||||
|
||||
-gui1)
|
||||
shift
|
||||
fb_launchui="1"
|
||||
;;
|
||||
|
||||
-maxHeap)
|
||||
shift
|
||||
jvm_maxheap="-Xmx$1m"
|
||||
shift
|
||||
;;
|
||||
|
||||
-ea)
|
||||
shift
|
||||
jvm_ea="-ea"
|
||||
;;
|
||||
|
||||
-javahome)
|
||||
shift
|
||||
fb_javacmd="$1/bin/java"
|
||||
shift
|
||||
;;
|
||||
|
||||
-debug)
|
||||
shift
|
||||
jvm_debug="-Dfindbugs.debug=true"
|
||||
;;
|
||||
|
||||
-conserveSpace)
|
||||
shift
|
||||
jvm_conservespace="-Dfindbugs.conserveSpace=true"
|
||||
;;
|
||||
|
||||
-property)
|
||||
shift
|
||||
jvm_user_props="-D$1 $jvm_user_props"
|
||||
shift
|
||||
;;
|
||||
|
||||
-D*=*)
|
||||
jvm_user_props="$1 $user_props"
|
||||
shift
|
||||
;;
|
||||
|
||||
-version)
|
||||
shift
|
||||
fb_launchui="version"
|
||||
;;
|
||||
|
||||
-help)
|
||||
shift
|
||||
fb_launchui="help"
|
||||
;;
|
||||
|
||||
# All arguments starting from the first unrecognized arguments
|
||||
# are passed on to the Java app.
|
||||
*)
|
||||
finishedArgs=true
|
||||
;;
|
||||
esac
|
||||
|
||||
done
|
||||
|
||||
# Extra JVM args for MacOSX.
|
||||
if [ $fb_osname = "Darwin" ]; then
|
||||
fb_jvmargs="$fb_jvmargs \
|
||||
-Xdock:name=FindBugs -Xdock:icon=${findbugs_home}/lib/buggy.icns \
|
||||
-Dapple.laf.useScreenMenuBar=true"
|
||||
fi
|
||||
|
||||
#
|
||||
# Launch JVM
|
||||
#
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home" \
|
||||
$jvm_debug $jvm_maxheap $jvm_ea $jvm_conservespace $jvm_user_props \
|
||||
-Dfindbugs.launchUI=$fb_launchui \
|
||||
-jar $findbugs_home/lib/findbugs.jar \
|
||||
${@:+"$@"}
|
||||
75
findbugs/findbugs-2.0.0/bin/listBugDatabaseInfo
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.ListBugDatabaseInfo
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
73
findbugs/findbugs-2.0.0/bin/mineBugHistory
Executable file
@@ -0,0 +1,73 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.MineBugHistory
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
75
findbugs/findbugs-2.0.0/bin/printAppVersion
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.PrintAppVersion
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
73
findbugs/findbugs-2.0.0/bin/printClass
Executable file
@@ -0,0 +1,73 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.visitclass.PrintClass
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
75
findbugs/findbugs-2.0.0/bin/rejarForAnalysis
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.RejarClassesForAnalysis
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/setBugDatabaseInfo
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.SetBugDatabaseInfo
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
80
findbugs/findbugs-2.0.0/bin/unionBugs
Executable file
@@ -0,0 +1,80 @@
|
||||
#! /bin/sh
|
||||
|
||||
# Deprecated
|
||||
|
||||
# Create the union of two results files, preserving
|
||||
# annotations in both files in the result.
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.workflow.UnionResults
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
75
findbugs/findbugs-2.0.0/bin/xpathFind
Executable file
@@ -0,0 +1,75 @@
|
||||
#! /bin/sh
|
||||
|
||||
program="$0"
|
||||
|
||||
# Follow symlinks until we get to the actual file.
|
||||
while [ -h "$program" ]; do
|
||||
link=`ls -ld "$program"`
|
||||
link=`expr "$link" : '.*-> \(.*\)'`
|
||||
if [ "`expr "$link" : '/.*'`" = 0 ]; then
|
||||
# Relative
|
||||
dir=`dirname "$program"`
|
||||
program="$dir/$link"
|
||||
else
|
||||
# Absolute
|
||||
program="$link"
|
||||
fi
|
||||
done
|
||||
|
||||
# Assume findbugs home directory is the parent
|
||||
# of the directory containing the script (which should
|
||||
# normally be "$findbugs_home/bin").
|
||||
dir=`dirname "$program"`
|
||||
findbugs_home="$dir/.."
|
||||
|
||||
# Handle FHS-compliant installations (e.g., Fink)
|
||||
if [ -d "$findbugs_home/share/findbugs" ]; then
|
||||
findbugs_home="$findbugs_home/share/findbugs"
|
||||
fi
|
||||
|
||||
# Make absolute
|
||||
findbugs_home=`cd "$findbugs_home" && pwd`
|
||||
|
||||
fb_pathsep=':'
|
||||
|
||||
# Handle cygwin, courtesy of Peter D. Stout
|
||||
fb_osname=`uname`
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
findbugs_home=`cygpath --mixed "$findbugs_home"`
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
# Handle MKS, courtesy of Kelly O'Hair
|
||||
if [ "${fb_osname}" = "Windows_NT" ]; then
|
||||
fb_pathsep=';'
|
||||
fi
|
||||
|
||||
if [ ! -d "$findbugs_home" ]; then
|
||||
echo "The path $findbugs_home,"
|
||||
echo "which is where I think FindBugs is located,"
|
||||
echo "does not seem to be a directory."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
# Choose default java binary
|
||||
fb_javacmd=java
|
||||
if [ ! -z "$JAVA_HOME" ] && [ -x "$JAVA_HOME/bin/java" ]; then
|
||||
if [ `expr "$fb_osname" : CYGWIN` -ne 0 ]; then
|
||||
fb_javacmd=`cygpath --mixed "$JAVA_HOME"`/bin/java
|
||||
else
|
||||
fb_javacmd="$JAVA_HOME/bin/java"
|
||||
fi
|
||||
fi
|
||||
|
||||
fb_mainclass=edu.umd.cs.findbugs.xml.XPathFind
|
||||
|
||||
fb_javacmd=${fb_javacmd:-"java"}
|
||||
fb_maxheap=${fb_maxheap:-"-Xmx768m"}
|
||||
fb_appjar=${fb_appjar:-"$findbugs_home/lib/findbugs.jar"}
|
||||
set -f
|
||||
#echo command: \
|
||||
exec "$fb_javacmd" \
|
||||
-classpath "$fb_appjar$fb_pathsep$CLASSPATH" \
|
||||
-Dfindbugs.home="$findbugs_home"\
|
||||
$fb_maxheap $fb_jvmargs $fb_mainclass ${@:+"$@"} $fb_appargs
|
||||
|
||||
# vim:ts=3
|
||||
237
findbugs/findbugs-2.0.0/doc/AddingDetectors.txt
Normal file
@@ -0,0 +1,237 @@
|
||||
Adding Detectors to FindBugs
|
||||
May 12, 2003
|
||||
Updated June 6, 2003 (detector meta-information, cleanups)
|
||||
|
||||
===============
|
||||
1. Introduction
|
||||
===============
|
||||
|
||||
FindBugs uses a plugin-based approach to adding detectors.
|
||||
This makes it easy for users to add their own detectors alongside
|
||||
the ones that come built in.
|
||||
|
||||
Basic idea: FindBugs has some Jar files in a "plugins" directory.
|
||||
At startup, each of those jar files is checked for a "findbugs.xml"
|
||||
file. That XML file registers instances of Detectors, as well
|
||||
as particular "bug patterns" that the detector reports.
|
||||
|
||||
Additionally to the findbugs.xml, bugrank.txt and messages.xml files are
|
||||
required for each FindBugs detector plugin.
|
||||
|
||||
At startup, FindBugs loads all plugin Jar files. At analysis time,
|
||||
all detectors named in the findbugs.xml files from those plugins
|
||||
are instantiated and applied to analyzed class files.
|
||||
|
||||
In order to format reported BugInstances as text for display,
|
||||
a messages file is loaded from the plugin. In order to support multiple
|
||||
language translations, a locale search is performed in a manner
|
||||
similar to the handling of resource bundles. For example, if the
|
||||
locale is "pt_BR", then the files
|
||||
|
||||
messages_pt_BR.xml
|
||||
messages_pt.xml
|
||||
messages.xml
|
||||
|
||||
are tried, in that order.
|
||||
|
||||
The "findbugs.xml" and "messages.xml" files used by the standard FindBugs
|
||||
bug pattern detectors (coreplugin.jar) can be found in the "etc" directory
|
||||
of the findbugs source distribution. Both files must be UTF-8 encoded.
|
||||
|
||||
|
||||
============================
|
||||
2. Example findbugs.xml file
|
||||
============================
|
||||
|
||||
<DetectorPlugin>
|
||||
|
||||
<Detector class="org.foobar.findbugs.FindUnreleasedLocks" speed="slow" />
|
||||
<Detector class="org.foobar.findbugs.ExperimentalDetector" speed="fast" disabled="true" />
|
||||
|
||||
<!-- More Detector elements would go here... -->
|
||||
|
||||
<BugPattern type="UBL_UNRELEASED_LOCK" abbrev="UL" category="MT_CORRECTNESS" />
|
||||
|
||||
<!-- More BugPattern elements would go here... -->
|
||||
|
||||
</DetectorPlugin>
|
||||
|
||||
|
||||
======================================
|
||||
3. Meaning of elements in findbugs.xml
|
||||
======================================
|
||||
|
||||
<DetectorPlugin> a collection of <Detector> and <BugPattern> elements.
|
||||
Each plugin Jar file can (and usually will) provide multiple detectors
|
||||
and define multiple bug patterns.
|
||||
|
||||
<Detector> specifies a class which implements the edu.umd.cs.findbugs.Detector
|
||||
interface and has a constructor that takes a single parameter of type
|
||||
edu.umd.cs.findbugs.BugReporter. This element has three possible attributes:
|
||||
|
||||
1. The required "class" attribute specifies the Detector class.
|
||||
|
||||
2. The optional "disabled" attribute, if set to "true", means
|
||||
that by default, the detector will be disabled at runtime.
|
||||
This is useful for detectors that aren't quite ready for prime time.
|
||||
|
||||
3. The required "speed" attribute supplies a value to be shown in the
|
||||
"Settings->Configure Detectors" dialog. It gives the user an idea of
|
||||
how expensive the analysis will be to perform. The value of this
|
||||
attribute should be one of "fast", "moderate", or "slow".
|
||||
|
||||
<BugPattern> specifies a kind of bug that will be reported.
|
||||
It has three required attributes:
|
||||
|
||||
1. "type" is a unique code identifying the bug. Only one BugPattern
|
||||
can have a a particular type.
|
||||
|
||||
2. "abbrev" is a short alphanumeric code for the bug.
|
||||
Note that multiple BugPatterns can use the same abbreviation
|
||||
if they are related. (See the BugCode element in messages.xml).
|
||||
|
||||
3. "category" can be one of categories defined in the core plugin's messages.xml:
|
||||
|
||||
CORRECTNESS - code that was probably not what the developer intended
|
||||
BAD_PRACTICE - violations of recommended and essential coding practice
|
||||
STYLE - code that is confusing, anomalous, or written in a way that that leads itself to errors
|
||||
MT_CORRECTNESS - multithreaded correctness issues
|
||||
MALICIOUS_CODE - a potential vulnerability if exposed to malicious code
|
||||
PERFORMANCE - a performance issue
|
||||
I18N - internationalization and locale
|
||||
|
||||
or you may create your own category, in which case you should define
|
||||
it in a <BugCategory> element in _your_ messages.xml file.
|
||||
|
||||
============================
|
||||
4. Example messages.xml file
|
||||
============================
|
||||
|
||||
<MessageCollection>
|
||||
|
||||
<Detector class="org.foobar.findbugs.FindUnreleasedLocks" >
|
||||
<Details>
|
||||
<![CDATA[
|
||||
<p> This detector looks for JSR-166 locks that are not released on all paths
|
||||
out of a method. Because it performs dataflow analysis, it is fairly slow.
|
||||
]]>
|
||||
</Details>
|
||||
</Detector>
|
||||
|
||||
<!-- More Detector nodes would go here... -->
|
||||
|
||||
<BugPattern type="UBL_UNRELEASED_LOCK">
|
||||
<ShortDescription>Lock not released on all paths out of method</ShortDescription>
|
||||
|
||||
<LongDescription>{1} does not release lock on all paths out of method</LongDescription>
|
||||
|
||||
<Details>
|
||||
<![CDATA[
|
||||
<p> A JSR-166 lock acquired in this method is not released on all paths
|
||||
out of the method. This could result in a deadlock if another thread
|
||||
tries to acquire the lock. Generally, you should use a finally
|
||||
block to ensure that acquired locks are always released.
|
||||
]]>
|
||||
</Details>
|
||||
</BugPattern>
|
||||
|
||||
<!-- More BugPattern nodes would go here... -->
|
||||
|
||||
<BugCode abbrev="UL">Unreleased locks</BugCode>
|
||||
|
||||
<!-- More BugCode nodes would go here... -->
|
||||
|
||||
</MessageCollection>
|
||||
|
||||
|
||||
======================================
|
||||
5. Meaning of elements in messages.xml
|
||||
======================================
|
||||
|
||||
<MessageCollection> is the top level element
|
||||
|
||||
<BugCategory> elements optionally describe any categories you
|
||||
may have created for your bug patterns. You can skip these if
|
||||
you are using only the categories defined by the core plugin.
|
||||
|
||||
The <Description> child element has a brief (a word or three)
|
||||
description of the category. The <Abbreviation> child element
|
||||
is typically a single capital latter. The optional <Details>
|
||||
child element may describe it in more detail (but no markup).
|
||||
|
||||
<Detector> holds meta-information about a Detector in the plugin.
|
||||
The required "class" attribute specifies the Detector class.
|
||||
Detector elements much have the following child elements:
|
||||
|
||||
The <Details> child element has a brief HTML description of the Detector.
|
||||
It should have HTML markup that would be valid in a BODY element.
|
||||
It should be specified in a CDATA section so that the HTML
|
||||
tags are not misinterpreted as XML.
|
||||
|
||||
<BugPattern> holds all of the human-readable messages for the bug pattern
|
||||
identified by the "type" attribute. The type corresponds to the
|
||||
type attribute of the BugPattern elements described in findbugs.xml.
|
||||
BugPattern elements must have the following child elements:
|
||||
|
||||
<ShortDescription> this is used for when "View->Full Descriptions"
|
||||
is turned off in the GUI, and it's also used as the title for
|
||||
descriptions in the Details window.
|
||||
|
||||
<LongDescription> this is used for when "View->Full Descriptions"
|
||||
is turned on in the GUI, and for output using the command line UI.
|
||||
The placeholders in the long description ({0}, {1}, etc.)
|
||||
refer to BugAnnotations attached to the BugInstances reported by
|
||||
the detector for this bug pattern. You may also use constructs
|
||||
like {1.name} or {1.returnType}.
|
||||
|
||||
<Details> this is the descriptive text to be used in the Details
|
||||
window. It consists of HTML markup to appear in the BODY element of an HTML
|
||||
document. It should be specified in a CDATA section so that the HTML
|
||||
tags are not misinterpreted as XML.
|
||||
|
||||
<BugCode> is the text which describes the common characteristic of all
|
||||
of the BugPatterns which share an abbreviation. In the example above,
|
||||
the abbreviation "UL" is for bugs in which a lock is not released.
|
||||
The text of a BugCode element is shown for tree nodes in the GUI
|
||||
which group bug instances by "bug type".
|
||||
|
||||
======================================
|
||||
6. Meaning of elements in bugrank.txt
|
||||
======================================
|
||||
|
||||
For the detailed and up to date information, please read the javadoc of the
|
||||
edu.umd.cs.findbugs.BugRanker class.
|
||||
|
||||
============================================
|
||||
7. Using 3rd party libraries in the detector
|
||||
============================================
|
||||
|
||||
FindBugs plugins may extend the default FindBugs classpath and use custom 3rd party
|
||||
libraries during the analysis. This libraries must be part of standard jar class path
|
||||
specified via "ClassPath" attribute in the META-INF/MANIFEST.MF file.
|
||||
|
||||
======================================
|
||||
8. Adding detectors to Eclipse plugin
|
||||
======================================
|
||||
|
||||
Since version 2.0.0 Eclipse plugin allows to configure or contribute custom detectors.
|
||||
|
||||
7.1. It is possible to contribute custom detectors via standard Eclipse extensions mechanism.
|
||||
Please check the documentation of the "findBugsEclipsePlugin/schema/detectorPlugins.exsd"
|
||||
extension point how to update the plugin.xml. Existing FindBugs detector plugins can
|
||||
be easily "extended" to be full featured FindBugs & Eclipse detector plugins.
|
||||
Usually you only need to add META-INF/MANIFEST.MF and plugin.xml to the jar and
|
||||
update your build scripts to not to override the MANIFEST.MF during the build.
|
||||
|
||||
7.2 It is possible to configure custom detectors via Eclipse workspace preferences.
|
||||
Go to "Window->Preferences->Java->FindBugs->Misc. Settings->Custom Detectors"
|
||||
and specify there locations of any additional plugin libraries.
|
||||
|
||||
7.3 Plugins contributed via standard Eclipse extensions mechanism (see 7.1)
|
||||
may extend the default FindBugs classpath and use custom libraries during the analysis.
|
||||
This libraries must be part of standard Eclipse plugin dependencies specified via
|
||||
either "Require-Bundle" or "Bundle-ClassPath" attributes in the MANIFEST.MF file.
|
||||
In case custom detectors need access to this custom libraries at runtime, an
|
||||
extra line must be added to the MANIFEST.MF (without quotation marks):
|
||||
"Eclipse-RegisterBuddy: edu.umd.cs.findbugs.plugin.eclipse".
|
||||
|
||||
3505
findbugs/findbugs-2.0.0/doc/Changes.html
Normal file
275
findbugs/findbugs-2.0.0/doc/FAQ.html
Normal file
@@ -0,0 +1,275 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs FAQ</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css">
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td>
|
||||
<h1>FindBugs FAQ</h1>
|
||||
|
||||
<p> This document contains answers to frequently asked questions about
|
||||
<a href="index.html">FindBugs</a>. If you just want general
|
||||
information about FindBugs, have a look at the
|
||||
<a href="factSheet.html">fact sheet</a> and the
|
||||
<a href="manual/index.html">manual</a>.
|
||||
|
||||
<h2>Contents</h2>
|
||||
<ol>
|
||||
<li> <a href="#q1">I'm getting java.lang.UnsupportedClassVersionError when I try to run FindBugs</a>
|
||||
<li> <a href="#q2">When I click the "Find Bugs!" button, I get a NoSuchMethodError or VerifyError</a>
|
||||
<li> <a href="#q3">FindBugs is running out of memory, or is taking a long time to finish</a>
|
||||
<li> <a href="#q4">What is the "auxiliary classpath"? Why should I specify it?</a>
|
||||
<li> <a href="#q5">The Eclipse plugin doesn't load</a>
|
||||
<li> <a href="#q6">I'm getting a lot of false "OS" and "ODR" warnings</a>
|
||||
<li> <a href="#q7">The Eclipse plugin loads, but doesn't work correctly</a>
|
||||
<li> <a href="#q8">Where is the Maven plugin for FindBugs?</a>
|
||||
<li> <a href="#q9">Where is the NetBeans plugin for FindBugs?</a>
|
||||
</ol>
|
||||
|
||||
<h2><a name="q1">Q1: I'm getting java.lang.UnsupportedClassVersionError when I try to run FindBugs</a></h2>
|
||||
|
||||
<p> FindBugs requires JRE 1.5.0 or later to run. If you use an earlier version,
|
||||
you will see an exception error message similar to the following:
|
||||
<pre>
|
||||
Exception in thread "main" java.lang.UnsupportedClassVersionError:
|
||||
edu/umd/cs/findbugs/gui/FindBugsFrame (Unsupported major.minor version 48.0)
|
||||
</pre>
|
||||
The solution is to upgrade to JRE 1.5.0 or later.
|
||||
|
||||
<h2><a name="q2">Q2: When I click the "Find Bugs!" button, I get a NoSuchMethodError or VerifyError</a></h2>
|
||||
|
||||
<p> The symptom of this bug is that when you start the FindBugs analysis,
|
||||
you see an exception similar to the following:
|
||||
<pre>
|
||||
java.lang.NoSuchMethodError: org.apache.bcel.Repository.setRepository(Lorg/apache/bcel/util/Repository;)V
|
||||
at edu.umd.cs.findbugs.FindBugs.clearRepository(FindBugs.java:483)
|
||||
...
|
||||
</pre>
|
||||
|
||||
or
|
||||
|
||||
<pre>
|
||||
java.lang.VerifyError: Cannot inherit from final class
|
||||
at java.lang.ClassLoader.defineClass0(Native Method)
|
||||
at java.lang.ClassLoader.defineClass(ClassLoader.java:537)
|
||||
...
|
||||
</pre>
|
||||
|
||||
<p> The problem here is that the wrong version of the
|
||||
<a href="http://jakarta.apache.org/bcel/">Apache BCEL</a>
|
||||
library is being found. FindBugs requires its own
|
||||
version of BCEL, which normally will be used automatically
|
||||
when you invoke the <code>findbugs</code> or <code>findbugs.bat</code>
|
||||
scripts used to launch FindBugs. If an old version of BCEL is installed
|
||||
in a location, such as "lib/endorsed" in the JRE installation,
|
||||
where it overrides classes on the application classpath,
|
||||
FindBugs will not execute properly.
|
||||
We know of several reasons this could happen
|
||||
|
||||
<ul>
|
||||
<li> If you install the
|
||||
<a href="http://java.sun.com/webservices/downloads/webservicespack.html">Java(TM) Web Services
|
||||
Developer Pack 1.2</a>
|
||||
in the <code>lib/endorsed</code> directory of your Java Runtime Environment (JRE).
|
||||
The file <code>xsltc.jar</code> contains an old version of BCEL that is incompatible with
|
||||
FindBugs.
|
||||
|
||||
<li> Another possibility is that you are using the IBM JDK.
|
||||
Some versions include a version of BCEL which conflicts with the
|
||||
one required by FindBugs. This problem is fixed in version 1.4.1 SP1,
|
||||
so upgrading your JDK should allow FindBugs to run correctly.
|
||||
|
||||
<li> Some versions of the Apache Xalan XSLT processor include
|
||||
an old version of BCEL in <code>xalan.jar</code>.
|
||||
|
||||
</ul>
|
||||
|
||||
<p> In all of these cases, you should be able to run FindBugs
|
||||
by either removing the offending version of BCEL from your JRE,
|
||||
or installing a clean JRE or JDK and using that to run FindBugs.
|
||||
|
||||
<p> Many thanks to Peter Meulmeester, Michael Levi, and Thomas Klaeger
|
||||
for providing information on this problem.
|
||||
|
||||
<h2><a name="q3">Q3: FindBugs is running out of memory, or is taking a long time to finish</a></h2>
|
||||
|
||||
<p> In general, FindBugs requires lots of memory and a relatively
|
||||
fast CPU. For large applications, 512M or more of heap space may be
|
||||
required. By default, FindBugs allocates 256M of heap space.
|
||||
You can increase this using the <code>-maxHeap <i>n</i></code> option,
|
||||
where <i>n</i> is the number of megabytes of heap space to allocate.
|
||||
|
||||
|
||||
<h2><a name="q4">Q4: What is the "auxiliary classpath"? Why should I specify it?</a></h2>
|
||||
|
||||
<p> Many important facts about a Java class require information about
|
||||
the classes that it references. For example:
|
||||
<ul>
|
||||
<li> What other classes and interfaces the class inherits from
|
||||
<li> What exceptions can be thrown by methods in external classes
|
||||
and interfaces
|
||||
</ul>
|
||||
|
||||
<p> The "auxiliary classpath" is a list of Jar files, directories, and
|
||||
class files containing classes that are <em>used</em> by the code you
|
||||
want FindBugs to analyze, but should not themselves be analyzed
|
||||
by FindBugs.
|
||||
|
||||
<p> If FindBugs doesn't have complete information about referenced classes,
|
||||
it will not be able to produce results that are as accurate as possible.
|
||||
For example, having a complete repository of referenced classes allows
|
||||
FindBugs to prune control flow information so it can concentrate on
|
||||
paths through methods that are most likely to be feasible at runtime.
|
||||
Also, some bug detectors (such as the suspicious reference comparison detector)
|
||||
rely on being able to perform type inference, which requires complete
|
||||
type hierarchy information.
|
||||
|
||||
<p> For these reasons, we strongly recommend that you completely specify
|
||||
the auxiliary classpath when you run FindBugs. You can do this
|
||||
by using the <code>-auxclasspath</code> command line option, or the
|
||||
"Classpath entries" list in the GUI project editor dialog.
|
||||
|
||||
<p> If FindBugs cannot find a class referenced by your application, it
|
||||
will print out a message when the analysis completes, specifying the
|
||||
classes that were missing. You should modify the auxiliary classpath
|
||||
to specify how to find the missing classes, and then run FindBugs again.
|
||||
|
||||
<h2><a name="q5">Q5: The Eclipse plugin doesn't load</a></h2>
|
||||
|
||||
<p> The symptom of this problem is that Eclipse fails to load
|
||||
the FindBugs UI plugin with the message:
|
||||
<blockquote>
|
||||
Plug-in "edu.umd.cs.findbugs.plugin.eclipse" was disabled due to missing or disabled
|
||||
prerequisite plug-in "org.eclipse.ui.ide"
|
||||
</blockquote>
|
||||
|
||||
<p> The reason for this problem is that the Eclipse
|
||||
plugin distributed with FindBugs
|
||||
does not work with 2.x versions of Eclipse.
|
||||
Please use Eclipse version 3.3 (June 2007) or newer.
|
||||
|
||||
<h2><a name="q6">Q6: I'm getting a lot of false "OS" and "ODR" warnings</a></h2>
|
||||
|
||||
<p> By default, FindBugs assumes that any method invocation can
|
||||
throw an unchecked runtime exception. As a result,
|
||||
it may assume that an unchecked exception thrown out of the
|
||||
method could bypass a call to a <code>close()</code> method
|
||||
for a stream or database resource.
|
||||
|
||||
<p> You can use the <code>-workHard</code> command line argument
|
||||
or the <code>findbugs.workHard</code> boolean analysis property
|
||||
to make FindBugs work harder to prune unlikely exception
|
||||
edges. This generally reduces the number of
|
||||
false warnings, at the expense of slowing down the
|
||||
analysis.
|
||||
|
||||
<h2><a name="q7">Q7: The Eclipse plugin loads, but doesn't work correctly</a></h2>
|
||||
|
||||
<p> In versions 0.0.6 and 0.0.7 of the FindBugs Eclipse plugin,
|
||||
which correspond to the 0.7.4 and 0.8.0 releases,
|
||||
bugs in the experimental SwitchFallthrough detector can prevent
|
||||
FindBugs from running properly within Eclipse.
|
||||
|
||||
<p> To work around the problem, make sure that SwitchFallthrough
|
||||
is disabled in the FindBugs Properties of your project.
|
||||
Right click on your project, and choose "Properties".
|
||||
In the Properties dialog, choose "FindBugs",
|
||||
and disable the checkbox next to SwitchFallthrough.
|
||||
|
||||
<p> Another common problem with the Eclipse plugin is that
|
||||
the FindBugs warnings do not appear in the "Problems" view.
|
||||
Make sure that FindBugs warnings are enabled in the filters
|
||||
for this view. The Filters menu is accessible by
|
||||
clicking on the icon that looks like this:
|
||||
<blockquote>
|
||||
<img src="eclipse-filters-icon.png">
|
||||
</blockquote>
|
||||
Make sure the "FindBugs Problem" checkbox is enabled.
|
||||
|
||||
<h2><a name="q8">Q8: Where is the Maven plugin for FindBugs?</a></h2>
|
||||
|
||||
<p>
|
||||
The <a href="http://maven.apache.org/">Maven</a> Plugin for FindBugs
|
||||
may be found <a href="http://maven-plugins.sourceforge.net/maven-findbugs-plugin/index.html">here</a>.
|
||||
Please note that the Maven plugin is not maintained by the FindBugs developers,
|
||||
so we can't answer questions about it.
|
||||
</p>
|
||||
|
||||
<h2><a name="q9">Q9: Where is the NetBeans plugin for FindBugs?</a></h2>
|
||||
|
||||
<p>We recommend <a href="http://kenai.com/projects/sqe/pages/Home">SQE: Software Quality Environment</a>
|
||||
which bundles FindBugs, PMD and CheckStyle. Use the following
|
||||
update site:
|
||||
<a href="http://deadlock.netbeans.org/hudson/job/sqe/lastStableBuild/artifact/build/full-sqe-updatecenter/updates.xml
|
||||
">http://deadlock.netbeans.org/hudson/job/sqe/lastStableBuild/artifact/build/full-sqe-updatecenter/updates.xml</a>a>
|
||||
<p>Pease note that the SQE plugin is not maintained by the FindBugs developers,
|
||||
so we can't answer questions about it.
|
||||
</p>
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A>
|
||||
|
||||
</td>
|
||||
|
||||
</table>
|
||||
|
||||
</body>
|
||||
|
||||
</html>
|
||||
125
findbugs/findbugs-2.0.0/doc/FilterFile.txt
Normal file
@@ -0,0 +1,125 @@
|
||||
=============
|
||||
How it works:
|
||||
=============
|
||||
|
||||
A filter file is an XML file with a top-level "FindBugsFilter" element
|
||||
which has some number of "Match" elements as children. Each Match
|
||||
element represents a predicate which is applied to generated bug instances.
|
||||
Usually, a filter will be used to exclude bug instances. For example:
|
||||
|
||||
findbugs -textui -exclude myExcludeFilter.xml myApp.jar
|
||||
|
||||
However, a filter could also be used to select bug instances to specifically
|
||||
report:
|
||||
|
||||
findbugs -textui -include myIncludeFilter.xml myApp.jar
|
||||
|
||||
Match has "class" and "classregex" attributes specifying what class or classes
|
||||
the predicate applies to.
|
||||
|
||||
Match contains children, which are conjuncts of the predicate.
|
||||
(I.e., each of the children must be true for the predicate to be true.)
|
||||
|
||||
=======================
|
||||
Types of Match clauses:
|
||||
=======================
|
||||
|
||||
<BugCode> specifies abbreviations of bugs.
|
||||
The "name" attribute is a comma-seperated list of abbreviations.
|
||||
|
||||
<Method> specifies a method. The "name" attribute is the name
|
||||
of the method. The "params" attribute is a comma separated list
|
||||
of the types of the method's parameters. The "returns" attribute is
|
||||
the method's return type. In "params" and "returns", class names
|
||||
must be fully qualified. (E.g., "java.lang.String" instead of just
|
||||
"String".) Note that "params" and "returns" are optional; you can
|
||||
just specify "name", and the clause will match all methods with
|
||||
that name. However, if you specify either "params" or "returns",
|
||||
you must specify both of them.
|
||||
|
||||
<Or> combines Match clauses as disjuncts. I.e., you can put two
|
||||
"Method" elements in an Or clause in order match either method.
|
||||
|
||||
========
|
||||
Caveats:
|
||||
========
|
||||
|
||||
Match clauses can only match information that is actually contained in the
|
||||
bug instances. Every bug instance has a class, so in general, excluding
|
||||
bugs by class will work.
|
||||
|
||||
Some bug instances have two classes. For example, the DE (dropped exception)
|
||||
bugs report both the class containing the method where the dropped exception
|
||||
happens, and the class which represents the type of the dropped exception.
|
||||
Only the FIRST (primary) class is matched against Match clauses.
|
||||
So, for example, if you want to suppress IC (initialization circularity)
|
||||
reports for classes "com.foobar.A" and "com.foobar.B", you would use
|
||||
two Match clauses:
|
||||
|
||||
<Match class="com.foobar.A">
|
||||
<BugCode name="IC" />
|
||||
</Match>
|
||||
|
||||
<Match class="com.foobar.B">
|
||||
<BugCode name="IC" />
|
||||
</Match>
|
||||
|
||||
Many kinds of bugs report what method they occur in. For those bug instances,
|
||||
you can put Method clauses in the Match element and they should work
|
||||
as expected.
|
||||
|
||||
=========
|
||||
Examples:
|
||||
=========
|
||||
|
||||
1. Match all bug reports for a class.
|
||||
|
||||
<Match class="com.foobar.MyClass" />
|
||||
|
||||
2. Match certain tests from a class.
|
||||
<Match class="com.foobar.MyClass">
|
||||
<BugCode name="DE,UrF,SIC" />
|
||||
</Match>
|
||||
|
||||
3. Match certain tests from all classes.
|
||||
|
||||
<Match classregex=".*" >
|
||||
<BugCode name="DE,UrF,SIC" />
|
||||
</Match>
|
||||
|
||||
4. Match bug types from specified methods of a class.
|
||||
|
||||
<Match class="com.foobar.MyClass">
|
||||
<Or>
|
||||
<Method name="frob" params="int,java.lang.String" returns="void" />
|
||||
<Method name="blat" params="" returns="boolean" />
|
||||
</Or>
|
||||
<BugCode name="DC" />
|
||||
</Match>
|
||||
|
||||
=================
|
||||
Complete Example:
|
||||
=================
|
||||
|
||||
<FindBugsFilter>
|
||||
<Match class="com.foobar.ClassNotToBeAnalyzed" />
|
||||
|
||||
<Match class="com.foobar.ClassWithSomeBugsMatched">
|
||||
<BugCode name="DE,UrF,SIC" />
|
||||
</Match>
|
||||
|
||||
<!-- Match all XYZ violations. -->
|
||||
<Match classregex=".*" >
|
||||
<BugCode name="XYZ" />
|
||||
</Match>
|
||||
|
||||
<!-- Match all doublecheck violations in these methods of "AnotherClass". -->
|
||||
<Match class="com.foobar.AnotherClass">
|
||||
<Or>
|
||||
<Method name="nonOverloadedMethod" />
|
||||
<Method name="frob" params="int,java.lang.String" returns="void" />
|
||||
<Method name="blat" params="" returns="boolean" />
|
||||
</Or>
|
||||
<BugCode name="DC" />
|
||||
</Match>
|
||||
</FindBugsFilter>
|
||||
5185
findbugs/findbugs-2.0.0/doc/allBugDescriptions.html
Normal file
BIN
findbugs/findbugs-2.0.0/doc/bug-logo.png
Normal file
|
After Width: | Height: | Size: 3.8 KiB |
5182
findbugs/findbugs-2.0.0/doc/bugDescriptions.html
Normal file
BIN
findbugs/findbugs-2.0.0/doc/buggy-sm.png
Normal file
|
After Width: | Height: | Size: 9.6 KiB |
121
findbugs/findbugs-2.0.0/doc/contributing.html
Normal file
@@ -0,0 +1,121 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Contributing to FindBugs</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<h1>Contributing to FindBugs</h1>
|
||||
|
||||
<p> If you have a bug fix or feature enhancement you would like to contribute,
|
||||
we would be happy to consider it for inclusion.</p>
|
||||
|
||||
<h2>Import FindBugs code as Eclipse projects</h2>
|
||||
|
||||
<p>The preferred way to get the FindBugs source code and create the patch is to use Eclipse + SVN.
|
||||
You can easily import FindBugs code into Eclipse by following the steps described
|
||||
here: <a href="http://code.google.com/p/findbugs/source/browse/trunk/eclipsePlugin/doc/building_findbugsplugin.txt">Import Eclipse projects</a>
|
||||
.
|
||||
</p>
|
||||
|
||||
<h2>Preparing a patch</h2>
|
||||
|
||||
<p> The best way to
|
||||
send an enhancement is to create a patch against the latest code
|
||||
in the FindBugs Subversion repository
|
||||
at <a href="http://findbugs.googlecode.com/svn/trunk/">http://findbugs.googlecode.com/svn/trunk/</a>
|
||||
(those people who have been given commit priviledges should use
|
||||
<a href="https://findbugs.googlecode.com/svn/trunk/">http<b>s</b>://findbugs.googlecode.com/svn/trunk/</a>).
|
||||
</p>
|
||||
|
||||
<p>To create a patch from Eclipse, please right click the [findbugs] or [findBugsEclipsePlugin] project
|
||||
and choose [Team | Create Patch...] context menu.
|
||||
</p>
|
||||
|
||||
<p> Please follow these guidelines when preparing your patch:</p>
|
||||
<ul>
|
||||
<li> <b>Use the same indentation style as the source file(s) you
|
||||
are modifying</b>. In particular, please use tabs (not spaces)
|
||||
to indent your code; one tab per indent level.
|
||||
<li> If at all possible, avoid making whitespace modifications.
|
||||
<li> Small patches are appreciated.
|
||||
<li> If you are submitting a new bug detector, please submit a small
|
||||
standalone source file that contains an instance of the
|
||||
kind of bug the detector looks for.
|
||||
</ul>
|
||||
|
||||
<p> Following these guidelines makes it much easier for us
|
||||
to incorporate new code.
|
||||
|
||||
<h2>How to submit a patch</h2>
|
||||
|
||||
<p> Patches may be submitted through the
|
||||
<a href="http://sourceforge.net/tracker/?atid=614695&group_id=96405&func=browse">Patches</a> tracker on the
|
||||
<a href="http://sourceforge.net/projects/findbugs/">sourceforge project page</a>.
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A>
|
||||
|
||||
</td>
|
||||
|
||||
</tr></table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
BIN
findbugs/findbugs-2.0.0/doc/customers/ITAsoftware.png
Normal file
|
After Width: | Height: | Size: 2.6 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/geoLocation.png
Normal file
|
After Width: | Height: | Size: 28 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/geoMap.png
Normal file
|
After Width: | Height: | Size: 58 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/glassfish.png
Normal file
|
After Width: | Height: | Size: 2.0 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/google.png
Normal file
|
After Width: | Height: | Size: 3.4 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/logo_umd.png
Normal file
|
After Width: | Height: | Size: 2.6 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/nsf.png
Normal file
|
After Width: | Height: | Size: 5.7 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/sat4j.png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/sleepycat.png
Normal file
|
After Width: | Height: | Size: 1.8 KiB |
BIN
findbugs/findbugs-2.0.0/doc/customers/sun.png
Normal file
|
After Width: | Height: | Size: 2.3 KiB |
219
findbugs/findbugs-2.0.0/doc/demo.html
Normal file
@@ -0,0 +1,219 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs™ 1.2 Demo and Results</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css" />
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
<h1>
|
||||
FindBugs 1.2 demo and results
|
||||
</h1>
|
||||
|
||||
<p>If you just want to try running FindBugs against your
|
||||
own code, you can
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jnlp/findbugs.jnlp">run FindBugs</a> using Java Webstart.
|
||||
This will use our new gui under Java 1.5+ and our old gui under Java 1.4.
|
||||
The new gui provides a number of new features, but requires Java 1.5+.
|
||||
Both use exactly the same analysis engine.
|
||||
|
||||
</p><p>This web page provides results of running FindBugs 1.2.0
|
||||
against several open source applications. We provide a summary
|
||||
of the number of bugs we found, as well as a generated HTML listing
|
||||
of the bugs and
|
||||
a <a href="http://java.sun.com/products/javawebstart/">Java
|
||||
WebStart</a> demo of the new GUI we've introduced in FindBugs version 1.1,
|
||||
displaying the warnings and the relevant source.
|
||||
|
||||
|
||||
</p><p>The applications and versions of them we report on
|
||||
are somewhat arbitrary. In some cases, they are release versions,
|
||||
in other cases nightly builds. We find lots of bugs in every large code
|
||||
base we examine; these applications are certainly not the worst we have seen.
|
||||
I have been allowed to confidentially examine the results of running FindBugs
|
||||
against several closed commercial code bases by well respected companies;
|
||||
the results I've seen there are not significantly different from
|
||||
what I've observed in open source code bases.
|
||||
|
||||
|
||||
</p><p><em>Experimental details</em>: These results are from running
|
||||
FindBugs 1.2.0 at standard effort level. Our results do not include
|
||||
any low priority warnings or any warnings about vulnerabilities to
|
||||
malicious code. Although we have (repeatedly) manually audited the results,
|
||||
we haven't manually filtered out false positives from these warnings,
|
||||
so that you can get a feeling for the quality of the warnings generated
|
||||
by FindBugs.
|
||||
</p><p>Some of the bugs contain audit comments: they are marked as to whether
|
||||
we thought the warning indicated a bug that should or must be fixed, or whether it was not, in fact, a bug.
|
||||
</p><p>In the webstart versions, we've only included the bugs for which
|
||||
we were able to identify source files. The number of lines of non-commenting source
|
||||
statements in the table below (KNCSS) is derived from the same files
|
||||
that we analyzed and in which we report bugs; we actually compute
|
||||
KNCSS from the classfiles, not the source files.
|
||||
|
||||
</p><p><em>Vulnerability disclosure</em>: Thankfully, Java isn't C or C++. Dereferencing
|
||||
a null pointer or accessing outside the bounds of an array generates a runtime
|
||||
exception rather than a shell exploit. We do not believe that any of the
|
||||
warnings here represents a security vulnerability, although we have not audited
|
||||
them to verify that. These projects are all aware of the existence of
|
||||
FindBugs, and FindBugs is already open source and available
|
||||
for use both by developers and attackers, we don't believe that making
|
||||
these results available constitutes a reckless disclosure.
|
||||
|
||||
|
||||
</p><p><em>Recommendations</em>: First, review the correctness warnings.
|
||||
We feel confident that developers
|
||||
would want to fix most of the high and medium priority correctness warnings we report.
|
||||
Once you've reviewed those,
|
||||
you might want to look at some of the other categories.
|
||||
</p><p>
|
||||
In other categories,
|
||||
such as Bad practice and Dodgy code, we accept more false positives. You
|
||||
might decide that a pattern bug pattern isn't relevant for your code
|
||||
base (e.g., you never use Serialization for persistent storage,
|
||||
so you never care about the fact that you didn't define a serializationUID),
|
||||
and even for the bug patterns relevant to your code base,
|
||||
perhaps only a minority will reflect problems serious enough to
|
||||
convince you to change your code.
|
||||
|
||||
</p><p><em>Please be patient</em> The Web start versions not only have to download the applications,
|
||||
they need to download about 10 megabytes of data and source files. Please
|
||||
be patient. Sorry we don't have a progress bar for the data and source download;
|
||||
the ability to remotely download a data and source archive is a little bit of
|
||||
a hack. We've provided small versions of some of the data sets that include
|
||||
only the correctness bugs and the source files containing those warnings. The small
|
||||
datasets are about a quarter of the sizes of the full datasets.
|
||||
</p>
|
||||
<p>
|
||||
</p><table border="2">
|
||||
<tr><th rowspan="2">Application</th><th colspan="2">Details</th><th colspan="2">Correctness bugs</th><th rowspan="2">Bad Practice</th><th rowspan="2">Dodgy</th><th rowspan="2">KNCSS
|
||||
</th></tr><tr><th>HTML</th><th>WebStart</th><th>NP bugs</th><th>Other
|
||||
</th></tr><tr><td align="right">Sun JDK 1.7.0-b12</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jdk7/index.html">All</a>
|
||||
</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jdk7/index.jnlp">All</a>
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jdk7/small.jnlp">Small</a>
|
||||
</td><td align="right">68</td><td align="right">180</td><td align="right">954</td><td align="right">654</td><td align="right">597
|
||||
|
||||
</td></tr><tr><td align="right">eclipse-SDK-3.3M7-solaris-gtk</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/eclipse/index.html">All</a>
|
||||
</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/eclipse/index.jnlp">All</a>
|
||||
<a href="http://findbugs.cs.umd.edu/demo/eclipse/small.jnlp">Small</a>
|
||||
</td><td align="right">146</td><td align="right">259</td><td align="right">1,079</td><td align="right">643</td><td align="right">1,447
|
||||
|
||||
</td></tr><tr><td align="right">netbeans-6_0-m8</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/netbeans/index.html">All</a>
|
||||
</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/netbeans/index.jnlp">All</a>
|
||||
<a href="http://findbugs.cs.umd.edu/demo/netbeans/small.jnlp">Small</a>
|
||||
</td><td align="right">189</td><td align="right">305</td><td align="right">3,010</td><td align="right">1,112</td><td align="right">1,022
|
||||
|
||||
</td></tr><tr><td align="right">glassfish-v2-b43</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/glassfish/index.html">All</a>
|
||||
</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/glassfish/index.jnlp">All</a>
|
||||
<a href="http://findbugs.cs.umd.edu/demo/glassfish/small.jnlp">Small</a>
|
||||
</td><td align="right">146</td><td align="right">154</td><td align="right">964</td><td align="right">1,222</td><td align="right">2,176
|
||||
|
||||
</td></tr><tr><td align="right">jboss-4.0.5</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jboss/index.html">All</a>
|
||||
</td><td align="right">
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jboss/index.jnlp">All</a>
|
||||
<a href="http://findbugs.cs.umd.edu/demo/jboss/small.jnlp">Small</a>
|
||||
</td><td align="right">30</td><td align="right">57</td><td align="right">263</td><td align="right">214</td><td align="right">178
|
||||
|
||||
</td></tr></table>
|
||||
<p><em>KNCSS</em> - Thousands of lines of non-commenting source statements
|
||||
|
||||
</p><h2>Bug categories</h2>
|
||||
<dl>
|
||||
<dt>Correctness bug
|
||||
</dt><dd>Probable bug - an apparent coding mistake
|
||||
resulting in code that was probably not what the
|
||||
developer intended. We strive for a low false positive rate.
|
||||
</dd><dt>Bad Practice
|
||||
</dt><dd>
|
||||
Violations of recommended and essential
|
||||
coding practice. Examples include hash code and equals
|
||||
problems, cloneable idiom, dropped exceptions,
|
||||
serializable problems, and misuse of finalize.
|
||||
We strive to make this analysis accurate,
|
||||
although some groups may
|
||||
not care about some of the bad practices.
|
||||
</dd><dt>Dodgy
|
||||
</dt><dd>
|
||||
Code that is confusing, anomalous, or
|
||||
written in a way that leads itself to errors.
|
||||
Examples include dead local stores, switch fall through,
|
||||
unconfirmed casts, and redundant null check of value
|
||||
known to be null.
|
||||
More false positives accepted.
|
||||
In previous versions of FindBugs, this category was known as Style.
|
||||
</dl>
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A></td></tr></table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
|
||||
|
||||
|
||||
118
findbugs/findbugs-2.0.0/doc/downloads.html
Normal file
@@ -0,0 +1,118 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs Downloads</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<h1>FindBugs downloads</h1>
|
||||
|
||||
<p> This page contains links to downloads
|
||||
of Findbugs version 2.0.0,
|
||||
released on 21:17:55 EST, 20 December, 2011. Download links
|
||||
for all FindBugs versions and files
|
||||
are <a href="http://sourceforge.net/project/showfiles.php?group_id=96405">available
|
||||
on the sourceforge download page</a>.
|
||||
|
||||
<ul>
|
||||
<li>FindBugs tool (standard version with command line, ant, and Swing interfaces)
|
||||
<ul>
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0.tar.gz?download">findbugs-2.0.0.tar.gz</a>
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0.zip?download">findbugs-2.0.0.zip</a>
|
||||
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0-source.zip?download">findbugs-2.0.0-source.zip</a>
|
||||
</ul>
|
||||
<ul>
|
||||
<li>The following versions of FindBugs are pre-configured to disable <a href="updateChecking.html">checks for updated versions</a>
|
||||
of FindBugs, and
|
||||
the plugin tha allows communication with the FindBugs community cloud is disabled by default.
|
||||
Such configurations are appropriate in situations where it is important that no information about the use of FindBugs
|
||||
be disclosed outside of the organization where it is used.
|
||||
|
||||
<ul>
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/findbugs-noUpdateChecks-2.0.0.tar.gz?download">findbugs-2.0.0.tar.gz</a>
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/findbugs-noUpdateChecks-2.0.0.zip?download">findbugs-2.0.0.zip</a>
|
||||
</ul>
|
||||
|
||||
|
||||
<li>Eclipse plugin for FindBugs version 2.0.0.20111220 (requires Eclipse 3.3 or later)
|
||||
<ul>
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/edu.umd.cs.findbugs.plugin.eclipse_2.0.0.20111220.zip?download">edu.umd.cs.findbugs.plugin.eclipse_2.0.0.20111220.zip</a>
|
||||
|
||||
<li><a href="http://prdownloads.sourceforge.net/findbugs/eclipsePlugin-2.0.0.20111220-source.zip?download">eclipsePlugin-2.0.0.20111220-source.zip</a>
|
||||
</ul>
|
||||
</ul>
|
||||
|
||||
The Eclipse plugin may also be obtained from one of the FindBugs Eclipse plugin update sites:
|
||||
<ul>
|
||||
<li><a href="http://findbugs.cs.umd.edu/eclipse">http://findbugs.cs.umd.edu/eclipse</a> update site for official releases</li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/eclipse-candidate">http://findbugs.cs.umd.edu/eclipse-candidate</a> update site for candidate releases and official releases</li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/eclipse-daily">http://findbugs.cs.umd.edu/eclipse-daily</a> update site for all releases, including developmental ones</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A>
|
||||
|
||||
</td>
|
||||
|
||||
</tr></table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
BIN
findbugs/findbugs-2.0.0/doc/eclipse-filters-icon.png
Normal file
|
After Width: | Height: | Size: 416 B |
128
findbugs/findbugs-2.0.0/doc/factSheet.html
Normal file
@@ -0,0 +1,128 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs™ Fact Sheet</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<h1>FindBugs™ Fact Sheet</h1>
|
||||
|
||||
<p> FindBugs looks for bugs in Java programs. It is based
|
||||
on the concept of <i>bug patterns</i>. A bug pattern is a code
|
||||
idiom that is often an error. Bug patterns arise for a variety
|
||||
of reasons:
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li> Difficult language features
|
||||
<li> Misunderstood API methods
|
||||
<li> Misunderstood invariants when code is modified during maintenance
|
||||
<li> Garden variety mistakes: typos, use of the wrong boolean operator
|
||||
</ul>
|
||||
|
||||
<p> FindBugs uses <i>static analysis</i> to inspect Java bytecode
|
||||
for occurrences of bug patterns.
|
||||
Static analysis means that FindBugs can find bugs by simply inspecting
|
||||
a program's code: executing the program is not necessary.
|
||||
This makes FindBugs very easy to use: in general, you should be
|
||||
able to use it to look for bugs in your code within a few minutes of downloading it.
|
||||
FindBugs works by analyzing Java bytecode (compiled class files),
|
||||
so you don't even need the program's source code to use it.
|
||||
Because its analysis is
|
||||
sometimes imprecise, FindBugs can report <i>false warnings</i>,
|
||||
which are warnings that do not indicate real errors.
|
||||
In practice, the rate of false warnings reported by FindBugs
|
||||
is less than 50%.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
FindBugs supports a plugin architecture allowing anyone to add new
|
||||
bug detectors. The <a href="publications.html">publications page</a>
|
||||
contains links to articles describing how to write a new detector
|
||||
for FindBugs. If you are familiar with Java bytecode
|
||||
you can write a new FindBugs detector in as little as a few minutes.
|
||||
</p>
|
||||
|
||||
<p> FindBugs is free software, available under the terms of the
|
||||
<a href="http://www.gnu.org/copyleft/lesser.html">Lesser GNU Public License</a>.
|
||||
It is written in Java, and can be run with any virtual machine compatible
|
||||
with Sun's JDK 1.5. It can analyze programs written for any version
|
||||
of Java. FindBugs was originally developed by Bill Pugh and David Hovemeyer.
|
||||
It is maintained by Bill Pugh, and
|
||||
a <a href="team.html">team of volunteers</a>.
|
||||
</p>
|
||||
|
||||
<p> FindBugs uses <a href="http://jakarta.apache.org/bcel/">BCEL</a> to
|
||||
analyze Java bytecode.
|
||||
As of version 1.1, FindBugs also supports bug detectors written using
|
||||
the <a href="http://asm.objectweb.org/">ASM</a> bytecode framework.
|
||||
FindBugs uses <a href="http://dom4j.org/">dom4j</a>
|
||||
for XML manipulation.
|
||||
</p>
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A>
|
||||
|
||||
</td>
|
||||
|
||||
</tr></table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
15
findbugs/findbugs-2.0.0/doc/findbugs.css
Normal file
@@ -0,0 +1,15 @@
|
||||
BODY {
|
||||
background: white;
|
||||
}
|
||||
|
||||
A.plain {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
A.sidebar {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
A.sidebar:hover, A.sidebar:active {
|
||||
text-decoration: underline;
|
||||
}
|
||||
285
findbugs/findbugs-2.0.0/doc/findbugs2.html
Normal file
@@ -0,0 +1,285 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs 2™ - Find Bugs in Java Programs</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css" />
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<table width="100%">
|
||||
<tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<p></p>
|
||||
<table>
|
||||
<tr>
|
||||
<td valign="center"><a href="http://findbugs.sourceforge.net/"><img src="buggy-sm.png" alt="FindBugs logo"
|
||||
border="0" /> </a></td>
|
||||
<td valign="center"><a href="http://www.umd.edu/"><img src="informal.png"
|
||||
alt="UMD logo" border="0" /> </a></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h1>FindBugs 2</h1>
|
||||
|
||||
<p>This page describes the major changes in FindBugs 2. We are well aware that the documentation on
|
||||
the new features in FindBugs 2.0 have not kept up with the implementation. We will be working to
|
||||
improve the documentation, but don't want to hold up the release any longer to improve the
|
||||
documentation.</p>
|
||||
<p>Anyone currently using FindBugs 1.3.9 should find FindBugs 2.0 to largely be a drop-in
|
||||
replacement that offers better accuracy and performance.</p>
|
||||
|
||||
|
||||
<p>
|
||||
Also check out <a href="http://code.google.com/p/findbugs/w/list">http://code.google.com/p/findbugs/w/list</a>
|
||||
for more information about some recent features/changes in FindBugs.
|
||||
</p>
|
||||
|
||||
<p>The major new features in FindBug 2 are as follows:</p>
|
||||
<ul>
|
||||
<li>Bug Rank - bugs are given a rank 1-20, and grouped into the categories scariest (rank 1-4),
|
||||
scary (rank 5-9), troubling (rank 10-14), and of concern (rank 15-20).
|
||||
<ul>
|
||||
<li>priority renamed confidence - many people were confused by the priority reported by
|
||||
FindBugs, and considered all HIGH priority issues to be important. To reflect the
|
||||
actually meaning of this attribute of issues, it has been renamed confidence. Issues of
|
||||
different bug patterns should be compared by there rank, not their confidence.</li>
|
||||
</ul>
|
||||
|
||||
</li>
|
||||
<li><a href="#cloud">Cloud storage</a> - having a convent way for developers to share
|
||||
information about when an issue was first seen, and whether it is believed to be a serious
|
||||
problem, is important to successful and cost-effective deployment of static analysis in a large
|
||||
software project.</li>
|
||||
<li><a href="#updateChecks">update checks</a> - FindBugs will check for releases of new
|
||||
versions of FindBugs. Note: we leverage this capability to count the number of FindBugs users.
|
||||
These update checks can easily be disabled.</li>
|
||||
<li><a href="#plugins">Plugins</a> - FindBugs 2.0 makes it much easier to define plugins that
|
||||
provide various capabilities, and install these plugins either on a per user or per installation
|
||||
basis.</li>
|
||||
<li><code>fb</code> command - rather than using the rather haphazard collection of command line
|
||||
scripts developed over the years for running various FindBugs commands, you can now use just
|
||||
one: <code>fb></code>.
|
||||
<ul>
|
||||
<li><code>fb analyze</code> - invokes the FindBugs analysis</li>
|
||||
<li><code>
|
||||
fb gui/code> - launches the FindBugs GUI
|
||||
<li><code>fb list</code> - lists the issues from a FindBugs analysis file</li>
|
||||
<li><code fb help></code> - lists the command available.</li>
|
||||
</code>
|
||||
<p>
|
||||
Plugins can be used to extend the commands that can be invoked via
|
||||
<code>fb</code>
|
||||
.
|
||||
|
||||
</p></li>
|
||||
</ul></li>
|
||||
<li><a href="#newBugPatterns">New bug patterns and detectors</a>,
|
||||
and improved accuracy</li>
|
||||
<li><a href="#performance">Improved performance</a>: overall, we've seen an average 10%
|
||||
performance improvement over a large range of benchmarks, although a few users have experienced
|
||||
performance regressions we are still trying to understand.</li>
|
||||
<li id="guava">Guava support - working with Kevin Bourrillion, we have provided additional support for the
|
||||
<a href="http://code.google.com/p/guava-libraries/">Guava library</a>, recognizing many common
|
||||
misuse patterns.
|
||||
</li>
|
||||
<li id="jsr305">JSR-305 support - improved detection of problems identified by JSR-305 annotations. In
|
||||
particular, we've significantly improved both the accuracy and performance of the analysis of
|
||||
type qualifiers.</li>
|
||||
</ul>
|
||||
|
||||
<h2 id="cloud">Cloud storage of issue evaluations</h2>
|
||||
<p>For many years, you could store evaluations of FindBugs issues within the XML containing the
|
||||
analysis results. However, this approach did not work well for a team of distributed developers.
|
||||
Instead, we now provide a cloud based mechanism for storing this information. We are providing a
|
||||
free communal cloud (hostied by Google appengine) for storing evaluations of FindBugs issues. You
|
||||
can set up your own private cloud for storing issues, but at the moment this checking out a copy of
|
||||
FindBugs, making some modifications and building the cloud storage plugin from source. We hope to
|
||||
make it easier to have your own private cloud in FindBugs 2.0.1.</p>
|
||||
<p>We have analyzed several large open source projects, and provide Java web start links to allow
|
||||
you to view the results. We'd be happy to work with projects to make the results available from a
|
||||
continuous build:</p>
|
||||
<ul>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/jdk.jnlp">Sun's JDK 8</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/eclipse.jnlp">Eclipse 3.8</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/tomcat.jnlp">Apache Tomcat 7.0</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/intellij.jnlp">IntelliJ IDEA</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/jboss.jnlp">JBoss</a></li>
|
||||
</ul>
|
||||
|
||||
<h2 id="updateChecks">FindBugs update checks</h2>
|
||||
<p>
|
||||
FindBugs now checks to see if a new version of FindBugs or a plugin has been released. We make use
|
||||
of this check to collect statistics on the operating system, java version, locale and FindBugs entry
|
||||
point (e.g., ant, command line, GUI). <a href="updateChecking.html">More information is
|
||||
available</a>, including information about how to disable update checks if your organization has a
|
||||
policy against allowing the collection of such information. No information about the code being
|
||||
analyzed is reported.
|
||||
|
||||
</p>
|
||||
|
||||
<h2 id="plugins">Plugins</h2>
|
||||
<p>FindBugs 2.0 makes it much easier to customize FindBugs with plugins.</p>
|
||||
<p>FindBugs looks for plugins in two places: your personal home directory, and in FindBugs home
|
||||
(plugins installed in your home directory take precedence). In both places, it looks in two places:
|
||||
the plugin directory, which contains plugins that are enabled by default, and the optionalPlugin
|
||||
directory, which contains plugins that are disabled by default but can be enabled for a particular
|
||||
project.</p>
|
||||
<p>The FindBugs project includes several plugins:</p>
|
||||
<ul>
|
||||
<li><i>Cloud plugins</i>: These plugins provide ways to persist and share information about
|
||||
issues seen in an analysis (e.g., when was this issue first seen, and any evaluations as to
|
||||
whether this is harmless or a must fix issue, as well as comments about the issue from
|
||||
developers)
|
||||
<ul>
|
||||
<li><code>bugCollectionCloud</code> - stores issue evaluations in the XML. The way
|
||||
issue evaluations were always stored before FindBugs 2.0. Distributed in the
|
||||
optionalPlugin directory.</li>
|
||||
<li><code>findbugsCommunalCloud</code> Stores issue evaluations in the communal cloud
|
||||
hosted at findbugs.appspot.com. Distributed in the plugin directory.</li>
|
||||
<li><code>jdbcCloudClient</code> an older, deprecated cloud that stored information in
|
||||
an SQL database. Not distributed, most be built from source.</li>
|
||||
</ul></li>
|
||||
<li><code>noUpdateChecks</code> - Disables checks for updated versions and usage counting.
|
||||
Distributed in the optionalPlugin directory.</li>
|
||||
<li><code>poweruser</code> - provides a number of additional commands for the <code>fb</code>
|
||||
command. It is believed most of these commands are used by few people outside of the FindBugs
|
||||
development team. Distributed in the optionalPlugin directory.</li>
|
||||
<li><i>Bug filing plugins</i>: these plugins assist in the filing of FindBugs issues in built
|
||||
trackers. The bug filing framework is designed to be extensible to other bug filing systems. At
|
||||
the moment, these plugins are not supported, and must be built from source.
|
||||
<ul>
|
||||
<li><code>jira</code></li>
|
||||
<li><code>google code</code></li>
|
||||
</ul></li>
|
||||
</ul>
|
||||
<h2 id="performance">Performance Improvements/regressions</h2>
|
||||
<p>
|
||||
In our own testing, <a href="performance.html">we've seen an overall improvement of 9% in
|
||||
FindBugs performance from 1.3.9 to 2.0.0, with the majority of benchmarks seeing improvements</a>. A
|
||||
few users have reported significant performance regressions and we are <a href="performance.html">asking
|
||||
for more information from anyone seeing significant performance regressions</a>.
|
||||
|
||||
</p>
|
||||
<h2 id="newBugPatterns">New Bug patterns</h2>
|
||||
<ul>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#AT_OPERATION_SEQUENCE_ON_CONCURRENT_ABSTRACTION">AT_OPERATION_SEQUENCE_ON_CONCURRENT_ABSTRACTION</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#BX_UNBOXING_IMMEDIATELY_REBOXED">BX_UNBOXING_IMMEDIATELY_REBOXED</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#CO_COMPARETO_RESULTS_MIN_VALUE">CO_COMPARETO_RESULTS_MIN_VALUE</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#DLS_DEAD_LOCAL_STORE_SHADOWS_FIELD">DLS_DEAD_LOCAL_STORE_SHADOWS_FIELD</a>
|
||||
</li>
|
||||
<li><a href="http://findbugs.sourceforge.net/bugDescriptions.html#DMI_ARGUMENTS_WRONG_ORDER">DMI_ARGUMENTS_WRONG_ORDER</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#DMI_BIGDECIMAL_CONSTRUCTED_FROM_DOUBLE">DMI_BIGDECIMAL_CONSTRUCTED_FROM_DOUBLE</a>
|
||||
</li>
|
||||
<li><a href="http://findbugs.sourceforge.net/bugDescriptions.html#DMI_DOH">DMI_DOH</a></li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#DMI_ENTRY_SETS_MAY_REUSE_ENTRY_OBJECTS">DMI_ENTRY_SETS_MAY_REUSE_ENTRY_OBJECTS</a>
|
||||
</li>
|
||||
<li><a href="http://findbugs.sourceforge.net/bugDescriptions.html#DM_DEFAULT_ENCODING">DM_DEFAULT_ENCODING</a>
|
||||
</li>
|
||||
<li><a href="http://findbugs.sourceforge.net/bugDescriptions.html#ICAST_INT_2_LONG_AS_INSTANT">ICAST_INT_2_LONG_AS_INSTANT</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#INT_BAD_COMPARISON_WITH_INT_VALUE">INT_BAD_COMPARISON_WITH_INT_VALUE</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#JML_JSR166_CALLING_WAIT_RATHER_THAN_AWAIT">JML_JSR166_CALLING_WAIT_RATHER_THAN_AWAIT</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#NP_UNWRITTEN_PUBLIC_OR_PROTECTED_FIELD">NP_UNWRITTEN_PUBLIC_OR_PROTECTED_FIELD</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE">OBL_UNSATISFIED_OBLIGATION_EXCEPTION_EDGE</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#PZ_DONT_REUSE_ENTRY_OBJECTS_IN_ITERATORS">PZ_DONT_REUSE_ENTRY_OBJECTS_IN_ITERATORS</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#RV_CHECK_COMPARETO_FOR_SPECIFIC_RETURN_VALUE">RV_CHECK_COMPARETO_FOR_SPECIFIC_RETURN_VALUE</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#RV_NEGATING_RESULT_OF_COMPARETO">RV_NEGATING_RESULT_OF_COMPARETO</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#RV_RETURN_VALUE_IGNORED_INFERRED">RV_RETURN_VALUE_IGNORED_INFERRED</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#SA_LOCAL_SELF_ASSIGNMENT_INSTEAD_OF_FIELD">SA_LOCAL_SELF_ASSIGNMENT_INSTEAD_OF_FIELD</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD">URF_UNREAD_PUBLIC_OR_PROTECTED_FIELD</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#UUF_UNUSED_PUBLIC_OR_PROTECTED_FIELD">UUF_UNUSED_PUBLIC_OR_PROTECTED_FIELD</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#UWF_UNWRITTEN_PUBLIC_OR_PROTECTED_FIELD">UWF_UNWRITTEN_PUBLIC_OR_PROTECTED_FIELD</a>
|
||||
</li>
|
||||
<li><a
|
||||
href="http://findbugs.sourceforge.net/bugDescriptions.html#VA_FORMAT_STRING_USES_NEWLINE">VA_FORMAT_STRING_USES_NEWLINE</a>
|
||||
</li>
|
||||
<li><a href="http://findbugs.sourceforge.net/bugDescriptions.html#VO_VOLATILE_INCREMENT">VO_VOLATILE_INCREMENT</a>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
BIN
findbugs/findbugs-2.0.0/doc/guaranteedDereference.png
Normal file
|
After Width: | Height: | Size: 40 KiB |
311
findbugs/findbugs-2.0.0/doc/index.html
Normal file
@@ -0,0 +1,311 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs™ - Find Bugs in Java Programs</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css" />
|
||||
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
||||
<table width="100%">
|
||||
<tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<p></p>
|
||||
<table>
|
||||
<tr>
|
||||
<td valign="center"><a href="http://findbugs.sourceforge.net/"><img src="buggy-sm.png" alt="FindBugs logo"
|
||||
border="0" /> </a></td>
|
||||
<td valign="center"><a href="http://www.umd.edu/"><img src="informal.png"
|
||||
alt="UMD logo" border="0" /> </a></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h1>FindBugs™ - Find Bugs in Java Programs</h1>
|
||||
|
||||
<p>
|
||||
This is the web page for FindBugs, a program which uses static analysis to look for bugs in Java
|
||||
code. It is free software, distributed under the terms of the <a
|
||||
href="http://www.gnu.org/licenses/lgpl.html">Lesser GNU Public License</a>. The name
|
||||
FindBugs™ and the <a href="buggy-sm.png">FindBugs logo</a> are trademarked by <a
|
||||
href="http://www.umd.edu">The University of Maryland</a>. FindBugs has been downloaded more than
|
||||
a million times.
|
||||
</p>
|
||||
|
||||
<p>The current version of FindBugs is 2.0.0.</p>
|
||||
|
||||
<p>
|
||||
FindBugs requires JRE (or JDK) 1.5.0 or later to run. However, it can analyze programs
|
||||
compiled for any version of Java, from 1.0 to 1.8. The current version of FindBugs is 2.0.0,
|
||||
released on 21:17:55 EST, 20 December, 2011. <a href="reportingBugs.html">We are very interested in getting
|
||||
feedback on how to improve FindBugs</a>. File bug reports on <a
|
||||
href="http://sourceforge.net/tracker/?func=browse&group_id=96405&atid=614693"> our
|
||||
sourceforge bug tracker</a>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
<a href="#changes">Changes</a> | <a href="#talks">Talks</a> | <a href="#papers">Papers </a> | <a
|
||||
href="#sponsors">Sponsors</a> | <a href="#support">Support</a>
|
||||
</p>
|
||||
<h1>FindBugs 2.0 Release</h1>
|
||||
<p>After many delays, we have released FindBugs 2.0. We are pretty happy and confident about the
|
||||
functionality, although we know the documentation of the changes in 2.0 is lacking. We decided that
|
||||
releasing 2.0 took precedence over fixing the documentation. Anyone currently using FindBugs 1.3.9
|
||||
should find FindBugs 2.0 to largely be a drop-in replacement that offers better accuracy and
|
||||
performance.</p>
|
||||
|
||||
<p>
|
||||
Also check out <a href="http://code.google.com/p/findbugs/w/list">http://code.google.com/p/findbugs/w/list</a>
|
||||
for more information about some recent features/changes in FindBugs.
|
||||
</p>
|
||||
|
||||
|
||||
<h3>
|
||||
<a href="findbugs2.html">Major changes in FindBugs 2.0</a>
|
||||
</h3>
|
||||
<ul>
|
||||
<li><a href="findbugs2.html#cloud">FindBugs Communal cloud</a></li>
|
||||
<li><a href="findbugs2.html#updateChecks">checks for updated versions of FindBugs</a></li>
|
||||
<li><a href="findbugs2.html#plugins">Powerful plugin capabilities</a></li>
|
||||
<li><a href="findbugsw.html#newBugPatterns">new bug patterns</a>,
|
||||
including new/improved support for <a href="findbugs2.html#guava">Guava</a>
|
||||
and <a href="findbugs2.html#jsr305">JSR-305</a>
|
||||
</li>
|
||||
<li><a href="findbugs2.html#performance">improved performance</a></li>
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Ways to run FindBugs</h2>
|
||||
<p>Here are various ways to run FindBugs. For plugins not supported by the FindBugs team, check to
|
||||
see what version of FindBugs they provide; it might take a little while for the plugins to update to
|
||||
FindBugs 2.0.</p>
|
||||
<dl>
|
||||
<dt>Command line, ant, GUI</dt>
|
||||
<dd>Provided in FindBugs download</dd>
|
||||
<dt>
|
||||
<a href="http://www.eclipse.org/">Eclipse</a>
|
||||
</dt>
|
||||
<dd>
|
||||
Update site for Eclipse plugin: <a href="http://findbugs.cs.umd.edu/eclipse">http://findbugs.cs.umd.edu/eclipse</a>.
|
||||
Supported by the FindBugs project.
|
||||
</dd>
|
||||
<dt>
|
||||
<a href="http://maven.apache.org/">Maven</a>
|
||||
</dt>
|
||||
<dd>
|
||||
<a href=" <a href="http://maven-plugins.sourceforge.net/maven-findbugs-plugin/index.html">http://maven-plugins.sourceforge.net/maven-findbugs-plugin/index.html</a>
|
||||
</dd>
|
||||
<dt>
|
||||
<a href="http://netbeans.org/">Netbeans</a>
|
||||
</dt>
|
||||
<dd>
|
||||
<a href="http://kenai.com/projects/sqe/pages/Home">SQE: Software Quality Environment</a>
|
||||
</dd>
|
||||
<dt>
|
||||
<a href="http://wiki.hudson-ci.org/display/HUDSON/Home">Hudson</a>
|
||||
</dt>
|
||||
<dd>
|
||||
<a href="http://wiki.hudson-ci.org/display/HUDSON/FindBugs+Plugin">http://wiki.hudson-ci.org/display/HUDSON/FindBugs+Plugin</a>
|
||||
</dd>
|
||||
<dt>
|
||||
<a href="http://www.jetbrains.com/idea/">IntelliJ</a>
|
||||
</dt>
|
||||
<dd>
|
||||
Several plugins, see <a href="http://code.google.com/p/findbugs/wiki/IntellijFindBugsPlugins">http://code.google.com/p/findbugs/wiki/IntellijFindBugsPlugins</a>
|
||||
for a descrption.
|
||||
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
|
||||
<h1>New</h1>
|
||||
<ul>
|
||||
<li>We've released <a href="findbugs2.html">FindBugs 2.0</a>
|
||||
</li>
|
||||
<li>FindBugs communal cloud and Java web start links:. We have analyzed several large open
|
||||
source projects, and provide Java web start links to allow you to view the results. We'd be
|
||||
happy to work with projects to make the results available from a continuous build:
|
||||
<p></p>
|
||||
<ul>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/jdk.jnlp">Sun's JDK 8</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/eclipse.jnlp">Eclipse 3.8</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/tomcat.jnlp">Apache Tomcat 7.0</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/intellij.jnlp">IntelliJ IDEA</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/cloud/jboss.jnlp">JBoss</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<h1>Experience with FindBugs</h1>
|
||||
<li><b>Google FindBugs Fixit</b>: Google has a tradition of <a
|
||||
href="http://www.nytimes.com/2007/10/21/jobs/21pre.html">engineering fixits</a>, special days where
|
||||
they try to get all of their engineers focused on some specific problem or technique for improving
|
||||
the systems at Google. A fixit might work to improve web accessibility, internal testing, removing
|
||||
TODO's from internal software, etc.
|
||||
|
||||
<p>On May 13-14, Google held a global fixit for UMD's FindBugs tool a static analysis tool for
|
||||
finding coding mistakes in Java software. The focus of the fixit was to get feedback on the
|
||||
4,000 highest confidence issues found by FindBugs at Google, and let Google engineers decide
|
||||
which issues, if any, needed fixing.</p>
|
||||
<p>More than 700 engineers ran FindBugs from dozens of offices. More than 250 of them entered
|
||||
more than 8,000 reviews of the issues. A review is a classification of an issue as must-fix,
|
||||
should-fix, mostly-harmless, not-a-bug, and several other categories. More than 75% of the
|
||||
reviews classified issues as must fix, should fix or I will fix. Many of the scariest issues
|
||||
received more than 10 reviews each.</p>
|
||||
<p>Engineers have already submitted changes that made more than 1,100 of the 3,800 issues go
|
||||
away. Engineers filed more than 1,700 bug reports, of which 600 have already been marked as
|
||||
fixed Work continues on addressing the issues raised by the fixit, and on supporting the
|
||||
integration of FindBugs into the software development process at Google.</p>
|
||||
<p>The fixit at Google showcased new capabilities of FindBugs that provide a cloud computing /
|
||||
social networking backdrop. Reviews of issues are immediately persisted into a central store,
|
||||
where they can be seen by other developers, and FindBugs is integrated into the internal Google
|
||||
tools for filing and viewing bug reports and for viewing the version control history of source
|
||||
files. For the Fixit, FindBugs was configured in a mode where engineers could not see reviews
|
||||
from other engineers until they had entered their own; after the fixit, the configuration will
|
||||
be changed to a more open configuration where engineers can see reviews from others without
|
||||
having to provide their own review first. These capabilities have all been contributed to UMD's
|
||||
open source FindBugs tool, although a fair bit of engineering remains to prepare the
|
||||
capabilities for general release and make sure they can integrate into systems outside of
|
||||
Google. The new capabilities are expected to be ready for general release in Fall 2009.</p></li>
|
||||
<ul></ul>
|
||||
|
||||
<h2>
|
||||
<a name="talks">Talks about FindBugs</a>
|
||||
</h2>
|
||||
<ul>
|
||||
<p>
|
||||
<a href="http://www.cs.umd.edu/~pugh/MistakesThatMatter.pdf">Mistakes That Matter</a>, JavaOne,
|
||||
2009
|
||||
</p>
|
||||
<li><a href="http://findbugs.cs.umd.edu/talks/findbugs.mov">Quicktime movie</a> showing of demo
|
||||
of our new GUI to view some of the null pointer bugs in Eclipse (Big file warning: 23 Megabytes)</li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/talks/JavaOne2007-TS2007.pdf">JavaOne 2007 talk on
|
||||
Improving Software Quality Using Static Analysis</a></li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/talks/fb-sdbp-2006.pdf">Talk</a> Bill Pugh gave at <a
|
||||
href="http://www.sdexpo.com/2006/sdbp/">SD Best Practices</a>, Sept 14th (more of a handle on
|
||||
tutorial about using FindBugs)</li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/talks/fb-Sept1213-2006.pdf">Talk</a> Bill Pugh gave at
|
||||
<a href="http://itasoftware.com/">ITA Software</a> and <a href="http://www.csail.mit.edu/">MIT</a>,
|
||||
Sept 12th and 13th (more of a research focus)</li>
|
||||
<li><a href="http://video.google.com/videoplay?docid=-8150751070230264609">Video of talk</a>
|
||||
Bill Pugh gave at <a href="http://www.google.com">Google</a>, July 6th, 2006</li>
|
||||
<li><a href="http://javaposse.com/index.php?post_id=95780">Java Posse podcast interview
|
||||
with Bill Pugh and Brian Goetz</a></li>
|
||||
</ul>
|
||||
<h2>
|
||||
<a name="papers">Papers about FindBugs</a>
|
||||
</h2>
|
||||
<ul>
|
||||
<li><a href="http://findbugs.cs.umd.edu/papers/MoreNullPointerBugs07.pdf">Finding More Null
|
||||
Pointer Bugs, But Not Too Many</a>, by <a href="http://faculty.ycp.edu/~dhovemey/">David
|
||||
Hovemeyer</a>, York College of Pennsylvania and <a href="http://www.cs.umd.edu/~pugh/">William
|
||||
Pugh</a>, Univ. of Maryland, <a href="http://paste07.cs.washington.edu/">7th ACM
|
||||
SIGPLAN-SIGSOFT Workshop on Program Analysis for Software Tools and Engineering</a>, June, 2007</li>
|
||||
<li><a href="http://findbugs.cs.umd.edu/papers/FindBugsExperiences07.pdf">Evaluating Static
|
||||
Analysis Defect Warnings On Production Software,</a> <a href="http://www.cs.umd.edu/~nat/">Nathaniel
|
||||
Ayewah and <a href="http://www.cs.umd.edu/~pugh/">William Pugh</a>, Univ. of Maryland, and
|
||||
J. David Morgenthaler, John Penix and YuQian Zhou, Google, Inc., <a
|
||||
href="http://paste07.cs.washington.edu/">7th ACM SIGPLAN-SIGSOFT Workshop on Program
|
||||
Analysis for Software Tools and Engineering</a>, June, 2007
|
||||
</a></li>
|
||||
</ul>
|
||||
|
||||
<h1>
|
||||
<a name="sponsors">Contributors and Sponsors</a>
|
||||
</h1>
|
||||
<p>
|
||||
The <a href="team.html">current development team</a> consists of <a
|
||||
href="http://www.cs.umd.edu/~pugh">Bill Pugh</a> and <a
|
||||
href="http://andrei.gmxhome.de/privat.html">Andrey Loskutov</a>.
|
||||
</p>
|
||||
<p>Current funding for FindBugs comes from a Google Faculty Research Awards. We'd be interested in
|
||||
any offers of support or sponsorship.</p>
|
||||
<h2>
|
||||
<a name="support">Additional Support</a>
|
||||
</h2>
|
||||
<p>
|
||||
Numerous <a =href="team.html">people</a> have made significant contributions to the FindBugs
|
||||
project, including founding work by <a href="http://goose.ycp.edu/~dhovemey/">David Hovemeyer</a>
|
||||
and the web cloud infrastructure by Keith Lea.
|
||||
</p>
|
||||
<p>
|
||||
YourKit is kindly supporting open source projects with its full-featured Java Profiler. YourKit, LLC
|
||||
is creator of innovative and intelligent tools for profiling Java and .NET applications. Take a look
|
||||
at YourKit's leading software products: <a href="http://www.yourkit.com/java/profiler/index.jsp">YourKit
|
||||
Java Profiler</a> and <a href="http://www.yourkit.com/.net/profiler/index.jsp">YourKit .NET
|
||||
Profiler</a>.
|
||||
</p>
|
||||
<p>
|
||||
The FindBugs project also uses <a href="http://www.atlassian.com/software/fisheye/">FishEye</a> and
|
||||
<a href="http://www.atlassian.com/software/clover/">Clover</a>, which are generously provided by <a
|
||||
href="http://www.cenqua.com/">Cenqua/Atlassian</a>.
|
||||
</p>
|
||||
<p>
|
||||
Additional financial support for the FindBugs project was provided by <a href="http://www.nsf.gov">National
|
||||
Science Foundation</a> grants ASC9720199 and CCR-0098162,
|
||||
</p>
|
||||
<p>Any opinions, findings and conclusions or recommendations expressed in this material are those of
|
||||
the author(s) and do not necessarily reflect the views of the National Science Foundation (NSF).
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A></p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
BIN
findbugs/findbugs-2.0.0/doc/infiniteRecursiveLoops.png
Normal file
|
After Width: | Height: | Size: 31 KiB |
BIN
findbugs/findbugs-2.0.0/doc/informal.png
Normal file
|
After Width: | Height: | Size: 9.7 KiB |
123
findbugs/findbugs-2.0.0/doc/ja/manual/acknowledgments.html
Normal file
@@ -0,0 +1,123 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>第14章 謝辞</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ マニュアル"><link rel="up" href="index.html" title="FindBugs™ マニュアル"><link rel="prev" href="license.html" title="第13章 ライセンス"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">第14章 謝辞</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="license.html">戻る</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> </td></tr></table><hr></div><div class="chapter" title="第14章 謝辞"><div class="titlepage"><div><div><h2 class="title"><a name="acknowledgments"></a>第14章 謝辞</h2></div></div></div><div class="toc"><p><b>目次</b></p><dl><dt><span class="sect1"><a href="acknowledgments.html#d0e3438">1. 貢献者</a></span></dt><dt><span class="sect1"><a href="acknowledgments.html#d0e3561">2. 使用しているソフトウェア</a></span></dt></dl></div><div class="sect1" title="1. 貢献者"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3438"></a>1. 貢献者</h2></div></div></div><p><span class="application">FindBugs</span> was originally written by Bill Pugh (<code class="email"><<a class="email" href="mailto:pugh@cs.umd.edu">pugh@cs.umd.edu</a>></code>).
|
||||
David Hovemeyer (<code class="email"><<a class="email" href="mailto:daveho@cs.umd.edu">daveho@cs.umd.edu</a>></code>) implemented some of the
|
||||
detectors, added the Swing GUI, and is a co-maintainer.</p><p>Mike Fagan (<code class="email"><<a class="email" href="mailto:mfagan@tde.com">mfagan@tde.com</a>></code>) contributed the <span class="application">Ant</span> build script,
|
||||
the <span class="application">Ant</span> task, and several enhancements and bug fixes to the GUI.</p><p>Germano Leichsenring contributed Japanese translations of the bug
|
||||
summaries.</p><p>David Li contributed the Emacs bug report format.</p><p>Peter D. Stout contributed recursive detection of Class-Path
|
||||
attributes in analyzed Jar files, German translations of
|
||||
text used in the Swing GUI, and other fixes.</p><p>Peter Friese wrote the <span class="application">FindBugs</span> Eclipse plugin.</p><p>Rohan Lloyd contributed several Mac OS X enhancements,
|
||||
bug detector improvements,
|
||||
and maintains the Fink package for <span class="application">FindBugs</span>.</p><p>Hiroshi Okugawa translated the <span class="application">FindBugs</span> manual and
|
||||
more of the bug summaries into Japanese.</p><p>Phil Crosby enhanced the Eclipse plugin to add a view
|
||||
to display the bug details.</p><p>Dave Brosius fixed a number of bugs, added user preferences
|
||||
to the Swing GUI, improved several bug detectors, and
|
||||
contributed the string concatenation detector.</p><p>Thomas Klaeger contributed a number of bug fixes and
|
||||
bug detector improvements.</p><p>Andrei Loskutov made a number of improvements to the
|
||||
Eclipse plugin.</p><p>Brian Goetz contributed a major refactoring of the
|
||||
visitor classes to improve readability and understandability.</p><p> Pete Angstadt fixed several problems in the Swing GUI.</p><p>Francis Lalonde provided a task resource file for the
|
||||
FindBugs Ant task.</p><p>Garvin LeClaire contributed support for output in
|
||||
Xdocs format, for use by Maven.</p><p>Holger Stenzhorn contributed improved German translations of items
|
||||
in the Swing GUI.</p><p>Juha Knuutila contributed Finnish translations of items
|
||||
in the Swing GUI.</p><p>Tanel Lebedev contributed Estonian translations of items
|
||||
in the Swing GUI.</p><p>Hanai Shisei (ruimo) contributed full Japanese translations of
|
||||
bug messages, and text used in the Swing GUI.</p><p>David Cotton contributed Fresh translations for bug
|
||||
messages and for the Swing GUI.</p><p>Michael Tamm contributed support for the "errorProperty" attribute
|
||||
in the Ant task.</p><p>Thomas Kuehne improved the German translation of the Swing GUI.</p><p>Len Trigg improved source file support for the Emacs output mode.</p><p>Greg Bentz provided a fix for the hashcode/equals detector.</p><p>K. Hashimoto contributed internationalization fixes and several other
|
||||
bug fixes.</p><p>
|
||||
Glenn Boysko contributed support for ignoring specified local
|
||||
variables in the dead local store detector.
|
||||
</p><p>
|
||||
Jay Dunning contributed a detector to find equality comparisons
|
||||
of floating-point values, and overhauled the analysis summary
|
||||
report and its representation in the saved XML format.
|
||||
</p><p>
|
||||
Olivier Parent contributed updated French translations for bug descriptions and
|
||||
Swing GUI.
|
||||
</p><p>
|
||||
Chris Nappin contributed the <code class="filename">plain.xsl</code>
|
||||
stylesheet.
|
||||
</p><p>
|
||||
Etienne Giraudy contributed the <code class="filename">fancy.xsl</code> and <code class="filename">fancy-hist.xsl</code>
|
||||
stylesheets, and made improvements to the <span class="command"><strong>-xml:withMessages</strong></span>
|
||||
option.
|
||||
</p><p>
|
||||
Takashi Okamoto fixed bugs in the project preferences dialog
|
||||
in the Eclipse plugin, and contributed to its internationalization and localization.
|
||||
</p><p>Thomas Einwaller fixed bugs in the project preferences dialog in the Eclipse plugin.</p><p>Jeff Knox contributed support for the warningsProperty attribute
|
||||
in the Ant task.</p><p>Peter Hendriks extended the Eclipse plugin preferences,
|
||||
and fixed a bug related to renaming the Eclipse plugin ID.</p><p>Mark McKay contributed an Ant task to launch the findbugs frame.</p><p>Dieter von Holten (dvholten) contributed
|
||||
some German improvements to findbugs_de.properties.</p><p>If you have contributed to <span class="application">FindBugs</span>, but aren't mentioned above,
|
||||
please send email to <code class="email"><<a class="email" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>></code> (and also accept
|
||||
our humble apologies).</p></div><div class="sect1" title="2. 使用しているソフトウェア"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3561"></a>2. 使用しているソフトウェア</h2></div></div></div><p><span class="application">FindBugs</span> は、いくつかのオープンソースソフトウェアパッケージを使用しています。これらがなければ、 <span class="application">FindBugs</span> の開発は、より一層困難なものになったことでしょう。</p><div class="sect2" title="2.1. BCEL"><div class="titlepage"><div><div><h3 class="title"><a name="d0e3571"></a>2.1. BCEL</h3></div></div></div><p><span class="application">FindBugs</span> includes software developed by the Apache Software Foundation
|
||||
(<a class="ulink" href="http://www.apache.org/" target="_top">http://www.apache.org/</a>).
|
||||
Specifically, it uses the <a class="ulink" href="http://jakarta.apache.org/bcel/" target="_top">Byte Code
|
||||
Engineering Library</a>.</p></div><div class="sect2" title="2.2. ASM"><div class="titlepage"><div><div><h3 class="title"><a name="d0e3584"></a>2.2. ASM</h3></div></div></div><p><span class="application">FindBugs</span> uses the <a class="ulink" href="http://asm.objectweb.org/" target="_top">ASM</a>
|
||||
bytecode framework, which is distributed under the following license:</p><div class="blockquote"><blockquote class="blockquote"><p>
|
||||
Copyright (c) 2000-2005 INRIA, France Telecom
|
||||
All rights reserved.
|
||||
</p><p>
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
</p><div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem"><p>
|
||||
Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
</p></li><li class="listitem"><p>
|
||||
Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
</p></li><li class="listitem"><p>
|
||||
Neither the name of the copyright holders nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
</p></li></ol></div><p>
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
THE POSSIBILITY OF SUCH DAMAGE.
|
||||
</p></blockquote></div></div><div class="sect2" title="2.3. DOM4J"><div class="titlepage"><div><div><h3 class="title"><a name="d0e3611"></a>2.3. DOM4J</h3></div></div></div><p><span class="application">FindBugs</span> uses <a class="ulink" href="http://dom4j.org" target="_top">DOM4J</a>, which is
|
||||
distributed under the following license:</p><div class="blockquote"><blockquote class="blockquote"><p>
|
||||
Copyright 2001 (C) MetaStuff, Ltd. All Rights Reserved.
|
||||
</p><p>
|
||||
Redistribution and use of this software and associated documentation
|
||||
("Software"), with or without modification, are permitted provided that
|
||||
the following conditions are met:
|
||||
</p><div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem"><p>
|
||||
Redistributions of source code must retain copyright statements and
|
||||
notices. Redistributions must also contain a copy of this document.
|
||||
</p></li><li class="listitem"><p>
|
||||
Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
</p></li><li class="listitem"><p>
|
||||
The name "DOM4J" must not be used to endorse or promote products
|
||||
derived from this Software without prior written permission
|
||||
of MetaStuff, Ltd. For written permission, please contact
|
||||
<code class="email"><<a class="email" href="mailto:dom4j-info@metastuff.com">dom4j-info@metastuff.com</a>></code>.
|
||||
</p></li><li class="listitem"><p>
|
||||
Products derived from this Software may not be called "DOM4J" nor may
|
||||
"DOM4J" appear in their names without prior written permission of
|
||||
MetaStuff, Ltd. DOM4J is a registered trademark of MetaStuff, Ltd.
|
||||
</p></li><li class="listitem"><p>
|
||||
Due credit should be given to the DOM4J Project (<a class="ulink" href="http://dom4j.org/" target="_top">http://dom4j.org/</a>).
|
||||
</p></li></ol></div><p>
|
||||
THIS SOFTWARE IS PROVIDED BY METASTUFF, LTD. AND CONTRIBUTORS ``AS IS''
|
||||
AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL METASTUFF, LTD. OR ITS
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
</p></blockquote></div></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="license.html">戻る</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> </td></tr><tr><td width="40%" align="left" valign="top">第13章 ライセンス </td><td width="20%" align="center"><a accesskey="h" href="index.html">ホーム</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div></body></html>
|
||||
6
findbugs/findbugs-2.0.0/doc/ja/manual/analysisprops.html
Normal file
67
findbugs/findbugs-2.0.0/doc/ja/manual/annotations.html
Normal file
@@ -0,0 +1,67 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>第10章 アノテーション</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ マニュアル"><link rel="up" href="index.html" title="FindBugs™ マニュアル"><link rel="prev" href="analysisprops.html" title="第9章 分析プロパティー"><link rel="next" href="rejarForAnalysis.html" title="第11章 rejarForAnalysis の使用方法"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">第10章 アノテーション</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="analysisprops.html">戻る</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="rejarForAnalysis.html">次へ</a></td></tr></table><hr></div><div class="chapter" title="第10章 アノテーション"><div class="titlepage"><div><div><h2 class="title"><a name="annotations"></a>第10章 アノテーション</h2></div></div></div><p><span class="application">FindBugs</span> はいくつかのアノテーションをサポートしています。開発者の意図を明確にすることで、 FindBugs はより的確に警告を発行することができます。アノテーションを使用するためには Java 5 が必要であり、 annotations.jar および jsr305.jar ファイルをコンパイル時のクラスパスに含める必要があります。</p><div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.CheckForNull</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>アノテーションをつけた要素は、 null である可能性があります。したがって、当該要素を使用する際は null チェックをするべきです。このアノテーションをメソッドに適用すると、メソッドの戻り値に適用されます。</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.CheckReturnValue</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Method, Constructor
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>priority:</strong></span> 警告の優先度を指定します (HIGH, MEDIUM, LOW, IGNORE) 。デフォルト値 :MEDIUM。</p><p>
|
||||
<span class="command"><strong>explanation:</strong></span>戻り値をチェックしなけばならない理由をテキストで説明します。デフォルト値 :""。</p></dd></dl></div><p>このアノテーションを使用して、呼出し後に戻り値をチェックすべきメソッドを表すことができます。</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotation</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>アノテーションクラスのclassオブジェクト。複数のクラスを指定することができます。</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>省略時の優先度を指定します (HIGH, MEDIUM, LOW, IGNORE) 。デフォルト値 :MEDIUM。</p></dd></dl></div><p>
|
||||
Indicates that all members of the class or package should be annotated with the default
|
||||
value of the supplied annotation classes. This would be used for behavior annotations
|
||||
such as @NonNull, @CheckForNull, or @CheckReturnValue. In particular, you can use
|
||||
@DefaultAnnotation(NonNull.class) on a class or package, and then use @Nullable only
|
||||
on those parameters, methods or fields that you want to allow to be null.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotationForFields</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>アノテーションクラスのclassオブジェクト。複数のクラスを指定することができます。</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>省略時の優先度を指定します (HIGH, MEDIUM, LOW, IGNORE) 。デフォルト値 :MEDIUM。</p></dd></dl></div><p>
|
||||
This is same as the DefaultAnnotation except it only applys to fields.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotationForMethods</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>アノテーションクラスのclassオブジェクト。複数のクラスを指定することができます。</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>省略時の優先度を指定します (HIGH, MEDIUM, LOW, IGNORE) 。デフォルト値 :MEDIUM。</p></dd></dl></div><p>
|
||||
This is same as the DefaultAnnotation except it only applys to methods.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotationForParameters</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>アノテーションクラスのclassオブジェクト。複数のクラスを指定することができます。</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>省略時の優先度を指定します (HIGH, MEDIUM, LOW, IGNORE) 。デフォルト値 :MEDIUM。</p></dd></dl></div><p>
|
||||
This is same as the DefaultAnnotation except it only applys to method parameters.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.NonNull</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>アノテーションをつけた要素は、 null であってはいけません。アノテーションをつけたフィールドは、構築完了後 null であってはいけません。アノテーションをつけたメソッドは、 null ではない値を戻り値としなければなりません。</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.Nullable</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>アノテーションをつけた要素は、 null であってはいけません。In general, this means developers will have to read the documentation to determine when a null value is acceptable and whether it is neccessary to check for a null value. FindBugs will treat the annotated items as though they had no annotation.</p><p>
|
||||
In pratice this annotation is useful only for overriding an overarching NonNull
|
||||
annotation.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.OverrideMustInvoke</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Method
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>Specify when the super invocation should be
|
||||
performed (FIRST, ANYTIME, LAST). Default value:ANYTIME.
|
||||
</p></dd></dl></div><p>
|
||||
Used to annotate a method that, if overridden, must (or should) be invoke super
|
||||
in the overriding method. Examples of such methods include finalize() and clone().
|
||||
The argument to the method indicates when the super invocation should occur:
|
||||
at any time, at the beginning of the overriding method, or at the end of the overriding method.
|
||||
(This anotation is not implmemented in FindBugs as of September 8, 2006).
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.PossiblyNull</strong></span></span></dt><dd><p>
|
||||
This annotation is deprecated. Use CheckForNull instead.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.SuppressWarnings</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Field, Method, Parameter, Constructor, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>The name of the warning. More than one name can be specified.
|
||||
</p><p>
|
||||
<span class="command"><strong>justification:</strong></span>Reason why the warning should be ignored. デフォルト値 :""。</p></dd></dl></div><p>
|
||||
The set of warnings that are to be suppressed by the compiler in the annotated element.
|
||||
Duplicate names are permitted. The second and successive occurrences of a name are ignored.
|
||||
The presence of unrecognized warning names is <span class="emphasis"><em>not</em></span> an error: Compilers
|
||||
must ignore any warning names they do not recognize. They are, however, free to emit a
|
||||
warning if an annotation contains an unrecognized warning name. Compiler vendors should
|
||||
document the warning names they support in conjunction with this annotation type. They
|
||||
are encouraged to cooperate to ensure that the same names work across multiple compilers.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.UnknownNullness</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
Used to indicate that the nullness of the target is unknown, or my vary in unknown ways in subclasses.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.UnknownNullness</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
Used to indicate that the nullness of the target is unknown, or my vary in unknown ways in subclasses.
|
||||
</p></dd></dl></div><p>また、 <span class="application">FindBugs</span> 次に示すアノテーションもサポートしています。 :</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">net.jcip.annotations.GuardedBy</li><li class="listitem">net.jcip.annotations.Immutable</li><li class="listitem">net.jcip.annotations.NotThreadSafe</li><li class="listitem">net.jcip.annotations.ThreadSafe</li></ul></div><p>
|
||||
</p><p><a class="ulink" href="http://jcip.net/" target="_top">Java Concurrency in Practice</a> の <a class="ulink" href="http://jcip.net/annotations/doc/index.html" target="_top"> API ドキュメント</a> を参照してください。</p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="analysisprops.html">戻る</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="rejarForAnalysis.html">次へ</a></td></tr><tr><td width="40%" align="left" valign="top">第9章 分析プロパティー </td><td width="20%" align="center"><a accesskey="h" href="index.html">ホーム</a></td><td width="40%" align="right" valign="top"> 第11章 rejarForAnalysis の使用方法</td></tr></table></div></body></html>
|
||||
40
findbugs/findbugs-2.0.0/doc/ja/manual/anttask.html
Normal file
40
findbugs/findbugs-2.0.0/doc/ja/manual/building.html
Normal file
@@ -0,0 +1,40 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>第3章 FindBugs™ のソールからのビルド</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ マニュアル"><link rel="up" href="index.html" title="FindBugs™ マニュアル"><link rel="prev" href="installing.html" title="第2章 FindBugs™ のインストール"><link rel="next" href="running.html" title="第4章 FindBugs™ の実行"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">第3章 <span class="application">FindBugs</span>™ のソールからのビルド</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="installing.html">戻る</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="running.html">次へ</a></td></tr></table><hr></div><div class="chapter" title="第3章 FindBugs™ のソールからのビルド"><div class="titlepage"><div><div><h2 class="title"><a name="building"></a>第3章 <span class="application">FindBugs</span>™ のソールからのビルド</h2></div></div></div><div class="toc"><p><b>目次</b></p><dl><dt><span class="sect1"><a href="building.html#d0e175">1. 前提条件</a></span></dt><dt><span class="sect1"><a href="building.html#d0e258">2. ソース配布物の展開</a></span></dt><dt><span class="sect1"><a href="building.html#d0e271">3. <code class="filename">local.properties</code> の修正</a></span></dt><dt><span class="sect1"><a href="building.html#d0e326">4. <span class="application">Ant</span> の実行</a></span></dt><dt><span class="sect1"><a href="building.html#d0e420">5. ソースディレクトリーからの <span class="application">FindBugs</span>™ の実行</a></span></dt></dl></div><p>この章では、 <span class="application">FindBugs</span> をソースコードからビルドする方法を説明します。<span class="application">FindBugs</span> を修正することに興味がないのであれば、 <a class="link" href="running.html" title="第4章 FindBugs™ の実行">次の章</a> に進んでください。</p><div class="sect1" title="1. 前提条件"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e175"></a>1. 前提条件</h2></div></div></div><p>ソースから <span class="application">FindBugs</span> をコンパイルするためには、以下のものが必要です。</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p><a class="ulink" href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0-source.zip?download" target="_top"><span class="application">FindBugs</span> のソース配布物</a>
|
||||
</p></li><li class="listitem"><p>
|
||||
<a class="ulink" href="http://java.sun.com/j2se/" target="_top">JDK 1.5.0 ベータ またはそれ以降</a>
|
||||
</p></li><li class="listitem"><p>
|
||||
<a class="ulink" href="http://ant.apache.org/" target="_top">Apache <span class="application">Ant</span></a>, バージョン 1.6.3 またはそれ以降</p></li></ul></div><p>
|
||||
</p><div class="warning" title="警告" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Warning"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[警告]" src="warning.png"></td><th align="left">警告</th></tr><tr><td align="left" valign="top"><p>Redhat Linux システムの <code class="filename">/usr/bin/ant</code> に同梱されている <span class="application">Ant</span> のバージョンでは、 <span class="application">FindBugs</span> のコンパイルは<span class="emphasis"><em>うまくできません</em></span>。<a class="ulink" href="http://ant.apache.org/" target="_top"><span class="application">Ant</span> web サイト</a>からバイナリ配布物をダウンロードしてインストールすることを推奨します。<span class="application">Ant</span> を実行する場合は、 環境変数 <em class="replaceable"><code>JAVA_HOME</code></em> が JDK 1.5 (またはそれ以降)をインストールしたディレクトリーを指していることを確認してください。</p></td></tr></table></div><p>体裁の整った <span class="application">FindBugs</span> のドキュメントを生成したい場合は、以下のソフトウェアも必要となります:</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p><a class="ulink" href="http://docbook.sourceforge.net/projects/xsl/index.html" target="_top">DocBook XSL スタイルシート</a>。<span class="application">FindBugs</span> のマニュアルを HTML に変換するのに必要です。</p></li><li class="listitem"><p><a class="ulink" href="http://saxon.sourceforge.net/" target="_top"><span class="application">Saxon</span> XSLT プロセッサー</a>。(同様に、 <span class="application">FindBugs</span> のマニュアルを HTML に変換するのに必要です。)</p></li></ul></div><p>
|
||||
</p></div><div class="sect1" title="2. ソース配布物の展開"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e258"></a>2. ソース配布物の展開</h2></div></div></div><p>ソース配布物をダウンロードした後に、それを作業用ディレクトリーに展開する必要があります。通常は、次のようなコマンドで展開を行います:</p><pre class="screen">
|
||||
<code class="prompt">$ </code><span class="command"><strong>unzip findbugs-2.0.0-source.zip</strong></span>
|
||||
</pre><p>
|
||||
|
||||
</p></div><div class="sect1" title="3. local.properties の修正"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e271"></a>3. <code class="filename">local.properties</code> の修正</h2></div></div></div><p>FindBugs のドキュメントをビルドするためには、 <code class="filename">local.properties</code> ファイルを修正する必要があります。このファイルは、 <span class="application">FindBugs</span> をビルドする際に <a class="ulink" href="http://ant.apache.org/" target="_top"><span class="application">Ant</span></a> <code class="filename">build.xml</code> ファイルが参照します。FindBugs のドキュメントをビルドしない場合は、このファイルは無視してもかまいません。</p><p><code class="filename">local.properties</code> での定義は、 <code class="filename">build.properties</code> ファイルでの定義に優先します。<code class="filename">build.properties</code> は次のような内容です:</p><pre class="programlisting">
|
||||
|
||||
# User Configuration:
|
||||
# This section must be modified to reflect your system.
|
||||
|
||||
local.software.home =/export/home/daveho/linux
|
||||
|
||||
# Set this to the directory containing the DocBook Modular XSL Stylesheets
|
||||
# from http://docbook.sourceforge.net/projects/xsl/
|
||||
|
||||
xsl.stylesheet.home =${local.software.home}/docbook/docbook-xsl-1.71.1
|
||||
|
||||
# Set this to the directory where Saxon (http://saxon.sourceforge.net/)
|
||||
# is installed.
|
||||
|
||||
saxon.home =${local.software.home}/java/saxon-6.5.5
|
||||
|
||||
</pre><p>
|
||||
</p><p><code class="varname">xsl.stylesheet.home</code> プロパティーには、<a class="ulink" href="http://docbook.sourceforge.net/projects/xsl/" target="_top">DocBook Modular XSL スタイルシート</a>がインストールしてあるディレクトリーの絶対パスを指定します。<span class="application">FindBugs</span> ドキュメントを生成しようと考えている場合にのみ、このプロパティーを指定する必要があります。</p><p><code class="varname">saxon.home</code> プロパティーには、<a class="ulink" href="http://saxon.sourceforge.net/" target="_top"><span class="application">Saxon</span> XSLT プロセッサー</a>がインストールしてあるディレクトリーの絶対パスを指定します。<span class="application">FindBugs</span> ドキュメントを生成しようと考えている場合にのみ、このプロパティーを指定する必要があります。</p></div><div class="sect1" title="4. Ant の実行"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e326"></a>4. <span class="application">Ant</span> の実行</h2></div></div></div><p>ソース配布物の展開、 <span class="application">Ant</span> のインストール、<code class="filename">build.properties</code>(<code class="filename">local.properties</code>) の修正 (これは任意) およびツール (<span class="application">Saxon</span> など)の環境構築ができれば、 <span class="application">FindBugs</span> をビルドするための準備は完了です。<span class="application">Ant</span> の起動する方法は、単にコマンドを実行するだけです。</p><pre class="screen">
|
||||
<code class="prompt">$ </code><span class="command"><strong>ant <em class="replaceable"><code>target</code></em></strong></span>
|
||||
</pre><p><em class="replaceable"><code>target</code></em> には以下のいずれかを指定します: </p><div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>build</strong></span></span></dt><dd><p>このターゲットは、 <span class="application">FindBugs</span> のコードをコンパイルします。これは、デフォルトのターゲットです。</p></dd><dt><span class="term"><span class="command"><strong>docs</strong></span></span></dt><dd><p>このターゲットは、ドキュメントの整形を行います(また、副作用としていくつかのソースのコンパイルも行います。)</p></dd><dt><span class="term"><span class="command"><strong>runjunit</strong></span></span></dt><dd><p>このターゲットは、コンパイルを行い <span class="application">FindBugs</span> が持っている JUnit テストを実行します。ユニットテストが失敗した場合は、エラーメッセージが表示されます。</p></dd><dt><span class="term"><span class="command"><strong>bindist</strong></span></span></dt><dd><p><span class="application">FindBugs</span> のバイナリ配布物を構築します。このターゲットは、 <code class="filename">.zip</code> および <code class="filename">.tar.gz</code> のアーカイブをそれぞれ作成します。</p></dd></dl></div><p>
|
||||
</p><p><span class="application">Ant</span> コマンドの実行後、次のような出力が表示されるはずです。 (この前に <span class="application">Ant</span> が実行したタスクに関するメッセージもいくらか出力されます。):</p><pre class="screen">
|
||||
<code class="computeroutput">
|
||||
BUILD SUCCESSFUL
|
||||
Total time: 17 seconds
|
||||
</code>
|
||||
</pre><p>
|
||||
</p></div><div class="sect1" title="5. ソースディレクトリーからの FindBugs™ の実行"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e420"></a>5. ソースディレクトリーからの <span class="application">FindBugs</span>™ の実行</h2></div></div></div><p><span class="command"><strong>build</strong></span> ターゲットの実行が終了すると、バイナリ配布物と同様の状態が作業ディレクトリーに構築されるように <span class="application">FindBugs</span> の<span class="application">Ant</span> ビルドスクリプトは記述されています。したがって、<a class="xref" href="running.html" title="第4章 FindBugs™ の実行">4章<i><span class="application">FindBugs</span>™ の実行</i></a> の <span class="application">FindBugs</span> の実行に関する情報はソース配布物の場合にも応用できます。</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="installing.html">戻る</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="running.html">次へ</a></td></tr><tr><td width="40%" align="left" valign="top">第2章 <span class="application">FindBugs</span>™ のインストール </td><td width="20%" align="center"><a accesskey="h" href="index.html">ホーム</a></td><td width="40%" align="right" valign="top"> 第4章 <span class="application">FindBugs</span>™ の実行</td></tr></table></div></body></html>
|
||||
280
findbugs/findbugs-2.0.0/doc/ja/manual/datamining.html
Normal file
3
findbugs/findbugs-2.0.0/doc/ja/manual/eclipse.html
Normal file
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/example-code.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/example-details.png
Normal file
|
After Width: | Height: | Size: 52 KiB |
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/example.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
168
findbugs/findbugs-2.0.0/doc/ja/manual/filter.html
Normal file
5
findbugs/findbugs-2.0.0/doc/ja/manual/gui.html
Normal file
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/important.png
Normal file
|
After Width: | Height: | Size: 722 B |
3
findbugs/findbugs-2.0.0/doc/ja/manual/index.html
Normal file
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/infiniteRecursiveLoops.png
Normal file
|
After Width: | Height: | Size: 24 KiB |
9
findbugs/findbugs-2.0.0/doc/ja/manual/installing.html
Normal file
@@ -0,0 +1,9 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>第2章 FindBugs™ のインストール</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ マニュアル"><link rel="up" href="index.html" title="FindBugs™ マニュアル"><link rel="prev" href="introduction.html" title="第1章 はじめに"><link rel="next" href="building.html" title="第3章 FindBugs™ のソールからのビルド"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">第2章 <span class="application">FindBugs</span>™ のインストール</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="introduction.html">戻る</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="building.html">次へ</a></td></tr></table><hr></div><div class="chapter" title="第2章 FindBugs™ のインストール"><div class="titlepage"><div><div><h2 class="title"><a name="installing"></a>第2章 <span class="application">FindBugs</span>™ のインストール</h2></div></div></div><div class="toc"><p><b>目次</b></p><dl><dt><span class="sect1"><a href="installing.html#d0e102">1. 配布物の展開</a></span></dt></dl></div><p>この章では、 <span class="application">FindBugs</span> のインストール方法を説明します。</p><div class="sect1" title="1. 配布物の展開"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e102"></a>1. 配布物の展開</h2></div></div></div><p><span class="application">FindBugs</span> をインストールする最も簡単な方法は、バイナリ配布物をダウンロードすることです。 バイナリ配布物は、 <a class="ulink" href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0.tar.gz?download" target="_top">gzipped tar 形式</a> および <a class="ulink" href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0.zip?download" target="_top">zip 形式</a> がそれぞれ入手可能です。バイナリ配布物をダウンロードしてきたら、それを任意のディレクトリーに展開します。</p><p>gzipped tar 形式配布物の展開方法例:</p><pre class="screen">
|
||||
<code class="prompt">$ </code><span class="command"><strong>gunzip -c findbugs-2.0.0.tar.gz | tar xvf -</strong></span>
|
||||
</pre><p>
|
||||
</p><p>zip 形式配布物の展開方法例:</p><pre class="screen">
|
||||
<code class="prompt">C:\Software></code><span class="command"><strong>unzip findbugs-2.0.0.zip</strong></span>
|
||||
</pre><p>
|
||||
</p><p>バイナリ配布物の展開すると、通常は <code class="filename">findbugs-2.0.0</code> ディレクトリーが作成されます。例えば、ディレクトリー <code class="filename">C:\Software</code> でバイナリ配布物を展開すると、ディレクトリー <code class="filename">C:\Software\findbugs-2.0.0</code> に <span class="application">FindBugs</span> は展開されます。このディレクトリーが <span class="application">FindBugs</span> のホームディレクトリーになります。このマニュアルでは、このホームディレクトリーを <em class="replaceable"><code>$FINDBUGS_HOME</code></em> (Windowsでは <em class="replaceable"><code>%FINDBUGS_HOME%</code></em>) を用いて参照します。</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="introduction.html">戻る</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="building.html">次へ</a></td></tr><tr><td width="40%" align="left" valign="top">第1章 はじめに </td><td width="20%" align="center"><a accesskey="h" href="index.html">ホーム</a></td><td width="40%" align="right" valign="top"> 第3章 <span class="application">FindBugs</span>™ のソールからのビルド</td></tr></table></div></body></html>
|
||||
3
findbugs/findbugs-2.0.0/doc/ja/manual/introduction.html
Normal file
3
findbugs/findbugs-2.0.0/doc/ja/manual/license.html
Normal file
@@ -0,0 +1,3 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>第13章 ライセンス</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ マニュアル"><link rel="up" href="index.html" title="FindBugs™ マニュアル"><link rel="prev" href="datamining.html" title="第12章 FindBugs™ によるデータ・マイニング"><link rel="next" href="acknowledgments.html" title="第14章 謝辞"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">第13章 ライセンス</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="datamining.html">戻る</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="acknowledgments.html">次へ</a></td></tr></table><hr></div><div class="chapter" title="第13章 ライセンス"><div class="titlepage"><div><div><h2 class="title"><a name="license"></a>第13章 ライセンス</h2></div></div></div><p>名称「FindBugs」および FindBugs のロゴは、メリーランド大学の登録商標です。FindBugs はフリーソフトウェアであり、 <a class="ulink" href="http://www.gnu.org/licenses/lgpl.html" target="_top">Lesser GNU Public License</a> の条件で配布されています。使用承諾書を入手したい場合は、 <span class="application">FindBugs</span> 配布物に含まれる <code class="filename">LICENSE.txt</code> ファイルを参照してください。</p><p>最新バージョンの FindBugs および そのソースコードは <a class="ulink" href="http://findbugs.sourceforge.net" target="_top">FindBugs web ページ</a> で入手できます。</p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="datamining.html">戻る</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="acknowledgments.html">次へ</a></td></tr><tr><td width="40%" align="left" valign="top">第12章 <span class="application">FindBugs</span>™ によるデータ・マイニング </td><td width="20%" align="center"><a accesskey="h" href="index.html">ホーム</a></td><td width="40%" align="right" valign="top"> 第14章 謝辞</td></tr></table></div></body></html>
|
||||
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/note.png
Normal file
|
After Width: | Height: | Size: 490 B |
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/project-dialog.png
Normal file
|
After Width: | Height: | Size: 12 KiB |
22
findbugs/findbugs-2.0.0/doc/ja/manual/running.html
Normal file
BIN
findbugs/findbugs-2.0.0/doc/ja/manual/warning.png
Normal file
|
After Width: | Height: | Size: 1.2 KiB |
126
findbugs/findbugs-2.0.0/doc/links.html
Normal file
@@ -0,0 +1,126 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs Links</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<h1>FindBugs Links</h1>
|
||||
|
||||
<p> This page contains links to related projects,
|
||||
including tools that are similar to FindBugs.
|
||||
|
||||
<h2>FindBugs Add-Ons</h2>
|
||||
|
||||
<ul>
|
||||
<li> <a href="http://fb-contrib.sourceforge.net/">fb-contrib</a>: additional bug detectors for use with
|
||||
FindBugs. The lead FindBugs team does not vouch for the relevance, accuracy or wisdom of the warnings
|
||||
generated by any third-party plugin.
|
||||
<li> <a href="http://www.tobject.de/development/findbugs.html">FindBugs Eclipse plugin</a>.
|
||||
This is now included as part of FindBugs.
|
||||
<li> <a href="http://maven-plugins.sourceforge.net/maven-findbugs-plugin/index.html">Maven FindBugs plugin</a>.
|
||||
Maven is a Java project management and project comprehension tool.
|
||||
The Maven FindBugs plugin allows FindBugs reports to be generated
|
||||
from within Maven.
|
||||
<li> <a href="http://mojo.codehaus.org/findbugs-maven-plugin/">Maven2 FindBugs plugin</a>.
|
||||
Maven2 is the latest version of the Java project management and project comprehension tool.
|
||||
The Maven2 FindBugs plugin allows FindBugs reports to be generated
|
||||
from within Maven.
|
||||
<li> <a href="http://qalab.sourceforge.net/">QALab</a> records and aggregates
|
||||
the results of static analysis (including FindBugs results)
|
||||
over time. Features include charts of warnings over time
|
||||
and summary reports showing hot spots in the source code.</li>
|
||||
</ul>
|
||||
|
||||
<h2>Similar Tools</h2>
|
||||
|
||||
<h3>Open source tools</h3>
|
||||
|
||||
<ul>
|
||||
<li> <a href="http://artho.com/jlint/index.shtml">JLint</a>. A static analysis tool
|
||||
to find race conditions, locking errors, null pointer uses,
|
||||
and a number of other problems in Java programs.
|
||||
<li> <a href="http://pmd.sourceforge.net/">PMD</a>. PMD scans Java
|
||||
source code for potential problems.
|
||||
<li> <a href="http://checkstyle.sourceforge.net/">Checkstyle</a>.
|
||||
Checkstyle is a style checker for Java.
|
||||
</ul>
|
||||
|
||||
<h3>Commercial tools and services</h3>
|
||||
|
||||
<ul>
|
||||
<li> <a href="http://www.jutils.com">lint4j</a>: lint tool for Java programs
|
||||
<li> <a href="http://www.parasoft.com/">JTest</a>: automatically generates
|
||||
<a href="http://junit.org/">JUnit</a> tests for Java classes.
|
||||
Also checks for many kinds of coding errors.
|
||||
<li> <a href="http://www.sureshotsoftware.com/javalint/">JiveLint</a>. Another
|
||||
lint utility for Java programs. Finds hashcode/equals problems,
|
||||
string reference comparisons, and more. Free 15 day demo.
|
||||
</ul>
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A>
|
||||
|
||||
</td>
|
||||
|
||||
</tr></table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
85
findbugs/findbugs-2.0.0/doc/mailingLists.html
Normal file
@@ -0,0 +1,85 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>FindBugs Mailing Lists</title>
|
||||
<link rel="stylesheet" type="text/css" href="findbugs.css">
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<table width="100%"><tr>
|
||||
|
||||
|
||||
<td bgcolor="#b9b9fe" valign="top" align="left" width="20%">
|
||||
<table width="100%" cellspacing="0" border="0">
|
||||
<tr><td><a class="sidebar" href="index.html"><img src="umdFindbugs.png" alt="FindBugs"></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Docs and Info</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="findbugs2.html">FindBugs 2.0</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="demo.html">Demo and data</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="users.html">Users and supporters</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://findbugs.blogspot.com/">FindBugs blog</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="factSheet.html">Fact sheet</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="manual/index.html">Manual</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="ja/manual/index.html">Manual(ja/日本語)</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="FAQ.html">FAQ</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="bugDescriptions.html">Bug descriptions</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="mailingLists.html">Mailing lists</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="publications.html">Documents and Publications</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="links.html">Links</a></font></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="downloads.html"><b>Downloads</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><a class="sidebar" href="http://www.cafeshops.com/findbugs"><b>FindBugs Swag</b></a></td></tr>
|
||||
|
||||
<tr><td> </td></tr>
|
||||
|
||||
<tr><td><b>Development</b></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/tracker/?group_id=96405">Open bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="reportingBugs.html">Reporting bugs</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="contributing.html">Contributing</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="team.html">Dev team</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="api/index.html">API</a> <a class="sidebar" href="api/overview-summary.html">[no frames]</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="Changes.html">Change log</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://sourceforge.net/projects/findbugs">SF project page</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/browse/">Browse source</a></font></td></tr>
|
||||
<tr><td><font size="-1"><a class="sidebar" href="http://code.google.com/p/findbugs/source/list">Latest code changes</a></font></td></tr>
|
||||
</table>
|
||||
</td>
|
||||
|
||||
<td align="left" valign="top">
|
||||
|
||||
<h1>FindBugs Mailing Lists</h1>
|
||||
|
||||
<p> There are two mailing lists for FindBugs.
|
||||
<ul>
|
||||
<li> <a href="http://www.cs.umd.edu/mailman/listinfo/findbugs-announce">Findbugs-announce</a>
|
||||
is a low volume (moderated) list for announcements of new releases.
|
||||
</li><li> <a href="http://www.cs.umd.edu/mailman/listinfo/findbugs-discuss">Findbugs-discuss</a>
|
||||
is for discussion of planned features, bugs, development issues, etc. Note
|
||||
that you must be a subscriber in order to post messages to the list.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
<hr> <p>
|
||||
<script language="JavaScript" type="text/javascript">
|
||||
<!---//hide script from old browsers
|
||||
document.write( "Last updated "+ document.lastModified + "." );
|
||||
//end hiding contents --->
|
||||
</script>
|
||||
<p> Send comments to <a class="sidebar" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>
|
||||
<p>
|
||||
<A href="http://sourceforge.net"><IMG src="http://sourceforge.net/sflogo.php?group_id=96405&type=5" width="210" height="62" border="0" alt="SourceForge.net Logo" /></A>
|
||||
|
||||
</td>
|
||||
|
||||
</tr></table>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
30
findbugs/findbugs-2.0.0/doc/manual-fo.xsl
Normal file
@@ -0,0 +1,30 @@
|
||||
<?xml version='1.0'?>
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
version='1.0'
|
||||
xmlns="http://www.w3.org/TR/xhtml1/transitional"
|
||||
exclude-result-prefixes="#default">
|
||||
|
||||
<!-- build.xml will substitute the real path to fo/docbook.xsl here. -->
|
||||
<xsl:import href="/Users/pugh/tools/docbook-xsl-1.76.1/fo/docbook.xsl"/>
|
||||
|
||||
<!-- Enumerate sections. -->
|
||||
<xsl:variable name="section.autolabel">1</xsl:variable>
|
||||
|
||||
<!-- Use graphics in admonitions -->
|
||||
<xsl:variable name="admon.graphics">1</xsl:variable>
|
||||
|
||||
<!-- Admonition graphics are in the "manual" subdirectory. -->
|
||||
<xsl:variable name="admon.graphics.path">manual/</xsl:variable>
|
||||
|
||||
<!-- Included graphics are also in the "manual" subdirectory. -->
|
||||
<xsl:variable name="img.src.path">manual/</xsl:variable>
|
||||
|
||||
<!-- Default image width is 5 inches - otherwise, they become much too large.
|
||||
FIXME: for some reason, this isn't honored. Blech.
|
||||
-->
|
||||
<xsl:variable name="default.image.width">5in</xsl:variable>
|
||||
|
||||
<!-- Just put chapters and sect1s in the TOC. -->
|
||||
<xsl:variable name="toc.section.depth">1</xsl:variable>
|
||||
|
||||
</xsl:stylesheet>
|
||||
3940
findbugs/findbugs-2.0.0/doc/manual.xml
Normal file
36
findbugs/findbugs-2.0.0/doc/manual.xsl
Normal file
@@ -0,0 +1,36 @@
|
||||
<?xml version='1.0'?>
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
|
||||
version='1.0'
|
||||
xmlns="http://www.w3.org/TR/xhtml1/transitional"
|
||||
exclude-result-prefixes="#default">
|
||||
|
||||
<!-- build.xml will substitute the real path to chunk.xsl here. -->
|
||||
<xsl:import href="/Users/pugh/tools/docbook-xsl-1.76.1/html/chunk.xsl"/>
|
||||
|
||||
<xsl:template name="user.header.content">
|
||||
|
||||
</xsl:template>
|
||||
|
||||
<!-- This causes the stylesheet to put chapters in a single HTML file,
|
||||
rather than putting individual sections into separate files. -->
|
||||
<xsl:variable name="chunk.section.depth">0</xsl:variable>
|
||||
|
||||
<!-- Put the HTML in the "manual" directory. -->
|
||||
<xsl:variable name="base.dir">manual/</xsl:variable>
|
||||
|
||||
<!-- Enumerate sections. -->
|
||||
<xsl:variable name="section.autolabel">1</xsl:variable>
|
||||
|
||||
<!-- Name the HTML files based on the id of the document elements. -->
|
||||
<xsl:variable name="use.id.as.filename">1</xsl:variable>
|
||||
|
||||
<!-- Use graphics in admonitions -->
|
||||
<xsl:variable name="admon.graphics">1</xsl:variable>
|
||||
|
||||
<!-- Admonition graphics are in the same place as the generated HTML. -->
|
||||
<xsl:variable name="admon.graphics.path"></xsl:variable>
|
||||
|
||||
<!-- Just put chapters and sect1s in the TOC. -->
|
||||
<xsl:variable name="toc.section.depth">1</xsl:variable>
|
||||
|
||||
</xsl:stylesheet>
|
||||
124
findbugs/findbugs-2.0.0/doc/manual/acknowledgments.html
Normal file
@@ -0,0 +1,124 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 14. Acknowledgments</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="license.html" title="Chapter 13. License"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 14. Acknowledgments</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="license.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> </td></tr></table><hr></div><div class="chapter" title="Chapter 14. Acknowledgments"><div class="titlepage"><div><div><h2 class="title"><a name="acknowledgments"></a>Chapter 14. Acknowledgments</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="acknowledgments.html#d0e3576">1. Contributors</a></span></dt><dt><span class="sect1"><a href="acknowledgments.html#d0e3699">2. Software Used</a></span></dt></dl></div><div class="sect1" title="1. Contributors"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3576"></a>1. Contributors</h2></div></div></div><p><span class="application">FindBugs</span> was originally written by Bill Pugh (<code class="email"><<a class="email" href="mailto:pugh@cs.umd.edu">pugh@cs.umd.edu</a>></code>).
|
||||
David Hovemeyer (<code class="email"><<a class="email" href="mailto:daveho@cs.umd.edu">daveho@cs.umd.edu</a>></code>) implemented some of the
|
||||
detectors, added the Swing GUI, and is a co-maintainer.</p><p>Mike Fagan (<code class="email"><<a class="email" href="mailto:mfagan@tde.com">mfagan@tde.com</a>></code>) contributed the <span class="application">Ant</span> build script,
|
||||
the <span class="application">Ant</span> task, and several enhancements and bug fixes to the GUI.</p><p>Germano Leichsenring contributed Japanese translations of the bug
|
||||
summaries.</p><p>David Li contributed the Emacs bug report format.</p><p>Peter D. Stout contributed recursive detection of Class-Path
|
||||
attributes in analyzed Jar files, German translations of
|
||||
text used in the Swing GUI, and other fixes.</p><p>Peter Friese wrote the <span class="application">FindBugs</span> Eclipse plugin.</p><p>Rohan Lloyd contributed several Mac OS X enhancements,
|
||||
bug detector improvements,
|
||||
and maintains the Fink package for <span class="application">FindBugs</span>.</p><p>Hiroshi Okugawa translated the <span class="application">FindBugs</span> manual and
|
||||
more of the bug summaries into Japanese.</p><p>Phil Crosby enhanced the Eclipse plugin to add a view
|
||||
to display the bug details.</p><p>Dave Brosius fixed a number of bugs, added user preferences
|
||||
to the Swing GUI, improved several bug detectors, and
|
||||
contributed the string concatenation detector.</p><p>Thomas Klaeger contributed a number of bug fixes and
|
||||
bug detector improvements.</p><p>Andrei Loskutov made a number of improvements to the
|
||||
Eclipse plugin.</p><p>Brian Goetz contributed a major refactoring of the
|
||||
visitor classes to improve readability and understandability.</p><p> Pete Angstadt fixed several problems in the Swing GUI.</p><p>Francis Lalonde provided a task resource file for the
|
||||
FindBugs Ant task.</p><p>Garvin LeClaire contributed support for output in
|
||||
Xdocs format, for use by Maven.</p><p>Holger Stenzhorn contributed improved German translations of items
|
||||
in the Swing GUI.</p><p>Juha Knuutila contributed Finnish translations of items
|
||||
in the Swing GUI.</p><p>Tanel Lebedev contributed Estonian translations of items
|
||||
in the Swing GUI.</p><p>Hanai Shisei (ruimo) contributed full Japanese translations of
|
||||
bug messages, and text used in the Swing GUI.</p><p>David Cotton contributed Fresh translations for bug
|
||||
messages and for the Swing GUI.</p><p>Michael Tamm contributed support for the "errorProperty" attribute
|
||||
in the Ant task.</p><p>Thomas Kuehne improved the German translation of the Swing GUI.</p><p>Len Trigg improved source file support for the Emacs output mode.</p><p>Greg Bentz provided a fix for the hashcode/equals detector.</p><p>K. Hashimoto contributed internationalization fixes and several other
|
||||
bug fixes.</p><p>
|
||||
Glenn Boysko contributed support for ignoring specified local
|
||||
variables in the dead local store detector.
|
||||
</p><p>
|
||||
Jay Dunning contributed a detector to find equality comparisons
|
||||
of floating-point values, and overhauled the analysis summary
|
||||
report and its representation in the saved XML format.
|
||||
</p><p>
|
||||
Olivier Parent contributed updated French translations for bug descriptions and
|
||||
Swing GUI.
|
||||
</p><p>
|
||||
Chris Nappin contributed the <code class="filename">plain.xsl</code>
|
||||
stylesheet.
|
||||
</p><p>
|
||||
Etienne Giraudy contributed the <code class="filename">fancy.xsl</code> and <code class="filename">fancy-hist.xsl</code>
|
||||
stylesheets, and made improvements to the <span class="command"><strong>-xml:withMessages</strong></span>
|
||||
option.
|
||||
</p><p>
|
||||
Takashi Okamoto fixed bugs in the project preferences dialog
|
||||
in the Eclipse plugin, and contributed to its internationalization and localization.
|
||||
</p><p>Thomas Einwaller fixed bugs in the project preferences dialog in the Eclipse plugin.</p><p>Jeff Knox contributed support for the warningsProperty attribute
|
||||
in the Ant task.</p><p>Peter Hendriks extended the Eclipse plugin preferences,
|
||||
and fixed a bug related to renaming the Eclipse plugin ID.</p><p>Mark McKay contributed an Ant task to launch the findbugs frame.</p><p>Dieter von Holten (dvholten) contributed
|
||||
some German improvements to findbugs_de.properties.</p><p>If you have contributed to <span class="application">FindBugs</span>, but aren't mentioned above,
|
||||
please send email to <code class="email"><<a class="email" href="mailto:findbugs@cs.umd.edu">findbugs@cs.umd.edu</a>></code> (and also accept
|
||||
our humble apologies).</p></div><div class="sect1" title="2. Software Used"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e3699"></a>2. Software Used</h2></div></div></div><p><span class="application">FindBugs</span> uses several open-source software packages, without which its
|
||||
development would have been much more difficult.</p><div class="sect2" title="2.1. BCEL"><div class="titlepage"><div><div><h3 class="title"><a name="d0e3706"></a>2.1. BCEL</h3></div></div></div><p><span class="application">FindBugs</span> includes software developed by the Apache Software Foundation
|
||||
(<a class="ulink" href="http://www.apache.org/" target="_top">http://www.apache.org/</a>).
|
||||
Specifically, it uses the <a class="ulink" href="http://jakarta.apache.org/bcel/" target="_top">Byte Code
|
||||
Engineering Library</a>.</p></div><div class="sect2" title="2.2. ASM"><div class="titlepage"><div><div><h3 class="title"><a name="d0e3719"></a>2.2. ASM</h3></div></div></div><p><span class="application">FindBugs</span> uses the <a class="ulink" href="http://asm.objectweb.org/" target="_top">ASM</a>
|
||||
bytecode framework, which is distributed under the following license:</p><div class="blockquote"><blockquote class="blockquote"><p>
|
||||
Copyright (c) 2000-2005 INRIA, France Telecom
|
||||
All rights reserved.
|
||||
</p><p>
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions
|
||||
are met:
|
||||
</p><div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem"><p>
|
||||
Redistributions of source code must retain the above copyright
|
||||
notice, this list of conditions and the following disclaimer.
|
||||
</p></li><li class="listitem"><p>
|
||||
Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
</p></li><li class="listitem"><p>
|
||||
Neither the name of the copyright holders nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
</p></li></ol></div><p>
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||
THE POSSIBILITY OF SUCH DAMAGE.
|
||||
</p></blockquote></div></div><div class="sect2" title="2.3. DOM4J"><div class="titlepage"><div><div><h3 class="title"><a name="d0e3746"></a>2.3. DOM4J</h3></div></div></div><p><span class="application">FindBugs</span> uses <a class="ulink" href="http://dom4j.org" target="_top">DOM4J</a>, which is
|
||||
distributed under the following license:</p><div class="blockquote"><blockquote class="blockquote"><p>
|
||||
Copyright 2001 (C) MetaStuff, Ltd. All Rights Reserved.
|
||||
</p><p>
|
||||
Redistribution and use of this software and associated documentation
|
||||
("Software"), with or without modification, are permitted provided that
|
||||
the following conditions are met:
|
||||
</p><div class="orderedlist"><ol class="orderedlist" type="1"><li class="listitem"><p>
|
||||
Redistributions of source code must retain copyright statements and
|
||||
notices. Redistributions must also contain a copy of this document.
|
||||
</p></li><li class="listitem"><p>
|
||||
Redistributions in binary form must reproduce the above copyright
|
||||
notice, this list of conditions and the following disclaimer in the
|
||||
documentation and/or other materials provided with the distribution.
|
||||
</p></li><li class="listitem"><p>
|
||||
The name "DOM4J" must not be used to endorse or promote products
|
||||
derived from this Software without prior written permission
|
||||
of MetaStuff, Ltd. For written permission, please contact
|
||||
<code class="email"><<a class="email" href="mailto:dom4j-info@metastuff.com">dom4j-info@metastuff.com</a>></code>.
|
||||
</p></li><li class="listitem"><p>
|
||||
Products derived from this Software may not be called "DOM4J" nor may
|
||||
"DOM4J" appear in their names without prior written permission of
|
||||
MetaStuff, Ltd. DOM4J is a registered trademark of MetaStuff, Ltd.
|
||||
</p></li><li class="listitem"><p>
|
||||
Due credit should be given to the DOM4J Project (<a class="ulink" href="http://dom4j.org/" target="_top">http://dom4j.org/</a>).
|
||||
</p></li></ol></div><p>
|
||||
THIS SOFTWARE IS PROVIDED BY METASTUFF, LTD. AND CONTRIBUTORS ``AS IS''
|
||||
AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL METASTUFF, LTD. OR ITS
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
||||
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
</p></blockquote></div></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="license.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> </td></tr><tr><td width="40%" align="left" valign="top">Chapter 13. License </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> </td></tr></table></div></body></html>
|
||||
45
findbugs/findbugs-2.0.0/doc/manual/analysisprops.html
Normal file
@@ -0,0 +1,45 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 9. Analysis Properties</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="filter.html" title="Chapter 8. Filter Files"><link rel="next" href="annotations.html" title="Chapter 10. Annotations"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 9. Analysis Properties</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="filter.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="annotations.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 9. Analysis Properties"><div class="titlepage"><div><div><h2 class="title"><a name="analysisprops"></a>Chapter 9. Analysis Properties</h2></div></div></div><p>
|
||||
<span class="application">FindBugs</span> allows several aspects of the analyses it performs to be
|
||||
customized. System properties are used to configure these options.
|
||||
This chapter describes the configurable analysis options.
|
||||
</p><p>
|
||||
The analysis options have two main purposes. First, they allow you
|
||||
to inform <span class="application">FindBugs</span> about the meaning of methods in your application,
|
||||
so that it can produce more accurate results, or produce fewer
|
||||
false warnings. Second, they allow you to configure the precision
|
||||
of the analysis performed. Reducing analysis precision can save
|
||||
memory and analysis time, at the expense of missing some real bugs,
|
||||
or producing more false warnings.
|
||||
</p><p>
|
||||
The analysis options are set using the <span class="command"><strong>-property</strong></span>
|
||||
command line option. For example:
|
||||
</p><pre class="screen">
|
||||
<code class="prompt">$ </code><span class="command"><strong>findbugs -textui -property "cfg.noprune=true" <em class="replaceable"><code>myApp.jar</code></em></strong></span>
|
||||
</pre><p>
|
||||
</p><p>
|
||||
The list of configurable analysis properties is shown in
|
||||
<a class="xref" href="analysisprops.html#analysisproptable" title="Table 9.1. Configurable Analysis Properties">Table 9.1, “Configurable Analysis Properties”</a>.
|
||||
</p><div class="table"><a name="analysisproptable"></a><p class="title"><b>Table 9.1. Configurable Analysis Properties</b></p><div class="table-contents"><table summary="Configurable Analysis Properties" border="1"><colgroup><col><col><col></colgroup><thead><tr><th align="left">Property Name</th><th align="left">Value</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left">findbugs.assertionmethods</td><td align="left">Comma-separated list of fully qualified method names:
|
||||
e.g., "com.foo.MyClass.checkAssertion"</td><td align="left">This property specifies the names of methods that are used
|
||||
to check program assertions. Specifying these methods allows
|
||||
the null pointer dereference bug detector to avoid reporting
|
||||
false warnings for values which are checked by assertion
|
||||
methods.</td></tr><tr><td align="left">findbugs.de.comment</td><td align="left">true or false</td><td align="left">If true, the DroppedException detector scans source code
|
||||
for empty catch blocks for a comment, and if one is found, does
|
||||
not report a warning.</td></tr><tr><td align="left">findbugs.maskedfields.locals</td><td align="left">true or false</td><td align="left">If true, emit low priority warnings for local variables
|
||||
which obscure fields. Default is false.</td></tr><tr><td align="left">findbugs.nullderef.assumensp</td><td align="left">true or false</td><td align="left">not used
|
||||
(intention: If true, the null dereference detector assumes that any
|
||||
reference value returned from a method or passed to a method
|
||||
in a parameter might be null. Default is false. Note that
|
||||
enabling this property will very likely cause a large number
|
||||
of false warnings to be produced.)</td></tr><tr><td align="left">findbugs.refcomp.reportAll</td><td align="left">true or false</td><td align="left">If true, all suspicious reference comparisons
|
||||
using the == and != operators are reported. If false,
|
||||
only one such warning is issued per method. Default
|
||||
is false.</td></tr><tr><td align="left">findbugs.sf.comment</td><td align="left">true or false</td><td align="left">If true, the SwitchFallthrough detector will only report
|
||||
warnings for cases where the source code does not have a comment
|
||||
containing the words "fall" or "nobreak". (An accurate source
|
||||
path must be used for this feature to work correctly.)
|
||||
This helps find cases where the switch fallthrough is likely
|
||||
to be unintentional.</td></tr></tbody></table></div></div><br class="table-break"></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="filter.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="annotations.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 8. Filter Files </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 10. Annotations</td></tr></table></div></body></html>
|
||||
101
findbugs/findbugs-2.0.0/doc/manual/annotations.html
Normal file
@@ -0,0 +1,101 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 10. Annotations</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="analysisprops.html" title="Chapter 9. Analysis Properties"><link rel="next" href="rejarForAnalysis.html" title="Chapter 11. Using rejarForAnalysis"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 10. Annotations</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="analysisprops.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="rejarForAnalysis.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 10. Annotations"><div class="titlepage"><div><div><h2 class="title"><a name="annotations"></a>Chapter 10. Annotations</h2></div></div></div><p>
|
||||
<span class="application">FindBugs</span> supports several annotations to express the developer's intent
|
||||
so that FindBugs can issue warnings more appropriately. You need to use
|
||||
Java 5 to use annotations, and must place the annotations.jar and jsr305.jar
|
||||
files in the classpath while compiling your program.
|
||||
</p><div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.CheckForNull</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
The annotated element might be null, and uses of the element should check for null.
|
||||
When this annotation is applied to a method it applies to the method return value.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.CheckReturnValue</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Method, Constructor
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>priority:</strong></span>The priority of the warning (HIGH, MEDIUM, LOW, IGNORE). Default value:MEDIUM.
|
||||
</p><p>
|
||||
<span class="command"><strong>explanation:</strong></span>A textual explaination of why the return value should be checked. Default value:"".
|
||||
</p></dd></dl></div><p>
|
||||
This annotation is used to denote a method whose return value should always be checked after invoking the method.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotation</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>Annotation class objects. More than one class can be specified.
|
||||
</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>Default priority(HIGH, MEDIUM, LOW, IGNORE). Default value:MEDIUM.
|
||||
</p></dd></dl></div><p>
|
||||
Indicates that all members of the class or package should be annotated with the default
|
||||
value of the supplied annotation classes. This would be used for behavior annotations
|
||||
such as @NonNull, @CheckForNull, or @CheckReturnValue. In particular, you can use
|
||||
@DefaultAnnotation(NonNull.class) on a class or package, and then use @Nullable only
|
||||
on those parameters, methods or fields that you want to allow to be null.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotationForFields</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>Annotation class objects. More than one class can be specified.
|
||||
</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>Default priority(HIGH, MEDIUM, LOW, IGNORE). Default value:MEDIUM.
|
||||
</p></dd></dl></div><p>
|
||||
This is same as the DefaultAnnotation except it only applys to fields.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotationForMethods</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>Annotation class objects. More than one class can be specified.
|
||||
</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>Default priority(HIGH, MEDIUM, LOW, IGNORE). Default value:MEDIUM.
|
||||
</p></dd></dl></div><p>
|
||||
This is same as the DefaultAnnotation except it only applys to methods.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.DefaultAnnotationForParameters</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>Annotation class objects. More than one class can be specified.
|
||||
</p><p>
|
||||
<span class="command"><strong>priority:</strong></span>Default priority(HIGH, MEDIUM, LOW, IGNORE). Default value:MEDIUM.
|
||||
</p></dd></dl></div><p>
|
||||
This is same as the DefaultAnnotation except it only applys to method parameters.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.NonNull</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
The annotated element must not be null.
|
||||
Annotated fields must not be null after construction has completed. Annotated methods must have non-null return values.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.Nullable</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
The annotated element could be null under some circumstances. In general, this means
|
||||
developers will have to read the documentation to determine when a null value is
|
||||
acceptable and whether it is neccessary to check for a null value. FindBugs will
|
||||
treat the annotated items as though they had no annotation.
|
||||
</p><p>
|
||||
In pratice this annotation is useful only for overriding an overarching NonNull
|
||||
annotation.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.OverrideMustInvoke</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Method
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>Specify when the super invocation should be
|
||||
performed (FIRST, ANYTIME, LAST). Default value:ANYTIME.
|
||||
</p></dd></dl></div><p>
|
||||
Used to annotate a method that, if overridden, must (or should) be invoke super
|
||||
in the overriding method. Examples of such methods include finalize() and clone().
|
||||
The argument to the method indicates when the super invocation should occur:
|
||||
at any time, at the beginning of the overriding method, or at the end of the overriding method.
|
||||
(This anotation is not implmemented in FindBugs as of September 8, 2006).
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.PossiblyNull</strong></span></span></dt><dd><p>
|
||||
This annotation is deprecated. Use CheckForNull instead.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.SuppressWarnings</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Type, Field, Method, Parameter, Constructor, Package
|
||||
<div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>[Parameter]</strong></span></span></dt><dd><p>
|
||||
<span class="command"><strong>value:</strong></span>The name of the warning. More than one name can be specified.
|
||||
</p><p>
|
||||
<span class="command"><strong>justification:</strong></span>Reason why the warning should be ignored. Default value:"".
|
||||
</p></dd></dl></div><p>
|
||||
The set of warnings that are to be suppressed by the compiler in the annotated element.
|
||||
Duplicate names are permitted. The second and successive occurrences of a name are ignored.
|
||||
The presence of unrecognized warning names is <span class="emphasis"><em>not</em></span> an error: Compilers
|
||||
must ignore any warning names they do not recognize. They are, however, free to emit a
|
||||
warning if an annotation contains an unrecognized warning name. Compiler vendors should
|
||||
document the warning names they support in conjunction with this annotation type. They
|
||||
are encouraged to cooperate to ensure that the same names work across multiple compilers.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.UnknownNullness</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
Used to indicate that the nullness of the target is unknown, or my vary in unknown ways in subclasses.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>edu.umd.cs.findbugs.annotations.UnknownNullness</strong></span></span></dt><dd><span class="command"><strong>[Target]</strong></span> Field, Method, Parameter
|
||||
<p>
|
||||
Used to indicate that the nullness of the target is unknown, or my vary in unknown ways in subclasses.
|
||||
</p></dd></dl></div><p>
|
||||
<span class="application">FindBugs</span> also supports the following annotations:
|
||||
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">net.jcip.annotations.GuardedBy</li><li class="listitem">net.jcip.annotations.Immutable</li><li class="listitem">net.jcip.annotations.NotThreadSafe</li><li class="listitem">net.jcip.annotations.ThreadSafe</li></ul></div><p>
|
||||
</p><p>
|
||||
You can refer the JCIP annotation <a class="ulink" href="http://jcip.net/annotations/doc/index.html" target="_top">
|
||||
API documentation</a> at <a class="ulink" href="http://jcip.net/" target="_top">Java Concurrency in Practice</a>.
|
||||
</p></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="analysisprops.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="rejarForAnalysis.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 9. Analysis Properties </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 11. Using rejarForAnalysis</td></tr></table></div></body></html>
|
||||
203
findbugs/findbugs-2.0.0/doc/manual/anttask.html
Normal file
@@ -0,0 +1,203 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 6. Using the FindBugs™ Ant task</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="gui.html" title="Chapter 5. Using the FindBugs GUI"><link rel="next" href="eclipse.html" title="Chapter 7. Using the FindBugs™ Eclipse plugin"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 6. Using the <span class="application">FindBugs</span>™ <span class="application">Ant</span> task</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="gui.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="eclipse.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 6. Using the FindBugs™ Ant task"><div class="titlepage"><div><div><h2 class="title"><a name="anttask"></a>Chapter 6. Using the <span class="application">FindBugs</span>™ <span class="application">Ant</span> task</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="anttask.html#d0e1200">1. Installing the <span class="application">Ant</span> task</a></span></dt><dt><span class="sect1"><a href="anttask.html#d0e1238">2. Modifying build.xml</a></span></dt><dt><span class="sect1"><a href="anttask.html#d0e1309">3. Executing the task</a></span></dt><dt><span class="sect1"><a href="anttask.html#d0e1334">4. Parameters</a></span></dt></dl></div><p>
|
||||
This chapter describes how to integrate <span class="application">FindBugs</span> into a build script
|
||||
for <a class="ulink" href="http://ant.apache.org/" target="_top"><span class="application">Ant</span></a>, which is a popular Java build
|
||||
and deployment tool. Using the <span class="application">FindBugs</span> <span class="application">Ant</span> task, your build script can
|
||||
automatically run <span class="application">FindBugs</span> on your Java code.
|
||||
</p><p>
|
||||
The <span class="application">Ant</span> task was generously contributed by Mike Fagan.
|
||||
</p><div class="sect1" title="1. Installing the Ant task"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1200"></a>1. Installing the <span class="application">Ant</span> task</h2></div></div></div><p>
|
||||
To install the <span class="application">Ant</span> task, simply copy <code class="filename"><em class="replaceable"><code>$FINDBUGS_HOME</code></em>/lib/findbugs-ant.jar</code>
|
||||
into the <code class="filename">lib</code> subdirectory of your <span class="application">Ant</span> installation.
|
||||
|
||||
</p><div class="note" title="Note" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Note"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Note]" src="note.png"></td><th align="left">Note</th></tr><tr><td align="left" valign="top"><p>It is strongly recommended that you use the <span class="application">Ant</span> task with the version
|
||||
of <span class="application">FindBugs</span> it was included with. We do not guarantee that the <span class="application">Ant</span> task Jar file
|
||||
will work with any version of <span class="application">FindBugs</span> other than the one it was included with.</p></td></tr></table></div><p>
|
||||
</p></div><div class="sect1" title="2. Modifying build.xml"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1238"></a>2. Modifying build.xml</h2></div></div></div><p>
|
||||
To incorporate <span class="application">FindBugs</span> into <code class="filename">build.xml</code> (the build script
|
||||
for <span class="application">Ant</span>), you first need to add a task definition. This should appear as follows:
|
||||
|
||||
</p><pre class="screen">
|
||||
<taskdef name="findbugs" classname="edu.umd.cs.findbugs.anttask.FindBugsTask"/>
|
||||
</pre><p>
|
||||
|
||||
The task definition specifies that when a <code class="literal">findbugs</code> element is
|
||||
seen in <code class="filename">build.xml</code>, it should use the indicated class to execute the task.
|
||||
</p><p>
|
||||
After you have added the task definition, you can define a target
|
||||
which uses the <code class="literal">findbugs</code> task. Here is an example
|
||||
which could be added to the <code class="filename">build.xml</code> for the
|
||||
Apache <a class="ulink" href="http://jakarta.apache.org/bcel/" target="_top">BCEL</a> library.
|
||||
|
||||
</p><pre class="screen">
|
||||
<property name="findbugs.home" value="/export/home/daveho/work/findbugs" />
|
||||
|
||||
<target name="findbugs" depends="jar">
|
||||
<findbugs home="${findbugs.home}"
|
||||
output="xml"
|
||||
outputFile="bcel-fb.xml" >
|
||||
<auxClasspath path="${basedir}/lib/Regex.jar" />
|
||||
<sourcePath path="${basedir}/src/java" />
|
||||
<class location="${basedir}/bin/bcel.jar" />
|
||||
</findbugs>
|
||||
</target>
|
||||
</pre><p>
|
||||
|
||||
The <code class="literal">findbugs</code> element must have the <code class="literal">home</code>
|
||||
attribute set to the directory in which <span class="application">FindBugs</span> is installed; in other words,
|
||||
<em class="replaceable"><code>$FINDBUGS_HOME</code></em>. See <a class="xref" href="installing.html" title="Chapter 2. Installing FindBugs™">Chapter 2, <i>Installing <span class="application">FindBugs</span>™</i></a>.
|
||||
</p><p>
|
||||
This target will execute <span class="application">FindBugs</span> on <code class="filename">bcel.jar</code>, which is the
|
||||
Jar file produced by BCEL's build script. (By making it depend on the "jar"
|
||||
target, we ensure that the library is fully compiled before running <span class="application">FindBugs</span> on it.)
|
||||
The output of <span class="application">FindBugs</span> will be saved in XML format to a file called
|
||||
<code class="filename">bcel-fb.xml</code>.
|
||||
An auxiliary Jar file, <code class="filename">Regex.jar</code>, is added to the aux classpath,
|
||||
because it is referenced by the main BCEL library. A source path is specified
|
||||
so that the saved bug data will have accurate references to the BCEL source code.
|
||||
</p></div><div class="sect1" title="3. Executing the task"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1309"></a>3. Executing the task</h2></div></div></div><p>
|
||||
Here is an example of invoking <span class="application">Ant</span> from the command line, using the <code class="literal">findbugs</code>
|
||||
target defined above.
|
||||
|
||||
</p><pre class="screen">
|
||||
<code class="prompt">[daveho@noir]$</code> <span class="command"><strong>ant findbugs</strong></span>
|
||||
Buildfile: build.xml
|
||||
|
||||
init:
|
||||
|
||||
compile:
|
||||
|
||||
examples:
|
||||
|
||||
jar:
|
||||
|
||||
findbugs:
|
||||
[findbugs] Running FindBugs...
|
||||
[findbugs] Bugs were found
|
||||
[findbugs] Output saved to bcel-fb.xml
|
||||
|
||||
BUILD SUCCESSFUL
|
||||
Total time: 35 seconds
|
||||
</pre><p>
|
||||
|
||||
In this case, because we saved the bug results in an XML file, we can
|
||||
use the <span class="application">FindBugs</span> GUI to view the results; see <a class="xref" href="running.html" title="Chapter 4. Running FindBugs™">Chapter 4, <i>Running <span class="application">FindBugs</span>™</i></a>.
|
||||
</p></div><div class="sect1" title="4. Parameters"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1334"></a>4. Parameters</h2></div></div></div><p>This section describes the parameters that may be specified when
|
||||
using the <span class="application">FindBugs</span> task.
|
||||
|
||||
</p><div class="variablelist"><dl><dt><span class="term"><code class="literal">class</code></span></dt><dd><p>
|
||||
A nested element specifying which classes to analyze. The <code class="literal">class</code>
|
||||
element must specify a <code class="literal">location</code> attribute which names the
|
||||
archive file (jar, zip, etc.), directory, or class file to be analyzed. Multiple <code class="literal">class</code>
|
||||
elements may be specified as children of a single <code class="literal">findbugs</code> element.
|
||||
</p></dd><dt><span class="term"><code class="literal">auxClasspath</code></span></dt><dd><p>
|
||||
An optional nested element which specifies a classpath (Jar files or directories)
|
||||
containing classes used by the analyzed library or application, but which
|
||||
you don't want to analyze. It is specified the same way as
|
||||
<span class="application">Ant</span>'s <code class="literal">classpath</code> element for the Java task.
|
||||
</p></dd><dt><span class="term"><code class="literal">sourcePath</code></span></dt><dd><p>
|
||||
An optional nested element which specifies a source directory path
|
||||
containing source files used to compile the Java code being analyzed.
|
||||
By specifying a source path, any generated XML bug output will have
|
||||
complete source information, which allows later viewing in the
|
||||
GUI.
|
||||
</p></dd><dt><span class="term"><code class="literal">home</code></span></dt><dd><p>
|
||||
A required attribute.
|
||||
It must be set to the name of the directory where <span class="application">FindBugs</span> is installed.
|
||||
</p></dd><dt><span class="term"><code class="literal">quietErrors</code></span></dt><dd><p>
|
||||
An optional boolean attribute.
|
||||
If true, reports of serious analysis errors and missing classes will
|
||||
be suppressed in the <span class="application">FindBugs</span> output. Default is false.
|
||||
</p></dd><dt><span class="term"><code class="literal">reportLevel</code></span></dt><dd><p>
|
||||
An optional attribute. It specifies
|
||||
the priority threshold for reporting bugs. If set to "low", all bugs are reported.
|
||||
If set to "medium" (the default), medium and high priority bugs are reported.
|
||||
If set to "high", only high priority bugs are reported.
|
||||
</p></dd><dt><span class="term"><code class="literal">output</code></span></dt><dd><p>
|
||||
Optional attribute.
|
||||
It specifies the output format. If set to "xml" (the default), output
|
||||
is in XML format.
|
||||
If set to "xml:withMessages", output is in XML format augmented with
|
||||
human-readable messages. (You should use this format if you plan
|
||||
to generate a report using an XSL stylesheet.)
|
||||
If set to "html", output is in HTML formatted (default stylesheet is default.xsl).
|
||||
If set to "text", output is in ad-hoc text format.
|
||||
If set to "emacs", output is in <a class="ulink" href="http://www.gnu.org/software/emacs/" target="_top">Emacs</a> error message format.
|
||||
If set to "xdocs", output is xdoc XML for use with Apache Maven.
|
||||
</p></dd><dt><span class="term"><code class="literal">stylesheet</code></span></dt><dd><p>
|
||||
Optional attribute.
|
||||
It specifies the stylesheet to use to generate html output when the output is set to html.
|
||||
Stylesheets included in the FindBugs distribution include default.xsl, fancy.xsl, fancy-hist.xsl, plain.xsl, and summary.xsl.
|
||||
The default value, if no stylesheet attribute is provided, is default.xsl.
|
||||
|
||||
</p></dd><dt><span class="term"><code class="literal">sort</code></span></dt><dd><p>
|
||||
Optional attribute. If the <code class="literal">output</code> attribute
|
||||
is set to "text", then the <code class="literal">sort</code> attribute specifies
|
||||
whether or not reported bugs are sorted by class. Default is true.
|
||||
</p></dd><dt><span class="term"><code class="literal">outputFile</code></span></dt><dd><p>
|
||||
Optional attribute. If specified, names the output file in which the
|
||||
<span class="application">FindBugs</span> output will be saved. By default, the output is displayed
|
||||
directly by <span class="application">Ant</span>.
|
||||
</p></dd><dt><span class="term"><code class="literal">debug</code></span></dt><dd><p>
|
||||
Optional boolean attribute. If set to true, <span class="application">FindBugs</span> prints diagnostic
|
||||
information about which classes are being analyzed, and which bug pattern
|
||||
detectors are being run. Default is false.
|
||||
</p></dd><dt><span class="term"><code class="literal">effort</code></span></dt><dd><p>
|
||||
Set the analysis effort level. The value specified should be
|
||||
one of <code class="literal">min</code>, <code class="literal">default</code>,
|
||||
or <code class="literal">max</code>. See <a class="xref" href="running.html#commandLineOptions" title="3. Command-line Options">Section 3, “Command-line Options”</a>
|
||||
for more information about setting the analysis level.
|
||||
</p></dd><dt><span class="term"><code class="literal">conserveSpace</code></span></dt><dd><p>Synonym for effort="min".</p></dd><dt><span class="term"><code class="literal">workHard</code></span></dt><dd><p>Synonym for effort="max".</p></dd><dt><span class="term"><code class="literal">visitors</code></span></dt><dd><p>
|
||||
Optional attribute. It specifies a comma-separated list of bug detectors
|
||||
which should be run. The bug detectors are specified by their class names,
|
||||
without any package qualification. By default, all detectors which are
|
||||
not disabled by default are run.
|
||||
</p></dd><dt><span class="term"><code class="literal">omitVisitors</code></span></dt><dd><p>
|
||||
Optional attribute. It is like the <code class="literal">visitors</code> attribute,
|
||||
except it specifies detectors which will <span class="emphasis"><em>not</em></span> be run.
|
||||
</p></dd><dt><span class="term"><code class="literal">excludeFilter</code></span></dt><dd><p>
|
||||
Optional attribute. It specifies the filename of a filter specifying bugs
|
||||
to exclude from being reported. See <a class="xref" href="filter.html" title="Chapter 8. Filter Files">Chapter 8, <i>Filter Files</i></a>.
|
||||
</p></dd><dt><span class="term"><code class="literal">includeFilter</code></span></dt><dd><p>
|
||||
Optional attribute. It specifies the filename of a filter specifying
|
||||
which bugs are reported. See <a class="xref" href="filter.html" title="Chapter 8. Filter Files">Chapter 8, <i>Filter Files</i></a>.
|
||||
</p></dd><dt><span class="term"><code class="literal">projectFile</code></span></dt><dd><p>
|
||||
Optional attribute. It specifies the name of a project file.
|
||||
Project files are created by the <span class="application">FindBugs</span> GUI, and specify classes,
|
||||
aux classpath entries, and source directories. By naming a project,
|
||||
you don't need to specify any <code class="literal">class</code> elements,
|
||||
nor do you need to specify <code class="literal">auxClasspath</code> or
|
||||
<code class="literal">sourcePath</code> attributes.
|
||||
See <a class="xref" href="running.html" title="Chapter 4. Running FindBugs™">Chapter 4, <i>Running <span class="application">FindBugs</span>™</i></a> for how to create a project.
|
||||
</p></dd><dt><span class="term"><code class="literal">jvmargs</code></span></dt><dd><p>
|
||||
Optional attribute. It specifies any arguments that should be passed
|
||||
to the Java virtual machine used to run <span class="application">FindBugs</span>. You may need to
|
||||
use this attribute to specify flags to increase the amount of memory
|
||||
the JVM may use if you are analyzing a very large program.
|
||||
</p></dd><dt><span class="term"><code class="literal">systemProperty</code></span></dt><dd><p>
|
||||
Optional nested element. If specified, defines a system property.
|
||||
The <code class="literal">name</code> attribute specifies the name of the
|
||||
system property, and the <code class="literal">value</code> attribute specifies
|
||||
the value of the system property.
|
||||
</p></dd><dt><span class="term"><code class="literal">timeout</code></span></dt><dd><p>
|
||||
Optional attribute. It specifies the amount of time, in milliseconds,
|
||||
that the Java process executing <span class="application">FindBugs</span> may run before it is
|
||||
assumed to be hung and is terminated. The default is 600,000
|
||||
milliseconds, which is ten minutes. Note that for very large
|
||||
programs, <span class="application">FindBugs</span> may require more than ten minutes to complete its
|
||||
analysis.
|
||||
</p></dd><dt><span class="term"><code class="literal">failOnError</code></span></dt><dd><p>
|
||||
Optional boolean attribute. Whether to abort the build process if there is an
|
||||
error running <span class="application">FindBugs</span>. Defaults to "false"
|
||||
</p></dd><dt><span class="term"><code class="literal">errorProperty</code></span></dt><dd><p>
|
||||
Optional attribute which specifies the name of a property that
|
||||
will be set to "true" if an error occurs while running <span class="application">FindBugs</span>.
|
||||
</p></dd><dt><span class="term"><code class="literal">warningsProperty</code></span></dt><dd><p>
|
||||
Optional attribute which specifies the name of a property
|
||||
that will be set to "true" if any warnings are reported by
|
||||
<span class="application">FindBugs</span> on the analyzed program.
|
||||
</p></dd></dl></div><p>
|
||||
|
||||
|
||||
</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="gui.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="eclipse.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 5. Using the <span class="application">FindBugs</span> GUI </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 7. Using the <span class="application">FindBugs</span>™ Eclipse plugin</td></tr></table></div></body></html>
|
||||
123
findbugs/findbugs-2.0.0/doc/manual/building.html
Normal file
@@ -0,0 +1,123 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 3. Building FindBugs™ from Source</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="installing.html" title="Chapter 2. Installing FindBugs™"><link rel="next" href="running.html" title="Chapter 4. Running FindBugs™"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 3. Building <span class="application">FindBugs</span>™ from Source</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="installing.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="running.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 3. Building FindBugs™ from Source"><div class="titlepage"><div><div><h2 class="title"><a name="building"></a>Chapter 3. Building <span class="application">FindBugs</span>™ from Source</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="building.html#d0e181">1. Prerequisites</a></span></dt><dt><span class="sect1"><a href="building.html#d0e270">2. Extracting the Source Distribution</a></span></dt><dt><span class="sect1"><a href="building.html#d0e283">3. Modifying <code class="filename">local.properties</code></a></span></dt><dt><span class="sect1"><a href="building.html#d0e341">4. Running <span class="application">Ant</span></a></span></dt><dt><span class="sect1"><a href="building.html#d0e435">5. Running <span class="application">FindBugs</span>™ from a source directory</a></span></dt></dl></div><p>
|
||||
This chapter describes how to build <span class="application">FindBugs</span> from source code. Unless you are
|
||||
interesting in modifying <span class="application">FindBugs</span>, you will probably want to skip to the
|
||||
<a class="link" href="running.html" title="Chapter 4. Running FindBugs™">next chapter</a>.
|
||||
</p><div class="sect1" title="1. Prerequisites"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e181"></a>1. Prerequisites</h2></div></div></div><p>
|
||||
To compile <span class="application">FindBugs</span> from source, you will need the following:
|
||||
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>
|
||||
The <a class="ulink" href="http://prdownloads.sourceforge.net/findbugs/findbugs-2.0.0-source.zip?download" target="_top"><span class="application">FindBugs</span> source distribution</a>
|
||||
</p></li><li class="listitem"><p>
|
||||
<a class="ulink" href="http://java.sun.com/j2se/" target="_top">JDK 1.5.0 beta or later</a>
|
||||
</p></li><li class="listitem"><p>
|
||||
<a class="ulink" href="http://ant.apache.org/" target="_top">Apache <span class="application">Ant</span></a>, version 1.6.3 or later
|
||||
</p></li></ul></div><p>
|
||||
</p><div class="warning" title="Warning" style="margin-left: 0.5in; margin-right: 0.5in;"><table border="0" summary="Warning"><tr><td rowspan="2" align="center" valign="top" width="25"><img alt="[Warning]" src="warning.png"></td><th align="left">Warning</th></tr><tr><td align="left" valign="top"><p>
|
||||
The version of <span class="application">Ant</span> included as <code class="filename">/usr/bin/ant</code> on
|
||||
Redhat Linux systems will <span class="emphasis"><em>not</em></span> work for compiling
|
||||
<span class="application">FindBugs</span>. We recommend you install a binary distribution of <span class="application">Ant</span>
|
||||
downloaded from the <a class="ulink" href="http://ant.apache.org/" target="_top"><span class="application">Ant</span> website</a>.
|
||||
Make sure that when you run <span class="application">Ant</span> your <em class="replaceable"><code>JAVA_HOME</code></em>
|
||||
environment variable points to the directory in which you installed
|
||||
JDK 1.5 (or later).
|
||||
</p></td></tr></table></div><p>
|
||||
If you want to be able to generate formatted versions of the <span class="application">FindBugs</span> documentation,
|
||||
you will also need the following software:
|
||||
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>
|
||||
The <a class="ulink" href="http://docbook.sourceforge.net/projects/xsl/index.html" target="_top">DocBook XSL Stylesheets</a>.
|
||||
These are required to convert the <span class="application">FindBugs</span> manual into HTML format.
|
||||
</p></li><li class="listitem"><p>
|
||||
The <a class="ulink" href="http://saxon.sourceforge.net/" target="_top"><span class="application">Saxon</span> XSLT Processor</a>.
|
||||
(Also required for converting the <span class="application">FindBugs</span> manual to HTML.)
|
||||
</p></li></ul></div><p>
|
||||
</p></div><div class="sect1" title="2. Extracting the Source Distribution"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e270"></a>2. Extracting the Source Distribution</h2></div></div></div><p>
|
||||
After you download the source distribution, you'll need to extract it into
|
||||
a working directory. A typical command to do this is:
|
||||
|
||||
</p><pre class="screen">
|
||||
<code class="prompt">$ </code><span class="command"><strong>unzip findbugs-2.0.0-source.zip</strong></span>
|
||||
</pre><p>
|
||||
|
||||
</p></div><div class="sect1" title="3. Modifying local.properties"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e283"></a>3. Modifying <code class="filename">local.properties</code></h2></div></div></div><p>
|
||||
If you intend to build the FindBugs documentation,
|
||||
you will need to modify the <code class="filename">local.properties</code> file
|
||||
used by the <a class="ulink" href="http://ant.apache.org/" target="_top"><span class="application">Ant</span></a>
|
||||
<code class="filename">build.xml</code> file to build <span class="application">FindBugs</span>.
|
||||
If you do not want to build the FindBugs documentation, then you
|
||||
can ignore this file.
|
||||
</p><p>
|
||||
The <code class="filename">local.properties</code> overrides definitions
|
||||
in the <code class="filename">build.properties</code> file.
|
||||
The <code class="filename">build.properties</code> file looks something like this:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
# User Configuration:
|
||||
# This section must be modified to reflect your system.
|
||||
|
||||
local.software.home =/export/home/daveho/linux
|
||||
|
||||
# Set this to the directory containing the DocBook Modular XSL Stylesheets
|
||||
# from http://docbook.sourceforge.net/projects/xsl/
|
||||
|
||||
xsl.stylesheet.home =${local.software.home}/docbook/docbook-xsl-1.71.1
|
||||
|
||||
# Set this to the directory where Saxon (http://saxon.sourceforge.net/)
|
||||
# is installed.
|
||||
|
||||
saxon.home =${local.software.home}/java/saxon-6.5.5
|
||||
|
||||
</pre><p>
|
||||
</p><p>
|
||||
The <code class="varname">xsl.stylesheet.home</code> property specifies the full
|
||||
path to the directory where you have installed the
|
||||
<a class="ulink" href="http://docbook.sourceforge.net/projects/xsl/" target="_top">DocBook Modular XSL
|
||||
Stylesheets</a>. You only need to specify this property if you will be
|
||||
generating the <span class="application">FindBugs</span> documentation.
|
||||
</p><p>
|
||||
The <code class="varname">saxon.home</code> property is the full path to the
|
||||
directory where you installed the <a class="ulink" href="http://saxon.sourceforge.net/" target="_top"><span class="application">Saxon</span> XSLT Processor</a>.
|
||||
You only need to specify this property if you will be
|
||||
generating the <span class="application">FindBugs</span> documentation.
|
||||
</p></div><div class="sect1" title="4. Running Ant"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e341"></a>4. Running <span class="application">Ant</span></h2></div></div></div><p>
|
||||
Once you have extracted the source distribution,
|
||||
made sure that <span class="application">Ant</span> is installed,
|
||||
modified <code class="filename">build.properties</code> (optional),
|
||||
and configured the tools (such as <span class="application">Saxon</span>),
|
||||
you are ready to build <span class="application">FindBugs</span>. Invoking <span class="application">Ant</span> is a simple matter
|
||||
of running the command
|
||||
</p><pre class="screen">
|
||||
<code class="prompt">$ </code><span class="command"><strong>ant <em class="replaceable"><code>target</code></em></strong></span>
|
||||
</pre><p>
|
||||
where <em class="replaceable"><code>target</code></em> is one of the following:
|
||||
</p><div class="variablelist"><dl><dt><span class="term"><span class="command"><strong>build</strong></span></span></dt><dd><p>
|
||||
This target compiles the code for <span class="application">FindBugs</span>. It is the default target.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>docs</strong></span></span></dt><dd><p>
|
||||
This target formats the documentation. (It also compiles some of
|
||||
the source code as a side-effect.)
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>runjunit</strong></span></span></dt><dd><p>
|
||||
This target compiles and runs the internal JUnit tests included
|
||||
in <span class="application">FindBugs</span>. It will print an error message if any unit
|
||||
tests fail.
|
||||
</p></dd><dt><span class="term"><span class="command"><strong>bindist</strong></span></span></dt><dd><p>
|
||||
Builds a binary distribution of <span class="application">FindBugs</span>.
|
||||
The target creates both <code class="filename">.zip</code> and
|
||||
<code class="filename">.tar.gz</code> archives.
|
||||
</p></dd></dl></div><p>
|
||||
</p><p>
|
||||
After running an <span class="application">Ant</span> command, you should see output similar to
|
||||
the following (after some other messages regarding the tasks that
|
||||
<span class="application">Ant</span> is running):
|
||||
</p><pre class="screen">
|
||||
<code class="computeroutput">
|
||||
BUILD SUCCESSFUL
|
||||
Total time: 17 seconds
|
||||
</code>
|
||||
</pre><p>
|
||||
</p></div><div class="sect1" title="5. Running FindBugs™ from a source directory"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e435"></a>5. Running <span class="application">FindBugs</span>™ from a source directory</h2></div></div></div><p>
|
||||
The <span class="application">Ant</span> build script for <span class="application">FindBugs</span> is written such that after
|
||||
building the <span class="command"><strong>build</strong></span> target, the working directory
|
||||
is set up just like a binary distribution. So, the information about
|
||||
running <span class="application">FindBugs</span> in <a class="xref" href="running.html" title="Chapter 4. Running FindBugs™">Chapter 4, <i>Running <span class="application">FindBugs</span>™</i></a>
|
||||
applies to source distributions, too.
|
||||
</p></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="installing.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="running.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 2. Installing <span class="application">FindBugs</span>™ </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 4. Running <span class="application">FindBugs</span>™</td></tr></table></div></body></html>
|
||||
421
findbugs/findbugs-2.0.0/doc/manual/datamining.html
Normal file
@@ -0,0 +1,421 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 12. Data mining of bugs with FindBugs™</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="rejarForAnalysis.html" title="Chapter 11. Using rejarForAnalysis"><link rel="next" href="license.html" title="Chapter 13. License"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 12. Data mining of bugs with <span class="application">FindBugs</span>™</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="rejarForAnalysis.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="license.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 12. Data mining of bugs with FindBugs™"><div class="titlepage"><div><div><h2 class="title"><a name="datamining"></a>Chapter 12. Data mining of bugs with <span class="application">FindBugs</span>™</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="datamining.html#commands">1. Commands</a></span></dt><dt><span class="sect1"><a href="datamining.html#examples">2. Examples</a></span></dt><dt><span class="sect1"><a href="datamining.html#antexample">3. Ant example</a></span></dt></dl></div><p>
|
||||
FindBugs incorporates an ability to perform sophisticated queries on bug
|
||||
databases and track warnings across multiple versions of code being
|
||||
studied, allowing you to do things such as seeing when a bug was first introduced, examining
|
||||
just the warnings that have been introduced since the last release, or graphing the number
|
||||
of infinite recursive loops in your code over time.</p><p>
|
||||
These techniques all depend upon the XML format used by FindBugs for storing warnings.
|
||||
These XML files usually contain just the warnings from one particular analysis run, but
|
||||
they can also store the results from analyzing a sequence of software builds or versions.
|
||||
</p><p>
|
||||
Any FindBugs XML bug database contains a version name and timestamp.
|
||||
FindBugs tries to compute a timestamp from the timestamps of the files that
|
||||
are analyzed (e.g., the timestamp is intended to be the time the class files
|
||||
were generated, not analyzed). Each bug database also contains a version name.
|
||||
Both the version name and timestamp can be set manually using the
|
||||
<span class="command"><strong>setBugDatabaseInfo</strong></span> (<a class="xref" href="datamining.html#setBugDatabaseInfo" title="1.7. setBugDatabaseInfo">Section 1.7, “setBugDatabaseInfo”</a>) command.
|
||||
</p><p>A multiversion bug database assigns a sequence number to each version of
|
||||
the analyzed code. These sequence numbers are simply successive integers,
|
||||
starting at 0 (e.g., a bug database for 4 versions of the code will contain
|
||||
versions 0..3). The bug database will also record the name and timestamp for
|
||||
each version. The <span class="command"><strong>filterBugs</strong></span> command allows you to refer
|
||||
to a version by sequence number, name or timestamp.</p><p>
|
||||
You can take a sequence (or pair) of single version bug databases and create
|
||||
from them a multiversion bug database, or combine a multiversion bug database
|
||||
with a sequence of later single-version bug databases.</p><p>
|
||||
Some of these commands can be invoked as ant tasks. See below for specifics
|
||||
on how to invoke them and what attributes and arguments they take. All of
|
||||
the examples assume that the <code class="literal">findbugs.lib</code>
|
||||
<code class="literal">refid</code> is set correctly. Here is one way to set it:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<!-- findbugs task definition -->
|
||||
<property name="findbugs.home" value="/your/path/to/findbugs" />
|
||||
<path id="findbugs.lib">
|
||||
<fileset dir="${findbugs.home}/lib">
|
||||
<include name="findbugs-ant.jar"/>
|
||||
</fileset>
|
||||
</path>
|
||||
|
||||
</pre><div class="sect1" title="1. Commands"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="commands"></a>1. Commands</h2></div></div></div><p>
|
||||
All tools for FindBugs data mining are can be invoked from the command line,
|
||||
and some of the more useful tools can also be invoked from an
|
||||
ant build file.</p><p>
|
||||
Briefly, the command-line tools are:</p><div class="variablelist"><dl><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#unionBugs" title="1.1. unionBugs">unionBugs</a></strong></span></span></dt><dd><p>
|
||||
combine the results from separate analysis of disjoint
|
||||
classes
|
||||
</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#computeBugHistory" title="1.2. computeBugHistory">computeBugHistory</a></strong></span></span></dt><dd><p>Merge bug warnings from multiple versions of
|
||||
analyzed code into
|
||||
a single multiversion bug database. This can either be used
|
||||
to add more versions to an existing multiversion database,
|
||||
or to create a multiversion database from a sequence of single version
|
||||
bug warning databases.</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#setBugDatabaseInfo" title="1.7. setBugDatabaseInfo">setBugDatabaseInfo</a></strong></span></span></dt><dd><p>Set information such as the revision name or
|
||||
timestamp in an XML bug database</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#listBugDatabaseInfo" title="1.8. listBugDatabaseInfo">listBugDatabaseInfo</a></strong></span></span></dt><dd><p>List information such as the revision name and
|
||||
timestamp for a list of XML bug databases</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#filterBugs" title="1.3. filterBugs">filterBugs</a></strong></span></span></dt><dd><p>Select a subset of a bug database</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#mineBugHistory" title="1.4. mineBugHistory">mineBugHistory</a></strong></span></span></dt><dd><p>Generate a tabular listing of the number of warnings in each
|
||||
version of a multiversion bug database</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#defectDensity" title="1.5. defectDensity">defectDensity</a></strong></span></span></dt><dd><p>List information about defect density
|
||||
(warnings per 1000 NCSS)
|
||||
for the entire project and each class and package</p></dd><dt><span class="term"><span class="command"><strong><a class="link" href="datamining.html#convertXmlToText" title="1.6. convertXmlToText">convertXmlToText</a></strong></span></span></dt><dd><p>Convert bug warnings in XML format to
|
||||
a textual one-line-per-bug format, or to HTML</p></dd></dl></div><div class="sect2" title="1.1. unionBugs"><div class="titlepage"><div><div><h3 class="title"><a name="unionBugs"></a>1.1. unionBugs</h3></div></div></div><p>
|
||||
If you have, for example, separately analyzing each jar file used in an application,
|
||||
you can use this command to combine the separately generated xml bug warning files into
|
||||
a single file containing all of the warnings.</p><p>Do <span class="emphasis"><em>not</em></span> use this command to combine results from analyzing different versions of the same
|
||||
file; use <span class="command"><strong>computeBugHistory</strong></span> instead.</p><p>Specify the xml files on the command line. The result is sent to standard output.</p></div><div class="sect2" title="1.2. computeBugHistory"><div class="titlepage"><div><div><h3 class="title"><a name="computeBugHistory"></a>1.2. computeBugHistory</h3></div></div></div><p>Use this command to generate a bug database containing information from different builds or versions
|
||||
of software you are analyzing.
|
||||
History is taken from the first file provided as input; any following
|
||||
files should be single version bug databases (if they contain history, the history in those
|
||||
files will be ignored).</p><p>By default, output is written to the standard output.
|
||||
</p><p>This functionality may also can be accessed from ant.
|
||||
First create a taskdef for <span class="command"><strong>computeBugHistory</strong></span> in your
|
||||
build file:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<taskdef name="computeBugHistory" classname="edu.umd.cs.findbugs.anttask.ComputeBugHistoryTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
</pre><p>Attributes for this ant task are listed in the following table.
|
||||
To specify input files, nest them inside with a
|
||||
<code class="literal"><datafile></code> element. For example:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<computeBugHistory home="${findbugs.home}" ...>
|
||||
<datafile name="analyze1.xml"/>
|
||||
<datafile name="analyze2.xml"/>
|
||||
</computeBugHistory>
|
||||
|
||||
</pre><div class="table"><a name="computeBugHistoryTable"></a><p class="title"><b>Table 12.1. Options for computeBugHistory command</b></p><div class="table-contents"><table summary="Options for computeBugHistory command" border="1"><colgroup><col><col><col></colgroup><thead><tr><th align="left">Command-line option</th><th align="left">Ant attribute</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left">-output <file></td><td align="left">output="<file>"</td><td align="left">save output in the named file (may also be an input file)</td></tr><tr><td align="left">-overrideRevisionNames[:truth]</td><td align="left">overrideRevisionNames="[true|false]"</td><td align="left">override revision names for each version with names computed from the filenames</td></tr><tr><td align="left">-noPackageMoves[:truth]</td><td align="left">noPackageMoves="[true|false]"</td><td align="left">if a class has moved to another package, treat warnings in that class as seperate</td></tr><tr><td align="left">-preciseMatch[:truth]</td><td align="left">preciseMatch="[true|false]"</td><td align="left">require bug patterns to match precisely</td></tr><tr><td align="left">-precisePriorityMatch[:truth]</td><td align="left">precisePriorityMatch="[true|false]"</td><td align="left">consider two warnings as the same only if priorities match exactly</td></tr><tr><td align="left">-quiet[:truth]</td><td align="left">quiet="[true|false]"</td><td align="left">don't generate any output to standard out unless there is an error</td></tr><tr><td align="left">-withMessages[:truth]</td><td align="left">withMessages="[true|false]"</td><td align="left">include human-readable messages describing the warnings in XML output</td></tr></tbody></table></div></div><br class="table-break"></div><div class="sect2" title="1.3. filterBugs"><div class="titlepage"><div><div><h3 class="title"><a name="filterBugs"></a>1.3. filterBugs</h3></div></div></div><p>This command is used to select a subset of warnings from a FindBugs XML warning file
|
||||
and write the selected subset to a new FindBugs warning file.</p><p>
|
||||
This command takes a sequence of options, and either zero, one or two
|
||||
filenames of findbugs xml bug files on the command line.</p><p>If no file names are provided, the command reads from standard input
|
||||
and writes to standard output. If one file name is provided,
|
||||
it reads from the file and writes to standard output.
|
||||
If two file names are provided, it reads from the first and writes the output
|
||||
to the second file name.</p><p>This functionality may also can be accessed from ant.
|
||||
First create a taskdef for <span class="command"><strong>filterBugs</strong></span> in your
|
||||
build file:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<taskdef name="filterBugs" classname="edu.umd.cs.findbugs.anttask.FilterBugsTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
</pre><p>Attributes for this ant task are listed in the following table.
|
||||
To specify an input file either use the input attribute or nest it inside
|
||||
the ant call with a <code class="literal"><datafile></code> element. For example:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<filterBugs home="${findbugs.home}" ...>
|
||||
<datafile name="analyze.xml"/>
|
||||
</filterBugs>
|
||||
|
||||
</pre><div class="table"><a name="filterOptionsTable"></a><p class="title"><b>Table 12.2. Options for filterBugs command</b></p><div class="table-contents"><table summary="Options for filterBugs command" border="1"><colgroup><col><col><col></colgroup><thead><tr><th align="left">Command-line option</th><th align="left">Ant attribute</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left"> </td><td align="left">input="<file>"</td><td align="left">use file as input</td></tr><tr><td align="left"> </td><td align="left">output="<file>"</td><td align="left">output results to file</td></tr><tr><td align="left">-not</td><td align="left">not="[true|false]"</td><td align="left">reverse (all) switches for the filter</td></tr><tr><td align="left">-withSource[:truth]</td><td align="left">withSource="[true|false]"</td><td align="left">only warnings for switch source is available</td></tr><tr><td align="left">-exclude <filter file></td><td align="left">exclude="<filter file>"</td><td align="left">exclude bugs matching given filter</td></tr><tr><td align="left">-include <filter file></td><td align="left">include="<filter file>"</td><td align="left">include only bugs matching given filter</td></tr><tr><td align="left">-annotation <text></td><td align="left">annotation="<text>"</td><td align="left">allow only warnings containing this text in a manual annotation</td></tr><tr><td align="left">-after <when></td><td align="left">after="<when>"</td><td align="left">allow only warnings that first occurred after this version</td></tr><tr><td align="left">-before <when></td><td align="left">before="<when>"</td><td align="left">allow only warnings that first occurred before this version</td></tr><tr><td align="left">-first <when></td><td align="left">first="<when>"</td><td align="left">allow only warnings that first occurred in this version</td></tr><tr><td align="left">-last <when></td><td align="left">last="<when>"</td><td align="left">allow only warnings that last occurred in this version</td></tr><tr><td align="left">-fixed <when></td><td align="left">fixed="<when>"</td><td align="left">allow only warnings that last occurred in the previous version (clobbers <code class="option">-last</code>)</td></tr><tr><td align="left">-present <when></td><td align="left">present="<when>"</td><td align="left">allow only warnings present in this version</td></tr><tr><td align="left">-absent <when></td><td align="left">absent="<when>"</td><td align="left">allow only warnings absent in this version</td></tr><tr><td align="left">-active[:truth]</td><td align="left">active="[true|false]"</td><td align="left">allow only warnings alive in the last sequence number</td></tr><tr><td align="left">-introducedByChange[:truth]</td><td align="left">introducedByChange="[true|false]"</td><td align="left">allow only warnings introduced by a change of an existing class</td></tr><tr><td align="left">-removedByChange[:truth]</td><td align="left">removedByChange="[true|false]"</td><td align="left">allow only warnings removed by a change of a persisting class</td></tr><tr><td align="left">-newCode[:truth]</td><td align="left">newCode="[true|false]"</td><td align="left">allow only warnings introduced by the addition of a new class</td></tr><tr><td align="left">-removedCode[:truth]</td><td align="left">removedCode="[true|false]"</td><td align="left">allow only warnings removed by removal of a class</td></tr><tr><td align="left">-priority <level></td><td align="left">priority="<level>"</td><td align="left">allow only warnings with this priority or higher</td></tr><tr><td align="left">-class <pattern></td><td align="left">class="<class>"</td><td align="left">allow only bugs whose primary class name matches this pattern</td></tr><tr><td align="left">-bugPattern <pattern></td><td align="left">bugPattern="<pattern>"</td><td align="left">allow only bugs whose type matches this pattern</td></tr><tr><td align="left">-category <category></td><td align="left">category="<category>"</td><td align="left">allow only warnings with a category that starts with this string</td></tr><tr><td align="left">-designation <designation></td><td align="left">designation="<designation>"</td><td align="left">allow only warnings with this designation (e.g., -designation SHOULD_FIX)</td></tr><tr><td align="left">-withMessages[:truth] </td><td align="left">withMessages="[true|false]"</td><td align="left">the generated XML should contain textual messages</td></tr></tbody></table></div></div><br class="table-break"></div><div class="sect2" title="1.4. mineBugHistory"><div class="titlepage"><div><div><h3 class="title"><a name="mineBugHistory"></a>1.4. mineBugHistory</h3></div></div></div><p>This command generates a table containing counts of the numbers of warnings
|
||||
in each version of a multiversion bug database.</p><p>This functionality may also can be accessed from ant.
|
||||
First create a taskdef for <span class="command"><strong>mineBugHistory</strong></span> in your
|
||||
build file:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<taskdef name="mineBugHistory" classname="edu.umd.cs.findbugs.anttask.MineBugHistoryTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
</pre><p>Attributes for this ant task are listed in the following table.
|
||||
To specify an input file either use the <code class="literal">input</code>
|
||||
attribute or nest it inside the ant call with a
|
||||
<code class="literal"><datafile></code> element. For example:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<mineBugHistory home="${findbugs.home}" ...>
|
||||
<datafile name="analyze.xml"/>
|
||||
</mineBugHistory>
|
||||
|
||||
</pre><div class="table"><a name="mineBugHistoryOptionsTable"></a><p class="title"><b>Table 12.3. Options for mineBugHistory command</b></p><div class="table-contents"><table summary="Options for mineBugHistory command" border="1"><colgroup><col><col><col></colgroup><thead><tr><th align="left">Command-line option</th><th align="left">Ant attribute</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left"> </td><td align="left">input="<file>"</td><td align="left">use file as input</td></tr><tr><td align="left"> </td><td align="left">output="<file>"</td><td align="left">write output to file</td></tr><tr><td align="left">-formatDates</td><td align="left">formatDates="[true|false]"</td><td align="left">render dates in textual form</td></tr><tr><td align="left">-noTabs</td><td align="left">noTabs="[true|false]"</td><td align="left">delimit columns with groups of spaces instead of tabs (see below)</td></tr><tr><td align="left">-summary</td><td align="left">summary="[true|false]"</td><td align="left">output terse summary of changes over the last ten entries</td></tr></tbody></table></div></div><br class="table-break"><p>
|
||||
The <code class="option">-noTabs</code> output can be easier to read from a shell
|
||||
with a fixed-width font.
|
||||
Because numeric columns are right-justified, spaces may precede the
|
||||
first column value. This option also causes <code class="option">-formatDates</code>
|
||||
to render dates in terser format without embedded whitespace.
|
||||
</p><p>The table is a tab-separated (barring <code class="option">-noTabs</code>)
|
||||
table with the following columns:</p><div class="table"><a name="mineBugHistoryColumns"></a><p class="title"><b>Table 12.4. Columns in mineBugHistory output</b></p><div class="table-contents"><table summary="Columns in mineBugHistory output" border="1"><colgroup><col><col></colgroup><thead><tr><th align="left">Title</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left">seq</td><td align="left">Sequence number (successive integers, starting at 0)</td></tr><tr><td align="left">version</td><td align="left">Version name</td></tr><tr><td align="left">time</td><td align="left">Release timestamp</td></tr><tr><td align="left">classes</td><td align="left">Number of classes analyzed</td></tr><tr><td align="left">NCSS</td><td align="left">Non Commenting Source Statements</td></tr><tr><td align="left">added</td><td align="left">Count of new warnings for a class that existed in the previous version</td></tr><tr><td align="left">newCode</td><td align="left">Count of new warnings for a class that did not exist in the previous version</td></tr><tr><td align="left">fixed</td><td align="left">Count of warnings removed from a class that remains in the current version</td></tr><tr><td align="left">removed</td><td align="left">Count of warnings in the previous version for a class that is not present in the current version</td></tr><tr><td align="left">retained</td><td align="left">Count of warnings that were in both the previous and current version</td></tr><tr><td align="left">dead</td><td align="left">Warnings that were present in earlier versions but in neither the current version or the immediately preceeding version</td></tr><tr><td align="left">active</td><td align="left">Total warnings present in the current version</td></tr></tbody></table></div></div><br class="table-break"></div><div class="sect2" title="1.5. defectDensity"><div class="titlepage"><div><div><h3 class="title"><a name="defectDensity"></a>1.5. defectDensity</h3></div></div></div><p>
|
||||
This command lists information about defect density (warnings per 1000 NCSS) for the entire project and each class and package.
|
||||
It can either be invoked with no files specified on the command line (in which case it reads from standard input)
|
||||
or with one file specified on the command line.</p><p>It generates a table with the following columns, and with one
|
||||
row for the entire project, and one row for each package or class that contains at least
|
||||
4 warnings.</p><div class="table"><a name="defectDensityColumns"></a><p class="title"><b>Table 12.5. Columns in defectDensity output</b></p><div class="table-contents"><table summary="Columns in defectDensity output" border="1"><colgroup><col><col></colgroup><thead><tr><th align="left">Title</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left">kind</td><td align="left">project, package or class</td></tr><tr><td align="left">name</td><td align="left">The name of the project, package or class</td></tr><tr><td align="left">density</td><td align="left">Number of warnings generated per 1000 lines of NCSS.</td></tr><tr><td align="left">bugs</td><td align="left">Number of warnings</td></tr><tr><td align="left">NCSS</td><td align="left">Calculated number of NCSS</td></tr></tbody></table></div></div><br class="table-break"></div><div class="sect2" title="1.6. convertXmlToText"><div class="titlepage"><div><div><h3 class="title"><a name="convertXmlToText"></a>1.6. convertXmlToText</h3></div></div></div><p>
|
||||
This command converts a warning collection in XML format to a text
|
||||
format with one line per warning, or to HTML.
|
||||
</p><p>This functionality may also can be accessed from ant.
|
||||
First create a taskdef for <span class="command"><strong>convertXmlToText</strong></span> in your
|
||||
build file:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<taskdef name="convertXmlToText" classname="edu.umd.cs.findbugs.anttask.ConvertXmlToTextTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
</pre><p>Attributes for this ant task are listed in the following table.</p><div class="table"><a name="convertXmlToTextTable"></a><p class="title"><b>Table 12.6. Options for convertXmlToText command</b></p><div class="table-contents"><table summary="Options for convertXmlToText command" border="1"><colgroup><col><col><col></colgroup><thead><tr><th align="left">Command-line option</th><th align="left">Ant attribute</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left"> </td><td align="left">input="<filename>"</td><td align="left">use file as input</td></tr><tr><td align="left"> </td><td align="left">output="<filename>"</td><td align="left">output results to file</td></tr><tr><td align="left">-longBugCodes</td><td align="left">longBugCodes="[true|false]"</td><td align="left">use the full bug pattern code instead of two-letter abbreviation</td></tr><tr><td align="left"> </td><td align="left">format="text"</td><td align="left">generate plain text output with one bug per line (command-line default)</td></tr><tr><td align="left">-html[:stylesheet]</td><td align="left">format="html:<stylesheet>"</td><td align="left">generate output with specified stylesheet (see below), or default.xsl if unspecified</td></tr></tbody></table></div></div><br class="table-break"><p>
|
||||
You may specify plain.xsl, default.xsl, fancy.xsl, fancy-hist.xsl,
|
||||
or your own XSL stylesheet for the -html/format option.
|
||||
Despite the name of this option, you may specify
|
||||
a stylesheet that emits something other than html.
|
||||
When applying a stylesheet other than those included
|
||||
with FindBugs (listed above), the -html/format option should be used
|
||||
with a path or URL to the stylesheet.
|
||||
</p></div><div class="sect2" title="1.7. setBugDatabaseInfo"><div class="titlepage"><div><div><h3 class="title"><a name="setBugDatabaseInfo"></a>1.7. setBugDatabaseInfo</h3></div></div></div><p>
|
||||
This command sets meta-information in a specified warning collection.
|
||||
It takes the following options:
|
||||
</p><p>This functionality may also can be accessed from ant.
|
||||
First create a taskdef for <span class="command"><strong>setBugDatabaseInfo</strong></span> in your
|
||||
build file:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<taskdef name="setBugDatabaseInfo" classname="edu.umd.cs.findbugs.anttask.SetBugDatabaseInfoTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
</pre><p>Attributes for this ant task are listed in the following table.
|
||||
To specify an input file either use the <code class="literal">input</code>
|
||||
attribute or nest it inside the ant call with a
|
||||
<code class="literal"><datafile></code> element. For example:
|
||||
</p><pre class="programlisting">
|
||||
|
||||
<setBugDatabaseInfo home="${findbugs.home}" ...>
|
||||
<datafile name="analyze.xml"/>
|
||||
</setBugDatabaseInfo>
|
||||
|
||||
</pre><div class="table"><a name="setBugDatabaseInfoOptions"></a><p class="title"><b>Table 12.7. setBugDatabaseInfo Options</b></p><div class="table-contents"><table summary="setBugDatabaseInfo Options" border="1"><colgroup><col><col><col></colgroup><thead><tr><th align="left">Command-line option</th><th align="left">Ant attribute</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left"> </td><td align="left">input="<file>"</td><td align="left">use file as input</td></tr><tr><td align="left"> </td><td align="left">output="<file>"</td><td align="left">write output to file</td></tr><tr><td align="left">-name <name></td><td align="left">name="<name>"</td><td align="left">set name for (last) revision</td></tr><tr><td align="left">-timestamp <when></td><td align="left">timestamp="<when>"</td><td align="left">set timestamp for (last) revision</td></tr><tr><td align="left">-source <directory></td><td align="left">source="<directory>"</td><td align="left">add specified directory to the source search path</td></tr><tr><td align="left">-findSource <directory></td><td align="left">findSource="<directory>"</td><td align="left">find and add all relevant source directions contained within specified directory</td></tr><tr><td align="left">-suppress <filter file></td><td align="left">suppress="<filter file>"</td><td align="left">suppress warnings matched by this file (replaces previous suppressions)</td></tr><tr><td align="left">-withMessages</td><td align="left">withMessages="[true|false]"</td><td align="left">add textual messages to XML</td></tr><tr><td align="left">-resetSource</td><td align="left">resetSource="[true|false]"</td><td align="left">remove all source search paths</td></tr></tbody></table></div></div><br class="table-break"></div><div class="sect2" title="1.8. listBugDatabaseInfo"><div class="titlepage"><div><div><h3 class="title"><a name="listBugDatabaseInfo"></a>1.8. listBugDatabaseInfo</h3></div></div></div><p>This command takes a list of zero or more xml bug database filenames on the command line.
|
||||
If zero file names are provided, it reads from standard input and does not generate
|
||||
a table header.</p><p>There is only one option: <code class="option">-formatDates</code> renders dates
|
||||
in textual form.
|
||||
</p><p>The output is a table one row per bug database and the following columns:</p><div class="table"><a name="listBugDatabaseInfoColumns"></a><p class="title"><b>Table 12.8. listBugDatabaseInfo Columns</b></p><div class="table-contents"><table summary="listBugDatabaseInfo Columns" border="1"><colgroup><col><col></colgroup><thead><tr><th align="left">Column</th><th align="left">Meaning</th></tr></thead><tbody><tr><td align="left">version</td><td align="left">version name</td></tr><tr><td align="left">time</td><td align="left">Release timestamp</td></tr><tr><td align="left">classes</td><td align="left">Number of classes analyzed</td></tr><tr><td align="left">NCSS</td><td align="left">Non Commenting Source Statements analyzed</td></tr><tr><td align="left">total</td><td align="left">Total number of warnings of all kinds</td></tr><tr><td align="left">high</td><td align="left">Total number of high priority warnings of all kinds</td></tr><tr><td align="left">medium</td><td align="left">Total number of medium/normal priority warnings of all kinds</td></tr><tr><td align="left">low</td><td align="left">Total number of low priority warnings of all kinds</td></tr><tr><td align="left">filename</td><td align="left">filename of database</td></tr></tbody></table></div></div><br class="table-break"></div></div><div class="sect1" title="2. Examples"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="examples"></a>2. Examples</h2></div></div></div><div class="sect2" title="2.1. Mining history using proveded shell scrips"><div class="titlepage"><div><div><h3 class="title"><a name="unixscriptsexamples"></a>2.1. Mining history using proveded shell scrips</h3></div></div></div><p>In all of the following, the commands are given in a directory that contains
|
||||
directories jdk1.6.0-b12, jdk1.6.0-b13, ..., jdk1.6.0-b60.</p><p>You can use the command:</p><pre class="screen">
|
||||
computeBugHistory jdk1.6.0-b* | filterBugs -bugPattern IL_ | mineBugHistory -formatDates
|
||||
</pre><p>to generate the following output:</p><pre class="screen">
|
||||
seq version time classes NCSS added newCode fixed removed retained dead active
|
||||
0 jdk1.6.0-b12 "Thu Nov 11 09:07:20 EST 2004" 13128 811569 0 4 0 0 0 0 4
|
||||
1 jdk1.6.0-b13 "Thu Nov 18 06:02:06 EST 2004" 13128 811570 0 0 0 0 4 0 4
|
||||
2 jdk1.6.0-b14 "Thu Dec 02 06:12:26 EST 2004" 13145 811786 0 0 2 0 2 0 2
|
||||
3 jdk1.6.0-b15 "Thu Dec 09 06:07:04 EST 2004" 13174 811693 0 0 1 0 1 2 1
|
||||
4 jdk1.6.0-b16 "Thu Dec 16 06:21:28 EST 2004" 13175 811715 0 0 0 0 1 3 1
|
||||
5 jdk1.6.0-b17 "Thu Dec 23 06:27:22 EST 2004" 13176 811974 0 0 0 0 1 3 1
|
||||
6 jdk1.6.0-b19 "Thu Jan 13 06:41:16 EST 2005" 13176 812011 0 0 0 0 1 3 1
|
||||
7 jdk1.6.0-b21 "Thu Jan 27 05:57:52 EST 2005" 13177 812173 0 0 0 0 1 3 1
|
||||
8 jdk1.6.0-b23 "Thu Feb 10 05:44:36 EST 2005" 13179 812188 0 0 0 0 1 3 1
|
||||
9 jdk1.6.0-b26 "Thu Mar 03 06:04:02 EST 2005" 13199 811770 0 0 0 0 1 3 1
|
||||
10 jdk1.6.0-b27 "Thu Mar 10 04:48:38 EST 2005" 13189 812440 0 0 0 0 1 3 1
|
||||
11 jdk1.6.0-b28 "Thu Mar 17 02:54:22 EST 2005" 13185 812056 0 0 0 0 1 3 1
|
||||
12 jdk1.6.0-b29 "Thu Mar 24 03:09:20 EST 2005" 13117 809468 0 0 0 0 1 3 1
|
||||
13 jdk1.6.0-b30 "Thu Mar 31 02:53:32 EST 2005" 13118 809501 0 0 0 0 1 3 1
|
||||
14 jdk1.6.0-b31 "Thu Apr 07 03:00:14 EDT 2005" 13117 809572 0 0 0 0 1 3 1
|
||||
15 jdk1.6.0-b32 "Thu Apr 14 02:56:56 EDT 2005" 13169 811096 0 0 0 0 1 3 1
|
||||
16 jdk1.6.0-b33 "Thu Apr 21 02:46:22 EDT 2005" 13187 811942 0 0 0 0 1 3 1
|
||||
17 jdk1.6.0-b34 "Thu Apr 28 02:49:00 EDT 2005" 13195 813488 0 1 0 0 1 3 2
|
||||
18 jdk1.6.0-b35 "Thu May 05 02:49:04 EDT 2005" 13457 829837 0 0 0 0 2 3 2
|
||||
19 jdk1.6.0-b36 "Thu May 12 02:59:46 EDT 2005" 13462 831278 0 0 0 0 2 3 2
|
||||
20 jdk1.6.0-b37 "Thu May 19 02:55:08 EDT 2005" 13464 831971 0 0 0 0 2 3 2
|
||||
21 jdk1.6.0-b38 "Thu May 26 03:08:16 EDT 2005" 13564 836565 0 0 0 0 2 3 2
|
||||
22 jdk1.6.0-b39 "Fri Jun 03 03:10:48 EDT 2005" 13856 849992 0 1 0 0 2 3 3
|
||||
23 jdk1.6.0-b40 "Thu Jun 09 03:30:28 EDT 2005" 15972 959619 0 2 0 0 3 3 5
|
||||
24 jdk1.6.0-b41 "Thu Jun 16 03:19:22 EDT 2005" 15972 959619 0 0 0 0 5 3 5
|
||||
25 jdk1.6.0-b42 "Fri Jun 24 03:38:54 EDT 2005" 15966 958581 0 0 0 0 5 3 5
|
||||
26 jdk1.6.0-b43 "Thu Jul 14 03:09:34 EDT 2005" 16041 960544 0 0 0 0 5 3 5
|
||||
27 jdk1.6.0-b44 "Thu Jul 21 03:05:54 EDT 2005" 16041 960547 0 0 0 0 5 3 5
|
||||
28 jdk1.6.0-b45 "Thu Jul 28 03:26:10 EDT 2005" 16037 960606 0 0 1 0 4 3 4
|
||||
29 jdk1.6.0-b46 "Thu Aug 04 03:02:48 EDT 2005" 15936 951355 0 0 0 0 4 4 4
|
||||
30 jdk1.6.0-b47 "Thu Aug 11 03:18:56 EDT 2005" 15964 952387 0 0 1 0 3 4 3
|
||||
31 jdk1.6.0-b48 "Thu Aug 18 08:10:40 EDT 2005" 15970 953421 0 0 0 0 3 5 3
|
||||
32 jdk1.6.0-b49 "Thu Aug 25 03:24:38 EDT 2005" 16048 958940 0 0 0 0 3 5 3
|
||||
33 jdk1.6.0-b50 "Thu Sep 01 01:52:40 EDT 2005" 16287 974937 1 0 0 0 3 5 4
|
||||
34 jdk1.6.0-b51 "Thu Sep 08 01:55:36 EDT 2005" 16362 979377 0 0 0 0 4 5 4
|
||||
35 jdk1.6.0-b52 "Thu Sep 15 02:04:08 EDT 2005" 16477 979399 0 0 0 0 4 5 4
|
||||
36 jdk1.6.0-b53 "Thu Sep 22 02:00:28 EDT 2005" 16019 957900 0 0 1 0 3 5 3
|
||||
37 jdk1.6.0-b54 "Thu Sep 29 01:54:34 EDT 2005" 16019 957900 0 0 0 0 3 6 3
|
||||
38 jdk1.6.0-b55 "Thu Oct 06 01:54:14 EDT 2005" 16051 959014 0 0 0 0 3 6 3
|
||||
39 jdk1.6.0-b56 "Thu Oct 13 01:54:12 EDT 2005" 16211 970835 0 0 0 0 3 6 3
|
||||
40 jdk1.6.0-b57 "Thu Oct 20 01:55:26 EDT 2005" 16279 971627 0 0 0 0 3 6 3
|
||||
41 jdk1.6.0-b58 "Thu Oct 27 01:56:30 EDT 2005" 16283 971945 0 0 0 0 3 6 3
|
||||
42 jdk1.6.0-b59 "Thu Nov 03 01:56:58 EST 2005" 16232 972193 0 0 0 0 3 6 3
|
||||
43 jdk1.6.0-b60 "Thu Nov 10 01:54:18 EST 2005" 16235 972346 0 0 0 0 3 6 3
|
||||
</pre><p>
|
||||
We could also generate that information directly, without creating an intermediate db.xml file, using the command
|
||||
</p><pre class="screen">
|
||||
computeBugHistory jdk1.6.0-b*/jre/lib/rt.xml | filterBugs -bugPattern IL_ db.xml | mineBugHistory -formatDates
|
||||
</pre><p>We can then use that information to display a graph showing the number of infinite recursive loops
|
||||
found by FindBugs in each build of Sun's JDK1.6.0. The blue area indicates the number of infinite
|
||||
recursive loops in that build, the red area above it indicates the number of infinite recursive loops that existed
|
||||
in some previous version but not in the current version (thus, the combined height of the red and blue areas
|
||||
is guaranteed to never decrease, and goes up whenever a new infinite recursive loop bug is introduced). The height
|
||||
of the red area is computed as the sum of the fixed, removed and dead values for each version.
|
||||
The reductions in builds 13 and 14 came after Sun was notified about the bugs found by FindBugs in the JDK.
|
||||
</p><div class="mediaobject"><img src="infiniteRecursiveLoops.png"></div><p>
|
||||
Given the db.xml file that contains the results for all the jdk1.6.0 builds, the following command will show the history of high and medium priority correctness warnings:
|
||||
</p><pre class="screen">
|
||||
filterBugs -priority M -category C db.xml | mineBugHistory -formatDates
|
||||
</pre><p>
|
||||
generating the table:
|
||||
</p><pre class="screen">
|
||||
seq version time classes NCSS added newCode fixed removed retained dead active
|
||||
0 jdk1.6.0-b12 "Thu Nov 11 09:07:20 EST 2004" 13128 811569 0 1075 0 0 0 0 1075
|
||||
1 jdk1.6.0-b13 "Thu Nov 18 06:02:06 EST 2004" 13128 811570 0 0 0 0 1075 0 1075
|
||||
2 jdk1.6.0-b14 "Thu Dec 02 06:12:26 EST 2004" 13145 811786 3 0 6 0 1069 0 1072
|
||||
3 jdk1.6.0-b15 "Thu Dec 09 06:07:04 EST 2004" 13174 811693 2 1 3 0 1069 6 1072
|
||||
4 jdk1.6.0-b16 "Thu Dec 16 06:21:28 EST 2004" 13175 811715 0 0 1 0 1071 9 1071
|
||||
5 jdk1.6.0-b17 "Thu Dec 23 06:27:22 EST 2004" 13176 811974 0 0 1 0 1070 10 1070
|
||||
6 jdk1.6.0-b19 "Thu Jan 13 06:41:16 EST 2005" 13176 812011 0 0 0 0 1070 11 1070
|
||||
7 jdk1.6.0-b21 "Thu Jan 27 05:57:52 EST 2005" 13177 812173 0 0 1 0 1069 11 1069
|
||||
8 jdk1.6.0-b23 "Thu Feb 10 05:44:36 EST 2005" 13179 812188 0 0 0 0 1069 12 1069
|
||||
9 jdk1.6.0-b26 "Thu Mar 03 06:04:02 EST 2005" 13199 811770 0 0 2 1 1066 12 1066
|
||||
10 jdk1.6.0-b27 "Thu Mar 10 04:48:38 EST 2005" 13189 812440 1 0 1 1 1064 15 1065
|
||||
11 jdk1.6.0-b28 "Thu Mar 17 02:54:22 EST 2005" 13185 812056 0 0 0 0 1065 17 1065
|
||||
12 jdk1.6.0-b29 "Thu Mar 24 03:09:20 EST 2005" 13117 809468 3 0 8 26 1031 17 1034
|
||||
13 jdk1.6.0-b30 "Thu Mar 31 02:53:32 EST 2005" 13118 809501 0 0 0 0 1034 51 1034
|
||||
14 jdk1.6.0-b31 "Thu Apr 07 03:00:14 EDT 2005" 13117 809572 0 0 0 0 1034 51 1034
|
||||
15 jdk1.6.0-b32 "Thu Apr 14 02:56:56 EDT 2005" 13169 811096 1 1 0 1 1033 51 1035
|
||||
16 jdk1.6.0-b33 "Thu Apr 21 02:46:22 EDT 2005" 13187 811942 3 0 2 1 1032 52 1035
|
||||
17 jdk1.6.0-b34 "Thu Apr 28 02:49:00 EDT 2005" 13195 813488 0 1 0 0 1035 55 1036
|
||||
18 jdk1.6.0-b35 "Thu May 05 02:49:04 EDT 2005" 13457 829837 0 36 2 0 1034 55 1070
|
||||
19 jdk1.6.0-b36 "Thu May 12 02:59:46 EDT 2005" 13462 831278 0 0 0 0 1070 57 1070
|
||||
20 jdk1.6.0-b37 "Thu May 19 02:55:08 EDT 2005" 13464 831971 0 1 1 0 1069 57 1070
|
||||
21 jdk1.6.0-b38 "Thu May 26 03:08:16 EDT 2005" 13564 836565 1 7 2 6 1062 58 1070
|
||||
22 jdk1.6.0-b39 "Fri Jun 03 03:10:48 EDT 2005" 13856 849992 6 39 5 0 1065 66 1110
|
||||
23 jdk1.6.0-b40 "Thu Jun 09 03:30:28 EDT 2005" 15972 959619 7 147 11 0 1099 71 1253
|
||||
24 jdk1.6.0-b41 "Thu Jun 16 03:19:22 EDT 2005" 15972 959619 0 0 0 0 1253 82 1253
|
||||
25 jdk1.6.0-b42 "Fri Jun 24 03:38:54 EDT 2005" 15966 958581 3 0 1 2 1250 82 1253
|
||||
26 jdk1.6.0-b43 "Thu Jul 14 03:09:34 EDT 2005" 16041 960544 5 11 15 8 1230 85 1246
|
||||
27 jdk1.6.0-b44 "Thu Jul 21 03:05:54 EDT 2005" 16041 960547 0 0 0 0 1246 108 1246
|
||||
28 jdk1.6.0-b45 "Thu Jul 28 03:26:10 EDT 2005" 16037 960606 19 0 2 0 1244 108 1263
|
||||
29 jdk1.6.0-b46 "Thu Aug 04 03:02:48 EDT 2005" 15936 951355 13 1 1 32 1230 110 1244
|
||||
30 jdk1.6.0-b47 "Thu Aug 11 03:18:56 EDT 2005" 15964 952387 163 8 7 20 1217 143 1388
|
||||
31 jdk1.6.0-b48 "Thu Aug 18 08:10:40 EDT 2005" 15970 953421 0 0 0 0 1388 170 1388
|
||||
32 jdk1.6.0-b49 "Thu Aug 25 03:24:38 EDT 2005" 16048 958940 1 11 1 0 1387 170 1399
|
||||
33 jdk1.6.0-b50 "Thu Sep 01 01:52:40 EDT 2005" 16287 974937 19 27 16 7 1376 171 1422
|
||||
34 jdk1.6.0-b51 "Thu Sep 08 01:55:36 EDT 2005" 16362 979377 1 15 3 0 1419 194 1435
|
||||
35 jdk1.6.0-b52 "Thu Sep 15 02:04:08 EDT 2005" 16477 979399 0 0 1 1 1433 197 1433
|
||||
36 jdk1.6.0-b53 "Thu Sep 22 02:00:28 EDT 2005" 16019 957900 13 12 16 20 1397 199 1422
|
||||
37 jdk1.6.0-b54 "Thu Sep 29 01:54:34 EDT 2005" 16019 957900 0 0 0 0 1422 235 1422
|
||||
38 jdk1.6.0-b55 "Thu Oct 06 01:54:14 EDT 2005" 16051 959014 1 4 7 0 1415 235 1420
|
||||
39 jdk1.6.0-b56 "Thu Oct 13 01:54:12 EDT 2005" 16211 970835 6 8 37 0 1383 242 1397
|
||||
40 jdk1.6.0-b57 "Thu Oct 20 01:55:26 EDT 2005" 16279 971627 0 0 0 0 1397 279 1397
|
||||
41 jdk1.6.0-b58 "Thu Oct 27 01:56:30 EDT 2005" 16283 971945 0 1 1 0 1396 279 1397
|
||||
42 jdk1.6.0-b59 "Thu Nov 03 01:56:58 EST 2005" 16232 972193 6 0 5 0 1392 280 1398
|
||||
43 jdk1.6.0-b60 "Thu Nov 10 01:54:18 EST 2005" 16235 972346 0 0 0 0 1398 285 1398
|
||||
44 jdk1.6.0-b61 "Thu Nov 17 01:58:42 EST 2005" 16202 971134 2 0 4 0 1394 285 1396
|
||||
</pre></div><div class="sect2" title="2.2. Incremental history maintenance"><div class="titlepage"><div><div><h3 class="title"><a name="incrementalhistory"></a>2.2. Incremental history maintenance</h3></div></div></div><p>
|
||||
If db.xml contains the results of running findbugs over builds b12 - b60, we can update db.xml to include the results of analyzing b61 with the commands:
|
||||
</p><pre class="screen">
|
||||
computeBugHistory -output db.xml db.xml jdk1.6.0-b61/jre/lib/rt.xml
|
||||
</pre></div></div><div class="sect1" title="3. Ant example"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="antexample"></a>3. Ant example</h2></div></div></div><p>
|
||||
Here is a complete ant script example for both running findbugs and running a chain of data-mining tools afterward:
|
||||
</p><pre class="screen">
|
||||
|
||||
<project name="analyze_asm_util" default="findbugs">
|
||||
<!-- findbugs task definition -->
|
||||
<property name="findbugs.home" value="/Users/ben/Documents/workspace/findbugs/findbugs" />
|
||||
<property name="jvmargs" value="-server -Xss1m -Xmx800m -Duser.language=en -Duser.region=EN -Dfindbugs.home=${findbugs.home}" />
|
||||
|
||||
<path id="findbugs.lib">
|
||||
<fileset dir="${findbugs.home}/lib">
|
||||
<include name="findbugs-ant.jar"/>
|
||||
</fileset>
|
||||
</path>
|
||||
|
||||
<taskdef name="findbugs" classname="edu.umd.cs.findbugs.anttask.FindBugsTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
<taskdef name="computeBugHistory" classname="edu.umd.cs.findbugs.anttask.ComputeBugHistoryTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
<taskdef name="setBugDatabaseInfo" classname="edu.umd.cs.findbugs.anttask.SetBugDatabaseInfoTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
<taskdef name="mineBugHistory" classname="edu.umd.cs.findbugs.anttask.MineBugHistoryTask">
|
||||
<classpath refid="findbugs.lib" />
|
||||
</taskdef>
|
||||
|
||||
<!-- findbugs task definition -->
|
||||
<target name="findbugs">
|
||||
<antcall target="analyze" />
|
||||
<antcall target="mine" />
|
||||
</target>
|
||||
|
||||
<!-- analyze task -->
|
||||
<target name="analyze">
|
||||
<!-- run findbugs against asm-util -->
|
||||
<findbugs home="${findbugs.home}"
|
||||
output="xml:withMessages"
|
||||
timeout="90000000"
|
||||
reportLevel="experimental"
|
||||
workHard="true"
|
||||
effort="max"
|
||||
adjustExperimental="true"
|
||||
jvmargs="${jvmargs}"
|
||||
failOnError="true"
|
||||
outputFile="out.xml"
|
||||
projectName="Findbugs"
|
||||
debug="false">
|
||||
<class location="asm-util-3.0.jar" />
|
||||
</findbugs>
|
||||
</target>
|
||||
|
||||
<target name="mine">
|
||||
|
||||
<!-- Set info to the latest analysis -->
|
||||
<setBugDatabaseInfo home="${findbugs.home}"
|
||||
withMessages="true"
|
||||
name="asm-util-3.0.jar"
|
||||
input="out.xml"
|
||||
output="out-rel.xml"/>
|
||||
|
||||
<!-- Checking if history file already exists (out-hist.xml) -->
|
||||
<condition property="mining.historyfile.available">
|
||||
<available file="out-hist.xml"/>
|
||||
</condition>
|
||||
<condition property="mining.historyfile.notavailable">
|
||||
<not>
|
||||
<available file="out-hist.xml"/>
|
||||
</not>
|
||||
</condition>
|
||||
|
||||
<!-- this target is executed if the history file do not exist (first run) -->
|
||||
<antcall target="history-init">
|
||||
<param name="data.file" value="out-rel.xml" />
|
||||
<param name="hist.file" value="out-hist.xml" />
|
||||
</antcall>
|
||||
<!-- else this one is executed -->
|
||||
<antcall target="history">
|
||||
<param name="data.file" value="out-rel.xml" />
|
||||
<param name="hist.file" value="out-hist.xml" />
|
||||
<param name="hist.summary.file" value="out-hist.txt" />
|
||||
</antcall>
|
||||
</target>
|
||||
|
||||
<!-- Initializing history file -->
|
||||
<target name="history-init" if="mining.historyfile.notavailable">
|
||||
<copy file="${data.file}" tofile="${hist.file}" />
|
||||
</target>
|
||||
|
||||
<!-- Computing bug history -->
|
||||
<target name="history" if="mining.historyfile.available">
|
||||
<!-- Merging ${data.file} into ${hist.file} -->
|
||||
<computeBugHistory home="${findbugs.home}"
|
||||
withMessages="true"
|
||||
output="${hist.file}">
|
||||
<dataFile name="${hist.file}"/>
|
||||
<dataFile name="${data.file}"/>
|
||||
</computeBugHistory>
|
||||
|
||||
<!-- Compute history into ${hist.summary.file} -->
|
||||
<mineBugHistory home="${findbugs.home}"
|
||||
formatDates="true"
|
||||
noTabs="true"
|
||||
input="${hist.file}"
|
||||
output="${hist.summary.file}"/>
|
||||
</target>
|
||||
|
||||
</project>
|
||||
|
||||
</pre></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="rejarForAnalysis.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="license.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 11. Using rejarForAnalysis </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 13. License</td></tr></table></div></body></html>
|
||||
112
findbugs/findbugs-2.0.0/doc/manual/eclipse.html
Normal file
@@ -0,0 +1,112 @@
|
||||
<html><head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
|
||||
<title>Chapter 7. Using the FindBugs™ Eclipse plugin</title><meta name="generator" content="DocBook XSL Stylesheets V1.76.1"><link rel="home" href="index.html" title="FindBugs™ Manual"><link rel="up" href="index.html" title="FindBugs™ Manual"><link rel="prev" href="anttask.html" title="Chapter 6. Using the FindBugs™ Ant task"><link rel="next" href="filter.html" title="Chapter 8. Filter Files"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">Chapter 7. Using the <span class="application">FindBugs</span>™ Eclipse plugin</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="anttask.html">Prev</a> </td><th width="60%" align="center"> </th><td width="20%" align="right"> <a accesskey="n" href="filter.html">Next</a></td></tr></table><hr></div><div class="chapter" title="Chapter 7. Using the FindBugs™ Eclipse plugin"><div class="titlepage"><div><div><h2 class="title"><a name="eclipse"></a>Chapter 7. Using the <span class="application">FindBugs</span>™ Eclipse plugin</h2></div></div></div><div class="toc"><p><b>Table of Contents</b></p><dl><dt><span class="sect1"><a href="eclipse.html#d0e1636">1. Requirements</a></span></dt><dt><span class="sect1"><a href="eclipse.html#d0e1644">2. Installation</a></span></dt><dt><span class="sect1"><a href="eclipse.html#d0e1691">3. Using the Plugin</a></span></dt><dt><span class="sect1"><a href="eclipse.html#d0e1722">4. Extending the Eclipse Plugin (since 2.0.0)</a></span></dt><dt><span class="sect1"><a href="eclipse.html#d0e1776">5. Troubleshooting</a></span></dt></dl></div><p>
|
||||
The FindBugs Eclipse plugin allows <span class="application">FindBugs</span> to be used within
|
||||
the <a class="ulink" href="http://www.eclipse.org/" target="_top">Eclipse</a> IDE.
|
||||
The FindBugs Eclipse plugin was generously contributed by Peter Friese.
|
||||
Phil Crosby and Andrei Loskutov contributed major improvements
|
||||
to the plugin.
|
||||
</p><div class="sect1" title="1. Requirements"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1636"></a>1. Requirements</h2></div></div></div><p>
|
||||
To use the <span class="application">FindBugs</span> Plugin for Eclipse, you need Eclipse 3.3 or later,
|
||||
and JRE/JDK 1.5 or later.
|
||||
</p></div><div class="sect1" title="2. Installation"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1644"></a>2. Installation</h2></div></div></div><p>
|
||||
We provide update sites that allow you to automatically install FindBugs into Eclipse and also query and install updates.
|
||||
There are three different update sites</p><div class="variablelist" title="FindBugs Eclipse update sites"><p class="title"><b>FindBugs Eclipse update sites</b></p><dl><dt><span class="term"><a class="ulink" href="http://findbugs.cs.umd.edu/eclipse/" target="_top">http://findbugs.cs.umd.edu/eclipse/</a></span></dt><dd><p>
|
||||
Only provides official releases of FindBugs.
|
||||
</p></dd><dt><span class="term"><a class="ulink" href="http://findbugs.cs.umd.edu/eclipse-candidate/" target="_top">http://findbugs.cs.umd.edu/eclipse-candidate/</a></span></dt><dd><p>
|
||||
Provides official releases and release candidates of FindBugs.
|
||||
</p></dd><dt><span class="term"><a class="ulink" href="http://findbugs.cs.umd.edu/eclipse-daily/" target="_top">http://findbugs.cs.umd.edu/eclipse-daily/</a></span></dt><dd><p>
|
||||
Provides the daily build of FindBugs. No testing other than that it compiles.
|
||||
</p></dd></dl></div><p>You can also manually
|
||||
download the plugin from the following link:
|
||||
<a class="ulink" href="http://prdownloads.sourceforge.net/findbugs/edu.umd.cs.findbugs.plugin.eclipse_2.0.0.20111220.zip?download" target="_top">http://prdownloads.sourceforge.net/findbugs/edu.umd.cs.findbugs.plugin.eclipse_2.0.0.20111220.zip?download</a>.
|
||||
Extract it in Eclipse's "plugins" subdirectory.
|
||||
(So <eclipse_install_dir>/plugins/edu.umd.cs.findbugs.plugin.eclipse_2.0.0.20111220/findbugs.png
|
||||
should be the path to the <span class="application">FindBugs</span> logo.)
|
||||
|
||||
</p><p>
|
||||
Once the plugin is extracted, start Eclipse and choose
|
||||
<span class="guimenu">Help</span> → <span class="guimenuitem">About Eclipse Platform</span> → <span class="guimenuitem">Plug-in Details</span>.
|
||||
You should find a plugin called "FindBugs Plug-in" provided by "FindBugs Project".
|
||||
</p></div><div class="sect1" title="3. Using the Plugin"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1691"></a>3. Using the Plugin</h2></div></div></div><p>
|
||||
To get started, right click on a Java project in Package Explorer,
|
||||
and select the option labeled "Find Bugs".
|
||||
<span class="application">FindBugs</span> will run, and problem markers (displayed in source
|
||||
windows, and also in the Eclipse Problems view) will point to
|
||||
locations in your code which have been identified as potential instances
|
||||
of bug patterns.
|
||||
</p><p>
|
||||
You can also run <span class="application">FindBugs</span> on existing java archives (jar, ear, zip, war etc). Simply
|
||||
create an empty Java project and attach archives to the project classpath. Having that, you
|
||||
can now right click the archive node in Package Explorer and select the option labeled
|
||||
"Find Bugs". If you additionally configure the source code locations for the binaries,
|
||||
<span class="application">FindBugs</span> will also link the generated warnings to the right source files.
|
||||
</p><p>
|
||||
You may customize how <span class="application">FindBugs</span> runs by opening the Properties
|
||||
dialog for a Java project, and choosing the "Findbugs" property page.
|
||||
Options you may choose include:
|
||||
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>
|
||||
Enable or disable the "Run FindBugs Automatically" checkbox.
|
||||
When enabled, FindBugs will run every time you modify a Java class
|
||||
within the project.
|
||||
</p></li><li class="listitem"><p>
|
||||
Choose minimum warning priority and enabled bug categories.
|
||||
These options will choose which warnings are shown.
|
||||
For example, if you select the "Medium" warning priority,
|
||||
only Medium and High priority warnings will be shown.
|
||||
Similarly, if you uncheck the "Style" checkbox, no warnings
|
||||
in the Style category will be displayed.
|
||||
</p></li><li class="listitem"><p>
|
||||
Select detectors. The table allows you to select which detectors
|
||||
you want to enable for your project.
|
||||
</p></li></ul></div></div><div class="sect1" title="4. Extending the Eclipse Plugin (since 2.0.0)"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1722"></a>4. Extending the Eclipse Plugin (since 2.0.0)</h2></div></div></div><p>
|
||||
Eclipse plugin supports contribution of custom <span class="application">FindBugs</span> detectors (see also
|
||||
<a class="ulink" href="http://code.google.com/p/findbugs/source/browse/trunk/findbugs/src/doc/AddingDetectors.txt" target="_top">AddingDetectors.txt</a>
|
||||
for more information). There are two ways to contribute custom plugins to the Eclipse:
|
||||
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>
|
||||
Existing standard <span class="application">FindBugs</span> detector packages can be configured via
|
||||
<span class="guimenu">Window</span> → <span class="guimenuitem">Preferences</span> → <span class="guimenuitem">Java</span> → <span class="guimenuitem"><span class="application">FindBugs</span></span> → <span class="guimenuitem">Misc. Settings</span> → <span class="guimenuitem">Custom Detectors</span>.
|
||||
Simply specify there locations of any additional plugin libraries.
|
||||
</p><p>
|
||||
The benefit of this solution is that already existing detector packages can be
|
||||
used "as is", and that you can quickly verify the quality of third party detectors.
|
||||
The drawback is that you have to apply this settings in each
|
||||
new Eclipse workspace, and this settings can't be shared between team members.
|
||||
</p></li><li class="listitem"><p>
|
||||
It is possible to contribute custom detectors via standard Eclipse extensions mechanism.
|
||||
</p><p>
|
||||
Please check the documentation of the
|
||||
<a class="ulink" href="http://code.google.com/p/findbugs/source/browse/trunk/eclipsePlugin/schema/detectorPlugins.exsd" target="_top">
|
||||
findBugsEclipsePlugin/schema/detectorPlugins.exsd</a>
|
||||
extension point how to update the plugin.xml. Existing <span class="application">FindBugs</span> detector plugins can
|
||||
be easily "extended" to be full featured <span class="application">FindBugs</span> AND Eclipse detector plugins.
|
||||
Usually you only need to add META-INF/MANIFEST.MF and plugin.xml to the jar and
|
||||
update your build scripts to not to override the MANIFEST.MF during the build.
|
||||
</p><p>
|
||||
The benefit of this solution is that for given (shared) Eclipse installation
|
||||
each team member has exactly same detectors set, and there is no need to configure
|
||||
anything anymore. The (really small) precondition
|
||||
is that you have to convert your existing detectors package to the valid
|
||||
Eclipse plugin. You can do this even for third-party detector packages.
|
||||
Another major differentiator is the ability to extend the default FindBugs
|
||||
classpath at runtime with required third party libraries (see
|
||||
<a class="ulink" href="http://code.google.com/p/findbugs/source/browse/trunk/findbugs/src/doc/AddingDetectors.txt" target="_top">AddingDetectors.txt</a>
|
||||
for more information).
|
||||
</p></li></ul></div></div><div class="sect1" title="5. Troubleshooting"><div class="titlepage"><div><div><h2 class="title" style="clear: both"><a name="d0e1776"></a>5. Troubleshooting</h2></div></div></div><p>
|
||||
This section lists common problems with the plugin and (if known) how to resolve them.
|
||||
</p><div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem"><p>
|
||||
If you see OutOfMemory error dialogs after starting <span class="application">FindBugs</span> analysis in Eclipse,
|
||||
please increase JVM available memory: change eclipse.ini and add the lines below
|
||||
to the end of the file:
|
||||
</p><pre class="programlisting">
|
||||
-vmargs
|
||||
-Xmx1000m
|
||||
</pre><p>
|
||||
Important: the configuration arguments starting with the line "-vmargs" must
|
||||
be last lines in the eclipse.ini file, and only one argument per line is allowed!
|
||||
</p></li><li class="listitem"><p>
|
||||
If you do not see any <span class="application">FindBugs</span> problem markers (in your source
|
||||
windows or in the Problems View), you may need to change your
|
||||
Problems View filter settings. See
|
||||
<a class="ulink" href="http://findbugs.sourceforge.net/FAQ.html#q7" target="_top">http://findbugs.sourceforge.net/FAQ.html#q7</a> for more information.
|
||||
</p></li></ul></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="anttask.html">Prev</a> </td><td width="20%" align="center"> </td><td width="40%" align="right"> <a accesskey="n" href="filter.html">Next</a></td></tr><tr><td width="40%" align="left" valign="top">Chapter 6. Using the <span class="application">FindBugs</span>™ <span class="application">Ant</span> task </td><td width="20%" align="center"><a accesskey="h" href="index.html">Home</a></td><td width="40%" align="right" valign="top"> Chapter 8. Filter Files</td></tr></table></div></body></html>
|
||||
BIN
findbugs/findbugs-2.0.0/doc/manual/example-code.png
Normal file
|
After Width: | Height: | Size: 17 KiB |
BIN
findbugs/findbugs-2.0.0/doc/manual/example-details.png
Normal file
|
After Width: | Height: | Size: 52 KiB |
BIN
findbugs/findbugs-2.0.0/doc/manual/example.png
Normal file
|
After Width: | Height: | Size: 17 KiB |