5858 Commits

Author SHA1 Message Date
5f847aa32d 'clean' target also cleans stuff in features and plugins subdirectories
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6521 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 21:41:41 +00:00
e8395fa5f9 version update
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6520 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 20:43:08 +00:00
9b33f0af3a code cleanup: plugin activator renamed PMDPlugin and all older PMD<xxx>Plugin classes removed
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6519 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 20:34:37 +00:00
a5ce52e470 code cleanup
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6518 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 20:00:51 +00:00
4a60b812ec all rule examples displayed in Rule Configuration panel
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6517 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 19:47:12 +00:00
0f181d80e1 code cleanup: extra '[' in <![CDATA[ removed
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6516 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 19:10:25 +00:00
67c81944b8 code cleanup (deprecated calls and optimization):
PMD report is only created once and reused by all renderers


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6514 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 18:45:19 +00:00
eabf55cf2e code cleanup
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6513 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 18:13:32 +00:00
342af0e915 ignores updated
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6512 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 17:31:26 +00:00
328a6b9ef4 eclipse version defaults updated to ganymede-SR1 ones
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6511 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 17:29:57 +00:00
5a15f05ffb code cleanup: serial warnings removed, unused locals and fields, deprecated calls
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6510 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 17:24:10 +00:00
ac71bd22e5 eclipse plugin reorganization: feature renamed net.sourceforge.pmd.eclipse as update
site doesn't work with net.sourceforge.pmd.eclipse.feature


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6509 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 06:41:36 +00:00
18757bc8e5 new version: 3.2.5.v200809252215 to be used to test plugin. It will be available
in eclipse.beta update site:

  http://pmd.sourceforge.net/eclipse.beta/



git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6508 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 05:26:39 +00:00
fbb70a65bd eclipse plugin reorganization
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6507 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 05:23:00 +00:00
9a9e723746 code cleanup: unused imports
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6506 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 02:29:41 +00:00
f0e9d13547 eclipse plugin reorganization
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6505 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-26 00:31:32 +00:00
8c72bbb2ac eclipse plugin reorganization
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6504 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-25 23:57:57 +00:00
f7371ac0de eclipse plugin reorganization
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6503 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-25 23:45:36 +00:00
c54f51b530 eclipse plugin reorganization
first of several commits to make sure the plugin can be generated in headless
mode from ant


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6502 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-25 23:18:33 +00:00
90264d6cb8 absolute paths replaced by
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6501 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-22 23:07:31 +00:00
f2014126b0 settings to enable building eclipse plugin using ant (from within eclipse itself so far)
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6500 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-22 22:33:30 +00:00
7bab6411d7 installing saxon9.jar in local repository as it's not in standard repositories
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6499 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-19 16:22:03 +00:00
089e5d40ad Correct package spelling.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6498 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-19 07:38:22 +00:00
4f9a67c710 Correct package spelling.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6497 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-19 06:40:59 +00:00
c0fc8a84d1 Allow the Attribute class to expose the original underlying type/value, instead of only exposing as a String. This is needed for XPath 2.0 support, so that attributes can have the proper type. The AttributeNode class is updated accordingly.
There are still issues with running existing rules as XPath 2.0, but this brings things closer.  Some of the issues may be due to incompatibilities with XPath 1.0, or to some as yet unfixed problem.

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6496 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 09:17:50 +00:00
87f754f1b3 Remove unused import.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6495 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 07:42:56 +00:00
3bbd95d420 Remove unused local variable.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6494 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 07:34:50 +00:00
b63f8a55e5 XPathRule version default should be 1.0, not 2.0.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6493 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 07:20:20 +00:00
2990661b5f Add Saxon to Eclipse classpath.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6492 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 06:21:16 +00:00
66283d5da4 Add support for XPath 2.0 and XPath 1.0 compatibility using Saxon. This is implemented using the Saxon OM classes, for good performance. Existing PMD XPath functions are refactored to be compatible with Saxon's extension support. The functions are exposed using 'pmd' and 'pmd-java' namespace prefixes, while these prefixes cause no issues for Jaxen, they are required by Saxon.
If you want to experiment using XPath 1.0 compatibility mode, simply change the default index on the 'version' enum property in XPathRule to a 1.  All Rules work properly in this mode using Saxon.  RuleChain is not in use, so performance is not currently as good as Jaxen, but it's not horrendous either.


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6491 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 06:17:42 +00:00
a3efb90211 Add SaxonB 9.1.0.2b. Also an Ant script which removes the TransformerFactory file, which if not removed causes Saxon to be used instead of the JVM default. SaxonB is not schema aware, but Xerces is. Changing how all XML processing is done is more than PMD should be dictating to any code which uses with PMD, thus this minor tweak to the Saxon jar.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6490 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-18 05:53:52 +00:00
dd3e4d1b1f Remove empty packages that have been refactored already.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6489 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-17 03:30:25 +00:00
28c1c9437e Remove empty packages that have been refactored already.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6488 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-17 03:23:54 +00:00
93b9f18764 Remove incorrect @Override annotation, move method above java.lang.Object overrides instead of at end of file.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6487 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-17 03:08:14 +00:00
4baa8866be code cleanup: javadoc warnings, use {@inheritDoc} tag
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6483 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-15 06:54:00 +00:00
8cd51f218b dogfood bugfix
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6482 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-15 05:12:55 +00:00
be36b08115 Partial update to allow easier property descriptor integration with XPATH rules. All property types can return any additional attributes in map.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6481 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-15 04:19:49 +00:00
37577e7c68 retroweaver was updated to 2.0.6
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6480 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-14 04:05:10 +00:00
3d992a4001 reorganization:
`pmd' target was removed

`qa' target can do most of the checks prior to generating a new release
(it's also used by the continuous integration setup)


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6479 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-13 17:52:42 +00:00
9314f35494 Refactor XPathRule, to support a "version" property (currently defaulting to 1.0), which will cause an underlying XPathRuleQuery to be used to handle the XPath query. The current XPathRule logic is moved into JaxenXPathRuleQuery, for 1.0 version. A SaxonXPathRuleQuery is added, for handling 2.0 and 2.0 compatibility mode versions. The Saxon implementation will be completed in a future commit.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6478 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-13 07:15:18 +00:00
97df3571b2 Upgrade Retroweaver to 2.0.6. Some of the upcoming changes for XPath 2.0 use some of the Integer functions added in 2.0.6 (e.g. Integer.signum).
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6477 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-13 06:13:36 +00:00
bb25fc773a Rename Node.getAsXml() to Node.getAsDocument(), which is a more accurate naming.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6476 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-13 06:04:21 +00:00
6cb5ffae77 Remove "pmd" target, which doesn't seem to be used. "pmdOnPmd" is the equivalent.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6475 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-13 05:57:32 +00:00
4eec4cdd51 Rename Node.getAsXml() to Node.getAsDocument(), which is a more accurate naming.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6474 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-13 05:47:17 +00:00
7e22318763 new internal ruleset for pmd specific rules that may not apply to
general purpose Java code.


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6473 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-11 20:25:08 +00:00
7f25760ba1 code cleanup: javadoc warnings
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6472 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-11 17:04:39 +00:00
20ee70ae16 code cleanup: x.getClass().equals(ASTxxx.class) replaced by x instanceof ASTxxx.
I used the XPath expression below to detect most cases but I don't think it's
general enough to create a new rule...

//PrimaryExpression[
(
PrimaryPrefix[Name[ends-with(@Image, 'getClass')]] or
PrimarySuffix[@Image='getClass'])
and
PrimarySuffix[Arguments[count(ArgumentList)=0]]
and
PrimarySuffix[@Image='equals']
and
PrimarySuffix/Arguments/ArgumentList/Expression/PrimaryExpression/PrimaryPrefix
/ResultType/Type/ReferenceType/ClassOrInterfaceType
]


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6471 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-11 16:36:07 +00:00
4119862e6d code cleanup: use ASTLiteral.isStringLiteral()
new property 'minimumLength' instead of hard coded minimum value

reformatting


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6470 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-11 07:13:10 +00:00
364fc5e4a9 code cleanup: use of ASTLiteral.isStringLiteral()
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6469 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-11 06:42:38 +00:00
69a1b7f0c0 Fixed ClassCastException in symbol table code
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6467 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-10 19:45:33 +00:00