Package org.sonar.java.ast.visitors
Class ComplexityVisitor
- java.lang.Object
-
- org.sonar.plugins.java.api.tree.BaseTreeVisitor
-
- org.sonar.java.ast.visitors.ComplexityVisitor
-
- All Implemented Interfaces:
TreeVisitor
public class ComplexityVisitor extends BaseTreeVisitor
-
-
Constructor Summary
Constructors Constructor Description ComplexityVisitor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<Tree>
getNodes(Tree tree)
void
visitBinaryExpression(BinaryExpressionTree tree)
void
visitCaseLabel(CaseLabelTree tree)
void
visitClass(ClassTree tree)
void
visitConditionalExpression(ConditionalExpressionTree tree)
void
visitDoWhileStatement(DoWhileStatementTree tree)
void
visitForEachStatement(ForEachStatement tree)
void
visitForStatement(ForStatementTree tree)
void
visitIfStatement(IfStatementTree tree)
void
visitLambdaExpression(LambdaExpressionTree lambdaExpressionTree)
void
visitMethod(MethodTree tree)
void
visitWhileStatement(WhileStatementTree tree)
-
Methods inherited from class org.sonar.plugins.java.api.tree.BaseTreeVisitor
scan, scan, scan, visitAnnotation, visitArrayAccessExpression, visitArrayDimension, visitArrayType, visitAssertStatement, visitAssignmentExpression, visitBlock, visitBreakStatement, visitCaseGroup, visitCatch, visitCompilationUnit, visitContinueStatement, visitEmptyStatement, visitEnumConstant, visitExportsDirectiveTree, visitExpressionStatement, visitIdentifier, visitImport, visitInstanceOf, visitLabeledStatement, visitLiteral, visitMemberSelectExpression, visitMethodInvocation, visitMethodReference, visitModifier, visitModule, visitNewArray, visitNewClass, visitOpensDirective, visitOther, visitPackage, visitParameterizedType, visitParenthesized, visitPrimitiveType, visitProvidesDirective, visitRequiresDirectiveTree, visitReturnStatement, visitSwitchStatement, visitSynchronizedStatement, visitThrowStatement, visitTryStatement, visitTypeArguments, visitTypeCast, visitTypeParameter, visitTypeParameters, visitUnaryExpression, visitUnionType, visitUsesDirective, visitVariable, visitVarType, visitWildcard
-
-
-
-
Method Detail
-
visitMethod
public void visitMethod(MethodTree tree)
- Specified by:
visitMethod
in interfaceTreeVisitor
- Overrides:
visitMethod
in classBaseTreeVisitor
-
visitClass
public void visitClass(ClassTree tree)
- Specified by:
visitClass
in interfaceTreeVisitor
- Overrides:
visitClass
in classBaseTreeVisitor
-
visitLambdaExpression
public void visitLambdaExpression(LambdaExpressionTree lambdaExpressionTree)
- Specified by:
visitLambdaExpression
in interfaceTreeVisitor
- Overrides:
visitLambdaExpression
in classBaseTreeVisitor
-
visitCaseLabel
public void visitCaseLabel(CaseLabelTree tree)
- Specified by:
visitCaseLabel
in interfaceTreeVisitor
- Overrides:
visitCaseLabel
in classBaseTreeVisitor
-
visitForEachStatement
public void visitForEachStatement(ForEachStatement tree)
- Specified by:
visitForEachStatement
in interfaceTreeVisitor
- Overrides:
visitForEachStatement
in classBaseTreeVisitor
-
visitForStatement
public void visitForStatement(ForStatementTree tree)
- Specified by:
visitForStatement
in interfaceTreeVisitor
- Overrides:
visitForStatement
in classBaseTreeVisitor
-
visitWhileStatement
public void visitWhileStatement(WhileStatementTree tree)
- Specified by:
visitWhileStatement
in interfaceTreeVisitor
- Overrides:
visitWhileStatement
in classBaseTreeVisitor
-
visitDoWhileStatement
public void visitDoWhileStatement(DoWhileStatementTree tree)
- Specified by:
visitDoWhileStatement
in interfaceTreeVisitor
- Overrides:
visitDoWhileStatement
in classBaseTreeVisitor
-
visitIfStatement
public void visitIfStatement(IfStatementTree tree)
- Specified by:
visitIfStatement
in interfaceTreeVisitor
- Overrides:
visitIfStatement
in classBaseTreeVisitor
-
visitConditionalExpression
public void visitConditionalExpression(ConditionalExpressionTree tree)
- Specified by:
visitConditionalExpression
in interfaceTreeVisitor
- Overrides:
visitConditionalExpression
in classBaseTreeVisitor
-
visitBinaryExpression
public void visitBinaryExpression(BinaryExpressionTree tree)
- Specified by:
visitBinaryExpression
in interfaceTreeVisitor
- Overrides:
visitBinaryExpression
in classBaseTreeVisitor
-
-