forked from phoedos/pmd
Integrate PMD v3.9
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@4954 51baf565-9d33-0410-a72c-fc3788e3496d
This commit is contained in:
@ -1,9 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<classpath>
|
||||
<classpathentry kind="src" path="src"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/jakarta-oro-2.0.8.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/backport-util-concurrent.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/asm-3.0.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/pmd-3.9.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/jaxen-1.1-beta-10.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/pmd-3.8.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/xercesImpl-2.6.2.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/xmlParserAPIs-2.6.2.jar"/>
|
||||
<classpathentry exported="true" kind="lib" path="lib/castor-0.9.6-xml.jar"/>
|
||||
|
@ -3,7 +3,10 @@ bin.includes = plugin.xml,\
|
||||
doc.zip,\
|
||||
schema/,\
|
||||
lib/,\
|
||||
pmd-core.jar
|
||||
pmd-core.jar,\
|
||||
lib/pmd-3.9.jar,\
|
||||
lib/asm-3.0.jar,\
|
||||
lib/backport-util-concurrent.jar
|
||||
src.includes = plugin.xml,\
|
||||
schema/,\
|
||||
toc.xml
|
||||
|
BIN
pmd-eclipse-pmd/lib/asm-3.0.jar
Normal file
BIN
pmd-eclipse-pmd/lib/asm-3.0.jar
Normal file
Binary file not shown.
BIN
pmd-eclipse-pmd/lib/backport-util-concurrent.jar
Normal file
BIN
pmd-eclipse-pmd/lib/backport-util-concurrent.jar
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
pmd-eclipse-pmd/lib/pmd-3.9.jar
Normal file
BIN
pmd-eclipse-pmd/lib/pmd-3.9.jar
Normal file
Binary file not shown.
@ -3,7 +3,7 @@
|
||||
<plugin
|
||||
id="net.sourceforge.pmd.core"
|
||||
name="PMD For Eclipse Core Plug-in"
|
||||
version="3.8.0"
|
||||
version="3.9.0"
|
||||
provider-name="PMD Development Team"
|
||||
class="net.sourceforge.pmd.core.PMDCorePlugin">
|
||||
|
||||
@ -11,13 +11,16 @@
|
||||
<library name="pmd-core.jar">
|
||||
<export name="*"/>
|
||||
</library>
|
||||
<library name="lib/jakarta-oro-2.0.8.jar">
|
||||
<library name="lib/pmd-3.9.jar">
|
||||
<export name="*"/>
|
||||
</library>
|
||||
<library name="lib/jaxen-1.1-beta-10.jar">
|
||||
<export name="*"/>
|
||||
</library>
|
||||
<library name="lib/pmd-3.8.jar">
|
||||
<library name="lib/asm-3.0.jar">
|
||||
<export name="*"/>
|
||||
</library>
|
||||
<library name="lib/backport-util-concurrent.jar">
|
||||
<export name="*"/>
|
||||
</library>
|
||||
<library name="lib/xercesImpl-2.6.2.jar">
|
||||
|
@ -45,6 +45,7 @@ import org.eclipse.core.runtime.CoreException;
|
||||
import org.eclipse.core.runtime.IStatus;
|
||||
import org.eclipse.core.runtime.Plugin;
|
||||
import org.eclipse.core.runtime.Status;
|
||||
import org.osgi.framework.Bundle;
|
||||
|
||||
/**
|
||||
* The plugin class for the Core PMD Plugin.
|
||||
@ -53,19 +54,20 @@ import org.eclipse.core.runtime.Status;
|
||||
* @version $Revision$
|
||||
*
|
||||
* $Log$
|
||||
* Revision 1.4 2006/06/20 21:04:49 phherlin
|
||||
* Enable PMD and fix error level violations
|
||||
*
|
||||
* Revision 1.3 2006/04/10 20:58:18 phherlin
|
||||
* Update to PMD 3.6
|
||||
*
|
||||
* Revision 1.2 2005/07/02 14:33:05 phherlin
|
||||
* Implement the RuleSets extension point
|
||||
*
|
||||
* Revision 1.1 2005/06/07 22:39:57 phherlin
|
||||
* Implementing extra ruleset declaration
|
||||
*
|
||||
*
|
||||
* Revision 1.5 2007/01/18 20:58:27 phherlin
|
||||
* Integrate PMD v3.9
|
||||
* Revision 1.4 2006/06/20 21:04:49 phherlin Enable
|
||||
* PMD and fix error level violations
|
||||
*
|
||||
* Revision 1.3 2006/04/10 20:58:18 phherlin Update to PMD 3.6
|
||||
*
|
||||
* Revision 1.2 2005/07/02 14:33:05 phherlin Implement the RuleSets extension
|
||||
* point
|
||||
*
|
||||
* Revision 1.1 2005/06/07 22:39:57 phherlin Implementing extra ruleset
|
||||
* declaration
|
||||
*
|
||||
*
|
||||
*/
|
||||
public class PMDCorePlugin extends Plugin {
|
||||
private static PMDCorePlugin pluginInstance; // NOPMD:AssignmentToNonFinalStatic
|
||||
@ -80,35 +82,42 @@ public class PMDCorePlugin extends Plugin {
|
||||
this.registerStandardRuleSets();
|
||||
this.registerAdditionalRuleSets();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Get the plugin instance
|
||||
*
|
||||
* @return the plugin instance
|
||||
*/
|
||||
public static PMDCorePlugin getDefault() {
|
||||
return pluginInstance;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return the ruleset manager instance
|
||||
*/
|
||||
public final IRuleSetManager getRuleSetManager() {
|
||||
return this.ruleSetManager;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Logs inside the Eclipse environment
|
||||
*
|
||||
* @param severity the severity of the log (IStatus code)
|
||||
* @param message the message to log
|
||||
* @param t a possible throwable, may be null
|
||||
*/
|
||||
public final void log(final int severity, final String message, final Throwable t) {
|
||||
this.getLog().log(new Status(severity, getBundle().getSymbolicName(), 0, message, t));
|
||||
Bundle bundle = getBundle();
|
||||
if (bundle != null) {
|
||||
getLog().log(new Status(severity, bundle.getSymbolicName(), 0, message, t));
|
||||
}
|
||||
|
||||
// TODO : when bundle is not created yet (ie at startup), we cannot log ; find a way to log.
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Registering the standard rulesets
|
||||
*
|
||||
*
|
||||
*/
|
||||
private void registerStandardRuleSets() {
|
||||
final RuleSetFactory factory = new RuleSetFactory();
|
||||
@ -124,9 +133,9 @@ public class PMDCorePlugin extends Plugin {
|
||||
}
|
||||
|
||||
/**
|
||||
* Register additional rulesets that may be provided by a fragment.
|
||||
* Find extension points implementation and call them
|
||||
*
|
||||
* Register additional rulesets that may be provided by a fragment. Find
|
||||
* extension points implementation and call them
|
||||
*
|
||||
*/
|
||||
private void registerAdditionalRuleSets() {
|
||||
try {
|
||||
|
@ -42,6 +42,9 @@ package net.sourceforge.pmd.core;
|
||||
* @version $Revision$
|
||||
*
|
||||
* $Log$
|
||||
* Revision 1.7 2007/01/18 20:58:27 phherlin
|
||||
* Integrate PMD v3.9
|
||||
*
|
||||
* Revision 1.6 2006/10/06 17:07:39 phherlin
|
||||
* Upgrade to PMD v3.8
|
||||
*
|
||||
@ -85,6 +88,7 @@ public class PluginConstants {
|
||||
"rulesets/strictexception.xml",
|
||||
"rulesets/strings.xml",
|
||||
"rulesets/sunsecure.xml",
|
||||
"rulesets/typeresolution.xml",
|
||||
"rulesets/unusedcode.xml"};
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user