Class StatementVisitor
- java.lang.Object
-
- org.antlr.v4.runtime.tree.AbstractParseTreeVisitor<T>
-
- io.github.danielnaczo.python3parser.Python3BaseVisitor<T>
-
- io.github.danielnaczo.python3parser.visitors.ast.GenericUnsupportedCSTVisitor<Statement>
-
- io.github.danielnaczo.python3parser.visitors.ast.StatementVisitor
-
- All Implemented Interfaces:
Python3Visitor<Statement>,org.antlr.v4.runtime.tree.ParseTreeVisitor<Statement>
public class StatementVisitor extends GenericUnsupportedCSTVisitor<Statement>
-
-
Constructor Summary
Constructors Constructor Description StatementVisitor()
-
Method Summary
-
Methods inherited from class io.github.danielnaczo.python3parser.visitors.ast.GenericUnsupportedCSTVisitor
visitAfterPositionalArgs, visitAnd_expr, visitAnd_test, visitAnnassign, visitArglist, visitArgument, visitArgumentDoubleStar, visitArgumentKeyword, visitArgumentNormal, visitArgumentStar, visitArith_expr, visitArith_op, visitAtom, visitAtom_expr, visitAugassign, visitAwait, visitComp_for, visitComp_if, visitComp_op, visitComparison, visitCompleteArgs, visitDecorator, visitDefaultTfpdef, visitDictFirst, visitDictionaryOrSet, visitDictorsetmaker, visitDicts, visitDotted_as_name, visitDotted_as_names, visitDotted_name, visitEval_input, visitExcept_clause, visitExpr, visitExpr_NormalAssignList, visitExprlist, visitExprOrStarExpr, visitFactor, visitFactor_op, visitFile_input, visitImport_as_name, visitImport_as_names, visitJustKeywordsArgs, visitKwlistArgs1, visitKwlistArgs2, visitKwOnlyListArgs, visitLambdef, visitLambdef_nocond, visitList, visitNormalOrDefaultTfpDef, visitNot_test, visitOr_test, visitParameters, visitPositionalList, visitPower, visitSetFirst, visitSets, visitShift_expr, visitShift_op, visitSingle_input, visitSlicelLower, visitSliceStep, visitSliceUpper, visitStar_expr, visitSubscript, visitSubscriptIndex, visitSubscriptlist, visitSubscriptSlice, visitTerm, visitTerm_op, visitTest, visitTest_nocond, visitTestlist, visitTestlist_compList, visitTestlist_compTuple, visitTestlist_star_expr, visitTestOrStar_expr, visitTestOrStarList_expr, visitTfpdef, visitTrailer, visitTrailerCall, visitTrailerName, visitTrailerSubscript, visitTuple, visitTypedargslist, visitVarAfterPositionalArgs, visitVarargslist, visitVarCompleteArgs, visitVarDefaultVfpdef, visitVarJustKeywordsArgs, visitVarKwlistArgs1, visitVarKwlistArgs2, visitVarKwOnlyListArgs, visitVarNormalOrDefaultTfpDef, visitVarPositionalList, visitVfpdef, visitWith_item, visitXor_expr, visitYield_arg, visitYield_expr
-
Methods inherited from class org.antlr.v4.runtime.tree.AbstractParseTreeVisitor
aggregateResult, defaultResult, shouldVisitNextChild, visit, visitChildren, visitErrorNode, visitTerminal
-
-
-
-
Method Detail
-
visitFuncdef
public Statement visitFuncdef(Python3Parser.FuncdefContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.funcdef().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitFuncdefin interfacePython3Visitor<Statement>- Overrides:
visitFuncdefin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitStmt
public Statement visitStmt(Python3Parser.StmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitStmtin interfacePython3Visitor<Statement>- Overrides:
visitStmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitSimple_stmt
public Statement visitSimple_stmt(Python3Parser.Simple_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.simple_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitSimple_stmtin interfacePython3Visitor<Statement>- Overrides:
visitSimple_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitSmall_stmt
public Statement visitSmall_stmt(Python3Parser.Small_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.small_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitSmall_stmtin interfacePython3Visitor<Statement>- Overrides:
visitSmall_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitExpr_stmt
public Statement visitExpr_stmt(Python3Parser.Expr_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.expr_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitExpr_stmtin interfacePython3Visitor<Statement>- Overrides:
visitExpr_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitExpr_stmtIndividualAssign
public Statement visitExpr_stmtIndividualAssign(Python3Parser.Expr_stmtIndividualAssignContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.expr_stmtIndividualAssign().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitExpr_stmtIndividualAssignin interfacePython3Visitor<Statement>- Overrides:
visitExpr_stmtIndividualAssignin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitExpr_stmtNormalAssign
public Statement visitExpr_stmtNormalAssign(Python3Parser.Expr_stmtNormalAssignContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.expr_stmtNormalAssign().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitExpr_stmtNormalAssignin interfacePython3Visitor<Statement>- Overrides:
visitExpr_stmtNormalAssignin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitDel_stmt
public Statement visitDel_stmt(Python3Parser.Del_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.del_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitDel_stmtin interfacePython3Visitor<Statement>- Overrides:
visitDel_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitPass_stmt
public Statement visitPass_stmt(Python3Parser.Pass_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.pass_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitPass_stmtin interfacePython3Visitor<Statement>- Overrides:
visitPass_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitFlow_stmt
public Statement visitFlow_stmt(Python3Parser.Flow_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.flow_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitFlow_stmtin interfacePython3Visitor<Statement>- Overrides:
visitFlow_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitBreak_stmt
public Statement visitBreak_stmt(Python3Parser.Break_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.break_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitBreak_stmtin interfacePython3Visitor<Statement>- Overrides:
visitBreak_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitContinue_stmt
public Statement visitContinue_stmt(Python3Parser.Continue_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.continue_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitContinue_stmtin interfacePython3Visitor<Statement>- Overrides:
visitContinue_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitReturn_stmt
public Statement visitReturn_stmt(Python3Parser.Return_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.return_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitReturn_stmtin interfacePython3Visitor<Statement>- Overrides:
visitReturn_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitYield_stmt
public Statement visitYield_stmt(Python3Parser.Yield_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.yield_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitYield_stmtin interfacePython3Visitor<Statement>- Overrides:
visitYield_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitRaise_stmt
public Statement visitRaise_stmt(Python3Parser.Raise_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.raise_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitRaise_stmtin interfacePython3Visitor<Statement>- Overrides:
visitRaise_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitImport_stmt
public Statement visitImport_stmt(Python3Parser.Import_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.import_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitImport_stmtin interfacePython3Visitor<Statement>- Overrides:
visitImport_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitImport_name
public Statement visitImport_name(Python3Parser.Import_nameContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.import_name().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitImport_namein interfacePython3Visitor<Statement>- Overrides:
visitImport_namein classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitImport_from
public Statement visitImport_from(Python3Parser.Import_fromContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.import_from().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitImport_fromin interfacePython3Visitor<Statement>- Overrides:
visitImport_fromin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitGlobal_stmt
public Statement visitGlobal_stmt(Python3Parser.Global_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.global_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitGlobal_stmtin interfacePython3Visitor<Statement>- Overrides:
visitGlobal_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitNonlocal_stmt
public Statement visitNonlocal_stmt(Python3Parser.Nonlocal_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.nonlocal_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitNonlocal_stmtin interfacePython3Visitor<Statement>- Overrides:
visitNonlocal_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitAssert_stmt
public Statement visitAssert_stmt(Python3Parser.Assert_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.assert_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitAssert_stmtin interfacePython3Visitor<Statement>- Overrides:
visitAssert_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitCompound_stmt
public Statement visitCompound_stmt(Python3Parser.Compound_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.compound_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitCompound_stmtin interfacePython3Visitor<Statement>- Overrides:
visitCompound_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitAsync_stmt
public Statement visitAsync_stmt(Python3Parser.Async_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.async_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitAsync_stmtin interfacePython3Visitor<Statement>- Overrides:
visitAsync_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitIf_stmt
public Statement visitIf_stmt(Python3Parser.If_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.if_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitIf_stmtin interfacePython3Visitor<Statement>- Overrides:
visitIf_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitWhile_stmt
public Statement visitWhile_stmt(Python3Parser.While_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.while_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitWhile_stmtin interfacePython3Visitor<Statement>- Overrides:
visitWhile_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitFor_stmt
public Statement visitFor_stmt(Python3Parser.For_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.for_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitFor_stmtin interfacePython3Visitor<Statement>- Overrides:
visitFor_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitTry_stmt
public Statement visitTry_stmt(Python3Parser.Try_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.try_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitTry_stmtin interfacePython3Visitor<Statement>- Overrides:
visitTry_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitWith_stmt
public Statement visitWith_stmt(Python3Parser.With_stmtContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.with_stmt().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitWith_stmtin interfacePython3Visitor<Statement>- Overrides:
visitWith_stmtin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitSuite
public Statement visitSuite(Python3Parser.SuiteContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.suite().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitSuitein interfacePython3Visitor<Statement>- Overrides:
visitSuitein classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
visitClassdef
public Statement visitClassdef(Python3Parser.ClassdefContext ctx)
Description copied from class:Python3BaseVisitorVisit a parse tree produced byPython3Parser.classdef().The default implementation returns the result of calling
AbstractParseTreeVisitor.visitChildren(org.antlr.v4.runtime.tree.RuleNode)onctx.- Specified by:
visitClassdefin interfacePython3Visitor<Statement>- Overrides:
visitClassdefin classGenericUnsupportedCSTVisitor<Statement>- Parameters:
ctx- the parse tree- Returns:
- the visitor result
-
-