edu.umd.cs.findbugs
public class FindBugs extends Object implements Constants2, ExitCodes, IFindBugsEngine
Field Summary | |
---|---|
static boolean | DEBUG |
static AnalysisFeatureSetting[] | DEFAULT_EFFORT |
static Set<String> | knownURLProtocolSet
Known URL protocols.
|
static AnalysisFeatureSetting[] | LESS_EFFORT |
static AnalysisFeatureSetting[] | MAX_EFFORT |
static AnalysisFeatureSetting[] | MIN_EFFORT |
static AnalysisFeatureSetting[] | MORE_EFFORT |
static boolean | TIMEDEBUG |
static int | TIMEQUANTUM |
Constructor Summary | |
---|---|
FindBugs()
Constructor.
| |
FindBugs(BugReporter bugReporter, Project project)
Constructor.
|
Method Summary | |
---|---|
void | addClassObserver(IClassObserver classObserver) |
void | addFilter(String filterFileName, boolean include) |
static void | configureBugCollection(IFindBugsEngine findBugs)
Configure the BugCollection (if the BugReporter being used
is constructing one).
|
static void | configureFilter(DelegatingBugReporter bugReporter, String filterFileName, boolean include) |
static void | configureTrainingDatabases(IFindBugsEngine findBugs)
Configure training databases.
|
boolean | emitTrainingOutput() |
void | enableTrainingInput(String trainingInputDir) |
void | enableTrainingOutput(String trainingOutputDir) |
void | execute() |
int | getBugCount() |
BugReporter | getBugReporter() |
String | getCurrentClass() |
int | getErrorCount() |
static String | getHome()
Get the FindBugs home directory. |
int | getMissingClassCount() |
Project | getProject() |
String | getProjectName() |
String | getReleaseName() |
String | getTrainingInputDir() |
String | getTrainingOutputDir() |
UserPreferences | getUserPreferences() |
static boolean | isDetectorEnabled(IFindBugsEngine findBugs, DetectorFactory factory)
Determing whether or not given DetectorFactory should be enabled.
|
static void | main(String[] argv) |
static void | processCommandLine(TextUICommandLine commandLine, String[] argv, IFindBugsEngine findBugs)
Process the command line.
|
void | setAbridgedMessages(boolean xmlWithAbridgedMessages) |
void | setAnalysisFeatureSettings(AnalysisFeatureSetting[] settingList) |
void | setBugReporter(BugReporter bugReporter) |
void | setClassScreener(IClassScreener classScreener) |
void | setDetectorFactoryCollection(DetectorFactoryCollection detectorFactoryCollection) |
static void | setHome(String home)
Set the FindBugs home directory. |
void | setProgressCallback(FindBugsProgress progressCallback) |
void | setProject(Project project) |
void | setProjectName(String projectName) |
void | setRelaxedReportingMode(boolean relaxedReportingMode) |
void | setReleaseName(String releaseName) |
void | setScanNestedArchives(boolean scanNestedArchives) |
void | setSourceInfoFile(String sourceInfoFile) |
void | setUserPreferences(UserPreferences userPreferences) |
static void | showCommandLineOptions()
Print command line options synopses to stdout. |
static void | showCommandLineOptions(TextUICommandLine commandLine) |
static void | showSynopsis() |
boolean | useTrainingInput() |
Parameters: bugReporter the BugReporter object that will be used to report BugInstance objects, analysis errors, class to source mapping, etc. project the Project indicating which files to analyze and the auxiliary classpath to use; note that the FindBugs object will create a private copy of the Project object
Parameters: findBugs the IFindBugsEngine
Throws: IOException
Parameters: findBugs the IFindBugsEngine factory the DetectorFactory
Returns: true if the DetectorFactory should be enabled, false otherwise
Parameters: commandLine the TextUICommandLine object which will parse the command line argv the command line arguments findBugs the IFindBugsEngine to configure
Throws: IOException FilterException