Class ScopeVisitor
- java.lang.Object
-
- org.sonar.plugins.javascript.api.visitors.DoubleDispatchVisitor
-
- org.sonar.javascript.tree.symbols.ScopeVisitor
-
- All Implemented Interfaces:
TreeVisitor
public class ScopeVisitor extends DoubleDispatchVisitor
This visitor creates scopes.
-
-
Constructor Summary
Constructors Constructor Description ScopeVisitor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<Tree,Scope>getTreeScopeMap()voidvisitAccessorMethodDeclaration(AccessorMethodDeclarationTree tree)voidvisitArrowFunction(ArrowFunctionTree tree)voidvisitBlock(BlockTree tree)voidvisitCatchBlock(CatchBlockTree tree)voidvisitClass(ClassTree tree)voidvisitForObjectStatement(ForObjectStatementTree tree)voidvisitForStatement(ForStatementTree tree)voidvisitFunctionDeclaration(FunctionDeclarationTree tree)voidvisitFunctionExpression(FunctionExpressionTree tree)voidvisitIdentifier(IdentifierTree tree)voidvisitMethodDeclaration(MethodDeclarationTree tree)voidvisitScript(ScriptTree tree)voidvisitSwitchStatement(SwitchStatementTree tree)-
Methods inherited from class org.sonar.plugins.javascript.api.visitors.DoubleDispatchVisitor
getContext, scan, scan, scanChildren, scanTree, visitArgumentList, visitArrayAssignmentPattern, visitArrayBindingPattern, visitArrayLiteral, visitAssignmentExpression, visitAssignmentPatternRestElement, visitBinaryExpression, visitBindingProperty, visitBreakStatement, visitCallExpression, visitCaseClause, visitComment, visitComputedPropertyName, visitConditionalExpression, visitContinueStatement, visitDebugger, visitDecorator, visitDefaultClause, visitDefaultExportDeclaration, visitDoWhileStatement, visitElseClause, visitEmptyStatement, visitExportClause, visitExportDefaultBinding, visitExportDefaultBindingWithExportList, visitExportDefaultBindingWithNameSpaceExport, visitExpressionStatement, visitExtendsClause, visitFieldDeclaration, visitFinallyBlock, visitFlowArrayTypeShorthand, visitFlowArrayTypeWithKeywordTree, visitFlowCastingExpression, visitFlowDeclare, visitFlowFunctionSignature, visitFlowFunctionType, visitFlowFunctionTypeParameter, visitFlowFunctionTypeParameterClause, visitFlowGenericParameter, visitFlowGenericParameterClause, visitFlowImplementsClause, visitFlowInterfaceDeclaration, visitFlowIntersectionType, visitFlowLiteralType, visitFlowMethodPropertyDefinitionKey, visitFlowModule, visitFlowModuleExports, visitFlowNamespacedType, visitFlowObjectTypeTree, visitFlowOpaqueType, visitFlowOptionalBindingElement, visitFlowOptionalType, visitFlowParameterizedGenerics, visitFlowParenthesisedType, visitFlowPropertyType, visitFlowPropertyTypeKey, visitFlowSimpleType, visitFlowTupleType, visitFlowTypeAliasStatement, visitFlowTypeAnnotation, visitFlowTypedBindingElement, visitFlowTypeofType, visitFlowUnionType, visitFromClause, visitIfStatement, visitImport, visitImportClause, visitImportDeclaration, visitImportModuleDeclaration, visitInitializedAssignmentPatternElement, visitInitializedBindingElement, visitJsxClosingElement, visitJsxEmptyClosingElement, visitJsxEmptyOpeningElement, visitJsxIdentifier, visitJsxJavaScriptExpression, visitJsxOpeningElement, visitJsxSelfClosingElement, visitJsxShortFragmentElement, visitJsxSpreadAttribute, visitJsxStandardAttribute, visitJsxStandardElement, visitJsxText, visitLabelledStatement, visitLiteral, visitMemberExpression, visitModule, visitNamedExportDeclaration, visitNamedImportExportClause, visitNameSpaceExportDeclaration, visitNameSpaceImport, visitNewExpression, visitNewTarget, visitObjectAssignmentPattern, visitObjectAssignmentPatternPairElement, visitObjectBindingPattern, visitObjectLiteral, visitPairProperty, visitParameterList, visitParenthesisedExpression, visitRestElement, visitReturnStatement, visitSpecifier, visitSpreadElement, visitSuper, visitTaggedTemplate, visitTemplateCharacters, visitTemplateExpression, visitTemplateLiteral, visitThrowStatement, visitToken, visitTryStatement, visitUnaryExpression, visitVariableDeclaration, visitVariableStatement, visitWhileStatement, visitWithStatement, visitYieldExpression
-
-
-
-
Method Detail
-
visitScript
public void visitScript(ScriptTree tree)
- Overrides:
visitScriptin classDoubleDispatchVisitor
-
visitBlock
public void visitBlock(BlockTree tree)
- Overrides:
visitBlockin classDoubleDispatchVisitor
-
visitForStatement
public void visitForStatement(ForStatementTree tree)
- Overrides:
visitForStatementin classDoubleDispatchVisitor
-
visitForObjectStatement
public void visitForObjectStatement(ForObjectStatementTree tree)
- Overrides:
visitForObjectStatementin classDoubleDispatchVisitor
-
visitSwitchStatement
public void visitSwitchStatement(SwitchStatementTree tree)
- Overrides:
visitSwitchStatementin classDoubleDispatchVisitor
-
visitMethodDeclaration
public void visitMethodDeclaration(MethodDeclarationTree tree)
- Overrides:
visitMethodDeclarationin classDoubleDispatchVisitor
-
visitAccessorMethodDeclaration
public void visitAccessorMethodDeclaration(AccessorMethodDeclarationTree tree)
- Overrides:
visitAccessorMethodDeclarationin classDoubleDispatchVisitor
-
visitCatchBlock
public void visitCatchBlock(CatchBlockTree tree)
- Overrides:
visitCatchBlockin classDoubleDispatchVisitor
-
visitFunctionDeclaration
public void visitFunctionDeclaration(FunctionDeclarationTree tree)
- Overrides:
visitFunctionDeclarationin classDoubleDispatchVisitor
-
visitArrowFunction
public void visitArrowFunction(ArrowFunctionTree tree)
- Overrides:
visitArrowFunctionin classDoubleDispatchVisitor
-
visitFunctionExpression
public void visitFunctionExpression(FunctionExpressionTree tree)
- Overrides:
visitFunctionExpressionin classDoubleDispatchVisitor
-
visitClass
public void visitClass(ClassTree tree)
- Overrides:
visitClassin classDoubleDispatchVisitor
-
visitIdentifier
public void visitIdentifier(IdentifierTree tree)
- Overrides:
visitIdentifierin classDoubleDispatchVisitor
-
-