From f75ad93b2c5f9be7cce635e08b6478531f807b0e Mon Sep 17 00:00:00 2001 From: Tom Copeland Date: Wed, 14 Dec 2005 14:26:33 +0000 Subject: [PATCH] Added David Corley's Javascript report, more details are here: http://tomcopeland.blogs.com/juniordeveloper/2005/12/demo_of_some_ni.html git-svn-id: https://pmd.svn.sourceforge.net/svnroot/pmd/trunk@4062 51baf565-9d33-0410-a72c-fc3788e3496d --- pmd/etc/changelog.txt | 1 + pmd/etc/xslt/arrow_down.gif | Bin 0 -> 131 bytes pmd/etc/xslt/arrow_up.gif | Bin 0 -> 130 bytes pmd/etc/xslt/corley-pmd-report.xslt | 137 ++++++++++++++++++++++++++++ pmd/etc/xslt/fcoltable.css | 75 +++++++++++++++ pmd/etc/xslt/fcoltable.js | 57 ++++++++++++ pmd/xdocs/credits.xml | 1 + 7 files changed, 271 insertions(+) create mode 100644 pmd/etc/xslt/arrow_down.gif create mode 100644 pmd/etc/xslt/arrow_up.gif create mode 100644 pmd/etc/xslt/corley-pmd-report.xslt create mode 100644 pmd/etc/xslt/fcoltable.css create mode 100644 pmd/etc/xslt/fcoltable.js diff --git a/pmd/etc/changelog.txt b/pmd/etc/changelog.txt index c26033cb00..8549438f8b 100644 --- a/pmd/etc/changelog.txt +++ b/pmd/etc/changelog.txt @@ -20,6 +20,7 @@ Modified renderers to support disabling printing of suppressed warnings. Introd Added current CLASSPATH to pmd.bat. UnusedFormalParameter now catches unused constructor parameters, and its warning message now reflects whether it caught a method or a constructor param. Rebuilt JavaCC parser with JavaCC 4.0beta1. +Added David Corley's Javascript report, more details are here: http://tomcopeland.blogs.com/juniordeveloper/2005/12/demo_of_some_ni.html TODO: Removed old-style CPD command line options that were deprecated in 3.4. November 30, 2005 - 3.4: diff --git a/pmd/etc/xslt/arrow_down.gif b/pmd/etc/xslt/arrow_down.gif new file mode 100644 index 0000000000000000000000000000000000000000..f0bb6a4ea640d9b2beda344c7485d260f5761779 GIT binary patch literal 131 zcmZ?wbhEHb6krfw*v!o^>1^DDBbk%W#`m8Mo^~Z-=JluvXG6M=M%Jv0O73_44+acK zK=CIFBLf3BgAPaxWCjC^LBUDS)q5?HkM0ihoS_kK#PIl-D%-2j1P>Oa%ti-AnU~WT VI^xvQF6&qvTT*m#iwgsTH2{W9F7W^W literal 0 HcmV?d00001 diff --git a/pmd/etc/xslt/arrow_up.gif b/pmd/etc/xslt/arrow_up.gif new file mode 100644 index 0000000000000000000000000000000000000000..e8234178efaea626368f6bb5fffaa716e862b596 GIT binary patch literal 130 zcmZ?wbhEHb6krfw*v!o^>1^DDBbk%W#`m8Mo^~Z-=JluvXG6M=M%Jv0O73_44+acK zK=CIFBLf3BgAPaxWCjC^e!)r4)q5>o$4-6JJxOK08WYFNxvd2&rdbFb + + + + + + + + + +p1 +p2 +p3 +p4 +p5 +p6 +p7 +p8 + + + + - + + + + + + PMD <xsl:value-of select="//pmd/@version"/> Report + + + + + +

PMD Report

+
+

Summary

+ + + + + + + + + + + + + + + + + + + + + + + + + +
FilesTotalQRank Level 1QRank Level 2QRank Level 3QRank Level 4QRank Level 5QRank Level 6QRank Level 7QRank Level 8
+
+ + + +

+ sortable_id_ + + + + + + + + + + + + + + + + + + + + + + + + +
PrioLineMethodDescription
Total number of violations for this class: (Click anywhere on this row to see/hide details)
+
+
+

Generated by PMD on .

+ + + + +
+ +
diff --git a/pmd/etc/xslt/fcoltable.css b/pmd/etc/xslt/fcoltable.css new file mode 100644 index 0000000000..46db4486e3 --- /dev/null +++ b/pmd/etc/xslt/fcoltable.css @@ -0,0 +1,75 @@ +body{ + font-family:Arial,Sans-Serif; + font-size:90%; + background:#cc9; +} +#boundary{ + background:#f8f8f8; + padding:2em; + width:40em; +} +h1{ + font-family:"Trebuchet MS",Sans-serif; + text-transform:uppercase; + color:#696; + font-size:120%; +} + +table.footcollapse{ + width:100%; +} +table.footcollapse caption{ + font-size:120%; + text-transform:uppercase; + text-align:left; + padding:.5em 1em; +} +table.footcollapse th{ + text-align:left; +} +table.footcollapse,table.footcollapse th,table.footcollapse th +{ + border:none; + border-collapse:collapse; +} +table.footcollapse thead th +{ + width:10em; + border-style:solid; + border-width:1px; + border-color:#cff #69c #69c #cff; + background:#9cf; + padding:2px 10px; +} +table.footcollapse tfoot th, +table.footcollapse tfoot td +{ + border-style:solid; + border-width:1px; + border-color:#9cf #369 #369 #9cf; + background:#69c; + padding:2px 10px; +} +table.footcollapse tbody{ + background:#ddd; +} +table.footcollapse tbody td{ + padding:5px 10px; + border:1px solid #999; +} +table.footcollapse tbody th{ + padding:2px 10px; + border:1px solid #999; + border-left:none; +} +table.footcollapse tbody tr.odd{ + background:#ccc; +} + +table.footcollapse tfoot td img{ + border:none; + vertical-align:bottom; + padding-left:10px; + float:right; +} + diff --git a/pmd/etc/xslt/fcoltable.js b/pmd/etc/xslt/fcoltable.js new file mode 100644 index 0000000000..573dfd2a9b --- /dev/null +++ b/pmd/etc/xslt/fcoltable.js @@ -0,0 +1,57 @@ +function tablecollapse() +{ + /* Variables */ + var collapseClass='footcollapse'; + var collapsePic='arrow_up.gif'; + var expandPic='arrow_down.gif'; + var initialCollapse=true; + + // loop through all tables + var t=document.getElementsByTagName('table'); + var checktest= new RegExp("(^|\\s)" + collapseClass + "(\\s|$)"); + for (var i=0;i
    +
  • David Corley - Nifty Javascript folding for XML report, demo is here
  • George Sexton - Bug report 1379701 for CompareObjectsWithEquals, suggested new rule for Additional String Concatenation Warnings in StringBuffer.
  • Didier Duquennoy - several bug reports for InefficientStringBuffering, bug report for ImmutableField, suggestions for improving Benchmark utility, bug report for InefficientStringBuffering, bug report for AvoidConcateningNonLiteralsInStringBuffer, reported a missed hit for EqualsNull, bug report for MissingStaticMethodInNonInstantiatableClass, pmd-netbeans feedback
  • Johan Stuyts - improvements to UncommentedEmptyConstructor, nice patch for UncommentedEmptyConstructor and UncommentedEmptyMethod, patch to allow empty catch blocks with comments in them, patch to clean up build environment