Skip to content

Commit

Permalink
Issue checkstyle#6586: aligned javadoc/xdoc for OverloadMethodsDeclar…
Browse files Browse the repository at this point in the history
…ationOrder
  • Loading branch information
pbludov authored and peterdemaeyer committed Apr 28, 2019
1 parent 624941b commit 42bab50
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
Expand Up @@ -29,23 +29,26 @@

/**
* <p>
* Checks that overload methods are grouped together. Example:
* Checks that overload methods are grouped together.
* </p>
* <p>
* Example of incorrect grouping overload methods:
* </p>
* <pre>
* {@code
* public void foo(int i) {}
* public void foo(String s) {}
* public void notFoo() {} // Have to be after foo(int i, String s)
* public void foo(int i, String s) {}
* }
* </pre>
* <p>
* An example of how to configure the check is:
* </p>
*
* <pre>
* &lt;module name="OverloadMethodsDeclarationOrder"/&gt;
* &lt;module name=&quot;OverloadMethodsDeclarationOrder&quot;/&gt;
* </pre>
*
* @since 5.8
*/
@StatelessCheck
public class OverloadMethodsDeclarationOrderCheck extends AbstractCheck {
Expand Down
Expand Up @@ -124,6 +124,7 @@ public class XdocsJavaDocsTest extends AbstractModuleTestSupport {
"NestedTryDepth",
"NoClone",
"OneStatementPerLine",
"OverloadMethodsDeclarationOrder",
"PackageAnnotation",
"PackageDeclaration",
"PackageName",
Expand Down
2 changes: 1 addition & 1 deletion src/xdocs/config_coding.xml
Expand Up @@ -3644,8 +3644,8 @@ r = 5; int t; //violation here
</section>

<section name="OverloadMethodsDeclarationOrder">
<p>Since Checkstyle 5.8</p>
<subsection name="Description" id="OverloadMethodsDeclarationOrder_Description">
<p>Since Checkstyle 5.8</p>
<p>
Checks that overload methods are grouped together.
</p>
Expand Down

0 comments on commit 42bab50

Please sign in to comment.