5927 Commits

Author SHA1 Message Date
Xavier Le Vourch
e233091080 3.2.5 release, based on PMD 4.2.4
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6600 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-13 18:54:32 +00:00
Xavier Le Vourch
87a6940645 update to PMD 4.2.4
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6599 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-13 18:30:37 +00:00
Ryan Gustafson
6054ef3c1e Cleanup the RuleSetFactory so that ClassLoader is an instance field, instead of a method argument. This removes 3 wrapper methods from the API, and a bunch of internal parameter passing. Resulting API is very much simpler.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6593 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-12 10:21:18 +00:00
Xavier Le Vourch
e129bed663 Fixed patch 2075906 - Add toString() to the rule UnnecessaryWrapperObjectCreation
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6592 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-11 18:42:30 +00:00
Ryan Gustafson
8bef2761e9 Correct issue passing report parameters to Renderer.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6590 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-11 04:43:30 +00:00
Ryan Gustafson
7124011961 Correct issue with excluding of SCCS directory (was inverted, matching only that directory). Also add more toString() on the FilenameFilters.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6589 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-11 04:17:34 +00:00
Ryan Gustafson
f502ee3a12 Rename SourceFileSelector to LanguageFilenameFilter. Delete SourceFileOrDirectoryFilter. Move DataSource finding code from the PMD class into FileUtil.
Overall, nice bit of cleanup and removal of code from the PMD class into a reusable utility (used by PMD and the Benchmark program).

Added a FUTURE marker as we still need to figure out a way to deal with excluding certain directories, the hard-coded "SCCS" is still in place.  Thankfully this only applies to command line usages, and not Ant.


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6588 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-10 06:09:57 +00:00
Ryan Gustafson
2073b275cf Refactor SourceFileSelector into lang package.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6587 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-10 03:18:39 +00:00
Ryan Gustafson
354519f879 Fix to support EOLs different from the current System's.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6586 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-10 02:14:14 +00:00
Ryan Gustafson
178a0a10e5 New Rule: Import ruleset: UnnecessaryFullyQualifiedName
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6585 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-09 00:30:53 +00:00
Xavier Le Vourch
2a9a5a289e 'What's new in PMD 5.0' links to Hudson's changes page for the snapshot
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6584 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-08 15:49:53 +00:00
Xavier Le Vourch
9cf0cead65 web site updates to link to the download location for the daily Hudson CI snapshot
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6582 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 22:52:36 +00:00
Xavier Le Vourch
c4ab6882f8 automatic snapshot updates:
1) src and bin packages are available in hudson setup, no need to upload to sf.net

(see http://hudson.brittanysoftware.com/job/PMD-snapshot/)

2) maven snapshots are not versioned


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6581 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 20:04:16 +00:00
Xavier Le Vourch
7189d805b6 renderers cleanup: consistent handling of EOL.
EOL was generated before violations and then again outside the renderer at
the end of the report.

side effect: ant task is now silent if there is no violation to be consistent
with ant common practices.


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6580 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 15:46:11 +00:00
Xavier Le Vourch
748faacab0 release process update: mvn site:deploy doesn't work... using rsync over ssh
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6579 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 15:34:25 +00:00
Xavier Le Vourch
9903991b77 release process updates to reflect changes in sf.net access
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6578 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 06:06:33 +00:00
Ryan Gustafson
95dbc6bc1b Fix incorrect parameter passing.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6577 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 05:06:07 +00:00
Ryan Gustafson
fbd966a099 Remove deprecated methods from Renderer.
Also split AbstractRenderer off into AbstractAccumulatingRenderer to make the distinction with the AbstractIncrementalRenderer explicit.  JavaDoc updated accordingly.

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6576 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-07 04:28:39 +00:00
Xavier Le Vourch
465b903f04 Text renderer is now silent if there's no violation instead of displaying "No problems found!"
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6573 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 22:58:54 +00:00
Xavier Le Vourch
4240972386 sourceforge.net upload host changed
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6572 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 21:26:21 +00:00
Xavier Le Vourch
6045d9e147 version change before new beta to test recent changes
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6571 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 19:30:16 +00:00
Xavier Le Vourch
49b0968c8c code cleanup: removal of $Log$ and $Revision$
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6570 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 19:26:32 +00:00
Xavier Le Vourch
a44f3a73ec bump pmd-build version number as jdk14 pom is no longer built
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6569 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 18:22:57 +00:00
Xavier Le Vourch
c862010a1d undo last change as there's problems with the reports target, specifically the clover target calling clean to make sure the classes are instrumented
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6568 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 18:09:27 +00:00
Xavier Le Vourch
3ae6746eff 'clean' target removed reports directory
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6567 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 17:11:47 +00:00
Ryan Gustafson
28e409d901 Revert inadvertent commit.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6566 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 05:39:25 +00:00
Ryan Gustafson
302e38ba8d Remove support for Java 1.4 runtime. Primarily this entails removal of the build processes and scripts used to support running with retroweaver. Additional changes are made to code which made checks for running on a 1.4 JVM (found via searches).
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6565 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 05:20:27 +00:00
Ryan Gustafson
c1f5d18669 Correct documentation.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6564 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 04:24:22 +00:00
Ryan Gustafson
6055d7d222 Comment cleanup.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6563 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 03:16:21 +00:00
Ryan Gustafson
34de466006 Rename OntheFlyRenderer to AbstractIncrementalRenderer.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6562 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 03:12:43 +00:00
Ryan Gustafson
d1cb839b37 Rework Renderer to support standardized option passing, as well as a more rigorous definition of those options. This approach allows for a RendererFactory to create Renderer instances, as well as a means to programmatically output details on all available Renderers. Both the PMD command line and Ant tasks now take advantage of the RendererFactory, and have been enhanced to support generic report option passing (ie. -parameter and <param> respectively). Removed obsoleted Renderer specific options from command line and Ant task (e.g. linkPrefix, etc). Finally, some Renderers were given more appropriate names. We should consider dropping some of these goofy Renderers out of the tree (there's about 4-5 Renderers for HTML!).
Added missing -showsuppresse option for PMD command line.  The default is the same as the Ant task (false), which is a change from prior PMD behavior, but I think this is justified for consistency's sake and the fact that most people likely use the Ant task anyway.

While working on CommandLineOptions, the argument processed code was cleaned up a bit so that missing parameters for options will now give better error messages.  This isn't to say there's not work that could still be done in this area, as the code is still rather too loosey-goosey for my tastes.


git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6561 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-06 03:06:55 +00:00
Ryan Gustafson
11bbd666ae JavaDoc fixes. Curiously the Ant build does not seem to report these as problems, Eclipse pointed them out for me.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6560 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-04 05:45:53 +00:00
Ryan Gustafson
b7d7a056b0 Delete unused file.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6559 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-04 01:27:32 +00:00
Ryan Gustafson
34ecdafcf1 Changelog update.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6558 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-04 01:06:42 +00:00
Ryan Gustafson
95d65ea2ec Provide full file path to PMD, instead of workspace relative path.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6557 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-04 00:52:32 +00:00
Xavier Le Vourch
5b92ce62f7 cpd ant task documentation for attributes
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6556 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-03 23:47:11 +00:00
Xavier Le Vourch
6669e7fdf1 Eclipse plugin should work with Eclipse 3.2+: dependency on 3.4 removed
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6554 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-03 22:13:02 +00:00
Xavier Le Vourch
17159a5f56 version update for new beta package
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6553 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-03 00:22:59 +00:00
Xavier Le Vourch
ca4303a790 code cleanup: javadoc warning
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6552 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-02 23:44:48 +00:00
Xavier Le Vourch
0add112542 wrong resource file name during refactoring
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6551 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-02 22:54:22 +00:00
Ryan Gustafson
a1b27d280a Remove deprecated APIs and classes.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6550 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-02 05:33:16 +00:00
Ryan Gustafson
2679c9eca5 Remove XPath 2.0 for XML rules, for now. I thought it would be a nice test case, but it's broken on Java 1.4.
I thought I had verified Saxon worked on Java 1.4, but apparently it cannot due in part to dependencies on the DefaultHandler2 class which is only available in Java 1.5 and later (or Java 1.4 with JAXP extension).  I think we'll just have to document this limitation for folks wanting to continue to use Java 1.4.

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6549 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-02 05:07:08 +00:00
Ryan Gustafson
7b4f809b41 Add MistypeCDATASection Rule to detect potential extra [ or ].
This is not in dogfood, as PMD does a lot of CDATASections which are the end of XPath steps, and this last character is a ].  We could reformat to work around the check (add a newline before the ]]>), but it seems a bit kludgy.

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6548 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-02 03:21:38 +00:00
Ryan Gustafson
7534aedf0c Remove 'language' attribute from the <ruleset> element in the XML Schema and DTD. Remove from the JSP/JSF RuleSets.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6547 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-02 01:43:58 +00:00
Ryan Gustafson
e6eac94c0b Remove Language from RuleSet class. Previous changes which associated Language with Rule are now the driver for processing instead of the RuleSet.
Work still needs to be done to clean up the XML Schema and DTD.  Nothing too complex there.

Slightly more complicated work needs to be done allow PMD to appropriately associate an source file based LanguageVersion on the RuleContext.  Once that is done, it will be technically possible to use a single RuleSet containing Rules for different Languages and actually run it against a mixed set of source files.

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6546 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-01 04:39:43 +00:00
Ryan Gustafson
0481bba385 Fix JavaDoc warning.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6545 51baf565-9d33-0410-a72c-fc3788e3496d
2008-10-01 02:22:08 +00:00
Ryan Gustafson
ad38760383 Update description of the 'xpath' property to be technically accurate.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6544 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-30 03:20:53 +00:00
Ryan Gustafson
454d19e6a9 Replace magic String with constant.
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6543 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-30 03:17:26 +00:00
Ryan Gustafson
98d32e0341 Change version property to have choices and labels be identical.
EnumeratedProperty is really odd in that it wants to serialize out the label.  I had assumed it would serialize out the value, and the label was merely used to provide a description in some GUI, and was not the externalized form.  Regardless, a verbose value is not what I want people to have to enter when manually providing a the version for XPathRule in XML.

git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6542 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-30 03:13:16 +00:00
Xavier Le Vourch
671f8f5b1e misc changes: properties, version number
git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@6541 51baf565-9d33-0410-a72c-fc3788e3496d
2008-09-30 01:01:18 +00:00