source: josm/trunk/tools/pmd/josm-ruleset.xml @ 11746

Last change on this file since 11746 was 11746, checked in by Don-vip, 2 years ago

PMD - Strict Exceptions

File size: 2.3 KB
Line 
1<?xml version="1.0"?>
2<ruleset name="JOSM ruleset"
3    xmlns="http://pmd.sourceforge.net/ruleset/2.0.0"
4    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5    xsi:schemaLocation="http://pmd.sourceforge.net/ruleset/2.0.0 http://pmd.sourceforge.net/ruleset_2_0_0.xsd">
6 
7  <description>JOSM PMD ruleset</description>
8 
9  <!-- <rule ref="rulesets/java/basic.xml"/>
10  <rule ref="rulesets/java/braces.xml"/>
11  <rule ref="rulesets/java/clone.xml"/>
12  <rule ref="rulesets/java/codesize.xml"/>
13  <rule ref="rulesets/java/comments.xml"/>
14  <rule ref="rulesets/java/design.xml"/>
15  <rule ref="rulesets/java/empty.xml"/>
16  <rule ref="rulesets/java/finalizers.xml"/>
17  <rule ref="rulesets/java/imports.xml"/>
18  <rule ref="rulesets/java/migrating.xml"/>
19  <rule ref="rulesets/java/naming.xml"/>
20  <rule ref="rulesets/java/optimizations.xml">
21        <exclude name="LocalVariableCouldBeFinal"/>
22        <exclude name="MethodArgumentCouldBeFinal"/>
23  </rule>-->
24  <rule ref="rulesets/java/strictexception.xml">
25        <exclude name="ExceptionAsFlowControl"/>
26        <exclude name="AvoidRethrowingException"/>
27  </rule>
28  <rule ref="rulesets/java/strings.xml">
29        <exclude name="AvoidDuplicateLiterals"/>
30        <exclude name="ConsecutiveLiteralAppends"/>
31        <exclude name="AvoidStringBufferField"/>
32        <exclude name="StringToString"/>
33        <exclude name="UselessStringValueOf"/>
34  </rule>
35  <rule ref="rulesets/java/typeresolution.xml">
36        <exclude name="LooseCoupling"/>
37        <exclude name="SignatureDeclareThrowsException"/>
38  </rule>
39  <rule ref="rulesets/java/typeresolution.xml/SignatureDeclareThrowsException">
40    <properties>
41        <property name="violationSuppressXPath" value="//MethodDeclaration/../Annotation/MarkerAnnotation/Name[@Image='Override']"/>
42        <property name="IgnoreJUnitCompletely" value="true"/>
43    </properties>
44  </rule>
45  <rule ref="rulesets/java/unnecessary.xml">
46        <exclude name="UselessParentheses"/>
47        <exclude name="UselessOverridingMethod"/>
48  </rule>
49  <rule ref="rulesets/java/unusedcode.xml">
50        <exclude name="UnusedFormalParameter"/>
51  </rule>
52  <rule ref="rulesets/java/unusedcode.xml/UnusedFormalParameter">
53    <properties>
54        <property name="violationSuppressXPath" value="//Annotation[MarkerAnnotation/Name/@Image='Deprecated']/..[MethodDeclaration|ConstructorDeclaration]"/>
55    </properties>
56  </rule>
57
58</ruleset>
Note: See TracBrowser for help on using the repository browser.