Package com.qulice.checkstyle
Class JavadocEmptyLineBeforeTagCheck
java.lang.Object
com.puppycrawl.tools.checkstyle.AbstractAutomaticBean
com.puppycrawl.tools.checkstyle.api.AbstractViolationReporter
com.puppycrawl.tools.checkstyle.api.AbstractCheck
com.qulice.checkstyle.JavadocEmptyLineBeforeTagCheck
- All Implemented Interfaces:
com.puppycrawl.tools.checkstyle.api.Configurable,com.puppycrawl.tools.checkstyle.api.Contextualizable
public final class JavadocEmptyLineBeforeTagCheck
extends com.puppycrawl.tools.checkstyle.api.AbstractCheck
Check for the empty Javadoc line before the group of at-clauses.
The group of at-clauses (@param, @return,
@since, @throws and the rest) must always be separated
from the description above it by an empty Javadoc line, no matter how
many paragraphs that description has. This holds for every Javadoc
block: packages, classes, interfaces, enums, enum constants,
annotations, annotation fields, records, fields, constructors and
methods. See
#1810.
The following Javadoc will be reported as a violation, since its description touches the first at-clause:
/**
* Just one line here.
* @since 0.1
*/
And this is how it should be written instead:
/** * Just one line here. * * @since 0.1 */
A Javadoc block with no at-clauses at all, and a block whose very first line already is an at-clause, are both left alone.
- Since:
- 0.27.0
-
Nested Class Summary
Nested classes/interfaces inherited from class com.puppycrawl.tools.checkstyle.AbstractAutomaticBean
com.puppycrawl.tools.checkstyle.AbstractAutomaticBean.OutputStreamOptions -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint[]int[]int[]voidvisitToken(com.puppycrawl.tools.checkstyle.api.DetailAST ast) Methods inherited from class com.puppycrawl.tools.checkstyle.api.AbstractCheck
beginTree, clearViolations, destroy, finishTree, getFileContents, getFilePath, getLine, getLineCodePoints, getLines, getTabWidth, getTokenNames, getViolations, init, isCommentNodesRequired, leaveToken, log, log, log, setFileContents, setTabWidth, setTokensMethods inherited from class com.puppycrawl.tools.checkstyle.api.AbstractViolationReporter
finishLocalSetup, getCustomMessages, getId, getMessageBundle, getSeverity, getSeverityLevel, setId, setSeverityMethods inherited from class com.puppycrawl.tools.checkstyle.AbstractAutomaticBean
configure, contextualize, getConfiguration, setupChild
-
Constructor Details
-
JavadocEmptyLineBeforeTagCheck
public JavadocEmptyLineBeforeTagCheck()Default constructor.
-
-
Method Details
-
getDefaultTokens
public int[] getDefaultTokens()- Specified by:
getDefaultTokensin classcom.puppycrawl.tools.checkstyle.api.AbstractCheck
-
getAcceptableTokens
public int[] getAcceptableTokens()- Specified by:
getAcceptableTokensin classcom.puppycrawl.tools.checkstyle.api.AbstractCheck
-
getRequiredTokens
public int[] getRequiredTokens()- Specified by:
getRequiredTokensin classcom.puppycrawl.tools.checkstyle.api.AbstractCheck
-
visitToken
public void visitToken(com.puppycrawl.tools.checkstyle.api.DetailAST ast) - Overrides:
visitTokenin classcom.puppycrawl.tools.checkstyle.api.AbstractCheck
-