forked from opensearch-project/opensearch-sdk-java
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use checkstyle for javadoc checks (opensearch-project#551)
* Use checkstyle for javadoc checks Signed-off-by: Daniel Widdis <widdis@gmail.com> * Add missing javadoc tags Signed-off-by: Daniel Widdis <widdis@gmail.com> --------- Signed-off-by: Daniel Widdis <widdis@gmail.com> Signed-off-by: Nurym <nurym0807@gmail.com>
- Loading branch information
Showing
9 changed files
with
91 additions
and
38 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
<?xml version="1.0"?> | ||
<!-- | ||
~ SPDX-License-Identifier: Apache-2.0 | ||
~ The OpenSearch Contributors require contributions made to | ||
~ this file be licensed under the Apache-2.0 license or a | ||
~ compatible open source license. | ||
--> | ||
|
||
<!DOCTYPE module PUBLIC | ||
"-//Checkstyle//DTD Checkstyle Configuration 1.3//EN" | ||
"https://checkstyle.org/dtds/configuration_1_3.dtd"> | ||
|
||
<!-- | ||
Formatting checks are done by spotless. This config is only for checks spotless doesn't do. | ||
--> | ||
|
||
<module name="Checker"> | ||
<property name="charset" value="UTF-8" /> | ||
|
||
<module name="SuppressionFilter"> | ||
<property name="file" value="${config_loc}/checkstyle_suppressions.xml" /> | ||
</module> | ||
|
||
<module name="TreeWalker"> | ||
<!-- Disallows star imports --> | ||
<module name="AvoidStarImport" /> | ||
|
||
<!-- Requires javadoc on public and protected interfaces, classes, enums --> | ||
<module name="MissingJavadocType"> | ||
<property name="scope" value="protected"/> | ||
</module> | ||
|
||
<!-- Requires javadoc on public and protected methods, excluding getters and setters --> | ||
<module name="MissingJavadocMethod"> | ||
<property name="scope" value="protected"/> | ||
<property name="allowMissingPropertyJavadoc" value="true"/> | ||
</module> | ||
|
||
<!-- Checks that javadocs contain correct param and return --> | ||
<module name="JavadocMethod"> | ||
<property name="id" value="JavadocMethod"/> | ||
<property name="accessModifiers" value="public, protected"/> | ||
</module> | ||
|
||
<!-- Allows missing returns on extension interface methods --> | ||
<module name="JavadocMethod"> | ||
<property name="id" value="JavadocMethodAllowMissingReturnTag"/> | ||
<property name="accessModifiers" value="public, protected"/> | ||
<property name="allowMissingReturnTag" value="true"/> | ||
</module> | ||
|
||
</module> | ||
</module> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?xml version="1.0"?> | ||
<!-- | ||
~ SPDX-License-Identifier: Apache-2.0 | ||
~ The OpenSearch Contributors require contributions made to | ||
~ this file be licensed under the Apache-2.0 license or a | ||
~ compatible open source license. | ||
--> | ||
|
||
<!DOCTYPE suppressions PUBLIC | ||
"-//Checkstyle//DTD SuppressionFilter Configuration 1.1//EN" | ||
"https://checkstyle.org/dtds/suppressions_1_1.dtd"> | ||
|
||
<suppressions> | ||
<!-- No javadoc checks on test classes --> | ||
<suppress checks="Javadoc*" files="[\\/]src[\\/]test[\\/].*" /> | ||
<!-- No return required for Extension interface classes --> | ||
<suppress id="JavadocMethod" files="\w+Extension\.java" /> | ||
<suppress id="JavadocMethodAllowMissingReturnTag" files="^((?!\w+Extension\.java).)*$" /> | ||
</suppressions> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters