?? manual.xml
字號(hào):
<varlistentry> <term><literal>quietErrors</literal></term> <listitem> <para> An optional boolean attribute. If true, reports of serious analysis errors and missing classes will be suppressed in the &FindBugs; output. Default is false. </para> </listitem> </varlistentry> <varlistentry> <term><literal>reportLevel</literal></term> <listitem> <para> 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. </para> </listitem> </varlistentry> <varlistentry> <term><literal>output</literal></term> <listitem> <para> 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 <ulink url="http://www.gnu.org/software/emacs/">Emacs</ulink> error message format. If set to "xdocs", output is xdoc XML for use with Apache Maven. </para> </listitem> </varlistentry> <varlistentry> <term><literal>stylesheet</literal></term> <listitem> <para> 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. </para> </listitem> </varlistentry> <varlistentry> <term><literal>sort</literal></term> <listitem> <para> Optional attribute. If the <literal>output</literal> attribute is set to "text", then the <literal>sort</literal> attribute specifies whether or not reported bugs are sorted by class. Default is true. </para> </listitem> </varlistentry> <varlistentry> <term><literal>outputFile</literal></term> <listitem> <para> Optional attribute. If specified, names the output file in which the &FindBugs; output will be saved. By default, the output is displayed directly by &Ant;. </para> </listitem> </varlistentry> <varlistentry> <term><literal>debug</literal></term> <listitem> <para> Optional boolean attribute. If set to true, &FindBugs; prints diagnostic information about which classes are being analyzed, and which bug pattern detectors are being run. Default is false. </para> </listitem> </varlistentry> <varlistentry> <term><literal>effort</literal></term> <listitem> <para> Set the analysis effort level. The value specified should be one of <literal>min</literal>, <literal>default</literal>, or <literal>max</literal>. See <xref linkend="commandLineOptions"/> for more information about setting the analysis level. </listitem> </varlistentry> <varlistentry> <term><literal>conserveSpace</literal></term> <listitem> <para>Synonym for effort="min".</para> </listitem> </varlistentry> <varlistentry> <term><literal>workHard</literal></term> <listitem> <para>Synonym for effort="max".</para> </listitem> </varlistentry> <varlistentry> <term><literal>visitors</literal></term> <listitem> <para> 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. </para> </listitem> </varlistentry> <varlistentry> <term><literal>omitVisitors</literal></term> <listitem> <para> Optional attribute. It is like the <literal>visitors</literal> attribute, except it specifies detectors which will <emphasis>not</emphasis> be run. </para> </listitem> </varlistentry> <varlistentry> <term><literal>excludeFilter</literal></term> <listitem> <para> Optional attribute. It specifies the filename of a filter specifying bugs to exclude from being reported. See <xref linkend="filter" />. </para> </listitem> </varlistentry> <varlistentry> <term><literal>includeFilter</literal></term> <listitem> <para> Optional attribute. It specifies the filename of a filter specifying which bugs are reported. See <xref linkend="filter" />. </para> </listitem> </varlistentry> <varlistentry> <term><literal>projectFile</literal></term> <listitem> <para> Optional attribute. It specifies the name of a project file. Project files are created by the &FindBugs; GUI, and specify classes, aux classpath entries, and source directories. By naming a project, you don't need to specify any <literal>class</literal> elements, nor do you need to specify <literal>auxClasspath</literal> or <literal>sourcePath</literal> attributes. See <xref linkend="running"/> for how to create a project. </para> </listitem> </varlistentry> <varlistentry> <term><literal>jvmargs</literal></term> <listitem> <para> Optional attribute. It specifies any arguments that should be passed to the Java virtual machine used to run &FindBugs;. 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. </para> </listitem> </varlistentry> <varlistentry> <term><literal>systemProperty</literal></term> <listitem> <para> Optional nested element. If specified, defines a system property. The <literal>name</literal> attribute specifies the name of the system property, and the <literal>value</literal> attribute specifies the value of the system property. </para> </listitem> </varlistentry> <varlistentry> <term><literal>timeout</literal></term> <listitem> <para> Optional attribute. It specifies the amount of time, in milliseconds, that the Java process executing &FindBugs; 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, &FindBugs; may require more than ten minutes to complete its analysis. </para> </listitem> </varlistentry> <varlistentry> <term><literal>failOnError</literal></term> <listitem> <para> Optional boolean attribute. Whether to abort the build process if there is an error running &FindBugs;. Defaults to "false" </para> </listitem> </varlistentry> <varlistentry> <term><literal>errorProperty</literal></term> <listitem> <para> Optional attribute which specifies the name of a property that will be set to "true" if an error occurs while running &FindBugs;. </para> </listitem> </varlistentry> <varlistentry> <term><literal>warningsProperty</literal></term> <listitem> <para> Optional attribute which specifies the name of a property that will be set to "true" if any warnings are reported by &FindBugs; on the analyzed program. </para> </listitem> </varlistentry></variablelist></para><!----></sect1></chapter><!-- ************************************************************************** Using the FindBugs Eclipse plugin **************************************************************************--><chapter id="eclipse"><title>Using the &FindBugs;™ Eclipse plugin</title><para>The FindBugs Eclipse plugin allows &FindBugs; to be used withinthe <ulink url="http://www.eclipse.org/">Eclipse</ulink> IDE.The FindBugs Eclipse plugin was generously contributed by Peter Friese.Phil Crosby and Andrei Loskutov contributed major improvementsto the plugin.</para><sect1><title>Requirements</title><para>To use the &FindBugs; Plugin for Eclipse, you need Eclipse 3.3 or later,and JRE/JDK 1.5 or later.</para></sect1><sect1><title>Installation</title><para> 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</para> <variablelist><title>FindBugs Eclipse update sites</title> <varlistentry><term><ulink url="http://findbugs.cs.umd.edu/eclipse/">http://findbugs.cs.umd.edu/eclipse/</ulink></term> <listitem> <para> Only provides official releases of FindBugs. </para> </listitem> </varlistentry> <varlistentry><term><ulink url="http://findbugs.cs.umd.edu/eclipse-candidate/">http://findbugs.cs.umd.edu/eclips-candidate/</ulink></term> <listitem> <para> Provides official releases and release candidates of FindBugs. </para> </listitem> </varlistentry> <varlistentry><term><ulink url="http://findbugs.cs.umd.edu/eclipse-daily/">http://findbugs.cs.umd.edu/eclipse-daily/</ulink></term> <listitem> <para> Provides the daily build of FindBugs. No testing other than that it compiles. </para> </listitem> </varlistentry> </variablelist> <para>You can also manuallydownload the plugin from the following link:<ulink url="http://prdownloads.sourceforge.net/findbugs/edu.umd.cs.findbugs.plugin.eclipse_1.3.8.20090315.zip?download">http://prdownloads.sourceforge.net/findbugs/edu.umd.cs.findbugs.plugin.eclipse_1.3.8.20090315.zip?download</ulink>.Extract it in Eclipse's "plugins" subdirectory.(So <eclipse_install_dir>/plugins/edu.umd.cs.findbugs.plugin.eclipse_1.3.8.20090315/findbugs.pngshould be the path to the &FindBugs; logo.)</para><para>Once the plugin is extracted, start Eclipse and choose<menuchoice> <guimenu>Help</guimenu> <guimenuitem>About Eclipse Platform</guimenuitem> <guimenuitem>Plug-in Details</guimenuitem></menuchoice>.You should find a plugin called "FindBugs Plug-in" provided by "FindBugs Project".</para></sect1><sect1><title>Using the Plugin</title><para>To get started, right click on a Java project,and select the option labeled "Find Bugs".&FindBugs; will run, and problem markers (displayed in sourcewindows, and also in the Eclipse Problems view) will point tolocations in your code which have been identified as potential instancesof bug patterns.</para><para>You may customize how &FindBugs; runs by opening the Propertiesdialog for a Java project, and choosing the "Findbugs" property page.Options you may choose include:</para><itemizedlist> <listitem> <para> Enable or disable the "Run FindBugs Automatically" checkbox. When enabled, FindBugs will run every time you modify a Java class within the project. </para> </listitem> <listitem> <para> 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. </para> </listitem> <listitem> <para> Select detectors. The table allows you to select which detectors you want to enable for your project. </para> </listitem></itemizedlist></sect1><sect1><title>Troubleshooting</title><para>The &FindBugs; Eclipse plugin is still experimental. This sectionlists common problems with the plugin and (if known) how to resolve them.</para><itemizedlist> <listitem> <para> If you do not see any &FindBugs; problem markers (in your source windows or in the Problems View), you may need to change your Problems View filter settings. See <ulink url="http://findbugs.sourceforge.net/FAQ.html#q7">http://findbugs.sourceforge.net/FAQ.html#q7</ulink> for more information. </para> </listitem></itemizedlist></sect1></chapter><!-- ************************************************************************** Filter files **************************************************************************--><chapter id="filter"><title>Filter Files</title><para>Filter files may be used to include or exclude bug reports for particular classesand methods. This chapter explains how to use filter files.<note><title>Planned Features</title><para>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -