Change message of MethodWithSameNameAsEnclosingClass
This commit is contained in:
1 parent
dd8b25802d
commit
18908eb117
1 file changed
+3
-2
@@ -2179,11 +2179,12 @@ public class Foo extends TestCase {
|
||||
<rule name="MethodWithSameNameAsEnclosingClass"
|
||||
language="java"
|
||||
since="1.5"
|
||||
message="Classes should not have non-constructor methods with the same name as the class"
|
||||
message="A method should not have the same name as its containing class"
|
||||
class="net.sourceforge.pmd.lang.rule.XPathRule"
|
||||
externalInfoUrl="${pmd.website.baseurl}/pmd_rules_java_errorprone.html#methodwithsamenameasenclosingclass">
|
||||
<description>
|
||||
Non-constructor methods should not have the same name as the enclosing class.
|
||||
A method should not have the same name as its containing class.
|
||||
This would be confusing as it would look like a constructor.
|
||||
</description>
|
||||
<priority>3</priority>
|
||||
<properties>
|
||||
|
||||
Reference in new issue
Block a user