Class NPathComplexityCheck.TokenEnd
- java.lang.Object
-
- com.puppycrawl.tools.checkstyle.checks.metrics.NPathComplexityCheck.TokenEnd
-
- Enclosing class:
- NPathComplexityCheck
private static class NPathComplexityCheck.TokenEnd extends java.lang.ObjectCoordinates of token end. Used to prevent inline ternary operator from being processed twice.
-
-
Field Summary
Fields Modifier and Type Field Description private intendColumnNoEnd column of token.private intendLineNoEnd line of token.
-
Constructor Summary
Constructors Modifier Constructor Description privateTokenEnd()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanisAfter(DetailAST ast)Checks if saved coordinates located after given token.voidreset()Sets end token coordinates to the start of the file.voidsetToken(DetailAST endToken)Sets end coordinates from given token.
-
-
-
Method Detail
-
setToken
public void setToken(DetailAST endToken)
Sets end coordinates from given token.- Parameters:
endToken- token.
-
reset
public void reset()
Sets end token coordinates to the start of the file.
-
isAfter
public boolean isAfter(DetailAST ast)
Checks if saved coordinates located after given token.- Parameters:
ast- given token.- Returns:
- true, if saved coordinates located after given token.
-
-