Fork me on GitHub

PMD Results

The following document contains the results of PMD 5.5.1.

Files

fr/paris/lutece/plugins/newsletter/modules/htmldocs/business/INewsletterHtmlDocDAO.java

Violation Line
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.business.HtmlDoc' 3
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.business.HtmlDoc' 3
Avoid unused imports such as 'fr.paris.lutece.util.ReferenceList' 5
Avoid unused imports such as 'fr.paris.lutece.util.ReferenceList' 5
Avoid unused imports such as 'java.sql.Timestamp' 7
Avoid unused imports such as 'java.sql.Timestamp' 7
Avoid unused imports such as 'java.util.Collection' 8
Avoid unused imports such as 'java.util.Collection' 8
Avoid unused imports such as 'java.util.Date' 9
Avoid unused imports such as 'java.util.Date' 9
Avoid unused imports such as 'java.util.List' 10
Avoid unused imports such as 'java.util.List' 10

fr/paris/lutece/plugins/newsletter/modules/htmldocs/business/NewsletterHtmlDoc.java

Violation Line
A getX() method which returns a boolean should be named isX() 5962

fr/paris/lutece/plugins/newsletter/modules/htmldocs/business/NewsletterHtmlDocTemplateRemovalListener.java

Violation Line
Avoid variables with short names like id 30

fr/paris/lutece/plugins/newsletter/modules/htmldocs/service/NewsletterHtmlDocService.java

Violation Line
A high number of imports can indicate a high degree of coupling within an object. 1277
The class 'NewsletterHtmlDocService' has a Cyclomatic Complexity of 5 (Highest = 12). 45277
Private field '_newsletterService' could be made final; it is only initialized in the declaration or constructor. 57
These nested if statements could be combined 9699
Avoid catching generic exceptions such as NullPointerException, RuntimeException, Exception in try-catch block 110
The method 'generateDocumentsList' has a Cyclomatic Complexity of 12. 139199
Avoid declaring a variable if it is unreferenced before a possible exit point. 143
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 168
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 221
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 224

fr/paris/lutece/plugins/newsletter/modules/htmldocs/service/NewsletterHtmlDocTopicService.java

Violation Line
A high number of imports can indicate a high degree of coupling within an object. 1298
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.business.portlet.HtmlDocsListPortletHome' 3
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.business.portlet.HtmlDocsListPortletHome' 3
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.business.portlet.HtmldocsPortletHome' 4
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.business.portlet.HtmldocsPortletHome' 4
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.service.HtmldocsPlugin' 5
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.service.HtmldocsPlugin' 5
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.service.PublishingService' 6
Avoid unused imports such as 'fr.paris.lutece.plugins.htmldocs.service.PublishingService' 6
Avoid unused imports such as 'fr.paris.lutece.portal.business.portlet.Portlet' 18
Avoid unused imports such as 'fr.paris.lutece.portal.business.portlet.Portlet' 18
Avoid unused imports such as 'fr.paris.lutece.portal.business.portlet.PortletTypeHome' 19
Avoid unused imports such as 'fr.paris.lutece.portal.business.portlet.PortletTypeHome' 19
Avoid unused private fields such as 'HTMLDOCSLIST_PORTLET'. 45
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 109
Substitute calls to size() == 0 (or size() != 0, size() > 0, size() < 1) with calls to isEmpty() 208

fr/paris/lutece/plugins/newsletter/modules/htmldocs/util/HtmlDomDocNewsletterDocument.java

Violation Line
Deeply nested if..then statements are hard to read 9195

fr/paris/lutece/plugins/newsletter/modules/htmldocs/util/NewsletterHtmlDocUtils.java

Violation Line
Rather than using a lot of String arguments, consider using a container object for those values. 4041
Avoid variables with short names like i 71

fr/paris/lutece/plugins/newsletter/modules/htmldocs/web/NewsletterDocumentServiceJspBean.java

Violation Line
A high number of imports can indicate a high degree of coupling within an object. 34256
Private field '_newsletterService' could be made final; it is only initialized in the declaration or constructor. 115
Prefer StringBuffer over += for concatenating strings 133
Prefer StringBuffer over += for concatenating strings 139
Prefer StringBuffer over += for concatenating strings 142
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 145
Avoid declaring a variable if it is unreferenced before a possible exit point. 202
Avoid declaring a variable if it is unreferenced before a possible exit point. 204
Avoid declaring a variable if it is unreferenced before a possible exit point. 205
Avoid declaring a variable if it is unreferenced before a possible exit point. 206
If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 206
Prefer StringBuffer over += for concatenating strings 208
Avoid declaring a variable if it is unreferenced before a possible exit point. 215